diff --git a/src/Resources/app/administration/src/component/adyen-notifications/index.js b/src/Resources/app/administration/src/component/adyen-notifications/index.js index 2e081bf2..ca642489 100644 --- a/src/Resources/app/administration/src/component/adyen-notifications/index.js +++ b/src/Resources/app/administration/src/component/adyen-notifications/index.js @@ -77,8 +77,8 @@ Component.register('adyen-notifications', { } }, - beforeMount() { - this.showWidget = this.adyenService.isAdyenOrder(this.order); + async beforeMount() { + this.showWidget = await this.adyenService.isAdyenOrder(this.order); if (this.showWidget) { this.fetchNotifications(); } diff --git a/src/Resources/app/administration/src/component/adyen-partial-payments/index.js b/src/Resources/app/administration/src/component/adyen-partial-payments/index.js index 66c7dea4..d658ed15 100644 --- a/src/Resources/app/administration/src/component/adyen-partial-payments/index.js +++ b/src/Resources/app/administration/src/component/adyen-partial-payments/index.js @@ -57,9 +57,9 @@ Component.register('adyen-partial-payments', { } }, - beforeMount() { + async beforeMount() { this.isVersionOlderThan65 = VersionHelper.isVersionOlderThan65(); - this.showWidget = this.adyenService.isAdyenOrder(this.order); + this.showWidget = await this.adyenService.isAdyenOrder(this.order); if (this.showWidget) { this.fetchAdyenPartialPayments(); diff --git a/src/Resources/app/administration/src/component/adyen-refund/index.js b/src/Resources/app/administration/src/component/adyen-refund/index.js index cd4639be..af83fa38 100644 --- a/src/Resources/app/administration/src/component/adyen-refund/index.js +++ b/src/Resources/app/administration/src/component/adyen-refund/index.js @@ -120,8 +120,8 @@ Component.register('adyen-refund', { }, }, - beforeMount() { - this.showWidget = this.adyenService.isAdyenOrder(this.order); + async beforeMount() { + this.showWidget = await this.adyenService.isAdyenOrder(this.order); if (this.showWidget) { this.fetchRefunds(); } diff --git a/src/Resources/app/administration/src/service/adyenService.js b/src/Resources/app/administration/src/service/adyenService.js index 9b18b896..5fac02f2 100644 --- a/src/Resources/app/administration/src/service/adyenService.js +++ b/src/Resources/app/administration/src/service/adyenService.js @@ -173,7 +173,7 @@ class ApiClient extends ApiService { }) .catch((error) => { console.error('An error occurred: ' + error.message); - throw error; + return false; }); } diff --git a/src/Resources/public/administration/css/adyen-payment-shopware6.css b/src/Resources/public/administration/css/adyen-payment-shopware6.css index 42edc958..90b0ba2e 100644 --- a/src/Resources/public/administration/css/adyen-payment-shopware6.css +++ b/src/Resources/public/administration/css/adyen-payment-shopware6.css @@ -1,4 +1,2 @@ .adyen-capture-card-header{display:flex;height:30px;margin-bottom:15px}.adyen-capture-card-header-first{margin-top:auto;width:100%} .adyen-refund-card-header{display:flex;height:30px;margin-bottom:15px}.adyen-refund-card-header-first{margin-top:auto;width:100%} - -/*# sourceMappingURL=adyen-payment-shopware6.css.map*/ \ No newline at end of file diff --git a/src/Resources/public/administration/js/adyen-payment-shopware6.js b/src/Resources/public/administration/js/adyen-payment-shopware6.js index 8e8e0ed4..985373b0 100644 --- a/src/Resources/public/administration/js/adyen-payment-shopware6.js +++ b/src/Resources/public/administration/js/adyen-payment-shopware6.js @@ -1,2 +1 @@ -(function(){var e={405:function(){},951:function(){},465:function(){let{Component:e}=Shopware,{Criteria:t}=Shopware.Data;e.extend("sw-entity-single-select-override","sw-entity-single-select",{props:{criteria:{type:Object,required:!1,default(){let e=new t(1,this.resultLimit);return e.addFilter(t.equals("stateMachine.technicalName","order_delivery.state")),e}}}})},918:function(){let e=Shopware.Classes.ApiService,{Application:t}=Shopware;class n extends e{constructor(e,t,n="adyen"){super(e,t,n),this.headers=this.getBasicHeaders({})}check(t){let n=this.getBasicHeaders({});return this.httpClient.post(`_action/${this.getApiBasePath()}/verify`,t,{headers:n}).then(t=>e.handleResponse(t))}capture(t){return this.httpClient.post(this.getApiBasePath()+"/capture",{orderId:t},{headers:this.headers}).then(t=>e.handleResponse(t)).catch(e=>{throw console.error("An error occurred during capture request: "+e.message),e})}getCaptureRequests(t){let n=this.getBasicHeaders({});return this.httpClient.get(this.getApiBasePath()+"/orders/"+t+"/captures",{headers:n}).then(t=>e.handleResponse(t)).catch(e=>{throw console.error("An error occurred during capture request: "+e.message),e})}isCaptureAllowed(t){let n=this.getBasicHeaders({});return this.httpClient.get(this.getApiBasePath()+"/orders/"+t+"/is-capture-allowed",{headers:n}).then(t=>e.handleResponse(t)).catch(e=>{throw console.error("An error occurred during is-capture-allowed request: "+e.message),e})}isManualCaptureEnabled(t){let n=this.getBasicHeaders({});return this.httpClient.get(this.getApiBasePath()+"/orders/"+t+"/is-manual-capture-enabled",{headers:n}).then(t=>e.handleResponse(t)).catch(e=>{throw console.error("An error occurred during is-capture-allowed request: "+e.message),e})}getRefunds(t){let n=this.getBasicHeaders({});return this.httpClient.get(this.getApiBasePath()+"/orders/"+t+"/refunds",{headers:n}).then(t=>e.handleResponse(t)).catch(e=>{throw console.error("An error occurred during refunds request: "+e.message),e})}postRefund(t,n){let a=this.getBasicHeaders({});return this.httpClient.post(this.getApiBasePath()+"/refunds",{orderId:t,refundAmount:n},{headers:a}).then(t=>e.handleResponse(t)).catch(e=>{throw console.error("An error occurred during post refund request: "+e.message),e})}fetchNotifications(t){let n=this.getBasicHeaders({});return this.httpClient.get(this.getApiBasePath()+"/orders/"+t+"/notifications",{headers:n}).then(t=>e.handleResponse(t)).catch(e=>{throw console.error("An error occurred: "+e.message),e})}rescheduleNotification(t){let n=this.getBasicHeaders({});return this.httpClient.get(this.getApiBasePath()+"/reschedule-notification/"+t,{headers:n}).then(t=>e.handleResponse(t)).catch(e=>{throw console.error("An error occurred: "+e.message),e})}isAdyenOrder(e){let t=e.transactions,n=!1;for(let e=0;ee.handleResponse(t)).catch(e=>{throw console.error("An error occurred: "+e.message),e})}}t.addServiceProvider("adyenService",e=>new n(t.getContainer("init").httpClient,e.loginService))},597:function(e,t,n){var a=n(405);a.__esModule&&(a=a.default),"string"==typeof a&&(a=[[e.id,a,""]]),a.locals&&(e.exports=a.locals),n(346).Z("252611c6",a,!0,{})},842:function(e,t,n){var a=n(951);a.__esModule&&(a=a.default),"string"==typeof a&&(a=[[e.id,a,""]]),a.locals&&(e.exports=a.locals),n(346).Z("3c1af017",a,!0,{})},346:function(e,t,n){"use strict";function a(e,t){for(var n=[],a={},s=0;sn.parts.length&&(a.parts.length=n.parts.length)}else{for(var i=[],s=0;s\n Test Configuration\n\n',inject:["adyenService"],mixins:[t.getByName("notification")],data(){return{isLoading:!1,isSaveSuccessful:!1}},computed:{pluginConfig(){let e=this.$parent;for(;void 0===e.actualConfigData;)e=e.$parent;let t=e.currentSalesChannelId,n=e.actualConfigData;return Object.assign({},n.null,n[t])}},methods:{saveFinish(){this.isSaveSuccessful=!1},check(){this.isLoading=!0,this.adyenService.check(this.pluginConfig).then(e=>{e.success?(this.isSaveSuccessful=!0,this.createNotificationSuccess({title:this.$tc("adyen.configTestTitle"),message:this.$tc("adyen.configTestSuccess")})):this.createNotificationError({title:this.$tc("adyen.configTestTitle"),message:this.$tc(e.message?e.message:"adyen.configTestFail")}),this.isLoading=!1})}}}),n(597);let{Component:a,Mixin:s}=Shopware;a.register("adyen-payment-capture",{template:'{% block adyen_capture %}\n \n
\n
\n
\n {{ $tc(\'adyen.noCaptureRequests\') }}\n
\n
\n \n {{ $tc(\'adyen.sendCaptureRequest\') }}\n \n
\n \n \n \n
\n \n \n
\n
\n {{ $tc(\'adyen.error\') }}\n
\n
\n{% endblock %}\n',inject:["adyenService","systemConfigApiService"],mixins:[s.getByName("notification")],props:{order:{type:Object,required:!0}},data(){return{columns:[{property:"pspReference",label:this.$tc("adyen.columnHeaders.pspReference")},{property:"amount",label:this.$tc("adyen.columnHeaders.amount")},{property:"status",label:this.$tc("adyen.columnHeaders.status")},{property:"createdAt",label:this.$tc("adyen.columnHeaders.created")},{property:"updatedAt",label:this.$tc("adyen.columnHeaders.updated")}],showModal:!1,captureRequests:[],allowCapture:!1,captureEnabled:!1,errorOccurred:!1,isLoading:!0,showWidget:!1}},methods:{openModal(){this.showModal=!0},onCloseModal(){this.showModal=!1},onSubmitCapture(){this.isLoading=!0,this.adyenService.capture(this.order.id).then(e=>{e.success?(this.fetchCaptureRequests(),this.createNotificationSuccess({title:this.$tc("adyen.adyenPaymentCaptureTitle"),message:this.$tc("adyen.captureSuccessful")})):this.createNotificationError({title:this.$tc("adyen.adyenPaymentCaptureTitle"),message:this.$tc(e.message?e.message:"adyen.error")})}).catch(()=>{this.createNotificationError({title:this.$tc("adyen.adyenPaymentCaptureTitle"),message:this.$tc("adyen.error")})}).finally(()=>{this.isLoading=!1,this.showModal=!1})},fetchCaptureRequests(){this.isLoading=!0,this.adyenService.getCaptureRequests(this.order.id).then(e=>{this.captureRequests=e,this.isCaptureAllowed()}).catch(()=>{this.errorOccurred=!0,this.captureRequests=[]}).finally(()=>{this.isLoading=!1})},isManualCaptureEnabled(){this.isLoading=!0,this.adyenService.isManualCaptureEnabled(this.order.id).then(e=>{this.captureEnabled=e,this.showWidget=this.adyenService.isAdyenOrder(this.order)&&this.captureEnabled}).catch(()=>{this.errorOccurred=!0,this.captureEnabled=!1}).finally(()=>{this.isLoading=!1})},isCaptureAllowed(){this.isLoading=!0,this.adyenService.isCaptureAllowed(this.order.id).then(e=>{this.allowCapture=e}).catch(()=>{this.errorOccurred=!0,this.allowCapture=!1}).finally(()=>{this.isLoading=!1})}},beforeMount(){this.isManualCaptureEnabled(),this.fetchCaptureRequests()}}),n(842);let{Component:r,Mixin:i}=Shopware;r.register("adyen-refund",{template:'{% block adyen_refund %}\n \n
\n
\n
\n {{ $tc(\'adyen.noRefundsCreated\') }}\n
\n
\n \n {{ $tc(\'sw-order.documentCard.labelCreateNew\') }}\n \n
\n \n
\n \n \n
\n \n
\n
\n \n \n
\n
\n {{ $tc(\'adyen.refundFetchError\') }}\n
\n
\n{% endblock %}\n',inject:["adyenService"],mixins:[i.getByName("notification")],props:{order:{type:Object,required:!0}},data(){return{columns:[{property:"pspReference",label:this.$tc("adyen.columnHeaders.pspReference")},{property:"amount",label:this.$tc("adyen.columnHeaders.amount")},{property:"status",label:this.$tc("adyen.columnHeaders.status")},{property:"createdAt",label:this.$tc("adyen.columnHeaders.created")},{property:"updatedAt",label:this.$tc("adyen.columnHeaders.updated")}],refundAmount:0,showModal:!1,refunds:[],allowRefund:!0,isLoadingTable:!0,errorOccurred:!1,isLoadingRefund:!1,showWidget:!1}},methods:{openModal(){this.showModal=!0},onCloseModal(){this.showModal=!1},onRefund(){this.isLoadingRefund=!0,this.adyenService.postRefund(this.order.id,this.refundAmount).then(e=>{e.success?(this.fetchRefunds(),this.createNotificationSuccess({title:this.$tc("adyen.refundTitle"),message:this.$tc("adyen.refundSuccessful")})):this.createNotificationError({title:this.$tc("adyen.refundTitle"),message:this.$tc(e.message?e.message:"adyen.error")})}).catch(()=>{this.createNotificationError({title:this.$tc("adyen.refundTitle"),message:this.$tc("adyen.error")})}).finally(()=>{this.isLoadingRefund=!1,this.showModal=!1})},fetchRefunds(){this.isLoadingTable=!0,this.adyenService.getRefunds(this.order.id).then(e=>{this.refunds=e,this.isRefundAllowed()}).catch(()=>{this.errorOccurred=!0,this.refunds=[]}).finally(()=>{this.isLoadingTable=!1})},isRefundAllowed(){let e=0;for(let t of this.refunds)"Failed"!==t.status&&(e+=t.rawAmount);this.allowRefund=this.order.amountTotal>e/100},isAdyenOrder(){let e=this.order.transactions,t=!1;for(let n=0;n\n \n \n {% block sw_data_grid_body_columns %}\n {% block sw_data_grid_column_actions %}\n \n {% endblock %}\n {% endblock %}\n \n

{{ $tc(\'adyen.noNotificationsReceived\') }}

\n
\n \n{% endblock %}\n',inject:["adyenService"],mixins:[d.getByName("notification")],props:{order:{type:Object,required:!0}},data(){return{notifications:[],columns:[{property:"pspReference",label:this.$tc("adyen.columnHeaders.pspReference")},{property:"eventCode",label:this.$tc("adyen.columnHeaders.event")},{property:"success",label:this.$tc("adyen.columnHeaders.success")},{property:"amount",label:this.$tc("adyen.columnHeaders.amount")},{property:"status",label:this.$tc("adyen.columnHeaders.status")},{property:"createdAt",label:this.$tc("adyen.columnHeaders.created")},{property:"updatedAt",label:this.$tc("adyen.columnHeaders.updated")},{property:"errorCount",label:this.$tc("adyen.columnHeaders.errorCount")},{property:"errorMessage",label:this.$tc("adyen.columnHeaders.errorMessage")}],showWidget:!1}},methods:{fetchNotifications(){this.adyenService.fetchNotifications(this.order.id).then(e=>{this.notifications=e})},onReschedule(e){this.adyenService.rescheduleNotification(e.notificationId).then(e=>{this.createNotificationSuccess({title:this.$tc("adyen.reprocessNotification"),message:this.$tc("adyen.notificationRescheduleSuccess")}),this.fetchNotifications()})}},beforeMount(){this.showWidget=this.adyenService.isAdyenOrder(this.order),this.showWidget&&this.fetchNotifications()}});let c={};c.isVersionOlderThan65=()=>{var e,t;return -1===(t="6.5.0.0",(e=Shopware.Context.app.config.version).startsWith(t+"-")?-1:t.startsWith(e+"-")?1:e.localeCompare(t,void 0,{numeric:!0,sensitivity:"case",caseFirst:"upper"}))};var l=c;let{Component:u}=Shopware;u.register("adyen-partial-payments",{template:'
\n
    \n
    {{ $tc(\'adyen.authorisedPayments\') }}
    \n
    \n {{ payment.pspReference }} -\n {{ payment.method }} -\n {{ payment.amount }}\n
    \n
    {{ errorMessage }}
    \n
\n
    \n \n
    \n
    \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
    \n
    \n PSP Reference\n
    \n
    \n
    \n Payment Method\n
    \n
    \n
    \n Amount\n
    \n
    \n \n \n
    \n {{ payment.method }}\n
    \n
    \n
    \n {{ payment.amount }}\n
    \n
    \n
    \n
    \n {{ errorMessage }}\n
\n
\n',inject:["adyenService"],props:{order:{type:Object,required:!0}},methods:{fetchAdyenPartialPayments(){this.adyenService.fetchAdyenPartialPayments(this.order.id).then(e=>{e.length>0?this.partialPayments=e:this.errorMessage=this.$tc("adyen.pendingWebhook")})}},data(){return{errorMessage:"",partialPayments:[],showWidget:!1,isVersionOlderThan65:!1}},beforeMount(){this.isVersionOlderThan65=l.isVersionOlderThan65(),this.showWidget=this.adyenService.isAdyenOrder(this.order),this.showWidget&&this.fetchAdyenPartialPayments()}}),Shopware.Component.override("sw-order-detail-general",{template:'{% block sw_order_detail_general_line_items_card %}\n {% parent %}\n \n \n \n{% endblock %}\n'}),Shopware.Component.override("sw-order-detail-base",{template:'{% block sw_order_detail_base_custom_fields %}\n {% parent %}\n \n \n \n{% endblock %}\n'}),Shopware.Component.override("sw-order-user-card",{template:'{% block sw_order_detail_base_secondary_info_payment %}\n {% parent %}\n\n \n{% endblock %}\n'}),Shopware.Component.override("sw-order-detail-details",{template:'{% block sw_order_detail_details_payment_method_select %}\n {% parent %}\n\n \n{% endblock %}\n'}),n(465);var h=JSON.parse('{"adyen":{"configTestTitle":"Configuration test","configTestSuccess":"Configuration is successfully tested","configTestFail":"There\'s an issue in your configuration","adyenRefunds":"Adyen Refunds","refundTitle":"Refund","refundSuccessful":"A refund has been successfully submitted.","invalidRefundAmount":"Refund amount exceeds order total","error":"An error has occurred. Please check the logs.","refundFetchError":"An error has occurred while attempting to get linked refunds.","refundConfirm":"Create refund for order","createRefund":"Create Refund","noRefundsCreated":"No refunds created","columnHeaders":{"pspReference":"PSP Reference","amount":"Amount","status":"Status","event":"Event","success":"Success","created":"Created","updated":"Updated","errorCount":"Error Count","errorMessage":"Error Message"},"reprocessNotification":"Reprocess Notification","notificationRescheduleSuccess":"Notification will be processed again.","notificationsTitle":"Adyen Webhook Notifications","noNotificationsReceived":"No webhook notifications received.","adyenPaymentCaptureTitle":"Adyen Capture Requests","noCaptureRequests":"No capture requests have been sent","sendCaptureRequest":"Send Capture Request","captureConfirm":"Capture payment for order","captureSuccessful":"Capture request has been successfully sent","pendingWebhook":"Order is pending webhook.","authorisedPayments":"Authorised Payments"}}');Shopware.Locale.extend("en-GB",h)}()})(); -//# sourceMappingURL=adyen-payment-shopware6.js.map \ No newline at end of file +(function(){var e={405:function(){},951:function(){},465:function(){let{Component:e}=Shopware,{Criteria:t}=Shopware.Data;e.extend("sw-entity-single-select-override","sw-entity-single-select",{props:{criteria:{type:Object,required:!1,default(){let e=new t(1,this.resultLimit);return e.addFilter(t.equals("stateMachine.technicalName","order_delivery.state")),e}}}})},918:function(){let e=Shopware.Classes.ApiService,{Application:t}=Shopware;class n extends e{constructor(e,t,n="adyen"){super(e,t,n),this.headers=this.getBasicHeaders({})}check(t){let n=this.getBasicHeaders({});return this.httpClient.post(`_action/${this.getApiBasePath()}/verify`,t,{headers:n}).then(t=>e.handleResponse(t))}capture(t){return this.httpClient.post(this.getApiBasePath()+"/capture",{orderId:t},{headers:this.headers}).then(t=>e.handleResponse(t)).catch(e=>{throw console.error("An error occurred during capture request: "+e.message),e})}getCaptureRequests(t){let n=this.getBasicHeaders({});return this.httpClient.get(this.getApiBasePath()+"/orders/"+t+"/captures",{headers:n}).then(t=>e.handleResponse(t)).catch(e=>{throw console.error("An error occurred during capture request: "+e.message),e})}isCaptureAllowed(t){let n=this.getBasicHeaders({});return this.httpClient.get(this.getApiBasePath()+"/orders/"+t+"/is-capture-allowed",{headers:n}).then(t=>e.handleResponse(t)).catch(e=>{throw console.error("An error occurred during is-capture-allowed request: "+e.message),e})}isManualCaptureEnabled(t){let n=this.getBasicHeaders({});return this.httpClient.get(this.getApiBasePath()+"/orders/"+t+"/is-manual-capture-enabled",{headers:n}).then(t=>e.handleResponse(t)).catch(e=>{throw console.error("An error occurred during is-capture-allowed request: "+e.message),e})}getRefunds(t){let n=this.getBasicHeaders({});return this.httpClient.get(this.getApiBasePath()+"/orders/"+t+"/refunds",{headers:n}).then(t=>e.handleResponse(t)).catch(e=>{throw console.error("An error occurred during refunds request: "+e.message),e})}postRefund(t,n){let a=this.getBasicHeaders({});return this.httpClient.post(this.getApiBasePath()+"/refunds",{orderId:t,refundAmount:n},{headers:a}).then(t=>e.handleResponse(t)).catch(e=>{throw console.error("An error occurred during post refund request: "+e.message),e})}fetchNotifications(t){let n=this.getBasicHeaders({});return this.httpClient.get(this.getApiBasePath()+"/orders/"+t+"/notifications",{headers:n}).then(t=>e.handleResponse(t)).catch(e=>{throw console.error("An error occurred: "+e.message),e})}rescheduleNotification(t){let n=this.getBasicHeaders({});return this.httpClient.get(this.getApiBasePath()+"/reschedule-notification/"+t,{headers:n}).then(t=>e.handleResponse(t)).catch(e=>{throw console.error("An error occurred: "+e.message),e})}isAdyenOrder(t){let n=this.getBasicHeaders({});return this.httpClient.get(this.getApiBasePath()+"/orders/"+t.id+"/is-adyen-order",{headers:n}).then(t=>e.handleResponse(t)).then(e=>e.status).catch(e=>(console.error("An error occurred: "+e.message),!1))}fetchAdyenPartialPayments(t){let n=this.getBasicHeaders({});return this.httpClient.get(this.getApiBasePath()+"/orders/"+t+"/partial-payments",{headers:n}).then(t=>e.handleResponse(t)).catch(e=>{throw console.error("An error occurred: "+e.message),e})}}t.addServiceProvider("adyenService",e=>new n(t.getContainer("init").httpClient,e.loginService))},597:function(e,t,n){var a=n(405);a.__esModule&&(a=a.default),"string"==typeof a&&(a=[[e.id,a,""]]),a.locals&&(e.exports=a.locals),n(346).Z("252611c6",a,!0,{})},842:function(e,t,n){var a=n(951);a.__esModule&&(a=a.default),"string"==typeof a&&(a=[[e.id,a,""]]),a.locals&&(e.exports=a.locals),n(346).Z("3c1af017",a,!0,{})},346:function(e,t,n){"use strict";function a(e,t){for(var n=[],a={},s=0;sn.parts.length&&(a.parts.length=n.parts.length)}else{for(var i=[],s=0;s\n Test Configuration\n\n',inject:["adyenService"],mixins:[t.getByName("notification")],data(){return{isLoading:!1,isSaveSuccessful:!1}},computed:{pluginConfig(){let e=this.$parent;for(;void 0===e.actualConfigData;)e=e.$parent;let t=e.currentSalesChannelId,n=e.actualConfigData;return Object.assign({},n.null,n[t])}},methods:{saveFinish(){this.isSaveSuccessful=!1},check(){this.isLoading=!0,this.adyenService.check(this.pluginConfig).then(e=>{e.success?(this.isSaveSuccessful=!0,this.createNotificationSuccess({title:this.$tc("adyen.configTestTitle"),message:this.$tc("adyen.configTestSuccess")})):this.createNotificationError({title:this.$tc("adyen.configTestTitle"),message:this.$tc(e.message?e.message:"adyen.configTestFail")}),this.isLoading=!1})}}}),n(597);let{Component:a,Mixin:s}=Shopware;a.register("adyen-payment-capture",{template:'{% block adyen_capture %}\n \n
\n
\n
\n {{ $tc(\'adyen.noCaptureRequests\') }}\n
\n
\n \n {{ $tc(\'adyen.sendCaptureRequest\') }}\n \n
\n \n \n \n
\n \n \n
\n
\n {{ $tc(\'adyen.error\') }}\n
\n
\n{% endblock %}\n',inject:["adyenService","systemConfigApiService"],mixins:[s.getByName("notification")],props:{order:{type:Object,required:!0}},data(){return{columns:[{property:"pspReference",label:this.$tc("adyen.columnHeaders.pspReference")},{property:"amount",label:this.$tc("adyen.columnHeaders.amount")},{property:"status",label:this.$tc("adyen.columnHeaders.status")},{property:"createdAt",label:this.$tc("adyen.columnHeaders.created")},{property:"updatedAt",label:this.$tc("adyen.columnHeaders.updated")}],showModal:!1,captureRequests:[],allowCapture:!1,captureEnabled:!1,errorOccurred:!1,isLoading:!0,showWidget:!1}},methods:{openModal(){this.showModal=!0},onCloseModal(){this.showModal=!1},onSubmitCapture(){this.isLoading=!0,this.adyenService.capture(this.order.id).then(e=>{e.success?(this.fetchCaptureRequests(),this.createNotificationSuccess({title:this.$tc("adyen.adyenPaymentCaptureTitle"),message:this.$tc("adyen.captureSuccessful")})):this.createNotificationError({title:this.$tc("adyen.adyenPaymentCaptureTitle"),message:this.$tc(e.message?e.message:"adyen.error")})}).catch(()=>{this.createNotificationError({title:this.$tc("adyen.adyenPaymentCaptureTitle"),message:this.$tc("adyen.error")})}).finally(()=>{this.isLoading=!1,this.showModal=!1})},fetchCaptureRequests(){this.isLoading=!0,this.adyenService.getCaptureRequests(this.order.id).then(e=>{this.captureRequests=e,this.isCaptureAllowed()}).catch(()=>{this.errorOccurred=!0,this.captureRequests=[]}).finally(()=>{this.isLoading=!1})},isManualCaptureEnabled(){this.isLoading=!0,this.adyenService.isManualCaptureEnabled(this.order.id).then(e=>{this.captureEnabled=e,this.showWidget=this.adyenService.isAdyenOrder(this.order)&&this.captureEnabled}).catch(()=>{this.errorOccurred=!0,this.captureEnabled=!1}).finally(()=>{this.isLoading=!1})},isCaptureAllowed(){this.isLoading=!0,this.adyenService.isCaptureAllowed(this.order.id).then(e=>{this.allowCapture=e}).catch(()=>{this.errorOccurred=!0,this.allowCapture=!1}).finally(()=>{this.isLoading=!1})}},beforeMount(){this.isManualCaptureEnabled(),this.fetchCaptureRequests()}}),n(842);let{Component:r,Mixin:i}=Shopware;r.register("adyen-refund",{template:'{% block adyen_refund %}\n \n
\n
\n
\n {{ $tc(\'adyen.noRefundsCreated\') }}\n
\n
\n \n {{ $tc(\'sw-order.documentCard.labelCreateNew\') }}\n \n
\n \n
\n \n \n
\n \n
\n
\n \n \n
\n
\n {{ $tc(\'adyen.refundFetchError\') }}\n
\n
\n{% endblock %}\n',inject:["adyenService"],mixins:[i.getByName("notification")],props:{order:{type:Object,required:!0}},data(){return{columns:[{property:"pspReference",label:this.$tc("adyen.columnHeaders.pspReference")},{property:"amount",label:this.$tc("adyen.columnHeaders.amount")},{property:"status",label:this.$tc("adyen.columnHeaders.status")},{property:"createdAt",label:this.$tc("adyen.columnHeaders.created")},{property:"updatedAt",label:this.$tc("adyen.columnHeaders.updated")}],refundAmount:0,showModal:!1,refunds:[],allowRefund:!0,isLoadingTable:!0,errorOccurred:!1,isLoadingRefund:!1,showWidget:!1}},methods:{openModal(){this.showModal=!0},onCloseModal(){this.showModal=!1},onRefund(){this.isLoadingRefund=!0,this.adyenService.postRefund(this.order.id,this.refundAmount).then(e=>{e.success?(this.fetchRefunds(),this.createNotificationSuccess({title:this.$tc("adyen.refundTitle"),message:this.$tc("adyen.refundSuccessful")})):this.createNotificationError({title:this.$tc("adyen.refundTitle"),message:this.$tc(e.message?e.message:"adyen.error")})}).catch(()=>{this.createNotificationError({title:this.$tc("adyen.refundTitle"),message:this.$tc("adyen.error")})}).finally(()=>{this.isLoadingRefund=!1,this.showModal=!1})},fetchRefunds(){this.isLoadingTable=!0,this.adyenService.getRefunds(this.order.id).then(e=>{this.refunds=e,this.isRefundAllowed()}).catch(()=>{this.errorOccurred=!0,this.refunds=[]}).finally(()=>{this.isLoadingTable=!1})},isRefundAllowed(){let e=0;for(let t of this.refunds)"Failed"!==t.status&&(e+=t.rawAmount);this.allowRefund=this.order.amountTotal>e/100}},async beforeMount(){this.showWidget=await this.adyenService.isAdyenOrder(this.order),this.showWidget&&this.fetchRefunds()}});let{Component:d,Mixin:o}=Shopware;d.register("adyen-notifications",{template:'{% block adyen_notifications %}\n
\n \n \n {% block sw_data_grid_body_columns %}\n {% block sw_data_grid_column_actions %}\n \n {% endblock %}\n {% endblock %}\n \n

{{ $tc(\'adyen.noNotificationsReceived\') }}

\n
\n
\n{% endblock %}\n',inject:["adyenService"],mixins:[o.getByName("notification")],props:{order:{type:Object,required:!0}},data(){return{notifications:[],columns:[{property:"pspReference",label:this.$tc("adyen.columnHeaders.pspReference")},{property:"eventCode",label:this.$tc("adyen.columnHeaders.event")},{property:"success",label:this.$tc("adyen.columnHeaders.success")},{property:"amount",label:this.$tc("adyen.columnHeaders.amount")},{property:"status",label:this.$tc("adyen.columnHeaders.status")},{property:"createdAt",label:this.$tc("adyen.columnHeaders.created")},{property:"updatedAt",label:this.$tc("adyen.columnHeaders.updated")},{property:"errorCount",label:this.$tc("adyen.columnHeaders.errorCount")},{property:"errorMessage",label:this.$tc("adyen.columnHeaders.errorMessage")}],showWidget:!1}},methods:{fetchNotifications(){this.adyenService.fetchNotifications(this.order.id).then(e=>{this.notifications=e})},onReschedule(e){this.adyenService.rescheduleNotification(e.notificationId).then(e=>{this.createNotificationSuccess({title:this.$tc("adyen.reprocessNotification"),message:this.$tc("adyen.notificationRescheduleSuccess")}),this.fetchNotifications()})}},async beforeMount(){this.showWidget=await this.adyenService.isAdyenOrder(this.order),this.showWidget&&this.fetchNotifications()}});let c={};c.isVersionOlderThan65=()=>{var e,t;return -1===(t="6.5.0.0",(e=Shopware.Context.app.config.version).startsWith(t+"-")?-1:t.startsWith(e+"-")?1:e.localeCompare(t,void 0,{numeric:!0,sensitivity:"case",caseFirst:"upper"}))};var l=c;let{Component:u}=Shopware;u.register("adyen-partial-payments",{template:'
\n
    \n
    {{ $tc(\'adyen.authorisedPayments\') }}
    \n
    \n {{ payment.pspReference }} -\n {{ payment.method }} -\n {{ payment.amount }}\n
    \n
    {{ errorMessage }}
    \n
\n
    \n \n
    \n
    \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
    \n
    \n PSP Reference\n
    \n
    \n
    \n Payment Method\n
    \n
    \n
    \n Amount\n
    \n
    \n \n \n
    \n {{ payment.method }}\n
    \n
    \n
    \n {{ payment.amount }}\n
    \n
    \n
    \n
    \n {{ errorMessage }}\n
\n
\n',inject:["adyenService"],props:{order:{type:Object,required:!0}},methods:{fetchAdyenPartialPayments(){this.adyenService.fetchAdyenPartialPayments(this.order.id).then(e=>{e.length>0?this.partialPayments=e:this.errorMessage=this.$tc("adyen.pendingWebhook")})}},data(){return{errorMessage:"",partialPayments:[],showWidget:!1,isVersionOlderThan65:!1}},async beforeMount(){this.isVersionOlderThan65=l.isVersionOlderThan65(),this.showWidget=await this.adyenService.isAdyenOrder(this.order),this.showWidget&&this.fetchAdyenPartialPayments()}}),Shopware.Component.override("sw-order-detail-general",{template:'{% block sw_order_detail_general_line_items_card %}\n {% parent %}\n \n \n \n{% endblock %}\n'}),Shopware.Component.override("sw-order-detail-base",{template:'{% block sw_order_detail_base_custom_fields %}\n {% parent %}\n \n \n \n{% endblock %}\n'}),Shopware.Component.override("sw-order-user-card",{template:'{% block sw_order_detail_base_secondary_info_payment %}\n {% parent %}\n\n \n{% endblock %}\n'}),Shopware.Component.override("sw-order-detail-details",{template:'{% block sw_order_detail_details_payment_method_select %}\n {% parent %}\n\n \n{% endblock %}\n'}),n(465);var h=JSON.parse('{"adyen":{"configTestTitle":"Configuration test","configTestSuccess":"Configuration is successfully tested","configTestFail":"There\'s an issue in your configuration","adyenRefunds":"Adyen Refunds","refundTitle":"Refund","refundSuccessful":"A refund has been successfully submitted.","invalidRefundAmount":"Refund amount exceeds order total","error":"An error has occurred. Please check the logs.","refundFetchError":"An error has occurred while attempting to get linked refunds.","refundConfirm":"Create refund for order","createRefund":"Create Refund","noRefundsCreated":"No refunds created","columnHeaders":{"pspReference":"PSP Reference","amount":"Amount","status":"Status","event":"Event","success":"Success","created":"Created","updated":"Updated","errorCount":"Error Count","errorMessage":"Error Message"},"reprocessNotification":"Reprocess Notification","notificationRescheduleSuccess":"Notification will be processed again.","notificationsTitle":"Adyen Webhook Notifications","noNotificationsReceived":"No webhook notifications received.","adyenPaymentCaptureTitle":"Adyen Capture Requests","noCaptureRequests":"No capture requests have been sent","sendCaptureRequest":"Send Capture Request","captureConfirm":"Capture payment for order","captureSuccessful":"Capture request has been successfully sent","pendingWebhook":"Order is pending webhook.","authorisedPayments":"Authorised Payments"}}');Shopware.Locale.extend("en-GB",h)}()})(); \ No newline at end of file diff --git a/src/Resources/public/static/css/adyen-payment-shopware6.css.map b/src/Resources/public/static/css/adyen-payment-shopware6.css.map deleted file mode 100644 index 773987d4..00000000 --- a/src/Resources/public/static/css/adyen-payment-shopware6.css.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"static/css/adyen-payment-shopware6.css","mappings":"AAsBA,2BACI,aACA,YACA,mBAGJ,iCACI,gBACA,W;ACRJ,0BACI,aACA,YACA,mBAGJ,gCACI,gBACA,W","sources":["webpack://administration/../../../../../adyen/adyen-shopware6/src/Resources/app/administration/src/component/adyen-payment-capture/adyen-payment-capture.scss","webpack://administration/../../../../../adyen/adyen-shopware6/src/Resources/app/administration/src/component/adyen-refund/adyen-refund.scss"],"sourcesContent":["/**\n * ######\n * ######\n * ############ ####( ###### #####. ###### ############ ############\n * ############# #####( ###### #####. ###### ############# #############\n * ###### #####( ###### #####. ###### ##### ###### ##### ######\n * ###### ###### #####( ###### #####. ###### ##### ##### ##### ######\n * ###### ###### #####( ###### #####. ###### ##### ##### ######\n * ############# ############# ############# ############# ##### ######\n * ############ ############ ############# ############ ##### ######\n * ######\n * #############\n * ############\n *\n * Adyen plugin for Shopware 6\n *\n * Copyright (c) 2022 Adyen N.V.\n * This file is open source and available under the MIT license.\n * See the LICENSE file for more info.\n *\n */\n\n.adyen-capture-card-header {\n display: flex;\n height: 30px;\n margin-bottom: 15px;\n}\n\n.adyen-capture-card-header-first {\n margin-top: auto;\n width: 100%;\n}\n","/**\n * ######\n * ######\n * ############ ####( ###### #####. ###### ############ ############\n * ############# #####( ###### #####. ###### ############# #############\n * ###### #####( ###### #####. ###### ##### ###### ##### ######\n * ###### ###### #####( ###### #####. ###### ##### ##### ##### ######\n * ###### ###### #####( ###### #####. ###### ##### ##### ######\n * ############# ############# ############# ############# ##### ######\n * ############ ############ ############# ############ ##### ######\n * ######\n * #############\n * ############\n *\n * Adyen plugin for Shopware 6\n *\n * Copyright (c) 2021 Adyen B.V.\n * This file is open source and available under the MIT license.\n * See the LICENSE file for more info.\n *\n */\n\n.adyen-refund-card-header {\n display: flex;\n height: 30px;\n margin-bottom: 15px;\n}\n\n.adyen-refund-card-header-first {\n margin-top: auto;\n width: 100%;\n}\n"],"names":[],"sourceRoot":""} \ No newline at end of file diff --git a/src/Resources/public/static/js/adyen-payment-shopware6.js.map b/src/Resources/public/static/js/adyen-payment-shopware6.js.map deleted file mode 100644 index defbb379..00000000 --- a/src/Resources/public/static/js/adyen-payment-shopware6.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"static/js/adyen-payment-shopware6.js","mappings":"oEAAA,GAAM,CAAEA,UAAAA,CAAS,CAAE,CAAGC,SAChB,CAAEC,SAAAA,CAAQ,CAAE,CAAGD,SAASE,IAAI,CAElCH,EAAUI,MAAM,CAAC,mCAAoC,0BAA2B,CAC5EC,MAAO,CACHC,SAAU,CACNC,KAAMC,OACNC,SAAU,GACVC,UACI,IAAMJ,EAAW,IAAIJ,EAAS,EAAG,IAAI,CAACS,WAAW,EAEjD,OADAL,EAASM,SAAS,CAACV,EAASW,MAAM,CAAC,6BAA8B,yBAC1DP,CACX,CACJ,CACJ,CACJ,E,iBCOA,IAAMQ,EAAab,SAASc,OAAO,CAACD,UAAU,CACxC,CAAEE,YAAAA,CAAW,CAAE,CAAGf,QAExB,O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AW,OAAQ,GAUtG,EAEA,MAAerK,ECrBf,GAAM,CAAEnE,UAAS,EAAE,CAAGC,SAItBD,EAAUqK,QAAQ,CAAC,yBAA0B,CACzCC,SC3BW,ipGD6BXC,OAAQ,CAAC,eAAe,CAExBlK,MAAO,CACH2C,MAAO,CACHzC,KAAMC,OACNC,SAAU,EACd,CACJ,EAEA8K,QAAS,CACL9H,4BACI,IAAI,CAACgI,YAAY,CAAChI,yBAAyB,CAAC,IAAI,CAACT,KAAK,CAACiB,EAAE,EAAErC,IAAI,CAAC,IACxD8J,EAAIrI,MAAM,CAAG,EACb,IAAI,CAACoL,eAAe,CAAG/C,EAEvB,IAAI,CAACgD,YAAY,CAAG,IAAI,CAAC5C,GAAG,CAAC,uBAErC,EACJ,CACJ,EAEApB,OACI,MAAO,CACHgE,aAAc,GACdD,gBAAiB,EAAE,CACnBjC,WAAY,GACZqB,qBAAsB,EAC1B,CACJ,EAEAf,cACI,IAAI,CAACe,oBAAoB,CAAGc,EAAcd,oBAAoB,GAC9D,IAAI,CAACrB,UAAU,CAAG,IAAI,CAACf,YAAY,CAAC1I,YAAY,CAAC,IAAI,CAACC,KAAK,EAEvD,IAAI,CAACwJ,UAAU,EACf,IAAI,CAAC/I,yBAAyB,EAEtC,CACJ,GEjEAxD,SAASD,SAAS,CAAC4O,QAAQ,CAAC,0BAA2B,CACnDtE,SCHW,+QDIf,GEFArK,SAASD,SAAS,CAAC4O,QAAQ,CAAC,uBAAwB,CAChDtE,SCHW,0QDIf,GEFArK,SAASD,SAAS,CAAC4O,QAAQ,CAAC,qBAAsB,CAC9CtE,SCHW,4KDIf,GEFArK,SAASD,SAAS,CAAC4O,QAAQ,CAAC,0BAA2B,CACnDtE,SCHW,uKDIf,G,o5CEgCArK,SAAS4O,MAAM,CAACzO,MAAM,CAAC,QAAS0O,E","sources":["webpack://administration/../../../../../adyen/adyen-shopware6/src/Resources/app/administration/src/component/entity/sw-entity-single-select-override/index.js","webpack://administration/../../../../../adyen/adyen-shopware6/src/Resources/app/administration/src/service/adyenService.js","webpack://administration/../../../../../adyen/adyen-shopware6/src/Resources/app/administration/src/component/adyen-payment-capture/adyen-payment-capture.scss?b32f","webpack://administration/../../../../../adyen/adyen-shopware6/src/Resources/app/administration/src/component/adyen-refund/adyen-refund.scss?fb2e","webpack://administration/./node_modules/vue-style-loader/lib/listToStyles.js","webpack://administration/./node_modules/vue-style-loader/lib/addStylesClient.js","webpack://administration/webpack/bootstrap","webpack://administration/webpack/runtime/define property getters","webpack://administration/webpack/runtime/hasOwnProperty shorthand","webpack://administration/webpack/runtime/publicPath","webpack://administration/data:text/javascript;charset=utf-8;base64,CiAgICAgICAgICAgIGlmICh3aW5kb3c/Ll9fc3dfXz8uYXNzZXRQYXRoKSB7CiAgICAgICAgICAgICAgICBfX3dlYnBhY2tfcHVibGljX3BhdGhfXyA9IHdpbmRvdy5fX3N3X18uYXNzZXRQYXRoICsgJy9idW5kbGVzL2FkeWVucGF5bWVudHNob3B3YXJlNi8nOwogICAgICAgICAgICB9CiAgICAgICAg","webpack://administration/../../../../../adyen/adyen-shopware6/src/Resources/app/administration/src/component/adyen-config-check-button/index.js","webpack://administration/../../../../../adyen/adyen-shopware6/src/Resources/app/administration/src/component/adyen-config-check-button/adyen-config-check-button.html.twig","webpack://administration/../../../../../adyen/adyen-shopware6/src/Resources/app/administration/src/component/adyen-payment-capture/index.js","webpack://administration/../../../../../adyen/adyen-shopware6/src/Resources/app/administration/src/component/adyen-payment-capture/adyen-payment-capture.html.twig","webpack://administration/../../../../../adyen/adyen-shopware6/src/Resources/app/administration/src/component/adyen-refund/index.js","webpack://administration/../../../../../adyen/adyen-shopware6/src/Resources/app/administration/src/component/adyen-refund/adyen-refund.html.twig","webpack://administration/../../../../../adyen/adyen-shopware6/src/Resources/app/administration/src/component/adyen-notifications/index.js","webpack://administration/../../../../../adyen/adyen-shopware6/src/Resources/app/administration/src/component/adyen-notifications/adyen-notifications.html.twig","webpack://administration/../../../../../adyen/adyen-shopware6/src/Resources/app/administration/src/helper/versionHelper.js","webpack://administration/../../../../../adyen/adyen-shopware6/src/Resources/app/administration/src/component/adyen-partial-payments/index.js","webpack://administration/../../../../../adyen/adyen-shopware6/src/Resources/app/administration/src/component/adyen-partial-payments/adyen-partial-payments.html.twig","webpack://administration/../../../../../adyen/adyen-shopware6/src/Resources/app/administration/src/sw-order-detail-general-override/index.js","webpack://administration/../../../../../adyen/adyen-shopware6/src/Resources/app/administration/src/sw-order-detail-general-override/sw-order-detail-general.html.twig","webpack://administration/../../../../../adyen/adyen-shopware6/src/Resources/app/administration/src/sw-order-detail-base-override/index.js","webpack://administration/../../../../../adyen/adyen-shopware6/src/Resources/app/administration/src/sw-order-detail-base-override/sw-order-detail-base.html.twig","webpack://administration/../../../../../adyen/adyen-shopware6/src/Resources/app/administration/src/sw-order-user-card-override/index.js","webpack://administration/../../../../../adyen/adyen-shopware6/src/Resources/app/administration/src/sw-order-user-card-override/sw-order-user-card.html.twig","webpack://administration/../../../../../adyen/adyen-shopware6/src/Resources/app/administration/src/sw-order-detail-details-override/index.js","webpack://administration/../../../../../adyen/adyen-shopware6/src/Resources/app/administration/src/sw-order-detail-details-override/sw-order-detail-details.html.twig","webpack://administration/../../../../../adyen/adyen-shopware6/src/Resources/app/administration/src/main.js"],"sourcesContent":["const { Component } = Shopware;\nconst { Criteria } = Shopware.Data;\n\nComponent.extend('sw-entity-single-select-override', 'sw-entity-single-select', {\n props: {\n criteria: {\n type: Object,\n required: false,\n default() {\n const criteria = new Criteria(1, this.resultLimit);\n criteria.addFilter(Criteria.equals('stateMachine.technicalName', 'order_delivery.state'));\n return criteria;\n }\n },\n }\n});\n","/**\n * ######\n * ######\n * ############ ####( ###### #####. ###### ############ ############\n * ############# #####( ###### #####. ###### ############# #############\n * ###### #####( ###### #####. ###### ##### ###### ##### ######\n * ###### ###### #####( ###### #####. ###### ##### ##### ##### ######\n * ###### ###### #####( ###### #####. ###### ##### ##### ######\n * ############# ############# ############# ############# ##### ######\n * ############ ############ ############# ############ ##### ######\n * ######\n * #############\n * ############\n *\n * Adyen plugin for Shopware 6\n *\n * Copyright (c) 2021 Adyen B.V.\n * This file is open source and available under the MIT license.\n * See the LICENSE file for more info.\n *\n */\n\nconst ApiService = Shopware.Classes.ApiService;\nconst { Application } = Shopware;\n\nclass ApiClient extends ApiService {\n constructor(httpClient, loginService, apiEndpoint = 'adyen') {\n super(httpClient, loginService, apiEndpoint);\n this.headers = this.getBasicHeaders({});\n }\n\n check(values) {\n const headers = this.getBasicHeaders({});\n\n return this.httpClient\n .post(`_action/${this.getApiBasePath()}/verify`, values,{\n headers\n })\n .then((response) => {\n return ApiService.handleResponse(response);\n });\n }\n\n capture(orderId) {\n return this.httpClient.post(\n this.getApiBasePath() + '/capture',\n { orderId },\n { headers: this.headers }\n ).then((response) => {\n return ApiService.handleResponse(response);\n }).catch((error) => {\n console.error('An error occurred during capture request: ' + error.message);\n throw error;\n });\n }\n\n getCaptureRequests(orderId) {\n const headers = this.getBasicHeaders({});\n\n return this.httpClient\n .get(this.getApiBasePath() + '/orders/' + orderId + '/captures', {\n headers\n })\n .then((response) => {\n return ApiService.handleResponse(response);\n }).catch((error) => {\n console.error('An error occurred during capture request: ' + error.message);\n throw error;\n });\n }\n\n isCaptureAllowed(orderId) {\n const headers = this.getBasicHeaders({});\n\n return this.httpClient\n .get(this.getApiBasePath() + '/orders/' + orderId + '/is-capture-allowed', {\n headers\n })\n .then((response) => {\n return ApiService.handleResponse(response);\n }).catch((error) => {\n console.error('An error occurred during is-capture-allowed request: ' + error.message);\n throw error;\n });\n }\n\n isManualCaptureEnabled(orderId) {\n const headers = this.getBasicHeaders({});\n\n return this.httpClient\n .get(this.getApiBasePath() + '/orders/' + orderId + '/is-manual-capture-enabled', {\n headers\n })\n .then((response) => {\n return ApiService.handleResponse(response);\n }).catch((error) => {\n console.error('An error occurred during is-capture-allowed request: ' + error.message);\n throw error;\n });\n }\n\n getRefunds(orderId) {\n const headers = this.getBasicHeaders({});\n\n return this.httpClient\n .get(this.getApiBasePath() + '/orders/' + orderId + '/refunds', {\n headers\n })\n .then((response) => {\n return ApiService.handleResponse(response);\n }).catch((error) => {\n console.error('An error occurred during refunds request: ' + error.message);\n throw error;\n });\n }\n\n postRefund(orderId, refundAmount) {\n const headers = this.getBasicHeaders({});\n return this.httpClient\n .post(this.getApiBasePath() + '/refunds', {orderId: orderId, refundAmount: refundAmount}, {\n headers\n })\n .then((response) => {\n return ApiService.handleResponse(response);\n\n }).catch((error) => {\n console.error('An error occurred during post refund request: ' + error.message);\n throw error;\n });\n }\n\n fetchNotifications(orderId) {\n const headers = this.getBasicHeaders({});\n\n return this.httpClient\n .get(this.getApiBasePath() + '/orders/' + orderId + '/notifications', {\n headers\n })\n .then((response) => {\n return ApiService.handleResponse(response);\n }).catch((error) => {\n console.error('An error occurred: ' + error.message);\n throw error;\n });\n }\n\n rescheduleNotification(notificationId) {\n const headers = this.getBasicHeaders({});\n\n return this.httpClient\n .get(this.getApiBasePath() + '/reschedule-notification/' + notificationId , {\n headers\n })\n .then((response) => {\n return ApiService.handleResponse(response);\n }).catch((error) => {\n console.error('An error occurred: ' + error.message);\n throw error;\n });\n }\n\n isAdyenOrder(order) {\n const orderTransactions = order.transactions;\n let isAdyen = false;\n for (let i = 0; i < orderTransactions.length; i++) {\n if (orderTransactions[i].customFields !== undefined) {\n if (orderTransactions[i].customFields.originalPspReference !== undefined) {\n isAdyen = true;\n }\n }\n }\n\n return isAdyen;\n }\n\n fetchAdyenPartialPayments(orderId) {\n const headers = this.getBasicHeaders({});\n\n return this.httpClient\n .get(this.getApiBasePath() + '/orders/' + orderId + '/partial-payments', {\n headers\n })\n .then((response) => {\n return ApiService.handleResponse(response);\n }).catch((error) => {\n console.error('An error occurred: ' + error.message);\n throw error;\n });\n }\n}\n\nApplication.addServiceProvider('adyenService', (container) => {\n const initContainer = Application.getContainer('init');\n return new ApiClient(initContainer.httpClient, container.loginService);\n});\n","// style-loader: Adds some css to the DOM by adding a