@solvimon/solvimon-web 0.1.0-alpha.20 → 0.1.0-alpha.21
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/AddPaymentMethodPane.vue_vue_type_script_setup_true_lang-B9WTpz0k.js +1 -0
- package/dist/AddPaymentMethodPane.vue_vue_type_script_setup_true_lang-DJCMa2Lz.mjs +223 -0
- package/dist/Amount.vue.es-DExaYBqm.js +1 -0
- package/dist/Amount.vue.es-DPqHB8Xd.mjs +22 -0
- package/dist/Avatar.vue.es-CJw5z7Uu.js +1 -0
- package/dist/Avatar.vue.es-ChcLSNaN.mjs +81 -0
- package/dist/BillingInformation.vue_vue_type_script_setup_true_lang-CTQ5RMtx.js +1 -0
- package/dist/BillingInformation.vue_vue_type_script_setup_true_lang-DApMAncl.mjs +60 -0
- package/dist/Button.vue.es-BWl37nzm.js +1 -0
- package/dist/Button.vue.es-VQCd3V3C.mjs +368 -0
- package/dist/Checkout.entry.ce-BTVuGyNq.js +1 -0
- package/dist/Checkout.entry.ce-DRHqEFd7.mjs +3674 -0
- package/dist/Chip.vue.es-CXG8o1Qf.mjs +114 -0
- package/dist/Chip.vue.es-DUgjuRWm.js +1 -0
- package/dist/Comparators.vue.es-CwhX3rbx.mjs +93 -0
- package/dist/Comparators.vue.es-DmkxV0gb.js +1 -0
- package/dist/ContentWithAsideLayout-Bnbsq8_5.mjs +32 -0
- package/dist/ContentWithAsideLayout-C6yMIVJF.js +1 -0
- package/dist/ContextMenu.vue.es-BllxeDTt.js +1 -0
- package/dist/ContextMenu.vue.es-C6TKlSXs.mjs +573 -0
- package/dist/CustomerBillingInformation.vue.es-CKQH_ds0.mjs +153 -0
- package/dist/CustomerBillingInformation.vue.es-CMCZ-lIM.js +1 -0
- package/dist/CustomerPaymentMethods.lib-B_753rau.mjs +4 -0
- package/dist/CustomerPaymentMethods.vue_vue_type_script_setup_true_lang-BxwllXwU.mjs +140 -0
- package/dist/CustomerPaymentMethods.vue_vue_type_script_setup_true_lang-n097Xf1H.js +1 -0
- package/dist/CustomerWalletBalances.vue_vue_type_script_setup_true_lang-C_yKvYtG.js +1 -0
- package/dist/CustomerWalletBalances.vue_vue_type_script_setup_true_lang-CtaoLbrM.mjs +2700 -0
- package/dist/Divider.vue.es-DnP_HqLz.mjs +22 -0
- package/dist/Divider.vue.es-UwnWvUTl.js +1 -0
- package/dist/DividerText.vue.es-BBdydUy_.js +1 -0
- package/dist/DividerText.vue.es-Bomiy4if.mjs +56 -0
- package/dist/EmptyStatePlaceholder.vue_vue_type_script_setup_true_lang-C9elbdbF.mjs +335 -0
- package/dist/EmptyStatePlaceholder.vue_vue_type_script_setup_true_lang-DXO9xpFT.js +1 -0
- package/dist/ErrorNotification.vue.es-0ZC_DozN.js +1 -0
- package/dist/ErrorNotification.vue.es-C6ngWAVU.mjs +31 -0
- package/dist/Expand.vue.es-BleuAfDz.mjs +32 -0
- package/dist/Expand.vue.es-BtM0EZEr.js +1 -0
- package/dist/FormMessage.vue.es-dqATjC2N.js +1 -0
- package/dist/FormMessage.vue.es-jG3fQZms.mjs +29 -0
- package/dist/IconButton.vue.es-DAR7e8NA.mjs +198 -0
- package/dist/IconButton.vue.es-DGLIdHkR.js +1 -0
- package/dist/IconTitle.vue.es-Bbusc4wK.mjs +103 -0
- package/dist/IconTitle.vue.es-D-q6w2E-.js +1 -0
- package/dist/Input.vue.es-AY1c0Rui.mjs +235 -0
- package/dist/Input.vue.es-BN95nPBw.js +1 -0
- package/dist/InvoiceDetailsBlock.vue_vue_type_script_setup_true_lang-1WjSbPEP.mjs +92 -0
- package/dist/InvoiceDetailsBlock.vue_vue_type_script_setup_true_lang-qiBCPY8l.js +1 -0
- package/dist/InvoiceEntryView.vue_vue_type_script_setup_true_lang-BXTInmf9.js +1 -0
- package/dist/InvoiceEntryView.vue_vue_type_script_setup_true_lang-D99nuBRE.mjs +41 -0
- package/dist/InvoiceSummary.vue.es-B0MPR0oI.js +1 -0
- package/dist/InvoiceSummary.vue.es-Bs5c2Ovx.mjs +2598 -0
- package/dist/Modal.vue.es-Chi6_MH_.js +1 -0
- package/dist/Modal.vue.es-DSkC4eMv.mjs +387 -0
- package/dist/PaymentErrorCard.vue_vue_type_script_setup_true_lang-Draz_8Ts.js +1 -0
- package/dist/PaymentErrorCard.vue_vue_type_script_setup_true_lang-vD88j_U7.mjs +144 -0
- package/dist/PaymentFeedbackCard.vue_vue_type_script_setup_true_lang-DVif_ME8.mjs +51 -0
- package/dist/PaymentFeedbackCard.vue_vue_type_script_setup_true_lang-Db6jAkqD.js +1 -0
- package/dist/{PaymentHistoryBlock-Ci8aSJeb.js → PaymentHistoryBlock-DGJ_PiVq.js} +1 -1
- package/dist/PaymentHistoryBlock-budeR7ep.mjs +4 -0
- package/dist/PaymentHistoryBlock.vue_vue_type_script_setup_true_lang-C28ofG7N.mjs +93 -0
- package/dist/PaymentHistoryBlock.vue_vue_type_script_setup_true_lang-Dv-3suBX.js +1 -0
- package/dist/PaymentIntegrationForm-Crrhar96.mjs +4 -0
- package/dist/{PaymentIntegrationForm-CsuueDE0.js → PaymentIntegrationForm-DqqGcEP1.js} +1 -1
- package/dist/PaymentIntegrationForm.vue_vue_type_script_setup_true_lang-C4bk0m8g.mjs +138 -0
- package/dist/PaymentIntegrationForm.vue_vue_type_script_setup_true_lang-CcEEdHQJ.js +1 -0
- package/dist/PaymentIntegrationFormAdyen-DM-xMcm0.mjs +621 -0
- package/dist/PaymentIntegrationFormAdyen-DronjwO3.js +98 -0
- package/dist/PaymentIntegrationFormStripe-yBm4KnpV.mjs +488 -0
- package/dist/PaymentIntegrationFormStripe-ybM6wirp.js +102 -0
- package/dist/PaymentMethod.vue.es-BdMcKq8_.mjs +623 -0
- package/dist/PaymentMethod.vue.es-Ctw9Es1g.js +1 -0
- package/dist/{PaymentMethodForm-hZuVHAti.js → PaymentMethodForm-BQ5TVHlS.js} +1 -1
- package/dist/PaymentMethodForm-C1bIGX10.mjs +4 -0
- package/dist/PaymentMethodForm.vue_vue_type_script_setup_true_lang-5KKkuVt5.mjs +167 -0
- package/dist/PaymentMethodForm.vue_vue_type_script_setup_true_lang-V88bCeDt.js +1 -0
- package/dist/PaymentMethodsList.vue_vue_type_script_setup_true_lang-B_207kq5.js +1 -0
- package/dist/PaymentMethodsList.vue_vue_type_script_setup_true_lang-CnmZ9dvP.mjs +169 -0
- package/dist/PlanCustomizationEditor-CCOTD6Qu.mjs +769 -0
- package/dist/PlanCustomizationEditor-CiZnVCM6.js +1 -0
- package/dist/PricingGroupRangeInput.vue.es-Bnb-ARie.mjs +627 -0
- package/dist/PricingGroupRangeInput.vue.es-D82XvoC_.js +185 -0
- package/dist/PricingGroupSingleEditor.vue_vue_type_script_setup_true_lang-CxMkCmti.js +1 -0
- package/dist/PricingGroupSingleEditor.vue_vue_type_script_setup_true_lang-skQMgHEL.mjs +131 -0
- package/dist/RadioGroupExtended.vue.es-B1YtLNKG.js +1 -0
- package/dist/RadioGroupExtended.vue.es-WDbo_yj1.mjs +163 -0
- package/dist/Section.vue.es-By1JltGi.mjs +72 -0
- package/dist/Section.vue.es-DuK52y67.js +1 -0
- package/dist/SecurePaymentsKPI.vue_vue_type_script_setup_true_lang-CS3KIkPL.mjs +687 -0
- package/dist/SecurePaymentsKPI.vue_vue_type_script_setup_true_lang-Ct3ZNq-j.js +1 -0
- package/dist/Skeleton.vue_vue_type_script_setup_true_lang-DRLoYWGY.mjs +51 -0
- package/dist/Skeleton.vue_vue_type_script_setup_true_lang-DypW8aNJ.js +1 -0
- package/dist/SubscriptionSchedules-DDCjVEbG.mjs +4 -0
- package/dist/SubscriptionSchedules-DEjIERyF.js +1 -0
- package/dist/SubscriptionSchedules.vue_vue_type_script_setup_true_lang-BlX0W6lw.js +1 -0
- package/dist/SubscriptionSchedules.vue_vue_type_script_setup_true_lang-JAedXFzq.mjs +5256 -0
- package/dist/SubscriptionSummary.vue_vue_type_script_setup_true_lang-D-Fa54M6.js +1 -0
- package/dist/SubscriptionSummary.vue_vue_type_script_setup_true_lang-DVMS4gJQ.mjs +91 -0
- package/dist/SubscriptionsList.vue_vue_type_script_setup_true_lang-BckZJtOc.mjs +284 -0
- package/dist/SubscriptionsList.vue_vue_type_script_setup_true_lang-DiXmEjUD.js +1 -0
- package/dist/TooltipParagraph.vue.es-DYu2ReL7.mjs +129 -0
- package/dist/TooltipParagraph.vue.es-sTgWAgcd.js +1 -0
- package/dist/TrialChip.vue.es-Cl-9_pdr.js +1 -0
- package/dist/TrialChip.vue.es-DX53r0ku.mjs +35 -0
- package/dist/accel.svg.es-C0hqmmEY.mjs +4 -0
- package/dist/accel.svg.es-DFJXdioD.js +1 -0
- package/dist/ach.svg.es-BYP873jU.js +1 -0
- package/dist/ach.svg.es-DduMiYM2.mjs +4 -0
- package/dist/adyen-BJfC7N6f.js +1 -0
- package/dist/adyen-Bugab0JE.mjs +4 -0
- package/dist/adyen-CvsH5fok.mjs +117 -0
- package/dist/adyen-Druit6gz.js +1 -0
- package/dist/adyenSdk-B01MB9Ia.mjs +58 -0
- package/dist/adyenSdk-BP2XXzeJ.js +1 -0
- package/dist/amazon-pay.svg.es-BACIX6C7.mjs +4 -0
- package/dist/amazon-pay.svg.es-CQWgtowB.js +1 -0
- package/dist/amex.svg.es-DKhW4Txt.js +1 -0
- package/dist/amex.svg.es-DjTEMRVg.mjs +4 -0
- package/dist/api.es-QaC926Xu.mjs +43 -0
- package/dist/api.es-duCDtZD9.js +1 -0
- package/dist/apple-pay.svg.es-B3tkA54p.mjs +4 -0
- package/dist/apple-pay.svg.es-Dyojd0F-.js +1 -0
- package/dist/bacs.svg.es-CZIjZIE8.mjs +4 -0
- package/dist/bacs.svg.es-GJpZs1sD.js +1 -0
- package/dist/bancontact.svg.es-B26-JwdE.mjs +4 -0
- package/dist/bancontact.svg.es-BQh7nAup.js +1 -0
- package/dist/carnet.svg.es-BtO3AmNu.mjs +4 -0
- package/dist/carnet.svg.es-DY04-F2L.js +1 -0
- package/dist/cartes-bancaires.svg.es-BleHMlkN.js +1 -0
- package/dist/cartes-bancaires.svg.es-DEPpdLvi.mjs +4 -0
- package/dist/cashapp.svg.es-DOGwRjXp.mjs +4 -0
- package/dist/cashapp.svg.es-MwXGYom6.js +1 -0
- package/dist/cn.es-CNvIP217.js +1 -0
- package/dist/{cn.es-BEU5D0Wz.mjs → cn.es-DjnGlmqV.mjs} +657 -927
- package/dist/comparators.es-D8WGL-c4.mjs +153 -0
- package/dist/comparators.es-OGt19O9U.js +1 -0
- package/dist/component-5wqcK7yz.mjs +8 -0
- package/dist/component-B7ZDyqBp.js +1 -0
- package/dist/components/BillingInformation/BillingInformation.cjs +1 -1
- package/dist/components/BillingInformation/BillingInformation.mjs +39 -48
- package/dist/components/BillingInformationForm/BillingInformationForm.cjs +1 -1
- package/dist/components/BillingInformationForm/BillingInformationForm.mjs +256 -307
- package/dist/components/CustomerPaymentMethods/CustomerPaymentMethods.cjs +1 -1
- package/dist/components/CustomerPaymentMethods/CustomerPaymentMethods.mjs +43 -52
- package/dist/components/Invoice/Invoice.cjs +1 -1
- package/dist/components/Invoice/Invoice.mjs +372 -430
- package/dist/components/InvoiceDetails/InvoiceDetails.cjs +1 -1
- package/dist/components/InvoiceDetails/InvoiceDetails.mjs +55 -65
- package/dist/components/InvoiceHeader/InvoiceHeader.cjs +1 -1
- package/dist/components/InvoiceHeader/InvoiceHeader.mjs +41 -46
- package/dist/components/InvoicesList/InvoicesList.cjs +1 -1
- package/dist/components/InvoicesList/InvoicesList.mjs +43 -53
- package/dist/components/PaymentHistory/PaymentHistory.cjs +1 -1
- package/dist/components/PaymentHistory/PaymentHistory.mjs +58 -68
- package/dist/components/PaymentMethodForm/PaymentMethodForm.cjs +1 -1
- package/dist/components/PaymentMethodForm/PaymentMethodForm.mjs +51 -63
- package/dist/components/SubscriptionSchedules/SubscriptionSchedules.cjs +1 -1
- package/dist/components/SubscriptionSchedules/SubscriptionSchedules.mjs +41 -50
- package/dist/components/SubscriptionsList/SubscriptionsList.cjs +1 -1
- package/dist/components/SubscriptionsList/SubscriptionsList.mjs +49 -60
- package/dist/components/WalletBalances/WalletBalances.cjs +1 -1
- package/dist/components/WalletBalances/WalletBalances.mjs +59 -70
- package/dist/configuration-BytDBAWs.mjs +14 -0
- package/dist/configuration-akTS7Wiw.js +1 -0
- package/dist/core/index.cjs +1 -1
- package/dist/core/index.mjs +89 -104
- package/dist/{countryData.es--zJAd6LA.mjs → countryData.es-BegoD-cZ.mjs} +2 -2
- package/dist/countryData.es-C4jHBzfo.js +1 -0
- package/dist/customElements-Bt8PbjIn.js +1187 -0
- package/dist/customElements-Com2NiGU.mjs +6531 -0
- package/dist/customer-CKgMJEgv.mjs +31 -0
- package/dist/customer-Q4JGfVfq.js +1 -0
- package/dist/customer.es-B5ppZf0j.mjs +20 -0
- package/dist/customer.es-BButyYo0.js +1 -0
- package/dist/dana.svg.es-BDtZLpwd.js +1 -0
- package/dist/dana.svg.es-Cy8Q6DZi.mjs +4 -0
- package/dist/dankort.svg.es-B7VqJdWq.mjs +4 -0
- package/dist/dankort.svg.es-CksaipXF.js +1 -0
- package/dist/{de-DE-CI2zQkiP.mjs → de-DE-CVCmzlNH.mjs} +5 -5
- package/dist/{de-DE-BeyQVhTv.mjs → de-DE-DBO5f-Eu.mjs} +38 -56
- package/dist/{de-DE-_40QfLNJ.js → de-DE-DqLD4IX2.js} +1 -1
- package/dist/de-DE-Ds_yJLS3.js +1 -0
- package/dist/diners.svg.es-BP9enCow.mjs +4 -0
- package/dist/diners.svg.es-D6Mu1pqP.js +1 -0
- package/dist/discover.svg.es-DEsEJBYh.mjs +4 -0
- package/dist/discover.svg.es-DgqWCMUM.js +1 -0
- package/dist/eftpos.svg.es--js6-yfk.mjs +4 -0
- package/dist/eftpos.svg.es-Dk2DOT8W.js +1 -0
- package/dist/elo.svg.es-C-BzjuRP.js +1 -0
- package/dist/elo.svg.es-CMZPAxcn.mjs +4 -0
- package/dist/{en-US-5YWNEi-V.mjs → en-US-3UmnS23B.mjs} +38 -56
- package/dist/en-US-C51ILrVv.js +1 -0
- package/dist/{en-US--NRsi7Hz.js → en-US-CvFmmI_O.js} +1 -1
- package/dist/{en-US-DksUWPIu.mjs → en-US-DVR9O7b_.mjs} +5 -5
- package/dist/eps.svg.es-B_85bP-W.js +1 -0
- package/dist/eps.svg.es-CzIPBSb9.mjs +4 -0
- package/dist/error-BHVZJGwD.mjs +13 -0
- package/dist/error-CmduqgVq.js +1 -0
- package/dist/floating-ui.vue.es-Bly3DGWm.js +1 -0
- package/dist/floating-ui.vue.es-CYt0fSY7.mjs +1108 -0
- package/dist/formatting.es-C72Nsrmh.js +1 -0
- package/dist/formatting.es-RclXHhKo.mjs +61 -0
- package/dist/gcash.svg.es-BKAdhWzv.js +1 -0
- package/dist/gcash.svg.es-BpDtvraq.mjs +4 -0
- package/dist/getComposedString.es-C__uhJpd.mjs +10 -0
- package/dist/getComposedString.es-haS4bAj7.js +1 -0
- package/dist/getCountryNameByCode.es-BDHua7VM.mjs +8 -0
- package/dist/getCountryNameByCode.es-Xxc0nZsH.js +1 -0
- package/dist/girocard.svg.es-HSOEvDif.js +1 -0
- package/dist/girocard.svg.es-Riswtk8Z.mjs +4 -0
- package/dist/go-pay.svg.es-CiIyLELZ.mjs +4 -0
- package/dist/go-pay.svg.es-DQjtunZ_.js +1 -0
- package/dist/google-pay.svg.es-Dgj_N6nz.mjs +4 -0
- package/dist/google-pay.svg.es-hzc_EgiJ.js +1 -0
- package/dist/hipercard.svg.es-B80bu8Vd.mjs +4 -0
- package/dist/hipercard.svg.es-CbCsRY2q.js +1 -0
- package/dist/icon-sprite.svg.es-Bt21fMEt.mjs +4 -0
- package/dist/icon-sprite.svg.es-Dauis9LS.js +1 -0
- package/dist/ideal.svg.es-Booz1IML.js +1 -0
- package/dist/ideal.svg.es-DaqTS2Ax.mjs +4 -0
- package/dist/index-BPU8tIml.mjs +828 -0
- package/dist/index-BPZPnOQQ.js +7 -0
- package/dist/index-CTwLxoOS.mjs +7250 -0
- package/dist/index-DwueOtPi.js +1 -0
- package/dist/index.cjs +1 -1
- package/dist/index.es-BclokHQX.js +1 -0
- package/dist/index.es-CXkP_k3u.mjs +345 -0
- package/dist/index.mjs +40 -40
- package/dist/invoices-CV9iAUHf.mjs +115 -0
- package/dist/invoices-CvpL4rv5.js +1 -0
- package/dist/{it-IT-CMy1tHKZ.mjs → it-IT-CDMnnFKZ.mjs} +5 -5
- package/dist/{it-IT-aPQY57ht.js → it-IT-CFEfSpPH.js} +1 -1
- package/dist/{it-IT-B6blp8MI.mjs → it-IT-CxBRisRm.mjs} +38 -56
- package/dist/it-IT-Dxw59eR_.js +1 -0
- package/dist/jcb.svg.es-B3WPB8c2.js +1 -0
- package/dist/jcb.svg.es-Couw-2p9.mjs +4 -0
- package/dist/kakao-pay.svg.es-CIFT8fob.mjs +4 -0
- package/dist/kakao-pay.svg.es-Cs-lCW74.js +1 -0
- package/dist/klarna.svg.es-Cs6XaHD7.js +1 -0
- package/dist/klarna.svg.es-WKt8_NZa.mjs +4 -0
- package/dist/maestro.svg.es-BvK4oPg4.js +1 -0
- package/dist/maestro.svg.es-DbdxwYUE.mjs +4 -0
- package/dist/mastercard.svg.es-B7T3PS12.mjs +4 -0
- package/dist/mastercard.svg.es-lp4AXyyV.js +1 -0
- package/dist/momo.svg.es-C5aLYf_R.js +1 -0
- package/dist/momo.svg.es-X5XB25fM.mjs +4 -0
- package/dist/{nl-NL-CjoW8r_M.mjs → nl-NL-BWGkVweu.mjs} +38 -56
- package/dist/nl-NL-Btbfd9p2.js +1 -0
- package/dist/{nl-NL-zRUAuEHg.js → nl-NL-jtVgF3jx.js} +1 -1
- package/dist/{nl-NL-CckNM7R9.mjs → nl-NL-o3UvtSNg.mjs} +5 -5
- package/dist/nyce.svg.es-ArAivAZW.js +1 -0
- package/dist/nyce.svg.es-DcPsO_sh.mjs +4 -0
- package/dist/object.es-8aLDIncs.mjs +12 -0
- package/dist/object.es-CdriXMPs.js +1 -0
- package/dist/open-banking.svg.es-C4mPhwsn.mjs +4 -0
- package/dist/open-banking.svg.es-Q3rRkCvP.js +1 -0
- package/dist/paymentMethods-BuwoJ1y9.mjs +75 -0
- package/dist/paymentMethods-ChWAwDSF.js +1 -0
- package/dist/payments-C_cMXQzE.mjs +45 -0
- package/dist/payments-DGckugN0.js +1 -0
- package/dist/paypal.svg.es-BC2AP20j.mjs +4 -0
- package/dist/paypal.svg.es-Cjp5sNI3.js +1 -0
- package/dist/pricing-BVAld27Y.js +1 -0
- package/dist/pricing-DLOeiAIB.mjs +16 -0
- package/dist/pricingItemConfigs.es-DMf1e6y7.mjs +76 -0
- package/dist/pricingItemConfigs.es-DlybwIh1.js +1 -0
- package/dist/pricingPlanSchedule-COfmWv_o.js +1 -0
- package/dist/pricingPlanSchedule-J1nb9pCu.mjs +129 -0
- package/dist/pulse.svg.es-Dit33E8S.js +1 -0
- package/dist/pulse.svg.es-Rmoz-9Ej.mjs +4 -0
- package/dist/screens/Checkout/Checkout.cjs +1 -1
- package/dist/screens/Checkout/Checkout.mjs +3 -5237
- package/dist/screens/CustomerOverview/CustomerOverview.cjs +1 -1
- package/dist/screens/CustomerOverview/CustomerOverview.mjs +112 -138
- package/dist/screens/PayInvoice/PayInvoice.cjs +1 -1
- package/dist/screens/PayInvoice/PayInvoice.mjs +348 -397
- package/dist/screens/PaymentMethodsManagement/PaymentMethodsManagement.cjs +1 -1
- package/dist/screens/PaymentMethodsManagement/PaymentMethodsManagement.mjs +153 -170
- package/dist/screens/SubscriptionDetails/SubscriptionDetails.cjs +1 -1
- package/dist/screens/SubscriptionDetails/SubscriptionDetails.mjs +609 -720
- package/dist/screens/SubscriptionManagement/SubscriptionManagement.cjs +1 -1
- package/dist/screens/SubscriptionManagement/SubscriptionManagement.mjs +466 -555
- package/dist/sepa.svg.es-0t4DKeA1.js +1 -0
- package/dist/sepa.svg.es-DIO_K345.mjs +4 -0
- package/dist/slots.es-BA4MyEAa.mjs +5 -0
- package/dist/slots.es-T9ZJRGtG.js +1 -0
- package/dist/sorting.es-DCihKqD2.mjs +77 -0
- package/dist/sorting.es-DQsjKr8A.js +1 -0
- package/dist/star.svg.es-BUZNUnYq.mjs +4 -0
- package/dist/star.svg.es-D2JncY7b.js +1 -0
- package/dist/subscription-9GORG-Gt.js +1 -0
- package/dist/subscription-CvfAEJeP.mjs +69 -0
- package/dist/subscriptions-B5VqRayX.mjs +55 -0
- package/dist/subscriptions-X0Ciw8z3.js +1 -0
- package/dist/trustly.svg.es-AM7Ha-3Y.mjs +4 -0
- package/dist/trustly.svg.es-GJByiFAs.js +1 -0
- package/dist/twint.svg.es-BJ2f48og.js +1 -0
- package/dist/twint.svg.es-DZogAQG6.mjs +4 -0
- package/dist/typeGuards.es-B4XMtlkM.mjs +8 -0
- package/dist/typeGuards.es-DS3vZaJn.js +1 -0
- package/dist/types/components/payments/PaymentCompletedCard/PaymentCompletedCard.types.d.ts +6 -0
- package/dist/types/components/payments/PaymentIntegrationForm/PaymentIntegrationForm.types.d.ts +7 -0
- package/dist/types/components/payments/PaymentIntegrationFormStripe/PaymentIntegrationFormStripeFrame.types.d.ts +2 -1
- package/dist/types/public/components/PaymentMethodForm/PaymentMethodForm.types.d.ts +7 -0
- package/dist/unionpay.svg.es-DjFZ5EMQ.js +1 -0
- package/dist/unionpay.svg.es-me7q-nTI.mjs +4 -0
- package/dist/url-BNKStNY9.js +1 -0
- package/dist/url-DwiuKYpu.mjs +20 -0
- package/dist/useActionDispatchProvider-B54GYEY7.js +1 -0
- package/dist/useActionDispatchProvider-e2lQXTid.mjs +11 -0
- package/dist/useCustomer-BJwJ9BkJ.js +1 -0
- package/dist/useCustomer-CC9zxV6c.mjs +20 -0
- package/dist/useCustomerFormLabels-72Pxw8X5.js +1 -0
- package/dist/useCustomerFormLabels-V2YuYMLU.mjs +930 -0
- package/dist/useExperimentalFeature-8Mzpj5wc.js +1 -0
- package/dist/useExperimentalFeature-B0IFn3Uw.mjs +6 -0
- package/dist/useIncrementalLoading-CaWOE8Xl.js +1 -0
- package/dist/useIncrementalLoading-Cgxw2GD7.mjs +48 -0
- package/dist/useInvoiceData-6mHUZC9a.mjs +38 -0
- package/dist/useInvoiceData-Bblwdl0f.js +1 -0
- package/dist/useInvoicesList-B5H5JfvY.mjs +500 -0
- package/dist/useInvoicesList-_U1-tn9_.js +1 -0
- package/dist/useLoadInitialData-CezlvhBV.js +1 -0
- package/dist/useLoadInitialData-ux_wpNiR.mjs +15 -0
- package/dist/usePaymentMethodAvailability-CkR4TwoV.mjs +118 -0
- package/dist/usePaymentMethodAvailability-DRwrBdto.js +1 -0
- package/dist/usePaymentMethodOptions-B6GIM9q4.js +1 -0
- package/dist/usePaymentMethodOptions-BfnLBZOo.mjs +37 -0
- package/dist/usePaymentMethods-C3QfLSrP.mjs +15 -0
- package/dist/usePaymentMethods-GFmQRp0X.js +1 -0
- package/dist/usePayments-BkwGyZT0.mjs +318 -0
- package/dist/usePayments-SQF_V7oL.js +1 -0
- package/dist/usePortal-BdM7hDge.js +1 -0
- package/dist/usePortal-DDG9b6FI.mjs +11 -0
- package/dist/useService-Bh47bllz.mjs +50 -0
- package/dist/useService-H7BjLg8P.js +1 -0
- package/dist/useSubscription-BJJYHYgr.mjs +210 -0
- package/dist/useSubscription-Q4C2DPhw.js +1 -0
- package/dist/useTimePeriod.es-9tZvAhyb.mjs +93 -0
- package/dist/useTimePeriod.es-pepm2TpV.js +1 -0
- package/dist/useViewport-BgdA2PPt.mjs +29 -0
- package/dist/useViewport-hPRVDWCm.js +1 -0
- package/dist/useWatchDebounced-CAU1WI1P.js +1 -0
- package/dist/useWatchDebounced-DT5IicPp.mjs +14 -0
- package/dist/visa.svg.es-B0T5Su99.mjs +4 -0
- package/dist/visa.svg.es-NY3BHhda.js +1 -0
- package/dist/vpay.svg.es-VViQi42w.js +1 -0
- package/dist/vpay.svg.es-Zt3rrmCy.mjs +4 -0
- package/dist/zip.svg.es-C9S_F31W.js +1 -0
- package/dist/zip.svg.es-QC6dxzC7.mjs +4 -0
- package/package.json +3 -3
- package/dist/AddPaymentMethodPane.vue_vue_type_script_setup_true_lang-Ce30EXY5.mjs +0 -240
- package/dist/AddPaymentMethodPane.vue_vue_type_script_setup_true_lang-kmam2c7P.js +0 -1
- package/dist/Amount.vue.es-BO5sS1UX.mjs +0 -25
- package/dist/Amount.vue.es-JDVa_3H-.js +0 -1
- package/dist/Avatar.vue.es-BGTZSAqU.js +0 -1
- package/dist/Avatar.vue.es-DJzJiYtv.mjs +0 -91
- package/dist/BillingInformation.vue_vue_type_script_setup_true_lang-Bq2mTdUs.mjs +0 -66
- package/dist/BillingInformation.vue_vue_type_script_setup_true_lang-BtNTRSqH.js +0 -1
- package/dist/Button.vue.es-Cm9pLU9i.mjs +0 -421
- package/dist/Button.vue.es-O8mNivLL.js +0 -1
- package/dist/Chip.vue.es-BBmn-qJp.mjs +0 -120
- package/dist/Chip.vue.es-DmCjC1hi.js +0 -1
- package/dist/Comparators.vue.es-CYfxd5H-.mjs +0 -120
- package/dist/Comparators.vue.es-DK8wGjxM.js +0 -1
- package/dist/ContentWithAsideLayout-DHpnJfGA.js +0 -1
- package/dist/ContentWithAsideLayout-Dy9xgxuF.mjs +0 -39
- package/dist/ContextMenu.vue.es-CTc1ktXb.mjs +0 -681
- package/dist/ContextMenu.vue.es-DaW0yp4Y.js +0 -1
- package/dist/CustomerBillingInformation.vue.es-BX0Da7Kr.js +0 -1
- package/dist/CustomerBillingInformation.vue.es-CMZO8oLj.mjs +0 -175
- package/dist/CustomerPaymentMethods.lib-CcSt0sl1.mjs +0 -4
- package/dist/CustomerPaymentMethods.vue_vue_type_script_setup_true_lang-Bi_dCntQ.js +0 -1
- package/dist/CustomerPaymentMethods.vue_vue_type_script_setup_true_lang-CtdFharm.mjs +0 -150
- package/dist/CustomerWalletBalances.vue_vue_type_script_setup_true_lang-BDqBXbJq.mjs +0 -3264
- package/dist/CustomerWalletBalances.vue_vue_type_script_setup_true_lang-ZyN2vlNu.js +0 -1
- package/dist/Divider.vue.es-ClFG8QtG.js +0 -1
- package/dist/Divider.vue.es-wKkIVBgb.mjs +0 -24
- package/dist/DividerText.vue.es-CeAHAe_Y.mjs +0 -72
- package/dist/DividerText.vue.es-DjT4i_YD.js +0 -1
- package/dist/EmptyStatePlaceholder.vue_vue_type_script_setup_true_lang-DLE5-9wz.mjs +0 -562
- package/dist/EmptyStatePlaceholder.vue_vue_type_script_setup_true_lang-DkIK-lID.js +0 -1
- package/dist/ErrorNotification.vue.es-CHyVTBGs.mjs +0 -38
- package/dist/ErrorNotification.vue.es-CaEFTi2k.js +0 -1
- package/dist/Expand.vue.es-C-lnbA1v.js +0 -1
- package/dist/Expand.vue.es-C4_XmqbR.mjs +0 -50
- package/dist/FormMessage.vue.es-Bd4_NG9H.js +0 -1
- package/dist/FormMessage.vue.es-C3oxwq_8.mjs +0 -46
- package/dist/IconButton.vue.es-BHdQskx0.js +0 -1
- package/dist/IconButton.vue.es-KywqWWvr.mjs +0 -228
- package/dist/IconTitle.vue.es-BmjBdZb_.mjs +0 -107
- package/dist/IconTitle.vue.es-D9Wc3PIq.js +0 -1
- package/dist/Input.vue.es-DqKJhFTr.js +0 -1
- package/dist/Input.vue.es-WZGF8dfr.mjs +0 -251
- package/dist/InvoiceDetailsBlock.vue_vue_type_script_setup_true_lang-B6efz7NU.mjs +0 -97
- package/dist/InvoiceDetailsBlock.vue_vue_type_script_setup_true_lang-LE6zBLKM.js +0 -1
- package/dist/InvoiceEntryView.vue_vue_type_script_setup_true_lang-C2aLMfu6.mjs +0 -49
- package/dist/InvoiceEntryView.vue_vue_type_script_setup_true_lang-CtpFzWU3.js +0 -1
- package/dist/InvoiceSummary.vue.es-BI5sD_8F.mjs +0 -2944
- package/dist/InvoiceSummary.vue.es-BWYIHezU.js +0 -1
- package/dist/Modal.vue.es-B_1aqm_m.js +0 -1
- package/dist/Modal.vue.es-qdUHDOnU.mjs +0 -483
- package/dist/PaymentErrorCard.vue_vue_type_script_setup_true_lang-BKKXQbge.js +0 -1
- package/dist/PaymentErrorCard.vue_vue_type_script_setup_true_lang-Ch1TFO7x.mjs +0 -154
- package/dist/PaymentFeedbackCard.vue_vue_type_script_setup_true_lang-CsH47WSM.mjs +0 -54
- package/dist/PaymentFeedbackCard.vue_vue_type_script_setup_true_lang-mKNNYnMU.js +0 -1
- package/dist/PaymentHistoryBlock-CgNUV8Gy.mjs +0 -4
- package/dist/PaymentHistoryBlock.vue_vue_type_script_setup_true_lang-DZwnDzha.js +0 -1
- package/dist/PaymentHistoryBlock.vue_vue_type_script_setup_true_lang-Uj1aK-dp.mjs +0 -101
- package/dist/PaymentIntegrationForm-CLokpXvK.mjs +0 -4
- package/dist/PaymentIntegrationForm.vue_vue_type_script_setup_true_lang-CRUs7sP4.mjs +0 -167
- package/dist/PaymentIntegrationForm.vue_vue_type_script_setup_true_lang-kKkzRi6w.js +0 -1
- package/dist/PaymentIntegrationFormAdyen-C885o8IE.mjs +0 -699
- package/dist/PaymentIntegrationFormAdyen-Co19AgvG.js +0 -1
- package/dist/PaymentIntegrationFormStripe-BjMdJmDC.mjs +0 -547
- package/dist/PaymentIntegrationFormStripe-DWff6wzK.js +0 -1
- package/dist/PaymentMethod.vue.es-CdskNJ3Z.js +0 -1
- package/dist/PaymentMethod.vue.es-rv-pu1CC.mjs +0 -677
- package/dist/PaymentMethodForm-IEuDxEPN.mjs +0 -4
- package/dist/PaymentMethodForm.vue_vue_type_script_setup_true_lang-Cj60U90J.js +0 -1
- package/dist/PaymentMethodForm.vue_vue_type_script_setup_true_lang-gA74Rak9.mjs +0 -172
- package/dist/PaymentMethodsList.vue_vue_type_script_setup_true_lang-B3H_AWMM.js +0 -1
- package/dist/PaymentMethodsList.vue_vue_type_script_setup_true_lang-CTn-OxM6.mjs +0 -189
- package/dist/PricingGroupRangeInput.vue.es-ButaePib.mjs +0 -632
- package/dist/PricingGroupRangeInput.vue.es-Cls2lm80.js +0 -1
- package/dist/Section.vue.es-CAJvEDn6.js +0 -1
- package/dist/Section.vue.es-DX_9ueCG.mjs +0 -79
- package/dist/SecurePaymentsKPI.vue_vue_type_script_setup_true_lang-CQAkPfJz.js +0 -1
- package/dist/SecurePaymentsKPI.vue_vue_type_script_setup_true_lang-DVtMzgjc.mjs +0 -1044
- package/dist/Skeleton.vue_vue_type_script_setup_true_lang-DGMxHc20.mjs +0 -78
- package/dist/Skeleton.vue_vue_type_script_setup_true_lang-DfMgIsGm.js +0 -1
- package/dist/SubscriptionSchedules.vue_vue_type_script_setup_true_lang-BJVXCHny.js +0 -1
- package/dist/SubscriptionSchedules.vue_vue_type_script_setup_true_lang-ByO-L6nm.mjs +0 -6171
- package/dist/SubscriptionSummary.vue_vue_type_script_setup_true_lang-C5zB3CgZ.mjs +0 -101
- package/dist/SubscriptionSummary.vue_vue_type_script_setup_true_lang-CabskT-r.js +0 -1
- package/dist/SubscriptionsList.vue_vue_type_script_setup_true_lang-D-T1wGg7.js +0 -1
- package/dist/SubscriptionsList.vue_vue_type_script_setup_true_lang-DKd2DIVb.mjs +0 -309
- package/dist/TooltipParagraph.vue.es-C5RTcrid.mjs +0 -136
- package/dist/TooltipParagraph.vue.es-H9fI7zzt.js +0 -1
- package/dist/TrialChip.vue.es-B1puKyR-.mjs +0 -56
- package/dist/TrialChip.vue.es-CCs50m02.js +0 -1
- package/dist/accel.svg.es-CE5tIWtm.mjs +0 -4
- package/dist/accel.svg.es-Dt_1wJmV.js +0 -1
- package/dist/ach.svg.es-B4tn0_IV.js +0 -1
- package/dist/ach.svg.es-D4QPcIU-.mjs +0 -4
- package/dist/adyen-51SvcyqV.mjs +0 -4
- package/dist/adyen-BXi_D9TQ.mjs +0 -123
- package/dist/adyen-DZsyEXkw.js +0 -1
- package/dist/adyen-VS2sDW0m.js +0 -1
- package/dist/amazon-pay.svg.es-B428S4f3.js +0 -1
- package/dist/amazon-pay.svg.es-DUScOW15.mjs +0 -4
- package/dist/amex.svg.es-BCXkaVLN.mjs +0 -4
- package/dist/amex.svg.es-Bn9e31C3.js +0 -1
- package/dist/api.es-C5pe8LUl.mjs +0 -62
- package/dist/api.es-Czekkp_X.js +0 -1
- package/dist/apple-pay.svg.es-Cfgn0K28.js +0 -1
- package/dist/apple-pay.svg.es-DlCfkt39.mjs +0 -4
- package/dist/bacs.svg.es-BKsvSeIP.mjs +0 -4
- package/dist/bacs.svg.es-hL7hLPkQ.js +0 -1
- package/dist/bancontact.svg.es-BbRqGgZ9.mjs +0 -4
- package/dist/bancontact.svg.es-DU2ejvNL.js +0 -1
- package/dist/carnet.svg.es-C5SFaOsa.js +0 -1
- package/dist/carnet.svg.es-Db-KEb13.mjs +0 -4
- package/dist/cartes-bancaires.svg.es-ByD-JAAi.mjs +0 -4
- package/dist/cartes-bancaires.svg.es-CbBJQZrk.js +0 -1
- package/dist/cashapp.svg.es-CnS5r_D8.mjs +0 -4
- package/dist/cashapp.svg.es-DE4vMu_p.js +0 -1
- package/dist/cn.es-DxSeYcoP.js +0 -1
- package/dist/comparators.es-9VsCB-JI.mjs +0 -175
- package/dist/comparators.es-wrKHduVq.js +0 -1
- package/dist/component-BG6DmXcy.mjs +0 -9
- package/dist/component-hDuDTBt5.js +0 -1
- package/dist/configuration-BjYwV4_B.js +0 -1
- package/dist/configuration-CD8cOXAJ.mjs +0 -15
- package/dist/countryData.es-D3MFzU92.js +0 -1
- package/dist/customElements-B-89a5oH.mjs +0 -6810
- package/dist/customElements-DD7bpqkx.js +0 -1
- package/dist/customer-DozNwS_a.js +0 -1
- package/dist/customer-Dzj1g9lV.mjs +0 -32
- package/dist/customer.es-C_vSWcVA.mjs +0 -30
- package/dist/customer.es-D42Md24r.js +0 -1
- package/dist/dana.svg.es-Bbn6_ktN.mjs +0 -4
- package/dist/dana.svg.es-DKZaseoJ.js +0 -1
- package/dist/dankort.svg.es-D8FgSiFf.js +0 -1
- package/dist/dankort.svg.es-DtAdliQq.mjs +0 -4
- package/dist/de-DE-BvHD68Ay.js +0 -1
- package/dist/diners.svg.es-DhchsD1D.mjs +0 -4
- package/dist/diners.svg.es-SydF_H-Z.js +0 -1
- package/dist/discover.svg.es-B8vgzVNG.js +0 -1
- package/dist/discover.svg.es-BnqYPvnV.mjs +0 -4
- package/dist/eftpos.svg.es-DO0YPaY1.js +0 -1
- package/dist/eftpos.svg.es-DRLaafYa.mjs +0 -4
- package/dist/elo.svg.es-CTOm1rvj.js +0 -1
- package/dist/elo.svg.es-CgkEOP_O.mjs +0 -4
- package/dist/en-US-dqfKx3GS.js +0 -1
- package/dist/eps.svg.es-CApyGjyU.js +0 -1
- package/dist/eps.svg.es-D6IHsRYP.mjs +0 -4
- package/dist/error-Cg-i7gGl.js +0 -1
- package/dist/error-DY_I2hPx.mjs +0 -13
- package/dist/floating-ui.vue.es-Bv94BfDm.js +0 -1
- package/dist/floating-ui.vue.es-DWY7pdz8.mjs +0 -1573
- package/dist/formatting.es-DBtYnvI5.js +0 -1
- package/dist/formatting.es-eYgXv_AK.mjs +0 -70
- package/dist/gcash.svg.es-BhJ-eA2z.mjs +0 -4
- package/dist/gcash.svg.es-JaL4fpZr.js +0 -1
- package/dist/getComposedString.es-CELkn0I7.mjs +0 -14
- package/dist/getComposedString.es-DvSNX-_z.js +0 -1
- package/dist/getCountryNameByCode.es-fP52nO_7.js +0 -1
- package/dist/getCountryNameByCode.es-ymC9R46j.mjs +0 -8
- package/dist/girocard.svg.es-D_3LML4l.mjs +0 -4
- package/dist/girocard.svg.es-tVgtT23w.js +0 -1
- package/dist/go-pay.svg.es-6UtgwVBA.mjs +0 -4
- package/dist/go-pay.svg.es-fYX6yMzJ.js +0 -1
- package/dist/google-pay.svg.es-BYXX1em8.js +0 -1
- package/dist/google-pay.svg.es-CRxXgFVl.mjs +0 -4
- package/dist/hipercard.svg.es-Ct1-mF9F.mjs +0 -4
- package/dist/hipercard.svg.es-D-nmiFXB.js +0 -1
- package/dist/icon-sprite.svg.es-BpwT0GQ5.js +0 -1
- package/dist/icon-sprite.svg.es-YYqtl2IP.mjs +0 -4
- package/dist/ideal.svg.es-D23EhJJ2.mjs +0 -4
- package/dist/ideal.svg.es-DXtHE0Jb.js +0 -1
- package/dist/index-Cai7laNY.mjs +0 -1069
- package/dist/index-DIFK3mcJ.js +0 -6
- package/dist/index-DyvRdSR7.mjs +0 -9673
- package/dist/index-IZaUTAsE.js +0 -1
- package/dist/index.es-2JWHHSgP.js +0 -1
- package/dist/index.es-D5xOw_SJ.mjs +0 -542
- package/dist/invoices-1oYkdQQV.mjs +0 -121
- package/dist/invoices-BAoh6X2a.js +0 -1
- package/dist/it-IT-CEP3oeWs.js +0 -1
- package/dist/jcb.svg.es-Bz6J-c0s.js +0 -1
- package/dist/jcb.svg.es-CcH08OoO.mjs +0 -4
- package/dist/kakao-pay.svg.es-DcgRDAsc.mjs +0 -4
- package/dist/kakao-pay.svg.es-qVTABboW.js +0 -1
- package/dist/klarna.svg.es-Clu-7zkp.js +0 -1
- package/dist/klarna.svg.es-DfIPX0gr.mjs +0 -4
- package/dist/maestro.svg.es-CVmNVokN.mjs +0 -4
- package/dist/maestro.svg.es-e8E_H2QU.js +0 -1
- package/dist/mastercard.svg.es-B8z0ZySS.mjs +0 -4
- package/dist/mastercard.svg.es-YO3_jGD6.js +0 -1
- package/dist/momo.svg.es-BXTQlQRy.js +0 -1
- package/dist/momo.svg.es-Bm5zCTOT.mjs +0 -4
- package/dist/nl-NL-e_vf6OuT.js +0 -1
- package/dist/nyce.svg.es-CgurqLKH.mjs +0 -4
- package/dist/nyce.svg.es-DM6esO47.js +0 -1
- package/dist/object.es-DFXiU9p3.js +0 -1
- package/dist/object.es-jvvnR8Kr.mjs +0 -12
- package/dist/open-banking.svg.es-DUM360xB.js +0 -1
- package/dist/open-banking.svg.es-DzzLCVp_.mjs +0 -4
- package/dist/paymentMethods-CZ3ydybI.js +0 -1
- package/dist/paymentMethods-DIV78w0O.mjs +0 -78
- package/dist/payments--lkjiwCt.js +0 -1
- package/dist/payments-Cvqdrprv.mjs +0 -47
- package/dist/paypal.svg.es-BdkNTf3c.js +0 -1
- package/dist/paypal.svg.es-DltWzW4V.mjs +0 -4
- package/dist/pricing-3W7XLwL6.js +0 -1
- package/dist/pricing-CJxS2hr2.mjs +0 -17
- package/dist/pricingItemConfigs.es-BPIm6S8M.mjs +0 -107
- package/dist/pricingItemConfigs.es-C73cQlxQ.js +0 -1
- package/dist/pricingPlanSchedule-B9HFiXy-.js +0 -1
- package/dist/pricingPlanSchedule-CXG3CQ61.mjs +0 -146
- package/dist/pulse.svg.es-BdpWAuIN.js +0 -1
- package/dist/pulse.svg.es-BecAwT-p.mjs +0 -4
- package/dist/sepa.svg.es-BF8PYKZg.js +0 -1
- package/dist/sepa.svg.es-cbE9g8gV.mjs +0 -4
- package/dist/slots.es-BpwYO3A3.mjs +0 -18
- package/dist/slots.es-Dq1PTUOv.js +0 -1
- package/dist/sorting.es-CjTrRfSW.mjs +0 -105
- package/dist/sorting.es-RyvcgbSL.js +0 -1
- package/dist/star.svg.es-DsCD-tSp.mjs +0 -4
- package/dist/star.svg.es-Q50IzqXr.js +0 -1
- package/dist/subscription-C41lG-rH.mjs +0 -89
- package/dist/subscription-b0OPx8Du.js +0 -1
- package/dist/subscriptions-300o4ae0.js +0 -1
- package/dist/subscriptions-DcMHBPVJ.mjs +0 -58
- package/dist/trustly.svg.es-C0Ou1HWk.mjs +0 -4
- package/dist/trustly.svg.es-CHojqNqm.js +0 -1
- package/dist/twint.svg.es-CQ-ZDfy8.js +0 -1
- package/dist/twint.svg.es-WrZYquRs.mjs +0 -4
- package/dist/typeGuards.es-C4nR5FkL.js +0 -1
- package/dist/typeGuards.es-fwUoeMCe.mjs +0 -12
- package/dist/unionpay.svg.es-DYgo83Hf.mjs +0 -4
- package/dist/unionpay.svg.es-YqJKKFEj.js +0 -1
- package/dist/url-CjULBkjW.js +0 -1
- package/dist/url-CvNDq4wp.mjs +0 -22
- package/dist/useActionDispatchProvider-BVOBO0Jx.mjs +0 -12
- package/dist/useActionDispatchProvider-Cv9amjTf.js +0 -1
- package/dist/useCustomer-DLHOs4BR.js +0 -1
- package/dist/useCustomer-EDhref7T.mjs +0 -25
- package/dist/useCustomerFormLabels-B61-4xQ7.mjs +0 -1168
- package/dist/useCustomerFormLabels-C6wW4n2e.js +0 -1
- package/dist/useExperimentalFeature-0yFoaEzV.js +0 -1
- package/dist/useExperimentalFeature-DvxOrFPU.mjs +0 -9
- package/dist/useIncrementalLoading-BK9pRYAU.mjs +0 -71
- package/dist/useIncrementalLoading-CdtGJm_Y.js +0 -1
- package/dist/useInvoiceData-BSjVeJrI.js +0 -1
- package/dist/useInvoiceData-C0Y5WrbT.mjs +0 -45
- package/dist/useInvoicesList-BRDZqsaB.js +0 -1
- package/dist/useInvoicesList-CYoE7q0u.mjs +0 -580
- package/dist/useLoadInitialData-Cp1OA8y6.mjs +0 -18
- package/dist/useLoadInitialData-u7IyXqb6.js +0 -1
- package/dist/usePaymentMethodAvailability-B3s1lqQ2.js +0 -1
- package/dist/usePaymentMethodAvailability-EuhZPghG.mjs +0 -141
- package/dist/usePaymentMethodOptions--8QpMvNm.js +0 -1
- package/dist/usePaymentMethodOptions-Cljh7HYp.mjs +0 -36
- package/dist/usePaymentMethods-BJzoI8dZ.mjs +0 -16
- package/dist/usePaymentMethods-DvEnJWmB.js +0 -1
- package/dist/usePayments-CANj0QVc.js +0 -1
- package/dist/usePayments-CaT1CBzE.mjs +0 -362
- package/dist/usePortal-BjGoSeLy.js +0 -1
- package/dist/usePortal-CMPQ0M9R.mjs +0 -12
- package/dist/useService-D73FNBjT.js +0 -1
- package/dist/useService-W3Kxems4.mjs +0 -72
- package/dist/useSubscription-D1UKnZAx.mjs +0 -250
- package/dist/useSubscription-DZfRHbL7.js +0 -1
- package/dist/useViewport-Bu0cyeSi.mjs +0 -38
- package/dist/useViewport-CKRY1CKR.js +0 -1
- package/dist/useWatchDebounced-C_YxgoQ6.js +0 -1
- package/dist/useWatchDebounced-Zmxd6InB.mjs +0 -16
- package/dist/visa.svg.es-B6aU_qRs.mjs +0 -4
- package/dist/visa.svg.es-D6sc4YTE.js +0 -1
- package/dist/vpay.svg.es-4qIqS4aX.mjs +0 -4
- package/dist/vpay.svg.es-CLGTyB09.js +0 -1
- package/dist/zip.svg.es-3PzSBe1E.mjs +0 -4
- package/dist/zip.svg.es-BRsgmur-.js +0 -1
|
@@ -1,2944 +0,0 @@
|
|
|
1
|
-
import { ref, openBlock, createElementBlock, renderSlot, defineComponent, normalizeClass, Fragment, renderList, createVNode, withCtx, createElementVNode, createTextVNode, toDisplayString, createBlock, unref, createCommentVNode, createSlots, withKeys, normalizeProps, guardReactiveProps, computed, mergeProps, isRef } from "vue";
|
|
2
|
-
import { u as useIntl, _ as _sfc_main$u, k as formatTimezone } from "./customElements-B-89a5oH.mjs";
|
|
3
|
-
import { _ as _sfc_main$l } from "./Amount.vue.es-BO5sS1UX.mjs";
|
|
4
|
-
import { i as isEmpty } from "./useService-W3Kxems4.mjs";
|
|
5
|
-
import { _ as _sfc_main$n, a as _sfc_main$s } from "./Button.vue.es-Cm9pLU9i.mjs";
|
|
6
|
-
import { _ as _export_sfc } from "./floating-ui.vue.es-DWY7pdz8.mjs";
|
|
7
|
-
import { a as getCustomerName } from "./customer.es-C_vSWcVA.mjs";
|
|
8
|
-
import { M as MAX_FRACTION_DIGITS, f as formatAmount, a as formatEnum } from "./formatting.es-eYgXv_AK.mjs";
|
|
9
|
-
import { _ as _sfc_main$k, u as useToggleList } from "./Comparators.vue.es-CYfxd5H-.mjs";
|
|
10
|
-
import { _ as _sfc_main$m } from "./Chip.vue.es-BBmn-qJp.mjs";
|
|
11
|
-
import { g as getComposedString } from "./getComposedString.es-CELkn0I7.mjs";
|
|
12
|
-
import { _ as _sfc_main$o, T as TooltipContent, a as _sfc_main$p } from "./TooltipParagraph.vue.es-C5RTcrid.mjs";
|
|
13
|
-
import { f as useResizeObserver } from "./index.es-D5xOw_SJ.mjs";
|
|
14
|
-
import { _ as _sfc_main$t } from "./DividerText.vue.es-CeAHAe_Y.mjs";
|
|
15
|
-
import { _ as _sfc_main$q } from "./IconTitle.vue.es-BmjBdZb_.mjs";
|
|
16
|
-
import { a as _sfc_main$r } from "./ContextMenu.vue.es-CTc1ktXb.mjs";
|
|
17
|
-
const useSimpleToggleList = (initialToggledItems = []) => {
|
|
18
|
-
const toggledItems = ref(initialToggledItems);
|
|
19
|
-
const toggle = (index) => {
|
|
20
|
-
const match = toggledItems.value.find((groupIndex) => groupIndex === index);
|
|
21
|
-
if (typeof match === "number") {
|
|
22
|
-
toggledItems.value = toggledItems.value.filter((groupIndex) => groupIndex !== index);
|
|
23
|
-
} else {
|
|
24
|
-
toggledItems.value = [...toggledItems.value, index];
|
|
25
|
-
}
|
|
26
|
-
};
|
|
27
|
-
return [toggledItems, toggle];
|
|
28
|
-
};
|
|
29
|
-
const _sfc_main$j = {};
|
|
30
|
-
const _hoisted_1$g = { class: "w-full table-fixed" };
|
|
31
|
-
function _sfc_render(_ctx, _cache) {
|
|
32
|
-
return openBlock(), createElementBlock("table", _hoisted_1$g, [
|
|
33
|
-
renderSlot(_ctx.$slots, "default")
|
|
34
|
-
]);
|
|
35
|
-
}
|
|
36
|
-
const InvoiceTable = /* @__PURE__ */ _export_sfc(_sfc_main$j, [["render", _sfc_render]]);
|
|
37
|
-
const _sfc_main$i = /* @__PURE__ */ defineComponent({
|
|
38
|
-
__name: "InvoiceTableData",
|
|
39
|
-
props: {
|
|
40
|
-
number: { type: Boolean, default: false },
|
|
41
|
-
hasPadding: { type: Boolean, default: true }
|
|
42
|
-
},
|
|
43
|
-
setup(__props) {
|
|
44
|
-
return (_ctx, _cache) => {
|
|
45
|
-
return openBlock(), createElementBlock("td", {
|
|
46
|
-
class: normalizeClass({
|
|
47
|
-
"text-right tabular-nums": __props.number,
|
|
48
|
-
"py-2": __props.hasPadding
|
|
49
|
-
})
|
|
50
|
-
}, [
|
|
51
|
-
renderSlot(_ctx.$slots, "default")
|
|
52
|
-
], 2);
|
|
53
|
-
};
|
|
54
|
-
}
|
|
55
|
-
});
|
|
56
|
-
const _sfc_main$h = /* @__PURE__ */ defineComponent({
|
|
57
|
-
__name: "InvoiceTableHeader",
|
|
58
|
-
props: {
|
|
59
|
-
left: { type: Boolean, default: false },
|
|
60
|
-
right: { type: Boolean, default: false }
|
|
61
|
-
},
|
|
62
|
-
setup(__props) {
|
|
63
|
-
return (_ctx, _cache) => {
|
|
64
|
-
return openBlock(), createElementBlock("th", {
|
|
65
|
-
class: normalizeClass(["border-b py-1.5 text-xs font-bold uppercase text-subtle", { "text-left": __props.left, "text-right": __props.right }])
|
|
66
|
-
}, [
|
|
67
|
-
renderSlot(_ctx.$slots, "default")
|
|
68
|
-
], 2);
|
|
69
|
-
};
|
|
70
|
-
}
|
|
71
|
-
});
|
|
72
|
-
const INVOICE_PERIOD = "INVOICE_PERIOD";
|
|
73
|
-
const INVOICE_PERIOD_SUBTOTAL = "INVOICE_PERIOD_SUBTOTAL";
|
|
74
|
-
const INVOICE_PERIOD_TOTAL = "INVOICE_PERIOD_TOTAL";
|
|
75
|
-
const SUMMARY_LINE_AMOUNT = "SUMMARY_LINE_AMOUNT";
|
|
76
|
-
const SUMMARY_TOTAL_TAX = "SUMMARY_TOTAL_TAX";
|
|
77
|
-
const SUMMARY_TOTAL_INCLUDING_TAX = "SUMMARY_TOTAL_INCLUDING_TAX";
|
|
78
|
-
const SUMMARY_TOTAL_EXCLUDING_TAX = "SUMMARY_TOTAL_EXCLUDING_TAX";
|
|
79
|
-
const SUMMARY_TOTAL_DISCOUNT = "SUMMARY_TOTAL_DISCOUNT";
|
|
80
|
-
const SUMMARY_AMOUNT_DUE = "SUMMARY_AMOUNT_DUE";
|
|
81
|
-
const DEDUCTION = "DEDUCTION";
|
|
82
|
-
const HAS_SUBLINES = "HAS_SUBLINES";
|
|
83
|
-
const _hoisted_1$f = { class: "flex items-center" };
|
|
84
|
-
const _hoisted_2$a = {
|
|
85
|
-
key: 0,
|
|
86
|
-
class: "text-xs text-secondary"
|
|
87
|
-
};
|
|
88
|
-
const _hoisted_3$6 = { class: "flex items-center" };
|
|
89
|
-
const _sfc_main$g = /* @__PURE__ */ defineComponent({
|
|
90
|
-
__name: "InvoiceSubLineRow",
|
|
91
|
-
props: {
|
|
92
|
-
subLines: {},
|
|
93
|
-
isOpen: { type: Boolean },
|
|
94
|
-
lineOrder: {},
|
|
95
|
-
periodOrder: {},
|
|
96
|
-
groupOrder: {},
|
|
97
|
-
processingOnlyCustomers: {},
|
|
98
|
-
displayInvoiceSubLinesPerProcessingOnlyCustomer: { type: Boolean },
|
|
99
|
-
showTaxPerLineItem: { type: Boolean, default: true }
|
|
100
|
-
},
|
|
101
|
-
setup(__props) {
|
|
102
|
-
const { formatMessage, formatNumber } = useIntl();
|
|
103
|
-
const props = __props;
|
|
104
|
-
const getCustomerName$1 = (customerId) => {
|
|
105
|
-
var _a;
|
|
106
|
-
const childCustomer = (_a = props.processingOnlyCustomers) == null ? void 0 : _a.find(
|
|
107
|
-
(childCustomer2) => childCustomer2.id === customerId
|
|
108
|
-
);
|
|
109
|
-
if (!childCustomer) {
|
|
110
|
-
return formatMessage({
|
|
111
|
-
id: "generic.not_available",
|
|
112
|
-
defaultMessage: "N/A",
|
|
113
|
-
description: "Used in scenarios where no data is available to be displayed"
|
|
114
|
-
});
|
|
115
|
-
}
|
|
116
|
-
return getCustomerName(childCustomer);
|
|
117
|
-
};
|
|
118
|
-
const getSubLineConditions = (subLine) => {
|
|
119
|
-
var _a;
|
|
120
|
-
return ((_a = subLine.usage_based_conversion) == null ? void 0 : _a.conditions) ?? subLine.conditions;
|
|
121
|
-
};
|
|
122
|
-
const getConversionCreditsQuantity = (subLine) => {
|
|
123
|
-
var _a, _b;
|
|
124
|
-
const quantity = (_b = (_a = subLine.details.conversion) == null ? void 0 : _a.credits) == null ? void 0 : _b.quantity;
|
|
125
|
-
if (quantity === void 0) {
|
|
126
|
-
return formatMessage({
|
|
127
|
-
id: "generic.not_available",
|
|
128
|
-
defaultMessage: "N/A",
|
|
129
|
-
description: "Used in scenarios where no data is available to be displayed"
|
|
130
|
-
});
|
|
131
|
-
}
|
|
132
|
-
return formatNumber(+quantity, { maximumFractionDigits: MAX_FRACTION_DIGITS });
|
|
133
|
-
};
|
|
134
|
-
return (_ctx, _cache) => {
|
|
135
|
-
return __props.subLines && __props.isOpen ? (openBlock(true), createElementBlock(Fragment, { key: 0 }, renderList(__props.subLines, (subLine, subLineIndex) => {
|
|
136
|
-
return openBlock(), createElementBlock(Fragment, { key: subLineIndex }, [
|
|
137
|
-
!subLine.processing_only_customer_resource_id ? (openBlock(), createElementBlock("tr", {
|
|
138
|
-
key: 0,
|
|
139
|
-
class: normalizeClass(subLineIndex > 0 ? "border-t" : "")
|
|
140
|
-
}, [
|
|
141
|
-
createVNode(_sfc_main$i, null, {
|
|
142
|
-
default: withCtx(() => {
|
|
143
|
-
var _a, _b, _c, _d, _e, _f;
|
|
144
|
-
return [
|
|
145
|
-
createElementVNode("div", _hoisted_1$f, [
|
|
146
|
-
renderSlot(_ctx.$slots, "invoice-line-prefix", {
|
|
147
|
-
lineOrder: __props.lineOrder,
|
|
148
|
-
periodOrder: __props.periodOrder,
|
|
149
|
-
groupOrder: __props.groupOrder
|
|
150
|
-
}),
|
|
151
|
-
createElementVNode("div", null, [
|
|
152
|
-
createElementVNode("div", null, [
|
|
153
|
-
subLine.description ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
|
|
154
|
-
createTextVNode(toDisplayString(subLine.description), 1)
|
|
155
|
-
], 64)) : subLine.details.description ? (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
|
156
|
-
createTextVNode(toDisplayString(subLine.details.description), 1)
|
|
157
|
-
], 64)) : (openBlock(), createElementBlock(Fragment, { key: 2 }, [
|
|
158
|
-
createTextVNode(" N/A ")
|
|
159
|
-
], 64))
|
|
160
|
-
]),
|
|
161
|
-
((_a = getSubLineConditions(subLine)) == null ? void 0 : _a.name) || ((_b = getSubLineConditions(subLine)) == null ? void 0 : _b.meter_properties) ? (openBlock(), createElementBlock("div", _hoisted_2$a, [
|
|
162
|
-
((_c = getSubLineConditions(subLine)) == null ? void 0 : _c.name) ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
|
|
163
|
-
createTextVNode(toDisplayString((_d = getSubLineConditions(subLine)) == null ? void 0 : _d.name), 1)
|
|
164
|
-
], 64)) : ((_e = getSubLineConditions(subLine)) == null ? void 0 : _e.meter_properties) ? (openBlock(), createBlock(unref(_sfc_main$k), {
|
|
165
|
-
key: 1,
|
|
166
|
-
comparators: (_f = getSubLineConditions(subLine)) == null ? void 0 : _f.meter_properties
|
|
167
|
-
}, null, 8, ["comparators"])) : createCommentVNode("", true)
|
|
168
|
-
])) : createCommentVNode("", true)
|
|
169
|
-
])
|
|
170
|
-
])
|
|
171
|
-
];
|
|
172
|
-
}),
|
|
173
|
-
_: 2
|
|
174
|
-
}, 1024),
|
|
175
|
-
createVNode(_sfc_main$i, {
|
|
176
|
-
number: "",
|
|
177
|
-
class: "text-right tabular-nums"
|
|
178
|
-
}, {
|
|
179
|
-
default: withCtx(() => [
|
|
180
|
-
createTextVNode(toDisplayString(getConversionCreditsQuantity(subLine)), 1)
|
|
181
|
-
]),
|
|
182
|
-
_: 2
|
|
183
|
-
}, 1024),
|
|
184
|
-
createVNode(_sfc_main$i, { class: "text-right tabular-nums" }, {
|
|
185
|
-
default: withCtx(() => {
|
|
186
|
-
var _a, _b;
|
|
187
|
-
return [
|
|
188
|
-
((_a = subLine.details.band) == null ? void 0 : _a.amount) ? (openBlock(), createBlock(_sfc_main$l, {
|
|
189
|
-
key: 0,
|
|
190
|
-
value: subLine.details.band.amount
|
|
191
|
-
}, null, 8, ["value"])) : ((_b = subLine.details.band) == null ? void 0 : _b.percentage) ? (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
|
192
|
-
createTextVNode(toDisplayString(subLine.details.band.percentage) + "% ", 1)
|
|
193
|
-
], 64)) : (openBlock(), createElementBlock(Fragment, { key: 2 }, [
|
|
194
|
-
createTextVNode(" N/A ")
|
|
195
|
-
], 64))
|
|
196
|
-
];
|
|
197
|
-
}),
|
|
198
|
-
_: 2
|
|
199
|
-
}, 1024),
|
|
200
|
-
__props.showTaxPerLineItem ? (openBlock(), createBlock(_sfc_main$i, { key: 0 }, {
|
|
201
|
-
default: withCtx(() => [..._cache[0] || (_cache[0] = [
|
|
202
|
-
createTextVNode(" ", -1)
|
|
203
|
-
])]),
|
|
204
|
-
_: 1
|
|
205
|
-
})) : createCommentVNode("", true),
|
|
206
|
-
subLine.details.amount ? (openBlock(), createBlock(_sfc_main$i, {
|
|
207
|
-
key: 1,
|
|
208
|
-
class: "text-right tabular-nums"
|
|
209
|
-
}, {
|
|
210
|
-
default: withCtx(() => [
|
|
211
|
-
createVNode(_sfc_main$l, {
|
|
212
|
-
value: subLine.details.amount,
|
|
213
|
-
"data-testid": unref(INVOICE_PERIOD_SUBTOTAL)
|
|
214
|
-
}, null, 8, ["value", "data-testid"])
|
|
215
|
-
]),
|
|
216
|
-
_: 2
|
|
217
|
-
}, 1024)) : createCommentVNode("", true)
|
|
218
|
-
], 2)) : __props.displayInvoiceSubLinesPerProcessingOnlyCustomer && __props.processingOnlyCustomers ? (openBlock(), createElementBlock("tr", {
|
|
219
|
-
key: 1,
|
|
220
|
-
class: normalizeClass(["group", { "border-t": subLineIndex > 0 }])
|
|
221
|
-
}, [
|
|
222
|
-
createVNode(_sfc_main$i, { class: "pl-4" }, {
|
|
223
|
-
default: withCtx(() => [
|
|
224
|
-
createElementVNode("div", _hoisted_3$6, [
|
|
225
|
-
createElementVNode("div", null, toDisplayString(getCustomerName$1(subLine.processing_only_customer_resource_id)), 1)
|
|
226
|
-
])
|
|
227
|
-
]),
|
|
228
|
-
_: 2
|
|
229
|
-
}, 1024),
|
|
230
|
-
renderSlot(_ctx.$slots, "subline-content", {
|
|
231
|
-
details: subLine.details,
|
|
232
|
-
hideTaxDetails: true
|
|
233
|
-
})
|
|
234
|
-
], 2)) : createCommentVNode("", true)
|
|
235
|
-
], 64);
|
|
236
|
-
}), 128)) : createCommentVNode("", true);
|
|
237
|
-
};
|
|
238
|
-
}
|
|
239
|
-
});
|
|
240
|
-
const _hoisted_1$e = { class: "flex gap-4" };
|
|
241
|
-
const _hoisted_2$9 = { class: "flex items-center gap-2" };
|
|
242
|
-
const _sfc_main$f = /* @__PURE__ */ defineComponent({
|
|
243
|
-
__name: "PricingClauseChip",
|
|
244
|
-
props: {
|
|
245
|
-
iconName: {}
|
|
246
|
-
},
|
|
247
|
-
setup(__props) {
|
|
248
|
-
return (_ctx, _cache) => {
|
|
249
|
-
return openBlock(), createElementBlock("div", _hoisted_1$e, [
|
|
250
|
-
createVNode(_sfc_main$m, null, {
|
|
251
|
-
default: withCtx(() => [
|
|
252
|
-
createElementVNode("div", _hoisted_2$9, [
|
|
253
|
-
createVNode(_sfc_main$n, {
|
|
254
|
-
icon: __props.iconName,
|
|
255
|
-
size: "xs"
|
|
256
|
-
}, null, 8, ["icon"]),
|
|
257
|
-
createElementVNode("span", null, [
|
|
258
|
-
renderSlot(_ctx.$slots, "chip-content")
|
|
259
|
-
])
|
|
260
|
-
])
|
|
261
|
-
]),
|
|
262
|
-
_: 3
|
|
263
|
-
}),
|
|
264
|
-
renderSlot(_ctx.$slots, "chip-postfix")
|
|
265
|
-
]);
|
|
266
|
-
};
|
|
267
|
-
}
|
|
268
|
-
});
|
|
269
|
-
const _hoisted_1$d = { class: "flex flex-col gap-2" };
|
|
270
|
-
const _sfc_main$e = /* @__PURE__ */ defineComponent({
|
|
271
|
-
__name: "InvoicePricingClauseChip",
|
|
272
|
-
props: {
|
|
273
|
-
clauseType: {},
|
|
274
|
-
priceDetailsBand: {},
|
|
275
|
-
invoiceLineDescription: {}
|
|
276
|
-
},
|
|
277
|
-
setup(__props) {
|
|
278
|
-
const intl = useIntl();
|
|
279
|
-
return (_ctx, _cache) => {
|
|
280
|
-
return openBlock(), createElementBlock("div", _hoisted_1$d, [
|
|
281
|
-
createElementVNode("span", null, toDisplayString(__props.invoiceLineDescription), 1),
|
|
282
|
-
__props.clauseType === "DISCOUNT" && __props.priceDetailsBand ? (openBlock(), createBlock(unref(_sfc_main$f), {
|
|
283
|
-
key: 0,
|
|
284
|
-
"icon-name": "south_east"
|
|
285
|
-
}, createSlots({ _: 2 }, [
|
|
286
|
-
__props.priceDetailsBand.amount ? {
|
|
287
|
-
name: "chip-content",
|
|
288
|
-
fn: withCtx(() => [
|
|
289
|
-
createTextVNode(toDisplayString(unref(intl).$t(
|
|
290
|
-
{
|
|
291
|
-
id: "invoice.amount_discount",
|
|
292
|
-
defaultMessage: "{amount} discount",
|
|
293
|
-
description: "Represents a certain amount of discount, where {amount} is replaced with the amount"
|
|
294
|
-
},
|
|
295
|
-
{
|
|
296
|
-
amount: unref(formatAmount)(__props.priceDetailsBand.amount)
|
|
297
|
-
}
|
|
298
|
-
).toUpperCase()), 1)
|
|
299
|
-
]),
|
|
300
|
-
key: "0"
|
|
301
|
-
} : __props.priceDetailsBand.percentage ? {
|
|
302
|
-
name: "chip-content",
|
|
303
|
-
fn: withCtx(() => [
|
|
304
|
-
createTextVNode(toDisplayString(unref(intl).$t(
|
|
305
|
-
{
|
|
306
|
-
id: "invoice.percentage_discount",
|
|
307
|
-
defaultMessage: "{percentage}% discount",
|
|
308
|
-
description: "Represents a certain percentage of discount, where {percentage} is replaced with the percentage (number only)"
|
|
309
|
-
},
|
|
310
|
-
{
|
|
311
|
-
percentage: __props.priceDetailsBand.percentage ?? "0"
|
|
312
|
-
}
|
|
313
|
-
).toUpperCase()), 1)
|
|
314
|
-
]),
|
|
315
|
-
key: "1"
|
|
316
|
-
} : void 0
|
|
317
|
-
]), 1024)) : __props.clauseType === "ADJUSTMENT" ? (openBlock(), createBlock(unref(_sfc_main$f), {
|
|
318
|
-
key: 1,
|
|
319
|
-
"icon-name": "info"
|
|
320
|
-
}, {
|
|
321
|
-
"chip-content": withCtx(() => [
|
|
322
|
-
createTextVNode(toDisplayString(unref(intl).$t({
|
|
323
|
-
id: "invoice.adjustment_chip_body",
|
|
324
|
-
defaultMessage: "Adjustment",
|
|
325
|
-
description: "Used on invoice lines to mark as adjusted"
|
|
326
|
-
}).toUpperCase()), 1)
|
|
327
|
-
]),
|
|
328
|
-
_: 1
|
|
329
|
-
})) : __props.clauseType === "MARKUP" ? (openBlock(), createBlock(unref(_sfc_main$f), {
|
|
330
|
-
key: 2,
|
|
331
|
-
"icon-name": "north_east"
|
|
332
|
-
}, {
|
|
333
|
-
"chip-content": withCtx(() => {
|
|
334
|
-
var _a;
|
|
335
|
-
return [
|
|
336
|
-
createTextVNode(toDisplayString(unref(intl).$t(
|
|
337
|
-
{
|
|
338
|
-
id: "invoice.markup_percentage",
|
|
339
|
-
defaultMessage: "{percentage}% markup",
|
|
340
|
-
description: "Markup percentage, where {percentage} is replaced with the percentage (number only)"
|
|
341
|
-
},
|
|
342
|
-
{ percentage: ((_a = __props.priceDetailsBand) == null ? void 0 : _a.percentage) ?? "0" }
|
|
343
|
-
).toUpperCase()), 1)
|
|
344
|
-
];
|
|
345
|
-
}),
|
|
346
|
-
_: 1
|
|
347
|
-
})) : __props.clauseType === "COMMITMENT" ? (openBlock(), createBlock(unref(_sfc_main$f), {
|
|
348
|
-
key: 3,
|
|
349
|
-
"icon-name": "sell"
|
|
350
|
-
}, {
|
|
351
|
-
"chip-content": withCtx(() => [
|
|
352
|
-
createTextVNode(toDisplayString(unref(intl).$t({
|
|
353
|
-
id: "invoice.commitment",
|
|
354
|
-
defaultMessage: "commitment",
|
|
355
|
-
description: "Used on invoice lines to mark as commitment"
|
|
356
|
-
}).toUpperCase()), 1)
|
|
357
|
-
]),
|
|
358
|
-
_: 1
|
|
359
|
-
})) : createCommentVNode("", true)
|
|
360
|
-
]);
|
|
361
|
-
};
|
|
362
|
-
}
|
|
363
|
-
});
|
|
364
|
-
const _hoisted_1$c = ["tabindex", "onClick"];
|
|
365
|
-
const _hoisted_2$8 = { class: "flex items-center" };
|
|
366
|
-
const _sfc_main$d = /* @__PURE__ */ defineComponent({
|
|
367
|
-
__name: "InvoiceCommitment",
|
|
368
|
-
props: {
|
|
369
|
-
commitments: {},
|
|
370
|
-
groupOrder: {},
|
|
371
|
-
invoicePeriodOrder: {},
|
|
372
|
-
processingOnlyCustomers: {},
|
|
373
|
-
displayInvoiceSubLinesPerProcessingOnlyCustomer: { type: Boolean }
|
|
374
|
-
},
|
|
375
|
-
setup(__props) {
|
|
376
|
-
const intl = useIntl();
|
|
377
|
-
const { getIsOpen, toggle } = useToggleList();
|
|
378
|
-
const toggleLine = (groupOrder, invoiceLineOrder) => {
|
|
379
|
-
toggle(formatIndex(groupOrder, invoiceLineOrder));
|
|
380
|
-
};
|
|
381
|
-
const formatIndex = (rootIndex, index) => `${rootIndex}-line-${index}`;
|
|
382
|
-
const getLineDescription = (line) => {
|
|
383
|
-
var _a;
|
|
384
|
-
return line.description ?? ((_a = line.details) == null ? void 0 : _a.description) ?? intl.$t({
|
|
385
|
-
id: "generic.not_available",
|
|
386
|
-
defaultMessage: "N/A",
|
|
387
|
-
description: "Used in scenarios where no data is available to be displayed"
|
|
388
|
-
});
|
|
389
|
-
};
|
|
390
|
-
return (_ctx, _cache) => {
|
|
391
|
-
return openBlock(), createBlock(InvoiceTable, null, {
|
|
392
|
-
default: withCtx(() => [
|
|
393
|
-
createElementVNode("tr", null, [
|
|
394
|
-
createVNode(_sfc_main$h, {
|
|
395
|
-
left: "",
|
|
396
|
-
colspan: "5"
|
|
397
|
-
}, {
|
|
398
|
-
default: withCtx(() => [
|
|
399
|
-
createTextVNode(toDisplayString(unref(intl).$t({
|
|
400
|
-
id: "invoice.table_header.unit",
|
|
401
|
-
defaultMessage: "Unit",
|
|
402
|
-
description: "Table header for the column containing the number of units of invoice groups"
|
|
403
|
-
})), 1)
|
|
404
|
-
]),
|
|
405
|
-
_: 1
|
|
406
|
-
}),
|
|
407
|
-
createVNode(_sfc_main$h, {
|
|
408
|
-
right: "",
|
|
409
|
-
class: "w-60"
|
|
410
|
-
}, {
|
|
411
|
-
default: withCtx(() => [
|
|
412
|
-
createTextVNode(toDisplayString(unref(intl).$t({
|
|
413
|
-
id: "invoice.table_header.sub_total",
|
|
414
|
-
defaultMessage: "Subtotal",
|
|
415
|
-
description: "Table header for the column containing the subtotal for invoices"
|
|
416
|
-
})), 1)
|
|
417
|
-
]),
|
|
418
|
-
_: 1
|
|
419
|
-
})
|
|
420
|
-
]),
|
|
421
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(__props.commitments, (line, lineIndex) => {
|
|
422
|
-
return openBlock(), createElementBlock(Fragment, { key: lineIndex }, [
|
|
423
|
-
createElementVNode("tr", {
|
|
424
|
-
class: normalizeClass(["border-t", { "cursor-pointer": line.sub_lines }]),
|
|
425
|
-
tabindex: line.sub_lines ? 0 : void 0,
|
|
426
|
-
onClick: ($event) => toggleLine(__props.groupOrder, line["line_order"])
|
|
427
|
-
}, [
|
|
428
|
-
createVNode(_sfc_main$i, { colspan: "2" }, {
|
|
429
|
-
default: withCtx(() => {
|
|
430
|
-
var _a;
|
|
431
|
-
return [
|
|
432
|
-
line.sub_lines ? (openBlock(), createBlock(_sfc_main$n, {
|
|
433
|
-
key: 0,
|
|
434
|
-
icon: "keyboard_arrow_down",
|
|
435
|
-
size: "md",
|
|
436
|
-
class: normalizeClass(["absolute -translate-x-7 text-slate-400", {
|
|
437
|
-
"-rotate-90": !unref(getIsOpen)(formatIndex(__props.groupOrder, line["line_order"]))
|
|
438
|
-
}])
|
|
439
|
-
}, null, 8, ["class"])) : createCommentVNode("", true),
|
|
440
|
-
createElementVNode("div", _hoisted_2$8, [
|
|
441
|
-
renderSlot(_ctx.$slots, "invoice-line-prefix", {
|
|
442
|
-
lineOrder: line.line_order,
|
|
443
|
-
periodOrder: __props.invoicePeriodOrder,
|
|
444
|
-
groupOrder: __props.groupOrder
|
|
445
|
-
}),
|
|
446
|
-
createVNode(_sfc_main$e, {
|
|
447
|
-
"clause-type": "COMMITMENT",
|
|
448
|
-
"invoice-line-description": getLineDescription(line),
|
|
449
|
-
"price-details-band": (_a = line.details) == null ? void 0 : _a.band
|
|
450
|
-
}, null, 8, ["invoice-line-description", "price-details-band"])
|
|
451
|
-
])
|
|
452
|
-
];
|
|
453
|
-
}),
|
|
454
|
-
_: 2
|
|
455
|
-
}, 1024),
|
|
456
|
-
createVNode(_sfc_main$i, { colspan: "3" }, {
|
|
457
|
-
default: withCtx(() => [..._cache[0] || (_cache[0] = [
|
|
458
|
-
createTextVNode(" ", -1)
|
|
459
|
-
])]),
|
|
460
|
-
_: 1
|
|
461
|
-
}),
|
|
462
|
-
createVNode(_sfc_main$i, { number: "" }, {
|
|
463
|
-
default: withCtx(() => {
|
|
464
|
-
var _a, _b;
|
|
465
|
-
return [
|
|
466
|
-
((_a = line.details) == null ? void 0 : _a.amount) ? (openBlock(), createBlock(_sfc_main$l, {
|
|
467
|
-
key: 0,
|
|
468
|
-
value: (_b = line.details) == null ? void 0 : _b.amount,
|
|
469
|
-
"data-testid": unref(SUMMARY_LINE_AMOUNT)
|
|
470
|
-
}, null, 8, ["value", "data-testid"])) : createCommentVNode("", true)
|
|
471
|
-
];
|
|
472
|
-
}),
|
|
473
|
-
_: 2
|
|
474
|
-
}, 1024)
|
|
475
|
-
], 10, _hoisted_1$c),
|
|
476
|
-
createVNode(_sfc_main$g, {
|
|
477
|
-
ref_for: true,
|
|
478
|
-
ref: formatIndex(__props.groupOrder, line["line_order"]),
|
|
479
|
-
"sub-lines": line.sub_lines ?? [],
|
|
480
|
-
"line-order": line["line_order"],
|
|
481
|
-
"period-order": __props.invoicePeriodOrder,
|
|
482
|
-
"group-order": __props.groupOrder,
|
|
483
|
-
"is-open": unref(getIsOpen)(formatIndex(__props.groupOrder, line["line_order"])),
|
|
484
|
-
"processing-only-customers": __props.processingOnlyCustomers,
|
|
485
|
-
"display-invoice-sub-lines-per-processing-only-customer": __props.displayInvoiceSubLinesPerProcessingOnlyCustomer
|
|
486
|
-
}, null, 8, ["sub-lines", "line-order", "period-order", "group-order", "is-open", "processing-only-customers", "display-invoice-sub-lines-per-processing-only-customer"])
|
|
487
|
-
], 64);
|
|
488
|
-
}), 128))
|
|
489
|
-
]),
|
|
490
|
-
_: 3
|
|
491
|
-
});
|
|
492
|
-
};
|
|
493
|
-
}
|
|
494
|
-
});
|
|
495
|
-
const _hoisted_1$b = ["tabindex", "onClick"];
|
|
496
|
-
const _hoisted_2$7 = { class: "flex items-center" };
|
|
497
|
-
const _sfc_main$c = /* @__PURE__ */ defineComponent({
|
|
498
|
-
__name: "InvoiceDiscountMarkup",
|
|
499
|
-
props: {
|
|
500
|
-
lines: {},
|
|
501
|
-
type: {},
|
|
502
|
-
handleToggleItems: { type: Function },
|
|
503
|
-
formatIndex: { type: Function },
|
|
504
|
-
expandedItems: {},
|
|
505
|
-
isExpandable: { type: Boolean },
|
|
506
|
-
invoicePeriodOrder: {},
|
|
507
|
-
groupOrder: {},
|
|
508
|
-
processingOnlyCustomers: {},
|
|
509
|
-
displayInvoiceSubLinesPerProcessingOnlyCustomer: { type: Boolean }
|
|
510
|
-
},
|
|
511
|
-
setup(__props) {
|
|
512
|
-
const intl = useIntl();
|
|
513
|
-
const { getIsOpen, toggle } = useToggleList();
|
|
514
|
-
const toggleLine = (groupOrder, invoiceLineOrder) => {
|
|
515
|
-
toggle(formatIndex(groupOrder, invoiceLineOrder));
|
|
516
|
-
};
|
|
517
|
-
const formatIndex = (rootIndex, index) => `${rootIndex}-line-${index}`;
|
|
518
|
-
return (_ctx, _cache) => {
|
|
519
|
-
return openBlock(), createBlock(InvoiceTable, null, {
|
|
520
|
-
default: withCtx(() => [
|
|
521
|
-
createElementVNode("tr", null, [
|
|
522
|
-
createVNode(_sfc_main$h, {
|
|
523
|
-
left: "",
|
|
524
|
-
class: "w-3/5"
|
|
525
|
-
}, {
|
|
526
|
-
default: withCtx(() => [
|
|
527
|
-
createTextVNode(toDisplayString(unref(intl).$t({
|
|
528
|
-
id: "invoice.table_header.quantity",
|
|
529
|
-
defaultMessage: "Quantity",
|
|
530
|
-
description: "Table header for quantity column"
|
|
531
|
-
})), 1)
|
|
532
|
-
]),
|
|
533
|
-
_: 1
|
|
534
|
-
}),
|
|
535
|
-
createVNode(_sfc_main$h, { colspan: "2" }, {
|
|
536
|
-
default: withCtx(() => [..._cache[0] || (_cache[0] = [
|
|
537
|
-
createTextVNode(" ", -1)
|
|
538
|
-
])]),
|
|
539
|
-
_: 1
|
|
540
|
-
}),
|
|
541
|
-
createVNode(_sfc_main$h, {
|
|
542
|
-
left: "",
|
|
543
|
-
class: "w-1/5"
|
|
544
|
-
}, {
|
|
545
|
-
default: withCtx(() => [
|
|
546
|
-
createTextVNode(toDisplayString(__props.type === "DISCOUNT" ? unref(intl).$t({
|
|
547
|
-
id: "invoice.table_header.discount",
|
|
548
|
-
defaultMessage: "Discount",
|
|
549
|
-
description: "Table header for discount column"
|
|
550
|
-
}) : unref(intl).$t({
|
|
551
|
-
id: "invoice.table_header.markup",
|
|
552
|
-
defaultMessage: "Markup",
|
|
553
|
-
description: "Table header for markup column"
|
|
554
|
-
})), 1)
|
|
555
|
-
]),
|
|
556
|
-
_: 1
|
|
557
|
-
}),
|
|
558
|
-
createVNode(_sfc_main$h, {
|
|
559
|
-
left: "",
|
|
560
|
-
class: "w-1/5"
|
|
561
|
-
}, {
|
|
562
|
-
default: withCtx(() => [
|
|
563
|
-
createTextVNode(toDisplayString(__props.type === "DISCOUNT" ? unref(intl).$t({
|
|
564
|
-
id: "invoice.table_header.total",
|
|
565
|
-
defaultMessage: "Total",
|
|
566
|
-
description: "Table header for total column"
|
|
567
|
-
}) : " "), 1)
|
|
568
|
-
]),
|
|
569
|
-
_: 1
|
|
570
|
-
}),
|
|
571
|
-
createVNode(_sfc_main$h, {
|
|
572
|
-
right: "",
|
|
573
|
-
class: "w-1/5"
|
|
574
|
-
}, {
|
|
575
|
-
default: withCtx(() => [
|
|
576
|
-
createTextVNode(toDisplayString(unref(intl).$t({
|
|
577
|
-
id: "invoice.table_header.sub_total",
|
|
578
|
-
defaultMessage: "Subtotal",
|
|
579
|
-
description: "Table header for the column containing the subtotal for invoices"
|
|
580
|
-
})), 1)
|
|
581
|
-
]),
|
|
582
|
-
_: 1
|
|
583
|
-
})
|
|
584
|
-
]),
|
|
585
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(__props.lines, (line, lineIndex) => {
|
|
586
|
-
return openBlock(), createElementBlock(Fragment, { key: lineIndex }, [
|
|
587
|
-
createElementVNode("tr", {
|
|
588
|
-
class: normalizeClass(["border-t", { "cursor-pointer": __props.isExpandable }]),
|
|
589
|
-
tabindex: __props.isExpandable ? 0 : void 0,
|
|
590
|
-
onClick: ($event) => toggleLine(__props.groupOrder, line["line_order"])
|
|
591
|
-
}, [
|
|
592
|
-
createVNode(_sfc_main$i, { class: "w-3/5" }, {
|
|
593
|
-
default: withCtx(() => {
|
|
594
|
-
var _a, _b;
|
|
595
|
-
return [
|
|
596
|
-
line.sub_lines ? (openBlock(), createBlock(_sfc_main$n, {
|
|
597
|
-
key: 0,
|
|
598
|
-
icon: "keyboard_arrow_down",
|
|
599
|
-
size: "md",
|
|
600
|
-
class: normalizeClass(["absolute -translate-x-7 text-slate-400", {
|
|
601
|
-
"-rotate-90": !unref(getIsOpen)(formatIndex(__props.groupOrder, line["line_order"]))
|
|
602
|
-
}])
|
|
603
|
-
}, null, 8, ["class"])) : createCommentVNode("", true),
|
|
604
|
-
createElementVNode("div", _hoisted_2$7, [
|
|
605
|
-
renderSlot(_ctx.$slots, "invoice-line-prefix", {
|
|
606
|
-
lineOrder: line.line_order,
|
|
607
|
-
periodOrder: __props.invoicePeriodOrder,
|
|
608
|
-
groupOrder: __props.groupOrder
|
|
609
|
-
}),
|
|
610
|
-
line.description ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
|
|
611
|
-
createTextVNode(toDisplayString(line.description), 1)
|
|
612
|
-
], 64)) : ((_a = line.details) == null ? void 0 : _a.description) ? (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
|
613
|
-
createTextVNode(toDisplayString((_b = line.details) == null ? void 0 : _b.description), 1)
|
|
614
|
-
], 64)) : (openBlock(), createElementBlock(Fragment, { key: 2 }, [
|
|
615
|
-
createTextVNode("N/A")
|
|
616
|
-
], 64))
|
|
617
|
-
])
|
|
618
|
-
];
|
|
619
|
-
}),
|
|
620
|
-
_: 2
|
|
621
|
-
}, 1024),
|
|
622
|
-
createVNode(_sfc_main$i, { colspan: "2" }, {
|
|
623
|
-
default: withCtx(() => [..._cache[1] || (_cache[1] = [
|
|
624
|
-
createTextVNode(" ", -1)
|
|
625
|
-
])]),
|
|
626
|
-
_: 1
|
|
627
|
-
}),
|
|
628
|
-
createVNode(_sfc_main$i, { class: "w-1/5 tabular-nums" }, {
|
|
629
|
-
default: withCtx(() => {
|
|
630
|
-
var _a, _b, _c;
|
|
631
|
-
return [
|
|
632
|
-
createTextVNode(toDisplayString(((_b = (_a = line.details) == null ? void 0 : _a.band) == null ? void 0 : _b.percentage) ? `${(_c = line.details) == null ? void 0 : _c.band.percentage}%` : " "), 1)
|
|
633
|
-
];
|
|
634
|
-
}),
|
|
635
|
-
_: 2
|
|
636
|
-
}, 1024),
|
|
637
|
-
createVNode(_sfc_main$i, { class: "w-1/5" }, {
|
|
638
|
-
default: withCtx(() => [..._cache[2] || (_cache[2] = [
|
|
639
|
-
createTextVNode(" ", -1)
|
|
640
|
-
])]),
|
|
641
|
-
_: 1
|
|
642
|
-
}),
|
|
643
|
-
createVNode(_sfc_main$i, {
|
|
644
|
-
number: "",
|
|
645
|
-
class: "w-1/5"
|
|
646
|
-
}, {
|
|
647
|
-
default: withCtx(() => {
|
|
648
|
-
var _a;
|
|
649
|
-
return [
|
|
650
|
-
((_a = line.details) == null ? void 0 : _a.amount) ? (openBlock(), createBlock(_sfc_main$l, {
|
|
651
|
-
key: 0,
|
|
652
|
-
value: line.details.amount,
|
|
653
|
-
"data-testid": unref(SUMMARY_LINE_AMOUNT)
|
|
654
|
-
}, null, 8, ["value", "data-testid"])) : createCommentVNode("", true)
|
|
655
|
-
];
|
|
656
|
-
}),
|
|
657
|
-
_: 2
|
|
658
|
-
}, 1024)
|
|
659
|
-
], 10, _hoisted_1$b),
|
|
660
|
-
createVNode(_sfc_main$g, {
|
|
661
|
-
ref_for: true,
|
|
662
|
-
ref: formatIndex(__props.groupOrder, line["line_order"]),
|
|
663
|
-
"sub-lines": line.sub_lines ?? [],
|
|
664
|
-
"line-order": line["line_order"],
|
|
665
|
-
"is-open": unref(getIsOpen)(formatIndex(__props.groupOrder, line["line_order"])),
|
|
666
|
-
"period-order": __props.invoicePeriodOrder,
|
|
667
|
-
"group-order": __props.groupOrder,
|
|
668
|
-
"processing-only-customers": __props.processingOnlyCustomers,
|
|
669
|
-
"display-invoice-sub-lines-per-processing-only-customer": __props.displayInvoiceSubLinesPerProcessingOnlyCustomer
|
|
670
|
-
}, null, 8, ["sub-lines", "line-order", "is-open", "period-order", "group-order", "processing-only-customers", "display-invoice-sub-lines-per-processing-only-customer"])
|
|
671
|
-
], 64);
|
|
672
|
-
}), 128))
|
|
673
|
-
]),
|
|
674
|
-
_: 3
|
|
675
|
-
});
|
|
676
|
-
};
|
|
677
|
-
}
|
|
678
|
-
});
|
|
679
|
-
const getInvoiceGroupAmountType = (group) => {
|
|
680
|
-
var _a;
|
|
681
|
-
return ((_a = group.lines) == null ? void 0 : _a.some((line) => !!line.sub_lines)) ? HAS_SUBLINES : void 0;
|
|
682
|
-
};
|
|
683
|
-
const _hoisted_1$a = ["tabindex"];
|
|
684
|
-
const _hoisted_2$6 = { key: 0 };
|
|
685
|
-
const _hoisted_3$5 = {
|
|
686
|
-
colspan: "2",
|
|
687
|
-
class: "p-0"
|
|
688
|
-
};
|
|
689
|
-
const _hoisted_4$5 = { class: "-mx-9 bg-gray-50 px-9 py-3 text-xs" };
|
|
690
|
-
const _sfc_main$b = /* @__PURE__ */ defineComponent({
|
|
691
|
-
__name: "InvoiceGroupCommitment",
|
|
692
|
-
props: {
|
|
693
|
-
group: {},
|
|
694
|
-
expandedItems: {},
|
|
695
|
-
handleToggleItems: { type: Function },
|
|
696
|
-
formatIndex: { type: Function },
|
|
697
|
-
invoicePeriodOrder: {},
|
|
698
|
-
groupOrder: {},
|
|
699
|
-
isExpandable: { type: Boolean },
|
|
700
|
-
forceExpanded: { type: Boolean },
|
|
701
|
-
amountType: {},
|
|
702
|
-
processingOnlyCustomers: {},
|
|
703
|
-
displayInvoiceSubLinesPerProcessingOnlyCustomer: { type: Boolean },
|
|
704
|
-
showTaxPerLineItem: { type: Boolean }
|
|
705
|
-
},
|
|
706
|
-
setup(__props) {
|
|
707
|
-
const intl = useIntl();
|
|
708
|
-
return (_ctx, _cache) => {
|
|
709
|
-
return openBlock(), createElementBlock(Fragment, null, [
|
|
710
|
-
createElementVNode("tr", {
|
|
711
|
-
class: normalizeClass(["border-t break-inside-avoid", { "cursor-pointer": __props.isExpandable }]),
|
|
712
|
-
tabindex: __props.isExpandable ? 0 : void 0,
|
|
713
|
-
onClick: _cache[0] || (_cache[0] = ($event) => __props.handleToggleItems(__props.formatIndex(__props.invoicePeriodOrder, __props.groupOrder))),
|
|
714
|
-
onKeyup: [
|
|
715
|
-
_cache[1] || (_cache[1] = withKeys(($event) => __props.handleToggleItems(__props.formatIndex(__props.invoicePeriodOrder, __props.groupOrder)), ["enter"])),
|
|
716
|
-
_cache[2] || (_cache[2] = withKeys(($event) => __props.handleToggleItems(__props.formatIndex(__props.invoicePeriodOrder, __props.groupOrder)), ["space"]))
|
|
717
|
-
]
|
|
718
|
-
}, [
|
|
719
|
-
createVNode(_sfc_main$i, { class: "p-0" }, {
|
|
720
|
-
default: withCtx(() => [
|
|
721
|
-
__props.isExpandable ? (openBlock(), createBlock(_sfc_main$n, {
|
|
722
|
-
key: 0,
|
|
723
|
-
icon: "keyboard_arrow_down",
|
|
724
|
-
size: "md",
|
|
725
|
-
class: normalizeClass(["absolute -translate-x-7 text-slate-400", {
|
|
726
|
-
"-rotate-90": !__props.expandedItems.includes(
|
|
727
|
-
__props.formatIndex(__props.invoicePeriodOrder, __props.groupOrder)
|
|
728
|
-
)
|
|
729
|
-
}])
|
|
730
|
-
}, null, 8, ["class"])) : createCommentVNode("", true),
|
|
731
|
-
createTextVNode(" " + toDisplayString(unref(intl).$t({
|
|
732
|
-
id: "invoice.commitment_heading",
|
|
733
|
-
defaultMessage: "Commitment",
|
|
734
|
-
description: "Heading used for commitment in invoice tables"
|
|
735
|
-
})), 1)
|
|
736
|
-
]),
|
|
737
|
-
_: 1
|
|
738
|
-
}),
|
|
739
|
-
createVNode(_sfc_main$i, { number: "" }, {
|
|
740
|
-
default: withCtx(() => [
|
|
741
|
-
__props.amountType === "INCLUDING_TAX" ? (openBlock(), createBlock(_sfc_main$l, {
|
|
742
|
-
key: 0,
|
|
743
|
-
value: __props.group.amount_including_tax,
|
|
744
|
-
"data-testid": unref(INVOICE_PERIOD_TOTAL),
|
|
745
|
-
"data-type": unref(getInvoiceGroupAmountType)(__props.group)
|
|
746
|
-
}, null, 8, ["value", "data-testid", "data-type"])) : (openBlock(), createBlock(_sfc_main$l, {
|
|
747
|
-
key: 1,
|
|
748
|
-
value: __props.group.amount_excluding_tax,
|
|
749
|
-
"data-testid": unref(INVOICE_PERIOD_TOTAL),
|
|
750
|
-
"data-type": unref(getInvoiceGroupAmountType)(__props.group)
|
|
751
|
-
}, null, 8, ["value", "data-testid", "data-type"]))
|
|
752
|
-
]),
|
|
753
|
-
_: 1
|
|
754
|
-
})
|
|
755
|
-
], 42, _hoisted_1$a),
|
|
756
|
-
(__props.forceExpanded || __props.expandedItems.includes(__props.formatIndex(__props.invoicePeriodOrder, __props.groupOrder))) && __props.group.lines ? (openBlock(), createElementBlock("tr", _hoisted_2$6, [
|
|
757
|
-
createElementVNode("td", _hoisted_3$5, [
|
|
758
|
-
createElementVNode("div", _hoisted_4$5, [
|
|
759
|
-
createVNode(_sfc_main$d, {
|
|
760
|
-
commitments: __props.group.lines,
|
|
761
|
-
"format-index": __props.formatIndex,
|
|
762
|
-
"handle-toggle-items": __props.handleToggleItems,
|
|
763
|
-
"expanded-items": __props.expandedItems,
|
|
764
|
-
"is-expandable": __props.isExpandable,
|
|
765
|
-
"invoice-period-order": __props.invoicePeriodOrder,
|
|
766
|
-
"group-order": __props.groupOrder,
|
|
767
|
-
"processing-only-customers": __props.processingOnlyCustomers,
|
|
768
|
-
"display-invoice-sub-lines-per-processing-only-customer": __props.displayInvoiceSubLinesPerProcessingOnlyCustomer
|
|
769
|
-
}, {
|
|
770
|
-
"invoice-line-prefix": withCtx((linePrefixProps) => [
|
|
771
|
-
renderSlot(_ctx.$slots, "invoice-line-prefix", normalizeProps(guardReactiveProps(linePrefixProps)))
|
|
772
|
-
]),
|
|
773
|
-
_: 3
|
|
774
|
-
}, 8, ["commitments", "format-index", "handle-toggle-items", "expanded-items", "is-expandable", "invoice-period-order", "group-order", "processing-only-customers", "display-invoice-sub-lines-per-processing-only-customer"])
|
|
775
|
-
])
|
|
776
|
-
])
|
|
777
|
-
])) : createCommentVNode("", true)
|
|
778
|
-
], 64);
|
|
779
|
-
};
|
|
780
|
-
}
|
|
781
|
-
});
|
|
782
|
-
const _hoisted_1$9 = ["tabindex"];
|
|
783
|
-
const _hoisted_2$5 = { key: 0 };
|
|
784
|
-
const _hoisted_3$4 = {
|
|
785
|
-
colspan: "2",
|
|
786
|
-
class: "p-0"
|
|
787
|
-
};
|
|
788
|
-
const _hoisted_4$4 = { class: "-mx-9 bg-gray-50 px-9 py-3 text-xs" };
|
|
789
|
-
const _sfc_main$a = /* @__PURE__ */ defineComponent({
|
|
790
|
-
__name: "InvoiceGroupDiscountMarkup",
|
|
791
|
-
props: {
|
|
792
|
-
heading: {},
|
|
793
|
-
group: {},
|
|
794
|
-
expandedItems: {},
|
|
795
|
-
handleToggleItems: { type: Function },
|
|
796
|
-
formatIndex: { type: Function },
|
|
797
|
-
invoicePeriodOrder: {},
|
|
798
|
-
groupOrder: {},
|
|
799
|
-
isExpandable: { type: Boolean },
|
|
800
|
-
forceExpanded: { type: Boolean },
|
|
801
|
-
amountType: {},
|
|
802
|
-
processingOnlyCustomers: {},
|
|
803
|
-
displayInvoiceSubLinesPerProcessingOnlyCustomer: { type: Boolean },
|
|
804
|
-
showTaxPerLineItem: { type: Boolean }
|
|
805
|
-
},
|
|
806
|
-
setup(__props) {
|
|
807
|
-
return (_ctx, _cache) => {
|
|
808
|
-
return openBlock(), createElementBlock(Fragment, null, [
|
|
809
|
-
createElementVNode("tr", {
|
|
810
|
-
class: normalizeClass(["border-t break-inside-avoid", { "cursor-pointer": __props.isExpandable }]),
|
|
811
|
-
tabindex: __props.isExpandable ? 0 : void 0,
|
|
812
|
-
onClick: _cache[0] || (_cache[0] = ($event) => __props.handleToggleItems(__props.formatIndex(__props.invoicePeriodOrder, __props.groupOrder))),
|
|
813
|
-
onKeyup: [
|
|
814
|
-
_cache[1] || (_cache[1] = withKeys(($event) => __props.handleToggleItems(__props.formatIndex(__props.invoicePeriodOrder, __props.groupOrder)), ["enter"])),
|
|
815
|
-
_cache[2] || (_cache[2] = withKeys(($event) => __props.handleToggleItems(__props.formatIndex(__props.invoicePeriodOrder, __props.groupOrder)), ["space"]))
|
|
816
|
-
]
|
|
817
|
-
}, [
|
|
818
|
-
createVNode(_sfc_main$i, { class: "p-0" }, {
|
|
819
|
-
default: withCtx(() => [
|
|
820
|
-
__props.isExpandable ? (openBlock(), createBlock(_sfc_main$n, {
|
|
821
|
-
key: 0,
|
|
822
|
-
icon: "keyboard_arrow_down",
|
|
823
|
-
size: "md",
|
|
824
|
-
class: normalizeClass(["absolute -translate-x-7 text-slate-400", {
|
|
825
|
-
"-rotate-90": !__props.expandedItems.includes(
|
|
826
|
-
__props.formatIndex(__props.invoicePeriodOrder, __props.groupOrder)
|
|
827
|
-
)
|
|
828
|
-
}])
|
|
829
|
-
}, null, 8, ["class"])) : createCommentVNode("", true),
|
|
830
|
-
createTextVNode(" " + toDisplayString(__props.heading), 1)
|
|
831
|
-
]),
|
|
832
|
-
_: 1
|
|
833
|
-
}),
|
|
834
|
-
createVNode(_sfc_main$i, { number: "" }, {
|
|
835
|
-
default: withCtx(() => [
|
|
836
|
-
__props.amountType === "INCLUDING_TAX" ? (openBlock(), createBlock(_sfc_main$l, {
|
|
837
|
-
key: 0,
|
|
838
|
-
value: __props.group.amount_including_tax,
|
|
839
|
-
"data-testid": unref(INVOICE_PERIOD_TOTAL),
|
|
840
|
-
"data-type": unref(getInvoiceGroupAmountType)(__props.group)
|
|
841
|
-
}, null, 8, ["value", "data-testid", "data-type"])) : (openBlock(), createBlock(_sfc_main$l, {
|
|
842
|
-
key: 1,
|
|
843
|
-
value: __props.group.amount_excluding_tax,
|
|
844
|
-
"data-testid": unref(INVOICE_PERIOD_TOTAL),
|
|
845
|
-
"data-type": unref(getInvoiceGroupAmountType)(__props.group)
|
|
846
|
-
}, null, 8, ["value", "data-testid", "data-type"]))
|
|
847
|
-
]),
|
|
848
|
-
_: 1
|
|
849
|
-
})
|
|
850
|
-
], 42, _hoisted_1$9),
|
|
851
|
-
(__props.forceExpanded || __props.expandedItems.includes(__props.formatIndex(__props.invoicePeriodOrder, __props.groupOrder))) && __props.group.lines ? (openBlock(), createElementBlock("tr", _hoisted_2$5, [
|
|
852
|
-
createElementVNode("td", _hoisted_3$4, [
|
|
853
|
-
createElementVNode("div", _hoisted_4$4, [
|
|
854
|
-
createVNode(_sfc_main$c, {
|
|
855
|
-
type: __props.group.type,
|
|
856
|
-
lines: __props.group.lines,
|
|
857
|
-
"format-index": __props.formatIndex,
|
|
858
|
-
"handle-toggle-items": __props.handleToggleItems,
|
|
859
|
-
"expanded-items": __props.expandedItems,
|
|
860
|
-
"is-expandable": __props.isExpandable,
|
|
861
|
-
"invoice-period-order": __props.invoicePeriodOrder,
|
|
862
|
-
"group-order": __props.groupOrder,
|
|
863
|
-
"processing-only-customers": __props.processingOnlyCustomers,
|
|
864
|
-
"display-invoice-sub-lines-per-processing-only-customer": __props.displayInvoiceSubLinesPerProcessingOnlyCustomer
|
|
865
|
-
}, {
|
|
866
|
-
"invoice-line-prefix": withCtx((linePrefixProps) => [
|
|
867
|
-
renderSlot(_ctx.$slots, "invoice-line-prefix", normalizeProps(guardReactiveProps(linePrefixProps)))
|
|
868
|
-
]),
|
|
869
|
-
_: 3
|
|
870
|
-
}, 8, ["type", "lines", "format-index", "handle-toggle-items", "expanded-items", "is-expandable", "invoice-period-order", "group-order", "processing-only-customers", "display-invoice-sub-lines-per-processing-only-customer"])
|
|
871
|
-
])
|
|
872
|
-
])
|
|
873
|
-
])) : createCommentVNode("", true)
|
|
874
|
-
], 64);
|
|
875
|
-
};
|
|
876
|
-
}
|
|
877
|
-
});
|
|
878
|
-
const getInvoiceGroupOriginalCustomerId = (group, isShowOriginalCustomerInvoiceLine) => {
|
|
879
|
-
if (!isShowOriginalCustomerInvoiceLine) {
|
|
880
|
-
return void 0;
|
|
881
|
-
}
|
|
882
|
-
return group.forwarded_from_customer_id;
|
|
883
|
-
};
|
|
884
|
-
const resolveInvoiceLineTierBounds = (band) => {
|
|
885
|
-
let lowerBound = { kind: "default" };
|
|
886
|
-
let topBound = { kind: "default" };
|
|
887
|
-
if (band.tier_lower_bound && "number" in band.tier_lower_bound) {
|
|
888
|
-
lowerBound = { kind: "number", value: +band.tier_lower_bound.number };
|
|
889
|
-
} else if (band.tier_lower_bound && "amount" in band.tier_lower_bound) {
|
|
890
|
-
const { quantity, currency } = band.tier_lower_bound.amount;
|
|
891
|
-
lowerBound = { kind: "amount", currency, quantity: quantity ?? 0 };
|
|
892
|
-
}
|
|
893
|
-
if (band.tier_top_bound && "number" in band.tier_top_bound) {
|
|
894
|
-
topBound = { kind: "number", value: +band.tier_top_bound.number };
|
|
895
|
-
} else if (band.tier_top_bound && "amount" in band.tier_top_bound) {
|
|
896
|
-
const { quantity, currency } = band.tier_top_bound.amount;
|
|
897
|
-
topBound = { kind: "amount", currency, quantity };
|
|
898
|
-
}
|
|
899
|
-
return { lowerBound, topBound };
|
|
900
|
-
};
|
|
901
|
-
const resolveInvoiceLineStatusLabel = (details) => {
|
|
902
|
-
var _a, _b, _c, _d;
|
|
903
|
-
switch (details == null ? void 0 : details.price_bound) {
|
|
904
|
-
case "BELOW_MINIMUM_AMOUNT":
|
|
905
|
-
return { kind: "band_minimum_amount", amount: (_a = details.band) == null ? void 0 : _a.minimum_amount };
|
|
906
|
-
case "NOT_HIT":
|
|
907
|
-
return { kind: "price_bound_within_bounds" };
|
|
908
|
-
case "ABOVE_MAXIMUM_AMOUNT":
|
|
909
|
-
return { kind: "price_bound_maximum_amount", amount: (_b = details.band) == null ? void 0 : _b.maximum_amount };
|
|
910
|
-
case "BELOW_MINIMUM_NUMBER":
|
|
911
|
-
return { kind: "band_minimum_number", value: (_c = details.band) == null ? void 0 : _c.minimum_number };
|
|
912
|
-
case "ABOVE_MAXIMUM_NUMBER":
|
|
913
|
-
return { kind: "band_maximum_number", value: (_d = details.band) == null ? void 0 : _d.maximum_number };
|
|
914
|
-
default:
|
|
915
|
-
return { kind: "none" };
|
|
916
|
-
}
|
|
917
|
-
};
|
|
918
|
-
const _hoisted_1$8 = { class: "items-left flex flex-col gap-1 leading-none" };
|
|
919
|
-
const _hoisted_2$4 = { class: "flex items-center" };
|
|
920
|
-
const _hoisted_3$3 = {
|
|
921
|
-
key: 0,
|
|
922
|
-
class: "ml-1 text-xs text-secondary"
|
|
923
|
-
};
|
|
924
|
-
const _hoisted_4$3 = { key: 0 };
|
|
925
|
-
const _hoisted_5$2 = {
|
|
926
|
-
key: 1,
|
|
927
|
-
class: "text-xs text-secondary"
|
|
928
|
-
};
|
|
929
|
-
const _hoisted_6$2 = {
|
|
930
|
-
key: 2,
|
|
931
|
-
class: "text-xs text-secondary"
|
|
932
|
-
};
|
|
933
|
-
const _hoisted_7$2 = { class: "text-[9pt] text-secondary" };
|
|
934
|
-
const _sfc_main$9 = /* @__PURE__ */ defineComponent({
|
|
935
|
-
__name: "InvoiceLineRow",
|
|
936
|
-
props: {
|
|
937
|
-
data: {},
|
|
938
|
-
isLast: { type: Boolean },
|
|
939
|
-
periodOrder: {},
|
|
940
|
-
groupOrder: {},
|
|
941
|
-
groupType: {},
|
|
942
|
-
isExpanded: { type: Boolean }
|
|
943
|
-
},
|
|
944
|
-
setup(__props) {
|
|
945
|
-
const { $t, formatNumber } = useIntl();
|
|
946
|
-
const props = __props;
|
|
947
|
-
const formatTierBound = (bound) => {
|
|
948
|
-
if (bound.kind === "default") return void 0;
|
|
949
|
-
if (bound.kind === "number") return formatNumber(bound.value);
|
|
950
|
-
return `${bound.currency} ${bound.quantity}`;
|
|
951
|
-
};
|
|
952
|
-
const formattedTier = (band) => {
|
|
953
|
-
if (!band) return "";
|
|
954
|
-
const { lowerBound, topBound } = resolveInvoiceLineTierBounds(band);
|
|
955
|
-
const formattedTopBound = formatTierBound(topBound);
|
|
956
|
-
return (formatTierBound(lowerBound) ?? "0") + (formattedTopBound ? ` - ${formattedTopBound}` : "+");
|
|
957
|
-
};
|
|
958
|
-
const includedVolumeDetails = computed(() => {
|
|
959
|
-
var _a;
|
|
960
|
-
return (_a = props.data.details) == null ? void 0 : _a.included_volume_details;
|
|
961
|
-
});
|
|
962
|
-
const statusLabel = computed(() => resolveInvoiceLineStatusLabel(props.data.details));
|
|
963
|
-
const invoiceLineName = computed(() => {
|
|
964
|
-
var _a, _b;
|
|
965
|
-
if ((_a = props.data) == null ? void 0 : _a.product_items) {
|
|
966
|
-
return getComposedString(props.data.product_items.map((item) => item.name));
|
|
967
|
-
}
|
|
968
|
-
return ((_b = props.data) == null ? void 0 : _b.description) ?? "N/A";
|
|
969
|
-
});
|
|
970
|
-
return (_ctx, _cache) => {
|
|
971
|
-
return openBlock(), createElementBlock(Fragment, null, [
|
|
972
|
-
createVNode(_sfc_main$i, { class: "align-top" }, {
|
|
973
|
-
default: withCtx(() => {
|
|
974
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _i;
|
|
975
|
-
return [
|
|
976
|
-
createElementVNode("div", _hoisted_1$8, [
|
|
977
|
-
createElementVNode("div", null, [
|
|
978
|
-
__props.data.sub_lines ? (openBlock(), createBlock(_sfc_main$n, {
|
|
979
|
-
key: 0,
|
|
980
|
-
icon: "keyboard_arrow_down",
|
|
981
|
-
size: "md",
|
|
982
|
-
class: normalizeClass(["absolute -translate-x-7 -translate-y-2 text-slate-400", {
|
|
983
|
-
"-rotate-90": !__props.isExpanded
|
|
984
|
-
}])
|
|
985
|
-
}, null, 8, ["class"])) : createCommentVNode("", true),
|
|
986
|
-
createElementVNode("div", _hoisted_2$4, [
|
|
987
|
-
renderSlot(_ctx.$slots, "invoice-line-prefix", {
|
|
988
|
-
lineOrder: __props.data.line_order,
|
|
989
|
-
periodOrder: __props.periodOrder,
|
|
990
|
-
groupOrder: __props.groupOrder
|
|
991
|
-
}),
|
|
992
|
-
["PRICING", "REVENUE", "ONE_OFF"].includes(__props.data.type) ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
|
|
993
|
-
createTextVNode(toDisplayString(invoiceLineName.value) + " ", 1),
|
|
994
|
-
__props.data.type === "ONE_OFF" && __props.groupType !== "ONE_OFF" ? (openBlock(), createElementBlock("div", _hoisted_3$3, toDisplayString(unref(formatEnum)(__props.data.type)), 1)) : createCommentVNode("", true)
|
|
995
|
-
], 64)) : (openBlock(), createBlock(_sfc_main$e, {
|
|
996
|
-
key: 1,
|
|
997
|
-
"invoice-line-description": invoiceLineName.value,
|
|
998
|
-
"clause-type": __props.data.type,
|
|
999
|
-
"price-details-band": (_a = __props.data.details) == null ? void 0 : _a.band
|
|
1000
|
-
}, null, 8, ["invoice-line-description", "clause-type", "price-details-band"]))
|
|
1001
|
-
])
|
|
1002
|
-
]),
|
|
1003
|
-
["TIERED", "STAIR_STEP", "TOP_TIERED"].includes(__props.data.pricing_type) && !includedVolumeDetails.value && ((_b = __props.data.details) == null ? void 0 : _b.band) ? (openBlock(), createElementBlock("div", _hoisted_4$3, toDisplayString(formattedTier((_c = __props.data.details) == null ? void 0 : _c.band)), 1)) : createCommentVNode("", true),
|
|
1004
|
-
((_e = (_d = __props.data.details) == null ? void 0 : _d.split_pricing) == null ? void 0 : _e.meter_properties) ? (openBlock(), createElementBlock("span", _hoisted_5$2, [
|
|
1005
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList((_g = (_f = __props.data.details) == null ? void 0 : _f.split_pricing) == null ? void 0 : _g.meter_properties, (meterProperty, index) => {
|
|
1006
|
-
return openBlock(), createElementBlock(Fragment, null, [
|
|
1007
|
-
createTextVNode(toDisplayString(meterProperty.meter_property.name) + ": " + toDisplayString(meterProperty.value), 1),
|
|
1008
|
-
index < __props.data.details.split_pricing.meter_properties.length - 1 ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
|
|
1009
|
-
createTextVNode(toDisplayString(", "))
|
|
1010
|
-
], 64)) : createCommentVNode("", true)
|
|
1011
|
-
], 64);
|
|
1012
|
-
}), 256))
|
|
1013
|
-
])) : createCommentVNode("", true),
|
|
1014
|
-
((_h = __props.data.conditions) == null ? void 0 : _h.name) || ((_i = __props.data.conditions) == null ? void 0 : _i.meter_properties) ? (openBlock(), createElementBlock("div", _hoisted_6$2, [
|
|
1015
|
-
__props.data.conditions.name ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
|
|
1016
|
-
createTextVNode(toDisplayString(__props.data.conditions.name), 1)
|
|
1017
|
-
], 64)) : __props.data.conditions.meter_properties ? (openBlock(), createBlock(unref(_sfc_main$k), {
|
|
1018
|
-
key: 1,
|
|
1019
|
-
comparators: __props.data.conditions.meter_properties
|
|
1020
|
-
}, null, 8, ["comparators"])) : createCommentVNode("", true)
|
|
1021
|
-
])) : createCommentVNode("", true)
|
|
1022
|
-
]),
|
|
1023
|
-
createElementVNode("span", _hoisted_7$2, [
|
|
1024
|
-
statusLabel.value.kind === "band_minimum_amount" ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
|
|
1025
|
-
createTextVNode(toDisplayString(unref($t)({
|
|
1026
|
-
id: "invoice.line.band_minimum_amount",
|
|
1027
|
-
defaultMessage: "Band minimum amount",
|
|
1028
|
-
description: "Minimum amount specified in a band"
|
|
1029
|
-
})) + " ", 1),
|
|
1030
|
-
statusLabel.value.amount ? (openBlock(), createBlock(_sfc_main$l, {
|
|
1031
|
-
key: 0,
|
|
1032
|
-
value: statusLabel.value.amount
|
|
1033
|
-
}, null, 8, ["value"])) : createCommentVNode("", true)
|
|
1034
|
-
], 64)) : statusLabel.value.kind === "price_bound_within_bounds" ? (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
|
1035
|
-
createTextVNode(toDisplayString(unref($t)({
|
|
1036
|
-
id: "invoice.line.price_bound_within_bounds",
|
|
1037
|
-
defaultMessage: "Within bounds",
|
|
1038
|
-
description: "Label used when min and max bounds are specified but reached"
|
|
1039
|
-
})), 1)
|
|
1040
|
-
], 64)) : statusLabel.value.kind === "price_bound_maximum_amount" ? (openBlock(), createElementBlock(Fragment, { key: 2 }, [
|
|
1041
|
-
createTextVNode(toDisplayString(unref($t)({
|
|
1042
|
-
id: "invoice.line.price_bound_maximum_amount",
|
|
1043
|
-
defaultMessage: "Maximum amount",
|
|
1044
|
-
description: "Maximum amount specified in a band"
|
|
1045
|
-
})) + " ", 1),
|
|
1046
|
-
statusLabel.value.amount ? (openBlock(), createBlock(_sfc_main$l, {
|
|
1047
|
-
key: 0,
|
|
1048
|
-
value: statusLabel.value.amount
|
|
1049
|
-
}, null, 8, ["value"])) : createCommentVNode("", true)
|
|
1050
|
-
], 64)) : statusLabel.value.kind === "band_minimum_number" ? (openBlock(), createElementBlock(Fragment, { key: 3 }, [
|
|
1051
|
-
createTextVNode(toDisplayString(unref($t)({
|
|
1052
|
-
id: "invoice.line.band_minimum_number",
|
|
1053
|
-
defaultMessage: "Minimum number",
|
|
1054
|
-
description: "Minimum number of units specified in a band"
|
|
1055
|
-
})) + " " + toDisplayString(statusLabel.value.value), 1)
|
|
1056
|
-
], 64)) : statusLabel.value.kind === "band_maximum_number" ? (openBlock(), createElementBlock(Fragment, { key: 4 }, [
|
|
1057
|
-
createTextVNode(toDisplayString(unref($t)({
|
|
1058
|
-
id: "invoice.line.band_maximum_number",
|
|
1059
|
-
defaultMessage: "Maximum number",
|
|
1060
|
-
description: "Maximum number of units specified in a band"
|
|
1061
|
-
})) + " " + toDisplayString(statusLabel.value.value), 1)
|
|
1062
|
-
], 64)) : createCommentVNode("", true)
|
|
1063
|
-
])
|
|
1064
|
-
];
|
|
1065
|
-
}),
|
|
1066
|
-
_: 3
|
|
1067
|
-
}),
|
|
1068
|
-
renderSlot(_ctx.$slots, "line-content", {
|
|
1069
|
-
details: __props.data.details
|
|
1070
|
-
})
|
|
1071
|
-
], 64);
|
|
1072
|
-
};
|
|
1073
|
-
}
|
|
1074
|
-
});
|
|
1075
|
-
const resolveInvoiceRowQuantity = (pricingType, details, preferConversionCredits) => {
|
|
1076
|
-
var _a, _b;
|
|
1077
|
-
if (pricingType === "PASS_THROUGH") return { kind: "hidden" };
|
|
1078
|
-
if (preferConversionCredits && ((_b = (_a = details == null ? void 0 : details.conversion) == null ? void 0 : _a.credits) == null ? void 0 : _b.quantity)) {
|
|
1079
|
-
return { kind: "conversion-credits", value: details.conversion.credits.quantity };
|
|
1080
|
-
}
|
|
1081
|
-
if (details == null ? void 0 : details.price_bound) {
|
|
1082
|
-
const { price_bound: priceBound, meter_value: meterValue, band } = details;
|
|
1083
|
-
if (priceBound === "BELOW_MINIMUM_AMOUNT" || priceBound === "ABOVE_MAXIMUM_AMOUNT") {
|
|
1084
|
-
return { kind: "raw", value: meterValue.count };
|
|
1085
|
-
}
|
|
1086
|
-
if (priceBound === "NOT_HIT" && "amount" in meterValue && meterValue.amount) {
|
|
1087
|
-
return { kind: "amount", amount: meterValue.amount };
|
|
1088
|
-
}
|
|
1089
|
-
if (priceBound === "NOT_HIT" && "number" in meterValue && meterValue.number) {
|
|
1090
|
-
return { kind: "raw", value: meterValue.number };
|
|
1091
|
-
}
|
|
1092
|
-
if (priceBound === "RATIO" && meterValue.number) {
|
|
1093
|
-
return { kind: "number", value: +meterValue.number };
|
|
1094
|
-
}
|
|
1095
|
-
if (priceBound === "BELOW_MINIMUM_NUMBER" && (band == null ? void 0 : band.minimum_number)) {
|
|
1096
|
-
return { kind: "number", value: +band.minimum_number };
|
|
1097
|
-
}
|
|
1098
|
-
if (priceBound === "ABOVE_MAXIMUM_NUMBER" && (band == null ? void 0 : band.maximum_number)) {
|
|
1099
|
-
return { kind: "number", value: +band.maximum_number };
|
|
1100
|
-
}
|
|
1101
|
-
return { kind: "hidden" };
|
|
1102
|
-
}
|
|
1103
|
-
if ((details == null ? void 0 : details.meter_value) && "number" in details.meter_value) {
|
|
1104
|
-
return { kind: "number", value: +details.meter_value.number };
|
|
1105
|
-
}
|
|
1106
|
-
if ((details == null ? void 0 : details.meter_value) && "amount" in details.meter_value) {
|
|
1107
|
-
return { kind: "amount", amount: details.meter_value.amount };
|
|
1108
|
-
}
|
|
1109
|
-
return { kind: "one" };
|
|
1110
|
-
};
|
|
1111
|
-
const BOUNDED_NUMBER_PRICE_BOUNDS = ["NOT_HIT", "BELOW_MINIMUM_NUMBER", "ABOVE_MAXIMUM_NUMBER"];
|
|
1112
|
-
const resolveInvoiceRowPrice = (pricingType, details, modelType) => {
|
|
1113
|
-
if (pricingType === "PASS_THROUGH") return { kind: "pass-through" };
|
|
1114
|
-
if (details == null ? void 0 : details.price_bound) {
|
|
1115
|
-
const { price_bound: priceBound, band: band2, amount: amount2 } = details;
|
|
1116
|
-
if (priceBound === "BELOW_MINIMUM_AMOUNT" && (band2 == null ? void 0 : band2.minimum_amount)) {
|
|
1117
|
-
return { kind: "amount", amount: band2.minimum_amount };
|
|
1118
|
-
}
|
|
1119
|
-
if (priceBound === "ABOVE_MAXIMUM_AMOUNT" && (band2 == null ? void 0 : band2.maximum_amount)) {
|
|
1120
|
-
return { kind: "amount", amount: band2.maximum_amount };
|
|
1121
|
-
}
|
|
1122
|
-
if (priceBound === "RATIO") {
|
|
1123
|
-
const perSeatAmount = modelType === "PER_SEAT" ? band2 == null ? void 0 : band2.amount : void 0;
|
|
1124
|
-
return { kind: "amount", amount: perSeatAmount ?? amount2, suffix: { kind: "tier-top-bound" } };
|
|
1125
|
-
}
|
|
1126
|
-
if (BOUNDED_NUMBER_PRICE_BOUNDS.includes(priceBound)) {
|
|
1127
|
-
if (band2 && band2.amount) {
|
|
1128
|
-
return { kind: "amount", amount: band2.amount };
|
|
1129
|
-
}
|
|
1130
|
-
if (band2 && "percentage" in band2) {
|
|
1131
|
-
return { kind: "percentage", value: band2.percentage };
|
|
1132
|
-
}
|
|
1133
|
-
if (band2 && amount2) {
|
|
1134
|
-
return { kind: "amount", amount: amount2, suffix: { kind: "fixed-amount" } };
|
|
1135
|
-
}
|
|
1136
|
-
}
|
|
1137
|
-
return { kind: "hidden" };
|
|
1138
|
-
}
|
|
1139
|
-
const band = details == null ? void 0 : details.band;
|
|
1140
|
-
const amount = details == null ? void 0 : details.amount;
|
|
1141
|
-
if (band && band.amount) {
|
|
1142
|
-
return { kind: "amount", amount: band.amount, suffix: { kind: "block-size-or-per-unit" } };
|
|
1143
|
-
}
|
|
1144
|
-
if (band && "percentage" in band) {
|
|
1145
|
-
return { kind: "percentage", value: band.percentage };
|
|
1146
|
-
}
|
|
1147
|
-
if (band && amount) {
|
|
1148
|
-
if (pricingType === "STAIR_STEP" || pricingType === "STAIR_STEP_TOP_UP") {
|
|
1149
|
-
return { kind: "amount", amount, suffix: { kind: "fixed-amount" } };
|
|
1150
|
-
}
|
|
1151
|
-
if (pricingType === "TOP_TIERED") {
|
|
1152
|
-
return { kind: "amount", amount, suffix: { kind: "per-unit" } };
|
|
1153
|
-
}
|
|
1154
|
-
if (pricingType === "FLAT") {
|
|
1155
|
-
return { kind: "amount", amount, suffix: { kind: "flat-fee" } };
|
|
1156
|
-
}
|
|
1157
|
-
return { kind: "amount", amount };
|
|
1158
|
-
}
|
|
1159
|
-
return { kind: "hidden" };
|
|
1160
|
-
};
|
|
1161
|
-
const _hoisted_1$7 = {
|
|
1162
|
-
key: 5,
|
|
1163
|
-
class: "text-xs text-secondary"
|
|
1164
|
-
};
|
|
1165
|
-
const _hoisted_2$3 = {
|
|
1166
|
-
key: 1,
|
|
1167
|
-
class: "tabular-nums"
|
|
1168
|
-
};
|
|
1169
|
-
const _hoisted_3$2 = {
|
|
1170
|
-
key: 0,
|
|
1171
|
-
class: "text-2xs text-secondary"
|
|
1172
|
-
};
|
|
1173
|
-
const _hoisted_4$2 = {
|
|
1174
|
-
key: 1,
|
|
1175
|
-
class: "text-2xs text-secondary"
|
|
1176
|
-
};
|
|
1177
|
-
const _hoisted_5$1 = {
|
|
1178
|
-
key: 0,
|
|
1179
|
-
class: "text-2xs text-secondary"
|
|
1180
|
-
};
|
|
1181
|
-
const _hoisted_6$1 = {
|
|
1182
|
-
key: 1,
|
|
1183
|
-
class: "text-2xs text-secondary"
|
|
1184
|
-
};
|
|
1185
|
-
const _hoisted_7$1 = {
|
|
1186
|
-
key: 2,
|
|
1187
|
-
class: "text-2xs text-secondary"
|
|
1188
|
-
};
|
|
1189
|
-
const _hoisted_8$1 = {
|
|
1190
|
-
key: 3,
|
|
1191
|
-
class: "text-2xs text-secondary"
|
|
1192
|
-
};
|
|
1193
|
-
const _hoisted_9$1 = {
|
|
1194
|
-
key: 4,
|
|
1195
|
-
class: "text-2xs text-secondary"
|
|
1196
|
-
};
|
|
1197
|
-
const _hoisted_10$1 = { class: "text-2xs text-secondary" };
|
|
1198
|
-
const _hoisted_11$1 = {
|
|
1199
|
-
key: 0,
|
|
1200
|
-
class: "flex justify-end"
|
|
1201
|
-
};
|
|
1202
|
-
const _hoisted_12$1 = { class: "flex items-center justify-end gap-1" };
|
|
1203
|
-
const _hoisted_13$1 = {
|
|
1204
|
-
key: 0,
|
|
1205
|
-
class: "text-2xs tabular-nums text-secondary"
|
|
1206
|
-
};
|
|
1207
|
-
const _hoisted_14$1 = {
|
|
1208
|
-
key: 1,
|
|
1209
|
-
class: "inline-block"
|
|
1210
|
-
};
|
|
1211
|
-
const _hoisted_15$1 = { class: "flex items-center justify-end gap-1" };
|
|
1212
|
-
const _sfc_main$8 = /* @__PURE__ */ defineComponent({
|
|
1213
|
-
__name: "InvoiceRowContent",
|
|
1214
|
-
props: {
|
|
1215
|
-
pricingType: {},
|
|
1216
|
-
details: {},
|
|
1217
|
-
taxCategories: {},
|
|
1218
|
-
amountType: {},
|
|
1219
|
-
hideTaxDetails: { type: Boolean },
|
|
1220
|
-
modelType: {},
|
|
1221
|
-
showTaxPerLineItem: { type: Boolean, default: true },
|
|
1222
|
-
preferConversionCredits: { type: Boolean }
|
|
1223
|
-
},
|
|
1224
|
-
setup(__props) {
|
|
1225
|
-
const props = __props;
|
|
1226
|
-
const includedVolumeDetails = computed(() => {
|
|
1227
|
-
var _a;
|
|
1228
|
-
return (_a = props.details) == null ? void 0 : _a.included_volume_details;
|
|
1229
|
-
});
|
|
1230
|
-
const availableIncludedVolume = computed(
|
|
1231
|
-
() => {
|
|
1232
|
-
var _a;
|
|
1233
|
-
return (_a = includedVolumeDetails.value) == null ? void 0 : _a.available_included_volume;
|
|
1234
|
-
}
|
|
1235
|
-
);
|
|
1236
|
-
const quantityDisplay = computed(
|
|
1237
|
-
() => resolveInvoiceRowQuantity(props.pricingType, props.details, props.preferConversionCredits)
|
|
1238
|
-
);
|
|
1239
|
-
const priceDisplay = computed(
|
|
1240
|
-
() => resolveInvoiceRowPrice(props.pricingType, props.details, props.modelType)
|
|
1241
|
-
);
|
|
1242
|
-
const { $t, formatNumber } = useIntl();
|
|
1243
|
-
const fixedAmountLabel = computed(
|
|
1244
|
-
() => $t({
|
|
1245
|
-
id: "invoice.line.fixed_amount",
|
|
1246
|
-
defaultMessage: "Fixed amount",
|
|
1247
|
-
description: "Label shown when a price band charges a fixed amount regardless of usage"
|
|
1248
|
-
})
|
|
1249
|
-
);
|
|
1250
|
-
const flatFeeLabel = computed(
|
|
1251
|
-
() => $t({
|
|
1252
|
-
id: "invoice.line.flat_fee",
|
|
1253
|
-
defaultMessage: "Flat fee",
|
|
1254
|
-
description: "Label shown for a flat, usage-independent fee"
|
|
1255
|
-
})
|
|
1256
|
-
);
|
|
1257
|
-
const tierTopBoundNumber = computed(() => {
|
|
1258
|
-
var _a, _b;
|
|
1259
|
-
const tierTopBound = (_b = (_a = props.details) == null ? void 0 : _a.band) == null ? void 0 : _b.tier_top_bound;
|
|
1260
|
-
return tierTopBound && "number" in tierTopBound ? tierTopBound.number : void 0;
|
|
1261
|
-
});
|
|
1262
|
-
const tierTopBoundUnitsLabel = computed(() => {
|
|
1263
|
-
if (tierTopBoundNumber.value === void 0) return void 0;
|
|
1264
|
-
return $t(
|
|
1265
|
-
{
|
|
1266
|
-
id: "invoice.line.per_units_tier_top_bound",
|
|
1267
|
-
defaultMessage: "per {count, plural, one {unit} other {{formattedCount} units}}",
|
|
1268
|
-
description: "Number of units a tiered price band applies per. Singular form omits the count."
|
|
1269
|
-
},
|
|
1270
|
-
{ count: +tierTopBoundNumber.value, formattedCount: tierTopBoundNumber.value }
|
|
1271
|
-
);
|
|
1272
|
-
});
|
|
1273
|
-
const perSeatAmount = computed(
|
|
1274
|
-
() => {
|
|
1275
|
-
var _a, _b;
|
|
1276
|
-
return props.modelType === "PER_SEAT" ? (_b = (_a = props.details) == null ? void 0 : _a.band) == null ? void 0 : _b.amount : void 0;
|
|
1277
|
-
}
|
|
1278
|
-
);
|
|
1279
|
-
const perUnitLabel = computed(
|
|
1280
|
-
() => props.modelType === "PER_SEAT" ? $t({
|
|
1281
|
-
id: "invoice.line.per_seat",
|
|
1282
|
-
defaultMessage: "Per seat",
|
|
1283
|
-
description: "Label shown when a price band applies per single seat"
|
|
1284
|
-
}) : $t({
|
|
1285
|
-
id: "invoice.line.per_unit",
|
|
1286
|
-
defaultMessage: "Per unit",
|
|
1287
|
-
description: "Label shown when a price band applies per single unit"
|
|
1288
|
-
})
|
|
1289
|
-
);
|
|
1290
|
-
const blockSizeNumber = computed(() => {
|
|
1291
|
-
var _a, _b;
|
|
1292
|
-
const blockSize = (_b = (_a = props.details) == null ? void 0 : _a.band) == null ? void 0 : _b.block_size;
|
|
1293
|
-
return blockSize && "number" in blockSize ? blockSize.number : void 0;
|
|
1294
|
-
});
|
|
1295
|
-
const blockSizeUnitsLabel = computed(() => {
|
|
1296
|
-
if (blockSizeNumber.value === void 0) return void 0;
|
|
1297
|
-
return $t(
|
|
1298
|
-
{
|
|
1299
|
-
id: "invoice.line.per_units_block_size",
|
|
1300
|
-
defaultMessage: "Per {count, plural, one {unit} other {{formattedCount} units}}",
|
|
1301
|
-
description: "Number of units a price band block applies per. Singular form omits the count."
|
|
1302
|
-
},
|
|
1303
|
-
{
|
|
1304
|
-
count: +blockSizeNumber.value,
|
|
1305
|
-
formattedCount: formatNumber(+blockSizeNumber.value)
|
|
1306
|
-
}
|
|
1307
|
-
);
|
|
1308
|
-
});
|
|
1309
|
-
return (_ctx, _cache) => {
|
|
1310
|
-
return openBlock(), createElementBlock(Fragment, null, [
|
|
1311
|
-
createVNode(_sfc_main$i, {
|
|
1312
|
-
number: "",
|
|
1313
|
-
class: "align-top"
|
|
1314
|
-
}, {
|
|
1315
|
-
default: withCtx(() => {
|
|
1316
|
-
var _a;
|
|
1317
|
-
return [
|
|
1318
|
-
quantityDisplay.value.kind === "raw" ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
|
|
1319
|
-
createTextVNode(toDisplayString(quantityDisplay.value.value), 1)
|
|
1320
|
-
], 64)) : quantityDisplay.value.kind === "amount" ? (openBlock(), createBlock(_sfc_main$l, {
|
|
1321
|
-
key: 1,
|
|
1322
|
-
value: quantityDisplay.value.amount
|
|
1323
|
-
}, null, 8, ["value"])) : quantityDisplay.value.kind === "number" ? (openBlock(), createElementBlock(Fragment, { key: 2 }, [
|
|
1324
|
-
createTextVNode(toDisplayString(unref(formatNumber)(quantityDisplay.value.value)), 1)
|
|
1325
|
-
], 64)) : quantityDisplay.value.kind === "conversion-credits" ? (openBlock(), createElementBlock(Fragment, { key: 3 }, [
|
|
1326
|
-
createTextVNode(toDisplayString(unref(formatNumber)(+quantityDisplay.value.value, {
|
|
1327
|
-
maximumFractionDigits: unref(MAX_FRACTION_DIGITS)
|
|
1328
|
-
})), 1)
|
|
1329
|
-
], 64)) : quantityDisplay.value.kind === "one" ? (openBlock(), createElementBlock(Fragment, { key: 4 }, [
|
|
1330
|
-
createTextVNode("1")
|
|
1331
|
-
], 64)) : createCommentVNode("", true),
|
|
1332
|
-
quantityDisplay.value.kind !== "conversion-credits" && quantityDisplay.value.kind !== "hidden" && !((_a = __props.details) == null ? void 0 : _a.price_bound) && availableIncludedVolume.value ? (openBlock(), createElementBlock("div", _hoisted_1$7, [
|
|
1333
|
-
availableIncludedVolume.value.type === "AMOUNT" ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
|
|
1334
|
-
createVNode(_sfc_main$l, {
|
|
1335
|
-
value: availableIncludedVolume.value.amount
|
|
1336
|
-
}, null, 8, ["value"]),
|
|
1337
|
-
createTextVNode(" " + toDisplayString(unref($t)({
|
|
1338
|
-
id: "invoice.line.included",
|
|
1339
|
-
defaultMessage: "included",
|
|
1340
|
-
description: "Used to specify an included amount. Should be lowercase."
|
|
1341
|
-
})), 1)
|
|
1342
|
-
], 64)) : availableIncludedVolume.value.type === "NUMBER" ? (openBlock(), createElementBlock("span", _hoisted_2$3, toDisplayString(availableIncludedVolume.value.number) + " " + toDisplayString(unref($t)({
|
|
1343
|
-
id: "invoice.line.units_included",
|
|
1344
|
-
defaultMessage: "units included",
|
|
1345
|
-
description: "Used to specify an included units. Should be lowercase."
|
|
1346
|
-
})), 1)) : createCommentVNode("", true)
|
|
1347
|
-
])) : createCommentVNode("", true)
|
|
1348
|
-
];
|
|
1349
|
-
}),
|
|
1350
|
-
_: 1
|
|
1351
|
-
}),
|
|
1352
|
-
priceDisplay.value.kind === "pass-through" ? (openBlock(), createBlock(_sfc_main$i, {
|
|
1353
|
-
key: 0,
|
|
1354
|
-
class: "text-right align-top"
|
|
1355
|
-
}, {
|
|
1356
|
-
default: withCtx(() => [
|
|
1357
|
-
createTextVNode(toDisplayString(unref($t)({
|
|
1358
|
-
id: "invoice.line.pass_through",
|
|
1359
|
-
defaultMessage: "Pass through",
|
|
1360
|
-
description: "Name of the pass through pricing type"
|
|
1361
|
-
})), 1)
|
|
1362
|
-
]),
|
|
1363
|
-
_: 1
|
|
1364
|
-
})) : (openBlock(), createBlock(_sfc_main$i, {
|
|
1365
|
-
key: 1,
|
|
1366
|
-
number: "",
|
|
1367
|
-
class: "align-top"
|
|
1368
|
-
}, {
|
|
1369
|
-
default: withCtx(() => {
|
|
1370
|
-
var _a, _b, _c, _d, _e;
|
|
1371
|
-
return [
|
|
1372
|
-
priceDisplay.value.kind === "amount" ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
|
|
1373
|
-
createVNode(_sfc_main$l, {
|
|
1374
|
-
value: priceDisplay.value.amount
|
|
1375
|
-
}, null, 8, ["value"]),
|
|
1376
|
-
((_a = priceDisplay.value.suffix) == null ? void 0 : _a.kind) === "tier-top-bound" ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
|
|
1377
|
-
tierTopBoundUnitsLabel.value ? (openBlock(), createElementBlock("div", _hoisted_3$2, toDisplayString(tierTopBoundUnitsLabel.value), 1)) : perSeatAmount.value ? (openBlock(), createElementBlock("div", _hoisted_4$2, toDisplayString(perUnitLabel.value), 1)) : createCommentVNode("", true)
|
|
1378
|
-
], 64)) : ((_b = priceDisplay.value.suffix) == null ? void 0 : _b.kind) === "block-size-or-per-unit" ? (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
|
1379
|
-
blockSizeUnitsLabel.value ? (openBlock(), createElementBlock("div", _hoisted_5$1, toDisplayString(blockSizeUnitsLabel.value), 1)) : __props.modelType !== "RECURRING" ? (openBlock(), createElementBlock("div", _hoisted_6$1, toDisplayString(perUnitLabel.value), 1)) : createCommentVNode("", true)
|
|
1380
|
-
], 64)) : ((_c = priceDisplay.value.suffix) == null ? void 0 : _c.kind) === "per-unit" ? (openBlock(), createElementBlock("div", _hoisted_7$1, toDisplayString(perUnitLabel.value), 1)) : ((_d = priceDisplay.value.suffix) == null ? void 0 : _d.kind) === "fixed-amount" ? (openBlock(), createElementBlock("div", _hoisted_8$1, toDisplayString(fixedAmountLabel.value), 1)) : ((_e = priceDisplay.value.suffix) == null ? void 0 : _e.kind) === "flat-fee" ? (openBlock(), createElementBlock("div", _hoisted_9$1, toDisplayString(flatFeeLabel.value), 1)) : createCommentVNode("", true)
|
|
1381
|
-
], 64)) : priceDisplay.value.kind === "percentage" ? (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
|
1382
|
-
createTextVNode(toDisplayString(priceDisplay.value.value) + "% ", 1)
|
|
1383
|
-
], 64)) : createCommentVNode("", true)
|
|
1384
|
-
];
|
|
1385
|
-
}),
|
|
1386
|
-
_: 1
|
|
1387
|
-
})),
|
|
1388
|
-
__props.showTaxPerLineItem ? (openBlock(), createBlock(_sfc_main$i, {
|
|
1389
|
-
key: 2,
|
|
1390
|
-
number: "",
|
|
1391
|
-
class: "align-top"
|
|
1392
|
-
}, {
|
|
1393
|
-
default: withCtx(() => [
|
|
1394
|
-
!__props.hideTaxDetails ? (openBlock(true), createElementBlock(Fragment, { key: 0 }, renderList(__props.taxCategories, (taxCategory, taxCategoryIndex) => {
|
|
1395
|
-
return openBlock(), createElementBlock("div", {
|
|
1396
|
-
key: taxCategoryIndex,
|
|
1397
|
-
class: "tabular-nums"
|
|
1398
|
-
}, [
|
|
1399
|
-
createElementVNode("div", null, toDisplayString(taxCategory.percentage) + "%", 1),
|
|
1400
|
-
createElementVNode("div", _hoisted_10$1, [
|
|
1401
|
-
createVNode(_sfc_main$l, {
|
|
1402
|
-
value: taxCategory.tax_amount
|
|
1403
|
-
}, null, 8, ["value"])
|
|
1404
|
-
])
|
|
1405
|
-
]);
|
|
1406
|
-
}), 128)) : createCommentVNode("", true)
|
|
1407
|
-
]),
|
|
1408
|
-
_: 1
|
|
1409
|
-
})) : createCommentVNode("", true),
|
|
1410
|
-
createVNode(_sfc_main$i, {
|
|
1411
|
-
number: "",
|
|
1412
|
-
class: "align-top"
|
|
1413
|
-
}, {
|
|
1414
|
-
default: withCtx(() => {
|
|
1415
|
-
var _a, _b, _c, _d, _e;
|
|
1416
|
-
return [
|
|
1417
|
-
((_b = (_a = __props.details) == null ? void 0 : _a.amount) == null ? void 0 : _b.currency) && ((_d = (_c = __props.details) == null ? void 0 : _c.amount) == null ? void 0 : _d.quantity) ? (openBlock(), createElementBlock("div", _hoisted_11$1, [
|
|
1418
|
-
__props.showTaxPerLineItem ? (openBlock(true), createElementBlock(Fragment, { key: 0 }, renderList(__props.taxCategories, (taxCategory, taxCategoryIndex) => {
|
|
1419
|
-
var _a2;
|
|
1420
|
-
return openBlock(), createElementBlock("div", {
|
|
1421
|
-
key: taxCategoryIndex,
|
|
1422
|
-
class: "inline-block"
|
|
1423
|
-
}, [
|
|
1424
|
-
createElementVNode("div", _hoisted_12$1, [
|
|
1425
|
-
createVNode(_sfc_main$l, {
|
|
1426
|
-
value: __props.details.amount,
|
|
1427
|
-
"data-testid": unref(SUMMARY_LINE_AMOUNT)
|
|
1428
|
-
}, null, 8, ["value", "data-testid"]),
|
|
1429
|
-
((_a2 = __props.details) == null ? void 0 : _a2.pricing_amount.quantity) !== __props.details.amount.quantity ? (openBlock(), createBlock(_sfc_main$o, {
|
|
1430
|
-
key: 0,
|
|
1431
|
-
placement: "top-end"
|
|
1432
|
-
}, {
|
|
1433
|
-
tooltip: withCtx(() => [
|
|
1434
|
-
createVNode(TooltipContent, null, {
|
|
1435
|
-
default: withCtx(() => [
|
|
1436
|
-
createVNode(_sfc_main$p, null, {
|
|
1437
|
-
default: withCtx(() => [
|
|
1438
|
-
createTextVNode(toDisplayString(unref($t)({
|
|
1439
|
-
id: "invoice.line.original_currency",
|
|
1440
|
-
defaultMessage: "Original currency",
|
|
1441
|
-
description: "Original currency"
|
|
1442
|
-
})) + " ", 1),
|
|
1443
|
-
createVNode(_sfc_main$l, {
|
|
1444
|
-
value: __props.details.pricing_amount,
|
|
1445
|
-
class: "font-semibold"
|
|
1446
|
-
}, null, 8, ["value"])
|
|
1447
|
-
]),
|
|
1448
|
-
_: 1
|
|
1449
|
-
})
|
|
1450
|
-
]),
|
|
1451
|
-
_: 1
|
|
1452
|
-
})
|
|
1453
|
-
]),
|
|
1454
|
-
default: withCtx(() => [
|
|
1455
|
-
createVNode(_sfc_main$n, {
|
|
1456
|
-
icon: "info",
|
|
1457
|
-
size: "2xs"
|
|
1458
|
-
})
|
|
1459
|
-
]),
|
|
1460
|
-
_: 1
|
|
1461
|
-
})) : createCommentVNode("", true)
|
|
1462
|
-
]),
|
|
1463
|
-
!__props.hideTaxDetails ? (openBlock(), createElementBlock("div", _hoisted_13$1, [
|
|
1464
|
-
__props.amountType === "INCLUDING_TAX" ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
|
|
1465
|
-
createTextVNode(toDisplayString(unref($t)({
|
|
1466
|
-
id: "invoice.line.excl.tax",
|
|
1467
|
-
defaultMessage: "Excl. tax",
|
|
1468
|
-
description: "Value excludes tax"
|
|
1469
|
-
})) + " ", 1),
|
|
1470
|
-
createVNode(_sfc_main$l, {
|
|
1471
|
-
value: taxCategory.base_amount
|
|
1472
|
-
}, null, 8, ["value"])
|
|
1473
|
-
], 64)) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
|
1474
|
-
createTextVNode(toDisplayString(unref($t)({
|
|
1475
|
-
id: "invoice.line.incl.tax",
|
|
1476
|
-
defaultMessage: "Incl. tax",
|
|
1477
|
-
description: "Value includes tax"
|
|
1478
|
-
})) + " ", 1),
|
|
1479
|
-
createVNode(_sfc_main$l, {
|
|
1480
|
-
value: taxCategory.total_amount
|
|
1481
|
-
}, null, 8, ["value"])
|
|
1482
|
-
], 64))
|
|
1483
|
-
])) : createCommentVNode("", true)
|
|
1484
|
-
]);
|
|
1485
|
-
}), 128)) : (openBlock(), createElementBlock("div", _hoisted_14$1, [
|
|
1486
|
-
createElementVNode("div", _hoisted_15$1, [
|
|
1487
|
-
createVNode(_sfc_main$l, {
|
|
1488
|
-
value: __props.details.amount,
|
|
1489
|
-
"data-testid": unref(SUMMARY_LINE_AMOUNT)
|
|
1490
|
-
}, null, 8, ["value", "data-testid"]),
|
|
1491
|
-
((_e = __props.details) == null ? void 0 : _e.pricing_amount.quantity) !== __props.details.amount.quantity ? (openBlock(), createBlock(_sfc_main$o, {
|
|
1492
|
-
key: 0,
|
|
1493
|
-
placement: "top-end"
|
|
1494
|
-
}, {
|
|
1495
|
-
tooltip: withCtx(() => [
|
|
1496
|
-
createVNode(TooltipContent, null, {
|
|
1497
|
-
default: withCtx(() => [
|
|
1498
|
-
createVNode(_sfc_main$p, null, {
|
|
1499
|
-
default: withCtx(() => [
|
|
1500
|
-
createTextVNode(toDisplayString(unref($t)({
|
|
1501
|
-
id: "invoice.line.original_currency",
|
|
1502
|
-
defaultMessage: "Original currency",
|
|
1503
|
-
description: "Original currency"
|
|
1504
|
-
})) + " ", 1),
|
|
1505
|
-
createVNode(_sfc_main$l, {
|
|
1506
|
-
value: __props.details.pricing_amount,
|
|
1507
|
-
class: "font-semibold"
|
|
1508
|
-
}, null, 8, ["value"])
|
|
1509
|
-
]),
|
|
1510
|
-
_: 1
|
|
1511
|
-
})
|
|
1512
|
-
]),
|
|
1513
|
-
_: 1
|
|
1514
|
-
})
|
|
1515
|
-
]),
|
|
1516
|
-
default: withCtx(() => [
|
|
1517
|
-
createVNode(_sfc_main$n, {
|
|
1518
|
-
icon: "info",
|
|
1519
|
-
size: "2xs"
|
|
1520
|
-
})
|
|
1521
|
-
]),
|
|
1522
|
-
_: 1
|
|
1523
|
-
})) : createCommentVNode("", true)
|
|
1524
|
-
])
|
|
1525
|
-
])),
|
|
1526
|
-
renderSlot(_ctx.$slots, "one-off-line-context-menu")
|
|
1527
|
-
])) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
|
1528
|
-
createTextVNode("-")
|
|
1529
|
-
], 64))
|
|
1530
|
-
];
|
|
1531
|
-
}),
|
|
1532
|
-
_: 3
|
|
1533
|
-
})
|
|
1534
|
-
], 64);
|
|
1535
|
-
};
|
|
1536
|
-
}
|
|
1537
|
-
});
|
|
1538
|
-
const _hoisted_1$6 = ["tabindex", "onClick"];
|
|
1539
|
-
const _sfc_main$7 = /* @__PURE__ */ defineComponent({
|
|
1540
|
-
__name: "InvoiceLineGroup",
|
|
1541
|
-
props: {
|
|
1542
|
-
group: {},
|
|
1543
|
-
startDate: {},
|
|
1544
|
-
endDate: {},
|
|
1545
|
-
total: {},
|
|
1546
|
-
amountType: {},
|
|
1547
|
-
invoicePeriodOrder: {},
|
|
1548
|
-
processingOnlyCustomers: {},
|
|
1549
|
-
displayInvoiceSubLinesPerProcessingOnlyCustomer: { type: Boolean },
|
|
1550
|
-
showTaxPerLineItem: { type: Boolean, default: true },
|
|
1551
|
-
isExpandable: { type: Boolean, default: true }
|
|
1552
|
-
},
|
|
1553
|
-
setup(__props) {
|
|
1554
|
-
const props = __props;
|
|
1555
|
-
const sortedLines = computed(
|
|
1556
|
-
() => {
|
|
1557
|
-
var _a;
|
|
1558
|
-
return (_a = [...props.group.lines ?? []]) == null ? void 0 : _a.sort((a, b) => a.line_order - b.line_order);
|
|
1559
|
-
}
|
|
1560
|
-
);
|
|
1561
|
-
const intl = useIntl();
|
|
1562
|
-
const { getIsOpen, toggle } = useToggleList();
|
|
1563
|
-
const toggleLine = (groupOrder, invoiceLineOrder) => {
|
|
1564
|
-
toggle(formatIndex(groupOrder, invoiceLineOrder));
|
|
1565
|
-
};
|
|
1566
|
-
const formatIndex = (rootIndex, index) => `${rootIndex}-line-${index}`;
|
|
1567
|
-
return (_ctx, _cache) => {
|
|
1568
|
-
return openBlock(), createElementBlock("div", null, [
|
|
1569
|
-
createVNode(InvoiceTable, null, {
|
|
1570
|
-
default: withCtx(() => [
|
|
1571
|
-
createElementVNode("tr", null, [
|
|
1572
|
-
createVNode(_sfc_main$h, {
|
|
1573
|
-
left: "",
|
|
1574
|
-
class: "w-1/5 text-secondary"
|
|
1575
|
-
}, {
|
|
1576
|
-
default: withCtx(() => [
|
|
1577
|
-
createTextVNode(toDisplayString(unref(intl).$t({
|
|
1578
|
-
id: "invoice.table_header.unit",
|
|
1579
|
-
defaultMessage: "Unit",
|
|
1580
|
-
description: "Table header for the column containing the number of units of invoice groups"
|
|
1581
|
-
})), 1)
|
|
1582
|
-
]),
|
|
1583
|
-
_: 1
|
|
1584
|
-
}),
|
|
1585
|
-
createVNode(_sfc_main$h, {
|
|
1586
|
-
right: "",
|
|
1587
|
-
class: "w-1/5 text-secondary"
|
|
1588
|
-
}, {
|
|
1589
|
-
default: withCtx(() => [
|
|
1590
|
-
createTextVNode(toDisplayString(unref(intl).$t({
|
|
1591
|
-
id: "invoice.table_header.quantity",
|
|
1592
|
-
defaultMessage: "Quantity",
|
|
1593
|
-
description: "Table header for quantity column"
|
|
1594
|
-
})), 1)
|
|
1595
|
-
]),
|
|
1596
|
-
_: 1
|
|
1597
|
-
}),
|
|
1598
|
-
createVNode(_sfc_main$h, {
|
|
1599
|
-
right: "",
|
|
1600
|
-
class: "w-1/5 text-secondary"
|
|
1601
|
-
}, {
|
|
1602
|
-
default: withCtx(() => [
|
|
1603
|
-
createTextVNode(toDisplayString(unref(intl).$t({
|
|
1604
|
-
id: "invoice.table_header.price",
|
|
1605
|
-
defaultMessage: "Price",
|
|
1606
|
-
description: "Table header for the column containing the number of units of invoice groups"
|
|
1607
|
-
})), 1)
|
|
1608
|
-
]),
|
|
1609
|
-
_: 1
|
|
1610
|
-
}),
|
|
1611
|
-
__props.showTaxPerLineItem ? (openBlock(), createBlock(_sfc_main$h, {
|
|
1612
|
-
key: 0,
|
|
1613
|
-
right: "",
|
|
1614
|
-
class: "w-1/5 text-secondary"
|
|
1615
|
-
}, {
|
|
1616
|
-
default: withCtx(() => [
|
|
1617
|
-
createTextVNode(toDisplayString(unref(intl).$t({
|
|
1618
|
-
id: "invoice.table_header.tax_rate",
|
|
1619
|
-
defaultMessage: "Tax rate",
|
|
1620
|
-
description: "Table header for the column containing the tax percentage of invoice groups"
|
|
1621
|
-
})), 1)
|
|
1622
|
-
]),
|
|
1623
|
-
_: 1
|
|
1624
|
-
})) : createCommentVNode("", true),
|
|
1625
|
-
createVNode(_sfc_main$h, {
|
|
1626
|
-
right: "",
|
|
1627
|
-
class: "w-1/5 text-secondary"
|
|
1628
|
-
}, {
|
|
1629
|
-
default: withCtx(() => [
|
|
1630
|
-
createTextVNode(toDisplayString(unref(intl).$t({
|
|
1631
|
-
id: "invoice.table_header.sub_total",
|
|
1632
|
-
defaultMessage: "Subtotal",
|
|
1633
|
-
description: "Table header for the column containing the subtotal for invoices"
|
|
1634
|
-
})), 1)
|
|
1635
|
-
]),
|
|
1636
|
-
_: 1
|
|
1637
|
-
})
|
|
1638
|
-
]),
|
|
1639
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(sortedLines.value, (line, i) => {
|
|
1640
|
-
return openBlock(), createElementBlock(Fragment, { key: i }, [
|
|
1641
|
-
createElementVNode("tr", {
|
|
1642
|
-
tabindex: __props.isExpandable && line.sub_lines ? 0 : void 0,
|
|
1643
|
-
class: normalizeClass(["group", {
|
|
1644
|
-
"cursor-pointer": __props.isExpandable && line.sub_lines,
|
|
1645
|
-
"border-t": i !== 0
|
|
1646
|
-
}]),
|
|
1647
|
-
onClick: ($event) => toggleLine(__props.group.group_order, line["line_order"])
|
|
1648
|
-
}, [
|
|
1649
|
-
(openBlock(), createBlock(_sfc_main$9, {
|
|
1650
|
-
key: i,
|
|
1651
|
-
data: line,
|
|
1652
|
-
"period-order": __props.invoicePeriodOrder,
|
|
1653
|
-
"group-order": __props.group.group_order,
|
|
1654
|
-
"is-last": i === sortedLines.value.length - 1,
|
|
1655
|
-
"group-type": __props.group.type,
|
|
1656
|
-
"is-expanded": unref(getIsOpen)(formatIndex(__props.group.group_order, line["line_order"]))
|
|
1657
|
-
}, {
|
|
1658
|
-
"invoice-line-prefix": withCtx((linePrefixProps) => [
|
|
1659
|
-
renderSlot(_ctx.$slots, "invoice-line-prefix", mergeProps({ ref_for: true }, linePrefixProps))
|
|
1660
|
-
]),
|
|
1661
|
-
"line-content": withCtx((lineContentProps) => {
|
|
1662
|
-
var _a, _b;
|
|
1663
|
-
return [
|
|
1664
|
-
createVNode(_sfc_main$8, {
|
|
1665
|
-
details: lineContentProps.details,
|
|
1666
|
-
"pricing-type": line.pricing_type,
|
|
1667
|
-
"tax-categories": line.tax_categories,
|
|
1668
|
-
"amount-type": __props.amountType,
|
|
1669
|
-
"model-type": (_b = (_a = line.product_items) == null ? void 0 : _a[0]) == null ? void 0 : _b.model_type,
|
|
1670
|
-
"show-tax-per-line-item": __props.showTaxPerLineItem
|
|
1671
|
-
}, createSlots({ _: 2 }, [
|
|
1672
|
-
line.type === "ONE_OFF" ? {
|
|
1673
|
-
name: "one-off-line-context-menu",
|
|
1674
|
-
fn: withCtx((oneOffGroupProps) => [
|
|
1675
|
-
renderSlot(_ctx.$slots, "one-off-line-context-menu", mergeProps({ ref_for: true }, oneOffGroupProps, {
|
|
1676
|
-
lineOrder: line.line_order
|
|
1677
|
-
}))
|
|
1678
|
-
]),
|
|
1679
|
-
key: "0"
|
|
1680
|
-
} : void 0
|
|
1681
|
-
]), 1032, ["details", "pricing-type", "tax-categories", "amount-type", "model-type", "show-tax-per-line-item"])
|
|
1682
|
-
];
|
|
1683
|
-
}),
|
|
1684
|
-
_: 2
|
|
1685
|
-
}, 1032, ["data", "period-order", "group-order", "is-last", "group-type", "is-expanded"]))
|
|
1686
|
-
], 10, _hoisted_1$6),
|
|
1687
|
-
createVNode(_sfc_main$g, {
|
|
1688
|
-
ref_for: true,
|
|
1689
|
-
ref: formatIndex(__props.group.group_order, line["line_order"]),
|
|
1690
|
-
"sub-lines": line.sub_lines ?? [],
|
|
1691
|
-
"processing-only-customers": __props.processingOnlyCustomers,
|
|
1692
|
-
"display-invoice-sub-lines-per-processing-only-customer": __props.displayInvoiceSubLinesPerProcessingOnlyCustomer,
|
|
1693
|
-
"line-order": line["line_order"],
|
|
1694
|
-
"is-open": unref(getIsOpen)(formatIndex(__props.group.group_order, line["line_order"])),
|
|
1695
|
-
"period-order": __props.invoicePeriodOrder,
|
|
1696
|
-
"group-order": __props.group.group_order,
|
|
1697
|
-
"show-tax-per-line-item": __props.showTaxPerLineItem
|
|
1698
|
-
}, {
|
|
1699
|
-
"invoice-line-prefix": withCtx((linePrefixProps) => [
|
|
1700
|
-
renderSlot(_ctx.$slots, "invoice-line-prefix", mergeProps({ ref_for: true }, linePrefixProps))
|
|
1701
|
-
]),
|
|
1702
|
-
"subline-content": withCtx((sublineContentProps) => {
|
|
1703
|
-
var _a, _b;
|
|
1704
|
-
return [
|
|
1705
|
-
createVNode(_sfc_main$8, {
|
|
1706
|
-
details: sublineContentProps.details,
|
|
1707
|
-
"hide-tax-details": sublineContentProps.hideTaxDetails,
|
|
1708
|
-
"prefer-conversion-credits": "",
|
|
1709
|
-
"pricing-type": line.pricing_type,
|
|
1710
|
-
"tax-categories": line.tax_categories,
|
|
1711
|
-
"amount-type": __props.amountType,
|
|
1712
|
-
"model-type": (_b = (_a = line.product_items) == null ? void 0 : _a[0]) == null ? void 0 : _b.model_type,
|
|
1713
|
-
"show-tax-per-line-item": __props.showTaxPerLineItem
|
|
1714
|
-
}, null, 8, ["details", "hide-tax-details", "pricing-type", "tax-categories", "amount-type", "model-type", "show-tax-per-line-item"])
|
|
1715
|
-
];
|
|
1716
|
-
}),
|
|
1717
|
-
_: 2
|
|
1718
|
-
}, 1032, ["sub-lines", "processing-only-customers", "display-invoice-sub-lines-per-processing-only-customer", "line-order", "is-open", "period-order", "group-order", "show-tax-per-line-item"])
|
|
1719
|
-
], 64);
|
|
1720
|
-
}), 128))
|
|
1721
|
-
]),
|
|
1722
|
-
_: 3
|
|
1723
|
-
})
|
|
1724
|
-
]);
|
|
1725
|
-
};
|
|
1726
|
-
}
|
|
1727
|
-
});
|
|
1728
|
-
const _hoisted_1$5 = { class: "flex items-center" };
|
|
1729
|
-
const _hoisted_2$2 = {
|
|
1730
|
-
key: 2,
|
|
1731
|
-
class: "ml-1 inline-flex h-3.5 w-3.5 shrink-0 items-center justify-center rounded-full bg-primary-100 text-2xs font-bold text-primary-600"
|
|
1732
|
-
};
|
|
1733
|
-
const _sfc_main$6 = /* @__PURE__ */ defineComponent({
|
|
1734
|
-
__name: "InvoiceTableRowLabel",
|
|
1735
|
-
props: {
|
|
1736
|
-
label: {},
|
|
1737
|
-
count: {}
|
|
1738
|
-
},
|
|
1739
|
-
setup(__props) {
|
|
1740
|
-
const labelElement = ref();
|
|
1741
|
-
const isLabelCutOff = ref(false);
|
|
1742
|
-
useResizeObserver(labelElement, ([entry]) => {
|
|
1743
|
-
isLabelCutOff.value = entry.target.clientWidth < entry.target.scrollWidth;
|
|
1744
|
-
});
|
|
1745
|
-
return (_ctx, _cache) => {
|
|
1746
|
-
return openBlock(), createElementBlock("div", _hoisted_1$5, [
|
|
1747
|
-
isLabelCutOff.value ? (openBlock(), createBlock(_sfc_main$o, {
|
|
1748
|
-
key: 0,
|
|
1749
|
-
placement: "bottom-start",
|
|
1750
|
-
class: "min-w-0 leading-normal"
|
|
1751
|
-
}, {
|
|
1752
|
-
tooltip: withCtx(() => [
|
|
1753
|
-
createVNode(TooltipContent, null, {
|
|
1754
|
-
default: withCtx(() => [
|
|
1755
|
-
createVNode(_sfc_main$p, null, {
|
|
1756
|
-
default: withCtx(() => [
|
|
1757
|
-
createTextVNode(toDisplayString(__props.label), 1)
|
|
1758
|
-
]),
|
|
1759
|
-
_: 1
|
|
1760
|
-
})
|
|
1761
|
-
]),
|
|
1762
|
-
_: 1
|
|
1763
|
-
})
|
|
1764
|
-
]),
|
|
1765
|
-
default: withCtx(() => [
|
|
1766
|
-
createElementVNode("span", {
|
|
1767
|
-
ref_key: "labelElement",
|
|
1768
|
-
ref: labelElement,
|
|
1769
|
-
class: "block truncate"
|
|
1770
|
-
}, toDisplayString(__props.label), 513)
|
|
1771
|
-
]),
|
|
1772
|
-
_: 1
|
|
1773
|
-
})) : (openBlock(), createElementBlock("span", {
|
|
1774
|
-
key: 1,
|
|
1775
|
-
ref_key: "labelElement",
|
|
1776
|
-
ref: labelElement,
|
|
1777
|
-
class: normalizeClass(["block", { truncate: __props.count !== void 0 }])
|
|
1778
|
-
}, toDisplayString(__props.label), 3)),
|
|
1779
|
-
__props.count !== void 0 ? (openBlock(), createElementBlock("span", _hoisted_2$2, toDisplayString(__props.count), 1)) : createCommentVNode("", true)
|
|
1780
|
-
]);
|
|
1781
|
-
};
|
|
1782
|
-
}
|
|
1783
|
-
});
|
|
1784
|
-
const _hoisted_1$4 = ["tabindex"];
|
|
1785
|
-
const _hoisted_2$1 = { key: 0 };
|
|
1786
|
-
const _hoisted_3$1 = {
|
|
1787
|
-
colspan: "2",
|
|
1788
|
-
class: "p-0"
|
|
1789
|
-
};
|
|
1790
|
-
const _hoisted_4$1 = { class: "-mx-9 bg-gray-50 px-9 py-3 text-xs" };
|
|
1791
|
-
const _sfc_main$5 = /* @__PURE__ */ defineComponent({
|
|
1792
|
-
__name: "InvoiceGroupRevenue",
|
|
1793
|
-
props: {
|
|
1794
|
-
forwardedFromCustomers: {},
|
|
1795
|
-
showOriginalCustomerInvoiceLine: {},
|
|
1796
|
-
group: {},
|
|
1797
|
-
expandedItems: {},
|
|
1798
|
-
handleToggleItems: {},
|
|
1799
|
-
formatIndex: {},
|
|
1800
|
-
invoicePeriodOrder: {},
|
|
1801
|
-
groupOrder: {},
|
|
1802
|
-
isExpandable: { type: Boolean },
|
|
1803
|
-
forceExpanded: { type: Boolean },
|
|
1804
|
-
amountType: {},
|
|
1805
|
-
processingOnlyCustomers: {},
|
|
1806
|
-
displayInvoiceSubLinesPerProcessingOnlyCustomer: { type: Boolean },
|
|
1807
|
-
showTaxPerLineItem: { type: Boolean, default: true }
|
|
1808
|
-
},
|
|
1809
|
-
setup(__props) {
|
|
1810
|
-
const props = __props;
|
|
1811
|
-
const label = computed(() => {
|
|
1812
|
-
var _a, _b, _c;
|
|
1813
|
-
const pricingAndProducts = [
|
|
1814
|
-
(_a = props.group.pricing) == null ? void 0 : _a.name,
|
|
1815
|
-
getComposedString(((_b = props.group.products) == null ? void 0 : _b.map((item) => item.name)) ?? [])
|
|
1816
|
-
].filter(Boolean).join(" - ");
|
|
1817
|
-
const originalCustomerId = getInvoiceGroupOriginalCustomerId(
|
|
1818
|
-
props.group,
|
|
1819
|
-
!!props.showOriginalCustomerInvoiceLine
|
|
1820
|
-
);
|
|
1821
|
-
if (!originalCustomerId) {
|
|
1822
|
-
return pricingAndProducts;
|
|
1823
|
-
}
|
|
1824
|
-
const originalCustomer = (_c = props.forwardedFromCustomers) == null ? void 0 : _c.find(
|
|
1825
|
-
(customer) => customer.id === originalCustomerId
|
|
1826
|
-
);
|
|
1827
|
-
return [originalCustomer && getCustomerName(originalCustomer), pricingAndProducts].filter(Boolean).join(" - ");
|
|
1828
|
-
});
|
|
1829
|
-
return (_ctx, _cache) => {
|
|
1830
|
-
return openBlock(), createElementBlock(Fragment, null, [
|
|
1831
|
-
createElementVNode("tr", {
|
|
1832
|
-
class: normalizeClass(["border-t break-inside-avoid", { "cursor-pointer": __props.isExpandable }]),
|
|
1833
|
-
tabindex: __props.isExpandable ? 0 : void 0,
|
|
1834
|
-
onClick: _cache[0] || (_cache[0] = ($event) => __props.handleToggleItems(__props.formatIndex(__props.invoicePeriodOrder, __props.groupOrder))),
|
|
1835
|
-
onKeyup: [
|
|
1836
|
-
_cache[1] || (_cache[1] = withKeys(($event) => __props.handleToggleItems(__props.formatIndex(__props.invoicePeriodOrder, __props.groupOrder)), ["enter"])),
|
|
1837
|
-
_cache[2] || (_cache[2] = withKeys(($event) => __props.handleToggleItems(__props.formatIndex(__props.invoicePeriodOrder, __props.groupOrder)), ["space"]))
|
|
1838
|
-
]
|
|
1839
|
-
}, [
|
|
1840
|
-
createVNode(_sfc_main$i, { class: "p-0" }, {
|
|
1841
|
-
default: withCtx(() => {
|
|
1842
|
-
var _a;
|
|
1843
|
-
return [
|
|
1844
|
-
__props.isExpandable ? (openBlock(), createBlock(_sfc_main$n, {
|
|
1845
|
-
key: 0,
|
|
1846
|
-
icon: "keyboard_arrow_down",
|
|
1847
|
-
size: "md",
|
|
1848
|
-
class: normalizeClass(["absolute -translate-x-7 text-slate-400", {
|
|
1849
|
-
"-rotate-90": !__props.expandedItems.includes(
|
|
1850
|
-
__props.formatIndex(__props.invoicePeriodOrder, __props.groupOrder)
|
|
1851
|
-
)
|
|
1852
|
-
}])
|
|
1853
|
-
}, null, 8, ["class"])) : createCommentVNode("", true),
|
|
1854
|
-
createVNode(_sfc_main$6, {
|
|
1855
|
-
label: label.value,
|
|
1856
|
-
count: __props.isExpandable ? ((_a = __props.group.lines) == null ? void 0 : _a.length) ?? 0 : void 0
|
|
1857
|
-
}, null, 8, ["label", "count"])
|
|
1858
|
-
];
|
|
1859
|
-
}),
|
|
1860
|
-
_: 1
|
|
1861
|
-
}),
|
|
1862
|
-
createVNode(_sfc_main$i, { number: "" }, {
|
|
1863
|
-
default: withCtx(() => [
|
|
1864
|
-
__props.amountType === "INCLUDING_TAX" ? (openBlock(), createBlock(_sfc_main$l, {
|
|
1865
|
-
key: 0,
|
|
1866
|
-
value: __props.group.amount_including_tax,
|
|
1867
|
-
"data-testid": unref(INVOICE_PERIOD_TOTAL),
|
|
1868
|
-
"data-type": unref(getInvoiceGroupAmountType)(__props.group)
|
|
1869
|
-
}, null, 8, ["value", "data-testid", "data-type"])) : (openBlock(), createBlock(_sfc_main$l, {
|
|
1870
|
-
key: 1,
|
|
1871
|
-
value: __props.group.amount_excluding_tax,
|
|
1872
|
-
"data-testid": unref(INVOICE_PERIOD_TOTAL),
|
|
1873
|
-
"data-type": unref(getInvoiceGroupAmountType)(__props.group)
|
|
1874
|
-
}, null, 8, ["value", "data-testid", "data-type"]))
|
|
1875
|
-
]),
|
|
1876
|
-
_: 1
|
|
1877
|
-
})
|
|
1878
|
-
], 42, _hoisted_1$4),
|
|
1879
|
-
__props.forceExpanded || __props.expandedItems.includes(__props.formatIndex(__props.invoicePeriodOrder, __props.groupOrder)) ? (openBlock(), createElementBlock("tr", _hoisted_2$1, [
|
|
1880
|
-
createElementVNode("td", _hoisted_3$1, [
|
|
1881
|
-
createElementVNode("div", _hoisted_4$1, [
|
|
1882
|
-
createVNode(_sfc_main$7, {
|
|
1883
|
-
"invoice-period-order": __props.invoicePeriodOrder,
|
|
1884
|
-
"start-date": __props.group.start_at,
|
|
1885
|
-
"end-date": __props.group.end_at,
|
|
1886
|
-
total: __props.group.amount_excluding_tax,
|
|
1887
|
-
group: __props.group,
|
|
1888
|
-
"amount-type": __props.amountType,
|
|
1889
|
-
"processing-only-customers": __props.processingOnlyCustomers,
|
|
1890
|
-
"display-invoice-sub-lines-per-processing-only-customer": __props.displayInvoiceSubLinesPerProcessingOnlyCustomer,
|
|
1891
|
-
"show-tax-per-line-item": __props.showTaxPerLineItem,
|
|
1892
|
-
"is-expandable": __props.isExpandable
|
|
1893
|
-
}, {
|
|
1894
|
-
"invoice-line-prefix": withCtx((linePrefixProps) => [
|
|
1895
|
-
renderSlot(_ctx.$slots, "invoice-line-prefix", normalizeProps(guardReactiveProps(linePrefixProps)))
|
|
1896
|
-
]),
|
|
1897
|
-
"one-off-line-context-menu": withCtx((oneOffGroupProps) => [
|
|
1898
|
-
renderSlot(_ctx.$slots, "one-off-line-context-menu", mergeProps(oneOffGroupProps, { groupOrder: __props.groupOrder }))
|
|
1899
|
-
]),
|
|
1900
|
-
_: 3
|
|
1901
|
-
}, 8, ["invoice-period-order", "start-date", "end-date", "total", "group", "amount-type", "processing-only-customers", "display-invoice-sub-lines-per-processing-only-customer", "show-tax-per-line-item", "is-expandable"])
|
|
1902
|
-
])
|
|
1903
|
-
])
|
|
1904
|
-
])) : createCommentVNode("", true)
|
|
1905
|
-
], 64);
|
|
1906
|
-
};
|
|
1907
|
-
}
|
|
1908
|
-
});
|
|
1909
|
-
const _sfc_main$4 = /* @__PURE__ */ defineComponent({
|
|
1910
|
-
__name: "InvoiceGroupWalletBalance",
|
|
1911
|
-
props: {
|
|
1912
|
-
lines: {},
|
|
1913
|
-
creditTypes: {}
|
|
1914
|
-
},
|
|
1915
|
-
setup(__props) {
|
|
1916
|
-
const props = __props;
|
|
1917
|
-
const { $t } = useIntl();
|
|
1918
|
-
const creditsLabel = computed(
|
|
1919
|
-
() => $t({
|
|
1920
|
-
defaultMessage: "Credits",
|
|
1921
|
-
description: "Generic fallback label for a wallet balance row with no known credit type",
|
|
1922
|
-
id: "invoiceGroupWalletBalance.creditsLabel"
|
|
1923
|
-
})
|
|
1924
|
-
);
|
|
1925
|
-
const creditTypesById = computed(
|
|
1926
|
-
() => (props.creditTypes ?? []).reduce((acc, creditType) => {
|
|
1927
|
-
acc[creditType.id] = creditType.name;
|
|
1928
|
-
return acc;
|
|
1929
|
-
}, {})
|
|
1930
|
-
);
|
|
1931
|
-
const getCreditTypeLabel = (credit) => {
|
|
1932
|
-
if (!(credit == null ? void 0 : credit.credit_type_id)) {
|
|
1933
|
-
return creditsLabel.value;
|
|
1934
|
-
}
|
|
1935
|
-
return creditTypesById.value[credit.credit_type_id] ?? credit.credit_type_id;
|
|
1936
|
-
};
|
|
1937
|
-
const walletBalanceRows = computed(() => {
|
|
1938
|
-
const seenRowKeys = /* @__PURE__ */ new Set();
|
|
1939
|
-
return (props.lines ?? []).map((line) => {
|
|
1940
|
-
var _a;
|
|
1941
|
-
return (_a = line.details) == null ? void 0 : _a.wallet_balance_details;
|
|
1942
|
-
}).filter((details) => !!details).map((details, index) => {
|
|
1943
|
-
var _a, _b, _c;
|
|
1944
|
-
const primaryCredit = [
|
|
1945
|
-
details.used_wallet_credits,
|
|
1946
|
-
details.left_wallet_credits,
|
|
1947
|
-
details.available_wallet_credits
|
|
1948
|
-
].find((credit) => Boolean(credit == null ? void 0 : credit.credit_type_id));
|
|
1949
|
-
return {
|
|
1950
|
-
key: `${(primaryCredit == null ? void 0 : primaryCredit.credit_type_id) ?? "credits"}-${index}`,
|
|
1951
|
-
label: getCreditTypeLabel(primaryCredit),
|
|
1952
|
-
available: ((_a = details.available_wallet_credits) == null ? void 0 : _a.quantity) ?? "-",
|
|
1953
|
-
used: ((_b = details.used_wallet_credits) == null ? void 0 : _b.quantity) ?? "-",
|
|
1954
|
-
left: ((_c = details.left_wallet_credits) == null ? void 0 : _c.quantity) ?? "-"
|
|
1955
|
-
};
|
|
1956
|
-
}).filter((row) => {
|
|
1957
|
-
const rowKey = `${row.label}-${row.available}-${row.used}-${row.left}`;
|
|
1958
|
-
if (seenRowKeys.has(rowKey)) {
|
|
1959
|
-
return false;
|
|
1960
|
-
}
|
|
1961
|
-
seenRowKeys.add(rowKey);
|
|
1962
|
-
return true;
|
|
1963
|
-
});
|
|
1964
|
-
});
|
|
1965
|
-
return (_ctx, _cache) => {
|
|
1966
|
-
return walletBalanceRows.value.length ? (openBlock(), createBlock(InvoiceTable, { key: 0 }, {
|
|
1967
|
-
default: withCtx(() => [
|
|
1968
|
-
createElementVNode("tr", null, [
|
|
1969
|
-
createVNode(_sfc_main$h, {
|
|
1970
|
-
left: "",
|
|
1971
|
-
class: "w-2/5 text-gray-400"
|
|
1972
|
-
}, {
|
|
1973
|
-
default: withCtx(() => [
|
|
1974
|
-
createTextVNode(toDisplayString(unref($t)({
|
|
1975
|
-
defaultMessage: "Credit breakdown",
|
|
1976
|
-
description: "Table heading for the credit-type column in the wallet balance table",
|
|
1977
|
-
id: "invoiceGroupWalletBalance.creditBreakdownHeading"
|
|
1978
|
-
})), 1)
|
|
1979
|
-
]),
|
|
1980
|
-
_: 1
|
|
1981
|
-
}),
|
|
1982
|
-
createVNode(_sfc_main$h, {
|
|
1983
|
-
right: "",
|
|
1984
|
-
class: "w-1/5 text-gray-400"
|
|
1985
|
-
}, {
|
|
1986
|
-
default: withCtx(() => [
|
|
1987
|
-
createTextVNode(toDisplayString(unref($t)({
|
|
1988
|
-
defaultMessage: "Available",
|
|
1989
|
-
description: "Table heading for the available-credits column in the wallet balance table",
|
|
1990
|
-
id: "invoiceGroupWalletBalance.availableHeading"
|
|
1991
|
-
})), 1)
|
|
1992
|
-
]),
|
|
1993
|
-
_: 1
|
|
1994
|
-
}),
|
|
1995
|
-
createVNode(_sfc_main$h, {
|
|
1996
|
-
right: "",
|
|
1997
|
-
class: "w-1/5 text-gray-400"
|
|
1998
|
-
}, {
|
|
1999
|
-
default: withCtx(() => [
|
|
2000
|
-
createTextVNode(toDisplayString(unref($t)({
|
|
2001
|
-
defaultMessage: "Used",
|
|
2002
|
-
description: "Table heading for the used-credits column in the wallet balance table",
|
|
2003
|
-
id: "invoiceGroupWalletBalance.usedHeading"
|
|
2004
|
-
})), 1)
|
|
2005
|
-
]),
|
|
2006
|
-
_: 1
|
|
2007
|
-
}),
|
|
2008
|
-
createVNode(_sfc_main$h, {
|
|
2009
|
-
right: "",
|
|
2010
|
-
class: "w-1/5 text-gray-400"
|
|
2011
|
-
}, {
|
|
2012
|
-
default: withCtx(() => [
|
|
2013
|
-
createTextVNode(toDisplayString(unref($t)({
|
|
2014
|
-
defaultMessage: "Left",
|
|
2015
|
-
description: "Table heading for the remaining-credits column in the wallet balance table",
|
|
2016
|
-
id: "invoiceGroupWalletBalance.leftHeading"
|
|
2017
|
-
})), 1)
|
|
2018
|
-
]),
|
|
2019
|
-
_: 1
|
|
2020
|
-
})
|
|
2021
|
-
]),
|
|
2022
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(walletBalanceRows.value, (row) => {
|
|
2023
|
-
return openBlock(), createElementBlock("tr", {
|
|
2024
|
-
key: row.key
|
|
2025
|
-
}, [
|
|
2026
|
-
createVNode(_sfc_main$i, null, {
|
|
2027
|
-
default: withCtx(() => [
|
|
2028
|
-
createTextVNode(toDisplayString(row.label), 1)
|
|
2029
|
-
]),
|
|
2030
|
-
_: 2
|
|
2031
|
-
}, 1024),
|
|
2032
|
-
createVNode(_sfc_main$i, { number: "" }, {
|
|
2033
|
-
default: withCtx(() => [
|
|
2034
|
-
createTextVNode(toDisplayString(row.available), 1)
|
|
2035
|
-
]),
|
|
2036
|
-
_: 2
|
|
2037
|
-
}, 1024),
|
|
2038
|
-
createVNode(_sfc_main$i, { number: "" }, {
|
|
2039
|
-
default: withCtx(() => [
|
|
2040
|
-
createTextVNode(toDisplayString(row.used), 1)
|
|
2041
|
-
]),
|
|
2042
|
-
_: 2
|
|
2043
|
-
}, 1024),
|
|
2044
|
-
createVNode(_sfc_main$i, { number: "" }, {
|
|
2045
|
-
default: withCtx(() => [
|
|
2046
|
-
createTextVNode(toDisplayString(row.left), 1)
|
|
2047
|
-
]),
|
|
2048
|
-
_: 2
|
|
2049
|
-
}, 1024)
|
|
2050
|
-
]);
|
|
2051
|
-
}), 128))
|
|
2052
|
-
]),
|
|
2053
|
-
_: 1
|
|
2054
|
-
})) : createCommentVNode("", true);
|
|
2055
|
-
};
|
|
2056
|
-
}
|
|
2057
|
-
});
|
|
2058
|
-
function toValue(r) {
|
|
2059
|
-
return typeof r === "function" ? r() : unref(r);
|
|
2060
|
-
}
|
|
2061
|
-
typeof WorkerGlobalScope !== "undefined" && globalThis instanceof WorkerGlobalScope;
|
|
2062
|
-
function useToggle(initialValue = false, options = {}) {
|
|
2063
|
-
const {
|
|
2064
|
-
truthyValue = true,
|
|
2065
|
-
falsyValue = false
|
|
2066
|
-
} = options;
|
|
2067
|
-
const valueIsRef = isRef(initialValue);
|
|
2068
|
-
const _value = ref(initialValue);
|
|
2069
|
-
function toggle(value) {
|
|
2070
|
-
if (arguments.length) {
|
|
2071
|
-
_value.value = value;
|
|
2072
|
-
return _value.value;
|
|
2073
|
-
} else {
|
|
2074
|
-
const truthy = toValue(truthyValue);
|
|
2075
|
-
_value.value = _value.value === truthy ? toValue(falsyValue) : truthy;
|
|
2076
|
-
return _value.value;
|
|
2077
|
-
}
|
|
2078
|
-
}
|
|
2079
|
-
if (valueIsRef)
|
|
2080
|
-
return toggle;
|
|
2081
|
-
else
|
|
2082
|
-
return [_value, toggle];
|
|
2083
|
-
}
|
|
2084
|
-
const _hoisted_1$3 = {
|
|
2085
|
-
key: 0,
|
|
2086
|
-
totals: "",
|
|
2087
|
-
class: "border-t break-inside-avoid"
|
|
2088
|
-
};
|
|
2089
|
-
const _sfc_main$3 = /* @__PURE__ */ defineComponent({
|
|
2090
|
-
__name: "InvoiceSummaryTotalExcludingTax",
|
|
2091
|
-
props: {
|
|
2092
|
-
baseAmount: {}
|
|
2093
|
-
},
|
|
2094
|
-
setup(__props) {
|
|
2095
|
-
const intl = useIntl();
|
|
2096
|
-
return (_ctx, _cache) => {
|
|
2097
|
-
return __props.baseAmount ? (openBlock(), createElementBlock("tr", _hoisted_1$3, [
|
|
2098
|
-
createVNode(_sfc_main$i, null, {
|
|
2099
|
-
default: withCtx(() => [
|
|
2100
|
-
createTextVNode(toDisplayString(unref(intl).$t({
|
|
2101
|
-
id: "invoice.table_header.total_excluding_taxes",
|
|
2102
|
-
defaultMessage: "Total excluding taxes",
|
|
2103
|
-
description: "Table row header for the total excluding taxes column in the invoice table"
|
|
2104
|
-
})), 1)
|
|
2105
|
-
]),
|
|
2106
|
-
_: 1
|
|
2107
|
-
}),
|
|
2108
|
-
createVNode(_sfc_main$i, { number: "" }, {
|
|
2109
|
-
default: withCtx(() => [
|
|
2110
|
-
createVNode(_sfc_main$l, {
|
|
2111
|
-
value: __props.baseAmount,
|
|
2112
|
-
"data-testid": unref(SUMMARY_TOTAL_EXCLUDING_TAX)
|
|
2113
|
-
}, null, 8, ["value", "data-testid"])
|
|
2114
|
-
]),
|
|
2115
|
-
_: 1
|
|
2116
|
-
})
|
|
2117
|
-
])) : createCommentVNode("", true);
|
|
2118
|
-
};
|
|
2119
|
-
}
|
|
2120
|
-
});
|
|
2121
|
-
const _hoisted_1$2 = {
|
|
2122
|
-
key: 0,
|
|
2123
|
-
class: "border-t font-bold break-inside-avoid"
|
|
2124
|
-
};
|
|
2125
|
-
const _sfc_main$2 = /* @__PURE__ */ defineComponent({
|
|
2126
|
-
__name: "InvoiceSummaryTotalIncludingTax",
|
|
2127
|
-
props: {
|
|
2128
|
-
totalAmount: {},
|
|
2129
|
-
isCustomerFacing: { type: Boolean }
|
|
2130
|
-
},
|
|
2131
|
-
setup(__props) {
|
|
2132
|
-
const intl = useIntl();
|
|
2133
|
-
return (_ctx, _cache) => {
|
|
2134
|
-
return __props.totalAmount ? (openBlock(), createElementBlock("tr", _hoisted_1$2, [
|
|
2135
|
-
createVNode(_sfc_main$i, { class: "font-bold" }, {
|
|
2136
|
-
default: withCtx(() => [
|
|
2137
|
-
createTextVNode(toDisplayString(__props.isCustomerFacing ? unref(intl).$t({
|
|
2138
|
-
id: "invoice.table_header.total_including_taxes_customer_facing",
|
|
2139
|
-
defaultMessage: "Total due today",
|
|
2140
|
-
description: "Table row header for the total including taxes column in the invoice table for a customer facing component"
|
|
2141
|
-
}) : unref(intl).$t({
|
|
2142
|
-
id: "invoice.table_header.total_including_taxes",
|
|
2143
|
-
defaultMessage: "Total including taxes",
|
|
2144
|
-
description: "Table row header for the total including taxes column in the invoice table"
|
|
2145
|
-
})), 1)
|
|
2146
|
-
]),
|
|
2147
|
-
_: 1
|
|
2148
|
-
}),
|
|
2149
|
-
createVNode(_sfc_main$i, { number: "" }, {
|
|
2150
|
-
default: withCtx(() => [
|
|
2151
|
-
createVNode(_sfc_main$l, {
|
|
2152
|
-
value: __props.totalAmount,
|
|
2153
|
-
"data-testid": unref(SUMMARY_TOTAL_INCLUDING_TAX)
|
|
2154
|
-
}, null, 8, ["value", "data-testid"])
|
|
2155
|
-
]),
|
|
2156
|
-
_: 1
|
|
2157
|
-
})
|
|
2158
|
-
])) : createCommentVNode("", true);
|
|
2159
|
-
};
|
|
2160
|
-
}
|
|
2161
|
-
});
|
|
2162
|
-
const _hoisted_1$1 = {
|
|
2163
|
-
key: 0,
|
|
2164
|
-
colspan: "4",
|
|
2165
|
-
class: "p-0"
|
|
2166
|
-
};
|
|
2167
|
-
const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
2168
|
-
__name: "InvoiceTaxes",
|
|
2169
|
-
props: {
|
|
2170
|
-
taxCategories: {}
|
|
2171
|
-
},
|
|
2172
|
-
setup(__props) {
|
|
2173
|
-
const intl = useIntl();
|
|
2174
|
-
return (_ctx, _cache) => {
|
|
2175
|
-
return openBlock(), createBlock(InvoiceTable, { class: "table-fixed" }, {
|
|
2176
|
-
default: withCtx(() => [
|
|
2177
|
-
createElementVNode("tr", null, [
|
|
2178
|
-
createVNode(_sfc_main$h, { left: "" }, {
|
|
2179
|
-
default: withCtx(() => [
|
|
2180
|
-
createTextVNode(toDisplayString(unref(intl).$t({
|
|
2181
|
-
id: "invoice.table_header.tax type",
|
|
2182
|
-
defaultMessage: "Tax type",
|
|
2183
|
-
description: "Table header for the column containing the tax type"
|
|
2184
|
-
})), 1)
|
|
2185
|
-
]),
|
|
2186
|
-
_: 1
|
|
2187
|
-
}),
|
|
2188
|
-
createVNode(_sfc_main$h, { right: "" }, {
|
|
2189
|
-
default: withCtx(() => [
|
|
2190
|
-
createTextVNode(toDisplayString(unref(intl).$t({
|
|
2191
|
-
id: "invoice.table_header.base amount",
|
|
2192
|
-
defaultMessage: "Base amount",
|
|
2193
|
-
description: "Table header for the column containing the base amount"
|
|
2194
|
-
})), 1)
|
|
2195
|
-
]),
|
|
2196
|
-
_: 1
|
|
2197
|
-
}),
|
|
2198
|
-
createVNode(_sfc_main$h, { right: "" }, {
|
|
2199
|
-
default: withCtx(() => [
|
|
2200
|
-
createTextVNode(toDisplayString(unref(intl).$t({
|
|
2201
|
-
id: "invoice.table_header.tax_percentage",
|
|
2202
|
-
defaultMessage: "Percentage",
|
|
2203
|
-
description: "Table header for the column containing the tax percentage"
|
|
2204
|
-
})), 1)
|
|
2205
|
-
]),
|
|
2206
|
-
_: 1
|
|
2207
|
-
}),
|
|
2208
|
-
createVNode(_sfc_main$h, { right: "" }, {
|
|
2209
|
-
default: withCtx(() => [
|
|
2210
|
-
createTextVNode(toDisplayString(unref(intl).$t({
|
|
2211
|
-
id: "invoice.table_header.tax amount",
|
|
2212
|
-
defaultMessage: "Tax amount",
|
|
2213
|
-
description: "Table header for the column containing the tax amount"
|
|
2214
|
-
})), 1)
|
|
2215
|
-
]),
|
|
2216
|
-
_: 1
|
|
2217
|
-
})
|
|
2218
|
-
]),
|
|
2219
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(__props.taxCategories, (taxCategory, taxCategoryIndex) => {
|
|
2220
|
-
return openBlock(), createElementBlock("tr", { key: taxCategoryIndex }, [
|
|
2221
|
-
taxCategory.rates ? (openBlock(), createElementBlock("td", _hoisted_1$1, [
|
|
2222
|
-
createVNode(InvoiceTable, { class: "table-fixed" }, {
|
|
2223
|
-
default: withCtx(() => [
|
|
2224
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(taxCategory.rates, (rate, rateIndex) => {
|
|
2225
|
-
return openBlock(), createElementBlock("tr", { key: rateIndex }, [
|
|
2226
|
-
createVNode(_sfc_main$i, null, {
|
|
2227
|
-
default: withCtx(() => [
|
|
2228
|
-
createTextVNode(toDisplayString(rate.name) + " (" + toDisplayString(taxCategory.category) + ") ", 1)
|
|
2229
|
-
]),
|
|
2230
|
-
_: 2
|
|
2231
|
-
}, 1024),
|
|
2232
|
-
createVNode(_sfc_main$i, { number: "" }, {
|
|
2233
|
-
default: withCtx(() => [
|
|
2234
|
-
createVNode(_sfc_main$l, {
|
|
2235
|
-
value: taxCategory.base_amount
|
|
2236
|
-
}, null, 8, ["value"])
|
|
2237
|
-
]),
|
|
2238
|
-
_: 2
|
|
2239
|
-
}, 1024),
|
|
2240
|
-
createVNode(_sfc_main$i, { number: "" }, {
|
|
2241
|
-
default: withCtx(() => [
|
|
2242
|
-
createTextVNode(toDisplayString(rate.percentage) + "%", 1)
|
|
2243
|
-
]),
|
|
2244
|
-
_: 2
|
|
2245
|
-
}, 1024),
|
|
2246
|
-
createVNode(_sfc_main$i, { number: "" }, {
|
|
2247
|
-
default: withCtx(() => [
|
|
2248
|
-
createVNode(_sfc_main$l, {
|
|
2249
|
-
value: rate.tax_amount
|
|
2250
|
-
}, null, 8, ["value"])
|
|
2251
|
-
]),
|
|
2252
|
-
_: 2
|
|
2253
|
-
}, 1024)
|
|
2254
|
-
]);
|
|
2255
|
-
}), 128))
|
|
2256
|
-
]),
|
|
2257
|
-
_: 2
|
|
2258
|
-
}, 1024)
|
|
2259
|
-
])) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
|
2260
|
-
createVNode(_sfc_main$i, null, {
|
|
2261
|
-
default: withCtx(() => [
|
|
2262
|
-
createTextVNode(toDisplayString(taxCategory.name) + " (" + toDisplayString(taxCategory.category) + ") ", 1)
|
|
2263
|
-
]),
|
|
2264
|
-
_: 2
|
|
2265
|
-
}, 1024),
|
|
2266
|
-
createVNode(_sfc_main$i, { number: "" }, {
|
|
2267
|
-
default: withCtx(() => [
|
|
2268
|
-
createVNode(_sfc_main$l, {
|
|
2269
|
-
value: taxCategory.base_amount
|
|
2270
|
-
}, null, 8, ["value"])
|
|
2271
|
-
]),
|
|
2272
|
-
_: 2
|
|
2273
|
-
}, 1024),
|
|
2274
|
-
createVNode(_sfc_main$i, { number: "" }, {
|
|
2275
|
-
default: withCtx(() => [
|
|
2276
|
-
createTextVNode(toDisplayString(taxCategory.percentage) + "%", 1)
|
|
2277
|
-
]),
|
|
2278
|
-
_: 2
|
|
2279
|
-
}, 1024),
|
|
2280
|
-
createVNode(_sfc_main$i, { number: "" }, {
|
|
2281
|
-
default: withCtx(() => [
|
|
2282
|
-
createVNode(_sfc_main$l, {
|
|
2283
|
-
value: taxCategory.tax_amount
|
|
2284
|
-
}, null, 8, ["value"])
|
|
2285
|
-
]),
|
|
2286
|
-
_: 2
|
|
2287
|
-
}, 1024)
|
|
2288
|
-
], 64))
|
|
2289
|
-
]);
|
|
2290
|
-
}), 128))
|
|
2291
|
-
]),
|
|
2292
|
-
_: 1
|
|
2293
|
-
});
|
|
2294
|
-
};
|
|
2295
|
-
}
|
|
2296
|
-
});
|
|
2297
|
-
const _hoisted_1 = { class: "flex items-start justify-between" };
|
|
2298
|
-
const _hoisted_2 = {
|
|
2299
|
-
key: 0,
|
|
2300
|
-
class: "max-h-9"
|
|
2301
|
-
};
|
|
2302
|
-
const _hoisted_3 = { class: "flex flex-col gap-2" };
|
|
2303
|
-
const _hoisted_4 = { key: 0 };
|
|
2304
|
-
const _hoisted_5 = { key: 3 };
|
|
2305
|
-
const _hoisted_6 = {
|
|
2306
|
-
colspan: "2",
|
|
2307
|
-
class: "p-0"
|
|
2308
|
-
};
|
|
2309
|
-
const _hoisted_7 = ["tabindex"];
|
|
2310
|
-
const _hoisted_8 = { key: 1 };
|
|
2311
|
-
const _hoisted_9 = {
|
|
2312
|
-
colspan: "2",
|
|
2313
|
-
class: "p-0"
|
|
2314
|
-
};
|
|
2315
|
-
const _hoisted_10 = { class: "-mx-9 bg-gray-50 px-9 py-3 text-xs" };
|
|
2316
|
-
const _hoisted_11 = ["tabindex", "onClick", "onKeyup"];
|
|
2317
|
-
const _hoisted_12 = { key: 0 };
|
|
2318
|
-
const _hoisted_13 = {
|
|
2319
|
-
colspan: "2",
|
|
2320
|
-
class: "p-0"
|
|
2321
|
-
};
|
|
2322
|
-
const _hoisted_14 = { class: "-mx-9 bg-gray-50 px-9 py-3 text-xs" };
|
|
2323
|
-
const _hoisted_15 = { key: 1 };
|
|
2324
|
-
const _hoisted_16 = {
|
|
2325
|
-
colspan: "2",
|
|
2326
|
-
class: "p-0"
|
|
2327
|
-
};
|
|
2328
|
-
const _hoisted_17 = {
|
|
2329
|
-
key: 0,
|
|
2330
|
-
class: "break-inside-avoid border-t font-bold"
|
|
2331
|
-
};
|
|
2332
|
-
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
2333
|
-
__name: "InvoiceSummary",
|
|
2334
|
-
props: {
|
|
2335
|
-
invoice: {},
|
|
2336
|
-
isExpandable: { type: Boolean, default: false },
|
|
2337
|
-
forceExpanded: { type: Boolean, default: false },
|
|
2338
|
-
heading: { default: "details" },
|
|
2339
|
-
isInvoiceLineCreatable: { type: Boolean, default: false },
|
|
2340
|
-
isNoteCreatable: { type: Boolean, default: false },
|
|
2341
|
-
showRenderedServicesHeader: { type: Boolean, default: true },
|
|
2342
|
-
isCustomerFacing: { type: Boolean },
|
|
2343
|
-
showTotals: { type: Boolean, default: true },
|
|
2344
|
-
hideOneOffCreditBreakdown: { type: Boolean, default: false },
|
|
2345
|
-
showWalletBalance: { type: Boolean, default: true }
|
|
2346
|
-
},
|
|
2347
|
-
emits: ["add-invoice-line", "add-note"],
|
|
2348
|
-
setup(__props, { emit: __emit }) {
|
|
2349
|
-
const intl = useIntl();
|
|
2350
|
-
const { formatMessage } = intl;
|
|
2351
|
-
const emit = __emit;
|
|
2352
|
-
const props = __props;
|
|
2353
|
-
const [expandedItems, toggleItems] = useSimpleToggleList();
|
|
2354
|
-
const [expandedDeductions, toggleDeductions] = useSimpleToggleList();
|
|
2355
|
-
const [expandedTaxes, toggleTaxes] = useToggle();
|
|
2356
|
-
const handleToggleItems = (...params) => {
|
|
2357
|
-
if (!props.isExpandable) return;
|
|
2358
|
-
toggleItems(...params);
|
|
2359
|
-
};
|
|
2360
|
-
const handleToggleDeductions = (index) => {
|
|
2361
|
-
if (!props.isExpandable) return;
|
|
2362
|
-
toggleDeductions(index);
|
|
2363
|
-
};
|
|
2364
|
-
const handleToggleTaxes = () => {
|
|
2365
|
-
if (!props.invoice.tax_categories || !props.isExpandable) return;
|
|
2366
|
-
toggleTaxes();
|
|
2367
|
-
};
|
|
2368
|
-
const formatIndex = (rootIndex, itemIndex) => +`${rootIndex}${itemIndex}`;
|
|
2369
|
-
const getTitle = (invoicePeriod) => {
|
|
2370
|
-
return intl.$t(
|
|
2371
|
-
{
|
|
2372
|
-
id: "invoice.service_period_heading",
|
|
2373
|
-
defaultMessage: "Service period - {start_at} - {end_at}",
|
|
2374
|
-
description: "Heading for rendered services where {start_at} is replaced for the start date and {end_at} for the end date in invoice summary"
|
|
2375
|
-
},
|
|
2376
|
-
{
|
|
2377
|
-
start_at: intl.formatDate({
|
|
2378
|
-
date: invoicePeriod.start_at,
|
|
2379
|
-
format: "date",
|
|
2380
|
-
timezone: formatTimezone(props.invoice.customer.timezone),
|
|
2381
|
-
offsetType: "offsetted"
|
|
2382
|
-
}),
|
|
2383
|
-
end_at: intl.formatDate({
|
|
2384
|
-
date: invoicePeriod.end_at,
|
|
2385
|
-
format: "date",
|
|
2386
|
-
timezone: formatTimezone(props.invoice.customer.timezone),
|
|
2387
|
-
offsetType: "offsetted"
|
|
2388
|
-
})
|
|
2389
|
-
}
|
|
2390
|
-
);
|
|
2391
|
-
};
|
|
2392
|
-
const getTableHeading = (invoiceGroupType) => {
|
|
2393
|
-
switch (invoiceGroupType) {
|
|
2394
|
-
case "PRICING":
|
|
2395
|
-
case "REVENUE": {
|
|
2396
|
-
return intl.$t({
|
|
2397
|
-
id: "invoice.table_heading.products",
|
|
2398
|
-
defaultMessage: "Products",
|
|
2399
|
-
description: "Table heading for the column containing the products of the invoice"
|
|
2400
|
-
});
|
|
2401
|
-
}
|
|
2402
|
-
case "COMMITMENT":
|
|
2403
|
-
return intl.$t({
|
|
2404
|
-
id: "invoice.table_heading.commitments",
|
|
2405
|
-
defaultMessage: "Commitments",
|
|
2406
|
-
description: "Table heading for the column containing the commitments of the invoice"
|
|
2407
|
-
});
|
|
2408
|
-
case "DISCOUNT":
|
|
2409
|
-
return intl.$t({
|
|
2410
|
-
id: "invoice.table_heading.discounts",
|
|
2411
|
-
defaultMessage: "Discounts",
|
|
2412
|
-
description: "Table heading for the column containing the discounts of the invoice"
|
|
2413
|
-
});
|
|
2414
|
-
case "MARKUP":
|
|
2415
|
-
return intl.$t({
|
|
2416
|
-
id: "invoice.table_heading.markups",
|
|
2417
|
-
defaultMessage: "Markups",
|
|
2418
|
-
description: "Table heading for the column containing the markups of the invoice"
|
|
2419
|
-
});
|
|
2420
|
-
case "ONE_OFF":
|
|
2421
|
-
return intl.$t({
|
|
2422
|
-
id: "invoice.table_heading.one_offs",
|
|
2423
|
-
defaultMessage: "One-off's",
|
|
2424
|
-
description: "Table heading for the column containing the one-offs of the invoice"
|
|
2425
|
-
});
|
|
2426
|
-
}
|
|
2427
|
-
};
|
|
2428
|
-
const getDeductionLabel = (group) => {
|
|
2429
|
-
var _a, _b;
|
|
2430
|
-
if ((_a = group.products) == null ? void 0 : _a.length) {
|
|
2431
|
-
return [(_b = group.pricing) == null ? void 0 : _b.name, getComposedString(group.products.map((item) => item.name))].filter(Boolean).join(" - ");
|
|
2432
|
-
}
|
|
2433
|
-
return group.description ?? "";
|
|
2434
|
-
};
|
|
2435
|
-
const groupHasWalletBalance = (group) => props.showWalletBalance && !(props.hideOneOffCreditBreakdown && group.type === "ONE_OFF") && (group.lines ?? []).some((line) => {
|
|
2436
|
-
var _a;
|
|
2437
|
-
return !!((_a = line.details) == null ? void 0 : _a.wallet_balance_details);
|
|
2438
|
-
});
|
|
2439
|
-
const getInvoiceGroupsByType = (invoicePeriod) => {
|
|
2440
|
-
return invoicePeriod.groups.reduce(
|
|
2441
|
-
(acc, invoiceGroup) => {
|
|
2442
|
-
if (!(invoiceGroup.type in acc)) {
|
|
2443
|
-
return { ...acc, [invoiceGroup.type]: [invoiceGroup] };
|
|
2444
|
-
}
|
|
2445
|
-
return {
|
|
2446
|
-
...acc,
|
|
2447
|
-
[invoiceGroup.type]: [...acc[invoiceGroup.type], invoiceGroup]
|
|
2448
|
-
};
|
|
2449
|
-
},
|
|
2450
|
-
{}
|
|
2451
|
-
);
|
|
2452
|
-
};
|
|
2453
|
-
const addInvoiceContextMenuItems = computed(() => {
|
|
2454
|
-
const result = [];
|
|
2455
|
-
const showInvoiceLineAddButton = ["ONE_OFF", "STANDARD", "ONE_OFF_CREDIT"].includes(props.invoice.type) && ["DRAFT", "OPEN"].includes(props.invoice.status) && props.isInvoiceLineCreatable;
|
|
2456
|
-
if (showInvoiceLineAddButton) {
|
|
2457
|
-
result.push({
|
|
2458
|
-
label: formatMessage({
|
|
2459
|
-
defaultMessage: "Invoice line",
|
|
2460
|
-
id: "JlhdD2",
|
|
2461
|
-
description: "Label for adding an invoice line"
|
|
2462
|
-
}),
|
|
2463
|
-
onClick: () => emit("add-invoice-line")
|
|
2464
|
-
});
|
|
2465
|
-
}
|
|
2466
|
-
if (props.isNoteCreatable) {
|
|
2467
|
-
result.push({
|
|
2468
|
-
label: formatMessage({
|
|
2469
|
-
defaultMessage: "Note",
|
|
2470
|
-
id: "jB8+k/",
|
|
2471
|
-
description: "Label for adding a note to an invoice"
|
|
2472
|
-
}),
|
|
2473
|
-
onClick: () => emit("add-note")
|
|
2474
|
-
});
|
|
2475
|
-
}
|
|
2476
|
-
return result;
|
|
2477
|
-
});
|
|
2478
|
-
const showTaxPerLineItem = computed(() => props.invoice.show_tax_per_line_item !== false);
|
|
2479
|
-
const sectionTitle = computed(() => {
|
|
2480
|
-
if (props.heading === "summary") {
|
|
2481
|
-
return intl.$t({
|
|
2482
|
-
id: "invoice.summaryTitle",
|
|
2483
|
-
defaultMessage: "Invoice summary",
|
|
2484
|
-
description: "Title for the compact, always-shown invoice summary section"
|
|
2485
|
-
});
|
|
2486
|
-
}
|
|
2487
|
-
switch (props.invoice.type) {
|
|
2488
|
-
case "CREDIT":
|
|
2489
|
-
return intl.$t({
|
|
2490
|
-
id: "invoice.creditDetailsTitle",
|
|
2491
|
-
defaultMessage: "Credit details",
|
|
2492
|
-
description: "Title for the invoice summary of a credit-note invoice"
|
|
2493
|
-
});
|
|
2494
|
-
case "ONE_OFF":
|
|
2495
|
-
return intl.$t({
|
|
2496
|
-
id: "invoice.oneOffDetailsTitle",
|
|
2497
|
-
defaultMessage: "One-off details",
|
|
2498
|
-
description: "Title for the invoice summary of a one-off invoice"
|
|
2499
|
-
});
|
|
2500
|
-
case "ONE_OFF_CREDIT":
|
|
2501
|
-
return intl.$t({
|
|
2502
|
-
id: "invoice.oneOffCreditDetailsTitle",
|
|
2503
|
-
defaultMessage: "One-off credit details",
|
|
2504
|
-
description: "Title for the invoice summary of a one-off credit-note invoice"
|
|
2505
|
-
});
|
|
2506
|
-
default:
|
|
2507
|
-
return intl.$t({
|
|
2508
|
-
id: "invoice.title",
|
|
2509
|
-
defaultMessage: "Details",
|
|
2510
|
-
description: "Title for the invoice summary"
|
|
2511
|
-
});
|
|
2512
|
-
}
|
|
2513
|
-
});
|
|
2514
|
-
return (_ctx, _cache) => {
|
|
2515
|
-
var _a;
|
|
2516
|
-
return openBlock(), createElementBlock("div", null, [
|
|
2517
|
-
createElementVNode("div", _hoisted_1, [
|
|
2518
|
-
_ctx.$slots.logo ? (openBlock(), createElementBlock("div", _hoisted_2, [
|
|
2519
|
-
renderSlot(_ctx.$slots, "logo")
|
|
2520
|
-
])) : (openBlock(), createBlock(_sfc_main$q, {
|
|
2521
|
-
key: 1,
|
|
2522
|
-
title: sectionTitle.value,
|
|
2523
|
-
variant: "neutral",
|
|
2524
|
-
icon: "draft",
|
|
2525
|
-
"icon-class": "print:hidden",
|
|
2526
|
-
"title-class": "print:text-sm"
|
|
2527
|
-
}, null, 8, ["title"])),
|
|
2528
|
-
_ctx.$slots.intro ? renderSlot(_ctx.$slots, "intro", {}, void 0, void 0, 2) : createCommentVNode("", true),
|
|
2529
|
-
createElementVNode("div", _hoisted_3, [
|
|
2530
|
-
((_a = addInvoiceContextMenuItems.value) == null ? void 0 : _a.length) ? (openBlock(), createBlock(_sfc_main$r, {
|
|
2531
|
-
key: 0,
|
|
2532
|
-
items: addInvoiceContextMenuItems.value,
|
|
2533
|
-
width: "auto"
|
|
2534
|
-
}, {
|
|
2535
|
-
trigger: withCtx(() => [
|
|
2536
|
-
createVNode(_sfc_main$s, {
|
|
2537
|
-
"icon-prefix": "add",
|
|
2538
|
-
size: "sm",
|
|
2539
|
-
intent: "secondary"
|
|
2540
|
-
}, {
|
|
2541
|
-
default: withCtx(() => [
|
|
2542
|
-
createTextVNode(toDisplayString(unref(formatMessage)({
|
|
2543
|
-
defaultMessage: "Add",
|
|
2544
|
-
id: "YnK/yF",
|
|
2545
|
-
description: "Label for adding an item to an invoice"
|
|
2546
|
-
})), 1)
|
|
2547
|
-
]),
|
|
2548
|
-
_: 1
|
|
2549
|
-
})
|
|
2550
|
-
]),
|
|
2551
|
-
_: 1
|
|
2552
|
-
}, 8, ["items"])) : createCommentVNode("", true),
|
|
2553
|
-
renderSlot(_ctx.$slots, "child-customers-selector")
|
|
2554
|
-
])
|
|
2555
|
-
]),
|
|
2556
|
-
_ctx.$slots.total ? renderSlot(_ctx.$slots, "total", {}, void 0, void 0, 0) : createCommentVNode("", true),
|
|
2557
|
-
renderSlot(_ctx.$slots, "notes"),
|
|
2558
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(__props.invoice.periods, (invoicePeriod, invoicePeriodIndex) => {
|
|
2559
|
-
return openBlock(), createElementBlock(Fragment, { key: invoicePeriodIndex }, [
|
|
2560
|
-
__props.showRenderedServicesHeader ? (openBlock(), createBlock(_sfc_main$t, {
|
|
2561
|
-
key: 0,
|
|
2562
|
-
class: "mt-6"
|
|
2563
|
-
}, {
|
|
2564
|
-
default: withCtx(() => [
|
|
2565
|
-
createVNode(_sfc_main$u, {
|
|
2566
|
-
tag: "h2",
|
|
2567
|
-
variant: "caps-heading"
|
|
2568
|
-
}, {
|
|
2569
|
-
default: withCtx(() => [
|
|
2570
|
-
createTextVNode(toDisplayString(getTitle(invoicePeriod)), 1)
|
|
2571
|
-
]),
|
|
2572
|
-
_: 2
|
|
2573
|
-
}, 1024)
|
|
2574
|
-
]),
|
|
2575
|
-
_: 2
|
|
2576
|
-
}, 1024)) : createCommentVNode("", true),
|
|
2577
|
-
invoicePeriod.groups ? (openBlock(), createBlock(InvoiceTable, {
|
|
2578
|
-
key: 1,
|
|
2579
|
-
class: normalizeClass({ "mt-3": __props.showRenderedServicesHeader }),
|
|
2580
|
-
"data-testid": unref(INVOICE_PERIOD)
|
|
2581
|
-
}, {
|
|
2582
|
-
default: withCtx(() => [
|
|
2583
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(Object.entries(
|
|
2584
|
-
getInvoiceGroupsByType(invoicePeriod)
|
|
2585
|
-
), ([groupType, groups], index) => {
|
|
2586
|
-
return openBlock(), createElementBlock(Fragment, { key: groupType }, [
|
|
2587
|
-
index > 0 ? (openBlock(), createElementBlock("tr", _hoisted_4, [..._cache[0] || (_cache[0] = [
|
|
2588
|
-
createElementVNode("td", null, [
|
|
2589
|
-
createElementVNode("div", { class: "h-4" })
|
|
2590
|
-
], -1)
|
|
2591
|
-
])])) : createCommentVNode("", true),
|
|
2592
|
-
createElementVNode("tr", null, [
|
|
2593
|
-
createVNode(_sfc_main$h, {
|
|
2594
|
-
left: "",
|
|
2595
|
-
class: "text-secondary"
|
|
2596
|
-
}, {
|
|
2597
|
-
default: withCtx(() => [
|
|
2598
|
-
createTextVNode(toDisplayString(getTableHeading(groupType)), 1)
|
|
2599
|
-
]),
|
|
2600
|
-
_: 2
|
|
2601
|
-
}, 1024),
|
|
2602
|
-
createVNode(_sfc_main$h, {
|
|
2603
|
-
right: "",
|
|
2604
|
-
class: "w-28 text-secondary"
|
|
2605
|
-
}, {
|
|
2606
|
-
default: withCtx(() => [
|
|
2607
|
-
createTextVNode(toDisplayString(unref(intl).$t({
|
|
2608
|
-
id: "invoice.amount_table_heading",
|
|
2609
|
-
defaultMessage: "Amount",
|
|
2610
|
-
description: "Table heading for the amount column in the invoice table"
|
|
2611
|
-
})), 1)
|
|
2612
|
-
]),
|
|
2613
|
-
_: 1
|
|
2614
|
-
})
|
|
2615
|
-
]),
|
|
2616
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(groups, (group, groupIndex) => {
|
|
2617
|
-
return openBlock(), createElementBlock(Fragment, { key: groupIndex }, [
|
|
2618
|
-
groupType === "REVENUE" || groupType === "PRICING" || groupType === "ONE_OFF" ? (openBlock(), createBlock(_sfc_main$5, {
|
|
2619
|
-
key: 0,
|
|
2620
|
-
group,
|
|
2621
|
-
"expanded-items": unref(expandedItems),
|
|
2622
|
-
"handle-toggle-items": handleToggleItems,
|
|
2623
|
-
"is-expandable": __props.isExpandable,
|
|
2624
|
-
"force-expanded": __props.forceExpanded,
|
|
2625
|
-
"format-index": formatIndex,
|
|
2626
|
-
"invoice-period-order": invoicePeriod.period_order,
|
|
2627
|
-
"group-order": group.group_order,
|
|
2628
|
-
"amount-type": __props.invoice.pricing_amount_type,
|
|
2629
|
-
"processing-only-customers": __props.invoice.processing_only_customers,
|
|
2630
|
-
"display-invoice-sub-lines-per-processing-only-customer": __props.invoice.display_invoice_sub_lines_per_processing_only_customer,
|
|
2631
|
-
"show-tax-per-line-item": showTaxPerLineItem.value,
|
|
2632
|
-
"forwarded-from-customers": __props.invoice.forwarded_from_customers,
|
|
2633
|
-
"show-original-customer-invoice-line": __props.invoice.show_original_customer_invoice_line
|
|
2634
|
-
}, {
|
|
2635
|
-
"invoice-line-prefix": withCtx((linePrefixProps) => [
|
|
2636
|
-
renderSlot(_ctx.$slots, "invoice-line-prefix", mergeProps({ ref_for: true }, linePrefixProps))
|
|
2637
|
-
]),
|
|
2638
|
-
"one-off-line-context-menu": withCtx((oneOffGroupProps) => [
|
|
2639
|
-
renderSlot(_ctx.$slots, "one-off-line-context-menu", mergeProps({ ref_for: true }, oneOffGroupProps, {
|
|
2640
|
-
periodOrder: invoicePeriod.period_order
|
|
2641
|
-
}))
|
|
2642
|
-
]),
|
|
2643
|
-
_: 2
|
|
2644
|
-
}, 1032, ["group", "expanded-items", "is-expandable", "force-expanded", "invoice-period-order", "group-order", "amount-type", "processing-only-customers", "display-invoice-sub-lines-per-processing-only-customer", "show-tax-per-line-item", "forwarded-from-customers", "show-original-customer-invoice-line"])) : groupType === "DISCOUNT" || groupType === "MARKUP" ? (openBlock(), createBlock(_sfc_main$a, {
|
|
2645
|
-
key: 1,
|
|
2646
|
-
group,
|
|
2647
|
-
"expanded-items": unref(expandedItems),
|
|
2648
|
-
"handle-toggle-items": handleToggleItems,
|
|
2649
|
-
"is-expandable": __props.isExpandable,
|
|
2650
|
-
"force-expanded": __props.forceExpanded,
|
|
2651
|
-
"format-index": formatIndex,
|
|
2652
|
-
"invoice-period-order": invoicePeriod.period_order,
|
|
2653
|
-
"group-order": group.group_order,
|
|
2654
|
-
"amount-type": __props.invoice.pricing_amount_type,
|
|
2655
|
-
heading: groupType === "DISCOUNT" ? unref(intl).$t({
|
|
2656
|
-
id: "invoice.discounts_table_heading",
|
|
2657
|
-
defaultMessage: "Discounts",
|
|
2658
|
-
description: "Heading for discounts in the invoice table"
|
|
2659
|
-
}) : unref(intl).$t({
|
|
2660
|
-
id: "invoice.markups_table_heading",
|
|
2661
|
-
defaultMessage: "Markups",
|
|
2662
|
-
description: "Heading for markups in the invoice table"
|
|
2663
|
-
})
|
|
2664
|
-
}, {
|
|
2665
|
-
"invoice-line-prefix": withCtx((linePrefixProps) => [
|
|
2666
|
-
renderSlot(_ctx.$slots, "invoice-line-prefix", mergeProps({ ref_for: true }, linePrefixProps))
|
|
2667
|
-
]),
|
|
2668
|
-
_: 3
|
|
2669
|
-
}, 8, ["group", "expanded-items", "is-expandable", "force-expanded", "invoice-period-order", "group-order", "amount-type", "heading"])) : groupType === "COMMITMENT" ? (openBlock(), createBlock(_sfc_main$b, {
|
|
2670
|
-
key: 2,
|
|
2671
|
-
group,
|
|
2672
|
-
"expanded-items": unref(expandedItems),
|
|
2673
|
-
"handle-toggle-items": handleToggleItems,
|
|
2674
|
-
"is-expandable": __props.isExpandable,
|
|
2675
|
-
"force-expanded": __props.forceExpanded,
|
|
2676
|
-
"format-index": formatIndex,
|
|
2677
|
-
"invoice-period-order": invoicePeriod.period_order,
|
|
2678
|
-
"group-order": group.group_order,
|
|
2679
|
-
"amount-type": __props.invoice.pricing_amount_type
|
|
2680
|
-
}, {
|
|
2681
|
-
"invoice-line-prefix": withCtx((linePrefixProps) => [
|
|
2682
|
-
renderSlot(_ctx.$slots, "invoice-line-prefix", mergeProps({ ref_for: true }, linePrefixProps))
|
|
2683
|
-
]),
|
|
2684
|
-
_: 3
|
|
2685
|
-
}, 8, ["group", "expanded-items", "is-expandable", "force-expanded", "invoice-period-order", "group-order", "amount-type"])) : createCommentVNode("", true),
|
|
2686
|
-
groupHasWalletBalance(group) ? (openBlock(), createElementBlock("tr", _hoisted_5, [
|
|
2687
|
-
createElementVNode("td", _hoisted_6, [
|
|
2688
|
-
createVNode(_sfc_main$4, {
|
|
2689
|
-
lines: group.lines,
|
|
2690
|
-
"credit-types": __props.invoice.credit_types
|
|
2691
|
-
}, null, 8, ["lines", "credit-types"])
|
|
2692
|
-
])
|
|
2693
|
-
])) : createCommentVNode("", true)
|
|
2694
|
-
], 64);
|
|
2695
|
-
}), 128))
|
|
2696
|
-
], 64);
|
|
2697
|
-
}), 128))
|
|
2698
|
-
]),
|
|
2699
|
-
_: 2
|
|
2700
|
-
}, 1032, ["class", "data-testid"])) : createCommentVNode("", true)
|
|
2701
|
-
], 64);
|
|
2702
|
-
}), 128)),
|
|
2703
|
-
__props.invoice.tax_summary && (__props.showTotals || (__props.forceExpanded || unref(expandedTaxes)) && __props.invoice.tax_categories) ? (openBlock(), createBlock(InvoiceTable, {
|
|
2704
|
-
key: 1,
|
|
2705
|
-
class: "mt-6 print:ml-auto print:w-2/3"
|
|
2706
|
-
}, {
|
|
2707
|
-
default: withCtx(() => [
|
|
2708
|
-
__props.showTotals ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
|
|
2709
|
-
createElementVNode("tr", null, [
|
|
2710
|
-
createVNode(_sfc_main$h, {
|
|
2711
|
-
left: "",
|
|
2712
|
-
class: "text-secondary"
|
|
2713
|
-
}, {
|
|
2714
|
-
default: withCtx(() => [
|
|
2715
|
-
createTextVNode(toDisplayString(unref(intl).$t({
|
|
2716
|
-
id: "invoice.totals_table_heading",
|
|
2717
|
-
defaultMessage: "Totals",
|
|
2718
|
-
description: "Table heading for the totals column in the invoice table"
|
|
2719
|
-
})), 1)
|
|
2720
|
-
]),
|
|
2721
|
-
_: 1
|
|
2722
|
-
}),
|
|
2723
|
-
createVNode(_sfc_main$h, {
|
|
2724
|
-
right: "",
|
|
2725
|
-
class: "w-28 text-secondary"
|
|
2726
|
-
}, {
|
|
2727
|
-
default: withCtx(() => [
|
|
2728
|
-
createTextVNode(toDisplayString(unref(intl).$t({
|
|
2729
|
-
id: "invoice.amount_table_heading",
|
|
2730
|
-
defaultMessage: "Amount",
|
|
2731
|
-
description: "Table heading for the amount column in the invoice table"
|
|
2732
|
-
})), 1)
|
|
2733
|
-
]),
|
|
2734
|
-
_: 1
|
|
2735
|
-
})
|
|
2736
|
-
]),
|
|
2737
|
-
__props.invoice.pricing_amount_type === "INCLUDING_TAX" ? (openBlock(), createBlock(_sfc_main$2, {
|
|
2738
|
-
key: 0,
|
|
2739
|
-
"total-amount": __props.invoice.tax_summary.total_amount,
|
|
2740
|
-
"is-customer-facing": __props.isCustomerFacing
|
|
2741
|
-
}, null, 8, ["total-amount", "is-customer-facing"])) : (openBlock(), createBlock(_sfc_main$3, {
|
|
2742
|
-
key: 1,
|
|
2743
|
-
"base-amount": __props.invoice.tax_summary.base_amount
|
|
2744
|
-
}, null, 8, ["base-amount"])),
|
|
2745
|
-
__props.invoice.tax_summary.tax_amount ? (openBlock(), createElementBlock("tr", {
|
|
2746
|
-
key: 2,
|
|
2747
|
-
class: normalizeClass([{ "cursor-pointer": __props.invoice.tax_categories && __props.isExpandable }, "break-inside-avoid border-t"]),
|
|
2748
|
-
tabindex: __props.isExpandable ? 0 : void 0,
|
|
2749
|
-
onClick: handleToggleTaxes,
|
|
2750
|
-
onKeyup: [
|
|
2751
|
-
withKeys(handleToggleTaxes, ["enter"]),
|
|
2752
|
-
withKeys(handleToggleTaxes, ["space"])
|
|
2753
|
-
]
|
|
2754
|
-
}, [
|
|
2755
|
-
createVNode(_sfc_main$i, null, {
|
|
2756
|
-
default: withCtx(() => [
|
|
2757
|
-
__props.isExpandable && __props.invoice.tax_categories && __props.invoice.tax_categories.length ? (openBlock(), createBlock(_sfc_main$n, {
|
|
2758
|
-
key: 0,
|
|
2759
|
-
icon: "keyboard_arrow_down",
|
|
2760
|
-
size: "md",
|
|
2761
|
-
class: normalizeClass(["absolute -translate-x-7 text-slate-400", { "-rotate-90": !unref(expandedTaxes) }])
|
|
2762
|
-
}, null, 8, ["class"])) : createCommentVNode("", true),
|
|
2763
|
-
createVNode(_sfc_main$6, {
|
|
2764
|
-
label: unref(intl).$t({
|
|
2765
|
-
id: "invoice.taxes_table_heading",
|
|
2766
|
-
defaultMessage: "Taxes",
|
|
2767
|
-
description: "Table heading for the taxes column in the invoice table"
|
|
2768
|
-
}),
|
|
2769
|
-
count: __props.isExpandable && __props.invoice.tax_categories ? __props.invoice.tax_categories.length : void 0
|
|
2770
|
-
}, null, 8, ["label", "count"])
|
|
2771
|
-
]),
|
|
2772
|
-
_: 1
|
|
2773
|
-
}),
|
|
2774
|
-
createVNode(_sfc_main$i, { number: "" }, {
|
|
2775
|
-
default: withCtx(() => [
|
|
2776
|
-
createVNode(_sfc_main$l, {
|
|
2777
|
-
value: __props.invoice.tax_summary.tax_amount,
|
|
2778
|
-
"data-testid": unref(SUMMARY_TOTAL_TAX)
|
|
2779
|
-
}, null, 8, ["value", "data-testid"])
|
|
2780
|
-
]),
|
|
2781
|
-
_: 1
|
|
2782
|
-
})
|
|
2783
|
-
], 42, _hoisted_7)) : createCommentVNode("", true)
|
|
2784
|
-
], 64)) : createCommentVNode("", true),
|
|
2785
|
-
(__props.forceExpanded || unref(expandedTaxes)) && __props.invoice.tax_categories ? (openBlock(), createElementBlock("tr", _hoisted_8, [
|
|
2786
|
-
createElementVNode("td", _hoisted_9, [
|
|
2787
|
-
createElementVNode("div", _hoisted_10, [
|
|
2788
|
-
createVNode(_sfc_main$1, {
|
|
2789
|
-
"tax-categories": __props.invoice.tax_categories
|
|
2790
|
-
}, null, 8, ["tax-categories"])
|
|
2791
|
-
])
|
|
2792
|
-
])
|
|
2793
|
-
])) : createCommentVNode("", true),
|
|
2794
|
-
__props.showTotals ? (openBlock(), createElementBlock(Fragment, { key: 2 }, [
|
|
2795
|
-
__props.invoice.pricing_amount_type === "INCLUDING_TAX" ? (openBlock(), createBlock(_sfc_main$3, {
|
|
2796
|
-
key: 0,
|
|
2797
|
-
"base-amount": __props.invoice.tax_summary.base_amount
|
|
2798
|
-
}, null, 8, ["base-amount"])) : (openBlock(), createBlock(_sfc_main$2, {
|
|
2799
|
-
key: 1,
|
|
2800
|
-
"total-amount": __props.invoice.tax_summary.total_amount
|
|
2801
|
-
}, null, 8, ["total-amount"]))
|
|
2802
|
-
], 64)) : createCommentVNode("", true)
|
|
2803
|
-
]),
|
|
2804
|
-
_: 1
|
|
2805
|
-
})) : createCommentVNode("", true),
|
|
2806
|
-
!unref(isEmpty)(__props.invoice.closed_periods) ? (openBlock(), createBlock(InvoiceTable, {
|
|
2807
|
-
key: 2,
|
|
2808
|
-
class: "mt-6"
|
|
2809
|
-
}, {
|
|
2810
|
-
default: withCtx(() => [
|
|
2811
|
-
createElementVNode("tr", null, [
|
|
2812
|
-
createVNode(_sfc_main$h, {
|
|
2813
|
-
left: "",
|
|
2814
|
-
class: "text-secondary"
|
|
2815
|
-
}, {
|
|
2816
|
-
default: withCtx(() => [
|
|
2817
|
-
createTextVNode(toDisplayString(unref(intl).$t({
|
|
2818
|
-
id: "invoice.already_deducted_table_heading",
|
|
2819
|
-
defaultMessage: "Already deducted",
|
|
2820
|
-
description: "Table heading for the already deducted rows in the invoice table"
|
|
2821
|
-
})), 1)
|
|
2822
|
-
]),
|
|
2823
|
-
_: 1
|
|
2824
|
-
})
|
|
2825
|
-
]),
|
|
2826
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(__props.invoice.closed_periods, (rootGroup, rootGroupIndex) => {
|
|
2827
|
-
return openBlock(), createElementBlock(Fragment, { key: rootGroupIndex }, [
|
|
2828
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(rootGroup.groups, (group, groupIndex) => {
|
|
2829
|
-
return openBlock(), createElementBlock(Fragment, { key: groupIndex }, [
|
|
2830
|
-
createElementVNode("tr", {
|
|
2831
|
-
class: normalizeClass(["break-inside-avoid border-t", { "pt-6": rootGroupIndex === 0, "cursor-pointer": __props.isExpandable }]),
|
|
2832
|
-
tabindex: __props.isExpandable ? 0 : void 0,
|
|
2833
|
-
onClick: ($event) => handleToggleDeductions(formatIndex(rootGroupIndex, groupIndex)),
|
|
2834
|
-
onKeyup: [
|
|
2835
|
-
withKeys(($event) => handleToggleDeductions(formatIndex(rootGroupIndex, groupIndex)), ["enter"]),
|
|
2836
|
-
withKeys(($event) => handleToggleDeductions(formatIndex(rootGroupIndex, groupIndex)), ["space"])
|
|
2837
|
-
]
|
|
2838
|
-
}, [
|
|
2839
|
-
createVNode(_sfc_main$i, { class: "p-0" }, {
|
|
2840
|
-
default: withCtx(() => {
|
|
2841
|
-
var _a2;
|
|
2842
|
-
return [
|
|
2843
|
-
__props.isExpandable ? (openBlock(), createBlock(_sfc_main$n, {
|
|
2844
|
-
key: 0,
|
|
2845
|
-
icon: "keyboard_arrow_down",
|
|
2846
|
-
size: "md",
|
|
2847
|
-
class: normalizeClass(["absolute -translate-x-7 text-slate-400", {
|
|
2848
|
-
"-rotate-90": !unref(expandedDeductions).includes(
|
|
2849
|
-
formatIndex(rootGroupIndex, groupIndex)
|
|
2850
|
-
)
|
|
2851
|
-
}])
|
|
2852
|
-
}, null, 8, ["class"])) : createCommentVNode("", true),
|
|
2853
|
-
createVNode(_sfc_main$6, {
|
|
2854
|
-
label: getDeductionLabel(group),
|
|
2855
|
-
count: __props.isExpandable ? ((_a2 = group.lines) == null ? void 0 : _a2.length) ?? 0 : void 0
|
|
2856
|
-
}, null, 8, ["label", "count"])
|
|
2857
|
-
];
|
|
2858
|
-
}),
|
|
2859
|
-
_: 2
|
|
2860
|
-
}, 1024),
|
|
2861
|
-
createVNode(_sfc_main$i, {
|
|
2862
|
-
number: "",
|
|
2863
|
-
class: "w-28"
|
|
2864
|
-
}, {
|
|
2865
|
-
default: withCtx(() => [
|
|
2866
|
-
createVNode(_sfc_main$l, {
|
|
2867
|
-
value: group.amount_excluding_tax,
|
|
2868
|
-
"data-testid": unref(SUMMARY_TOTAL_DISCOUNT),
|
|
2869
|
-
"data-type": unref(DEDUCTION)
|
|
2870
|
-
}, null, 8, ["value", "data-testid", "data-type"])
|
|
2871
|
-
]),
|
|
2872
|
-
_: 2
|
|
2873
|
-
}, 1024)
|
|
2874
|
-
], 42, _hoisted_11),
|
|
2875
|
-
__props.forceExpanded || unref(expandedDeductions).includes(formatIndex(rootGroupIndex, groupIndex)) ? (openBlock(), createElementBlock("tr", _hoisted_12, [
|
|
2876
|
-
createElementVNode("td", _hoisted_13, [
|
|
2877
|
-
createElementVNode("div", _hoisted_14, [
|
|
2878
|
-
createVNode(_sfc_main$7, {
|
|
2879
|
-
"start-date": group.start_at,
|
|
2880
|
-
"end-date": group.end_at,
|
|
2881
|
-
total: group.amount_excluding_tax,
|
|
2882
|
-
group,
|
|
2883
|
-
"amount-type": __props.invoice.pricing_amount_type,
|
|
2884
|
-
"show-tax-per-line-item": showTaxPerLineItem.value,
|
|
2885
|
-
"processing-only-customers": __props.invoice.processing_only_customers,
|
|
2886
|
-
"display-invoice-sub-lines-per-processing-only-customer": __props.invoice.display_invoice_sub_lines_per_processing_only_customer
|
|
2887
|
-
}, {
|
|
2888
|
-
"one-off-line-context-menu": withCtx((oneOffGroupProps) => [
|
|
2889
|
-
renderSlot(_ctx.$slots, "one-off-line-context-menu", mergeProps({ ref_for: true }, oneOffGroupProps, {
|
|
2890
|
-
groupOrder: group.group_order,
|
|
2891
|
-
periodOrder: rootGroup.period_order
|
|
2892
|
-
}))
|
|
2893
|
-
]),
|
|
2894
|
-
_: 2
|
|
2895
|
-
}, 1032, ["start-date", "end-date", "total", "group", "amount-type", "show-tax-per-line-item", "processing-only-customers", "display-invoice-sub-lines-per-processing-only-customer"])
|
|
2896
|
-
])
|
|
2897
|
-
])
|
|
2898
|
-
])) : createCommentVNode("", true),
|
|
2899
|
-
groupHasWalletBalance(group) ? (openBlock(), createElementBlock("tr", _hoisted_15, [
|
|
2900
|
-
createElementVNode("td", _hoisted_16, [
|
|
2901
|
-
createVNode(_sfc_main$4, {
|
|
2902
|
-
lines: group.lines,
|
|
2903
|
-
"credit-types": __props.invoice.credit_types
|
|
2904
|
-
}, null, 8, ["lines", "credit-types"])
|
|
2905
|
-
])
|
|
2906
|
-
])) : createCommentVNode("", true)
|
|
2907
|
-
], 64);
|
|
2908
|
-
}), 128))
|
|
2909
|
-
], 64);
|
|
2910
|
-
}), 128)),
|
|
2911
|
-
__props.invoice.open_invoice_amount && !__props.invoice.paid && __props.showTotals ? (openBlock(), createElementBlock("tr", _hoisted_17, [
|
|
2912
|
-
createVNode(_sfc_main$i, { class: "font-bold" }, {
|
|
2913
|
-
default: withCtx(() => [
|
|
2914
|
-
createTextVNode(toDisplayString(unref(intl).$t({
|
|
2915
|
-
id: "invoice.amount_due_table_heading",
|
|
2916
|
-
defaultMessage: "Amount due",
|
|
2917
|
-
description: "Table heading for the amount due row in the invoice table"
|
|
2918
|
-
})), 1)
|
|
2919
|
-
]),
|
|
2920
|
-
_: 1
|
|
2921
|
-
}),
|
|
2922
|
-
createVNode(_sfc_main$i, { number: "" }, {
|
|
2923
|
-
default: withCtx(() => [
|
|
2924
|
-
createVNode(_sfc_main$l, {
|
|
2925
|
-
value: __props.invoice.open_invoice_amount,
|
|
2926
|
-
"data-testid": unref(SUMMARY_AMOUNT_DUE)
|
|
2927
|
-
}, null, 8, ["value", "data-testid"])
|
|
2928
|
-
]),
|
|
2929
|
-
_: 1
|
|
2930
|
-
})
|
|
2931
|
-
])) : createCommentVNode("", true)
|
|
2932
|
-
]),
|
|
2933
|
-
_: 3
|
|
2934
|
-
})) : createCommentVNode("", true)
|
|
2935
|
-
]);
|
|
2936
|
-
};
|
|
2937
|
-
}
|
|
2938
|
-
});
|
|
2939
|
-
export {
|
|
2940
|
-
InvoiceTable as I,
|
|
2941
|
-
_sfc_main as _,
|
|
2942
|
-
_sfc_main$h as a,
|
|
2943
|
-
_sfc_main$i as b
|
|
2944
|
-
};
|