@wisemen/wise-invoicing-web 0.0.3 → 0.0.5
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/{BillingDocumentDetailViewDataProvider-CwonTh2r.js → BillingDocumentDetailViewDataProvider-DdaNbuI2.js} +1085 -995
- package/dist/BillingDocumentDetailViewDataProvider.css +1 -1
- package/dist/{BillingDocumentPdf-GWCCjE6F.js → BillingDocumentPdf-D_NOfBhQ.js} +10 -10
- package/dist/{CreditNoteDetailViewDataProvider-CaucKK9o.js → CreditNoteDetailViewDataProvider-5ljhBOoN.js} +181 -181
- package/dist/{CreditNotePdfViewDataProvider-CDkvm-3m.js → CreditNotePdfViewDataProvider-CiWZN7Zy.js} +3 -3
- package/dist/{CustomFieldValueText-CC9spLWf.js → CustomFieldValueText-ne5yy02J.js} +2 -2
- package/dist/DataProvider-Dj34ljUX.js +75 -0
- package/dist/{DunningCaseDetailViewDataProvider-1Ui9yqUb.js → DunningCaseDetailViewDataProvider-CetbSmjq.js} +136 -130
- package/dist/DunningCaseOverviewView-Bq0BKVXG.js +747 -0
- package/dist/{DunningCaseReminderPdfViewDataProvider-CVnr9ge6.js → DunningCaseReminderPdfViewDataProvider-B3Y2aYFf.js} +5 -2
- package/dist/DunningCaseSendDialog-C47X_JjC.js +349 -0
- package/dist/InvoiceDetailViewDataProvider-DYH2ODDi.js +1670 -0
- package/dist/{InvoiceOverviewViewDataProvider-CNK7H5r2.js → InvoiceOverviewViewDataProvider-BT9cuQXw.js} +504 -440
- package/dist/{InvoicePdfView-CrWU8Xa-.js → InvoicePdfView-ug0BiMqe.js} +2 -2
- package/dist/{InvoicePdfViewDataProvider-nHZoeRxn.js → InvoicePdfViewDataProvider-WvjMiEZG.js} +3 -3
- package/dist/{InvoicePublicPdfViewDataProvider-CXWSg2pq.js → InvoicePublicPdfViewDataProvider-BI9RQqYp.js} +3 -3
- package/dist/{IssuerSettingsViewDataProvider-DcA6rgOJ.js → IssuerSettingsViewDataProvider-Bs4rEES2.js} +4 -4
- package/dist/ReminderSettingsViewDataProvider-5n2EfxPG.js +711 -0
- package/dist/{api.util-Dm_TQedZ.js → api.util-BCSgCfpS.js} +528 -509
- package/dist/{billingDocumentDetail.transformer-tmy9Tf_b.js → billingDocumentDetail.transformer-DIKAl4_L.js} +58 -89
- package/dist/client/index.d.ts +1 -1
- package/dist/client/types.gen.d.ts +28 -5
- package/dist/client/zod.gen.d.ts +869 -623
- package/dist/composables/invoicingConfig.composable.d.ts +0 -2
- package/dist/{creditNoteDetail.query-BM2saU0n.js → creditNoteDetail.query-DHP69UiB.js} +13 -13
- package/dist/{dist-DP8KNFVD.js → dist-D9lp7NDv.js} +20 -36
- package/dist/{dist-DJ8yJcb9.js → dist-PErDVE6-.js} +621 -671
- package/dist/{documentTitle.composable-D7XA-8iJ.js → documentTitle.composable-4ApFl9TZ.js} +22 -22
- package/dist/{invoicingConfig.composable-AjojW4qE.js → i18n.lib-B74GKndD.js} +58 -66
- package/dist/index.d.ts +51 -0
- package/dist/index.js +174 -175
- package/dist/{invoice.service-PsmVGGTR.js → invoice.service-DG5eacZC.js} +35 -35
- package/dist/{invoiceDeliveryStatus.util-CL8K78pD.js → invoiceDeliveryStatus.util-CX-IdqAu.js} +4 -4
- package/dist/{invoiceDetail.query-D2eFdE0j.js → invoiceDetail.query-C_IMGjOX.js} +1 -1
- package/dist/invoicingConfig.composable-BYqn1I9n.js +60 -0
- package/dist/{issuerSettings.query-d5i7Wd7j.js → issuerSettings.query-6wnSPphB.js} +2 -2
- package/dist/libs/i18n.lib.d.ts +50 -0
- package/dist/locales/en-US.json.d.ts +25 -0
- package/dist/locales/nl-BE.json.d.ts +25 -0
- package/dist/models/billing-document/billingDocumentLineItemGroupUpdateForm.model.d.ts +9 -3
- package/dist/modules/dunning-case/actions/dunningCase.actions.d.ts +12 -0
- package/dist/modules/dunning-case/actions/dunningCaseNavigateToCustomer.action.d.ts +1 -0
- package/dist/modules/dunning-case/actions/dunningCaseNavigateToDetail.action.d.ts +1 -0
- package/dist/modules/dunning-case/api/mutations/reminderConfigUpdate.mutation.d.ts +2 -0
- package/dist/modules/dunning-case/api/queries/dunningCaseIndex.query.d.ts +0 -1
- package/dist/modules/dunning-case/models/dunningCase.model.d.ts +12 -2
- package/dist/modules/dunning-case/models/reminderConfigForm.model.d.ts +3 -1
- package/dist/modules/dunning-case/use-cases/overview/components/DunningCaseOverviewActionsCell.vue.d.ts +13 -0
- package/dist/modules/dunning-case/use-cases/overview/components/DunningCaseOverviewCustomerCell.vue.d.ts +7 -0
- package/dist/modules/dunning-case/use-cases/overview/components/DunningCaseOverviewDaysOverdueCell.vue.d.ts +7 -0
- package/dist/modules/dunning-case/use-cases/overview/components/DunningCaseOverviewLastReminderCell.vue.d.ts +7 -0
- package/dist/modules/dunning-case/use-cases/overview/components/DunningCaseOverviewLevelCell.vue.d.ts +7 -0
- package/dist/modules/dunning-case/use-cases/overview/components/DunningCaseOverviewMetrics.vue.d.ts +8 -0
- package/dist/modules/dunning-case/use-cases/overview/components/DunningCaseOverviewOutstandingCell.vue.d.ts +7 -0
- package/dist/modules/dunning-case/use-cases/overview/components/DunningCaseOverviewReminderCell.vue.d.ts +7 -0
- package/dist/modules/dunning-case/use-cases/overview/components/dunningCaseOverviewLastReminderCell.spec.d.ts +1 -0
- package/dist/modules/dunning-case/use-cases/overview/components/dunningCaseOverviewReminderCell.spec.d.ts +1 -0
- package/dist/modules/dunning-case/use-cases/overview/composables/dunningCaseOverview.composable.d.ts +24 -0
- package/dist/modules/dunning-case/use-cases/overview/composables/dunningCaseOverviewTableColumns.composable.d.ts +8 -0
- package/dist/modules/dunning-case/use-cases/send/components/DunningCaseBulkSendStat.vue.d.ts +9 -0
- package/dist/modules/dunning-case/use-cases/send/components/DunningCaseBulkSendSummary.vue.d.ts +8 -0
- package/dist/modules/dunning-case/use-cases/send/components/DunningCaseSendFeeRow.vue.d.ts +8 -0
- package/dist/modules/dunning-case/use-cases/send/components/DunningCaseSendInvoiceRow.vue.d.ts +8 -0
- package/dist/modules/dunning-case/use-cases/send/components/DunningCaseSendInvoiceSummary.vue.d.ts +8 -0
- package/dist/modules/dunning-case/use-cases/send/components/DunningCaseSendRecipientAlert.vue.d.ts +7 -0
- package/dist/modules/dunning-case/use-cases/send/composables/dunningCaseReminderSubject.composable.d.ts +6 -0
- package/dist/modules/dunning-case/use-cases/send/composables/dunningCaseSendRecipient.composable.d.ts +16 -0
- package/dist/modules/dunning-case/use-cases/send/dialogs/dunningCaseBulkSendDialog.spec.d.ts +1 -0
- package/dist/modules/dunning-case/use-cases/send/utils/dunningCaseSend.util.d.ts +13 -0
- package/dist/modules/dunning-case/use-cases/settings/components/ReminderLadderFeeNotice.vue.d.ts +3 -0
- package/dist/modules/dunning-case/use-cases/settings/components/ReminderLadderPanel.vue.d.ts +12 -0
- package/dist/modules/dunning-case/use-cases/settings/components/ReminderLadderRow.vue.d.ts +28 -0
- package/dist/modules/dunning-case/use-cases/settings/components/ReminderLadderTimeline.vue.d.ts +13 -0
- package/dist/modules/dunning-case/use-cases/settings/components/ReminderTemplateTabs.vue.d.ts +20 -0
- package/dist/modules/dunning-case/use-cases/settings/components/ReminderTemplatesPanel.vue.d.ts +24 -0
- package/dist/modules/dunning-case/use-cases/settings/components/reminderLadderFeeNotice.spec.d.ts +1 -0
- package/dist/modules/dunning-case/use-cases/settings/composables/reminderLadder.composable.d.ts +43 -0
- package/dist/modules/invoice/api/invoiceIndexCache.util.d.ts +4 -4
- package/dist/modules/invoice/api/queries/invoiceUserSearch.query.d.ts +3 -0
- package/dist/modules/invoice/api/query-keys/invoice.queryKeys.d.ts +8 -0
- package/dist/modules/invoice/api/services/invoiceUser.service.d.ts +6 -0
- package/dist/modules/invoice/components/form/InvoiceFormPreparedByField.vue.d.ts +16 -0
- package/dist/modules/invoice/models/invoice/update/invoicePreparer.model.d.ts +4 -0
- package/dist/modules/invoice/models/invoice/update/invoicePreparer.transformer.d.ts +5 -0
- package/dist/modules/invoice/models/invoice/update/invoiceUserSearchQueryParams.model.d.ts +3 -0
- package/dist/modules/invoice/models/invoice/update/invoiceUserSearchQueryParams.transformer.d.ts +6 -0
- package/dist/modules/invoice/use-cases/overview/dialogs/InvoiceOverviewBulkActionDialog.vue.d.ts +1 -0
- package/dist/{plainDate.transformer-BxvJpJOv.js → plainDate.transformer-Dfe5r84P.js} +32 -1
- package/dist/{reminderConfig.query-C7I3M2pu.js → reminderConfig.query-B9OQY7IT.js} +56 -54
- package/dist/search.composable-BCtYqudV.js +52 -0
- package/dist/style.css +1 -1
- package/dist/ui/billing-document/table/billingDocumentLineItemsTable.context.d.ts +6 -6
- package/dist/ui/billing-document/table/composables/useBillingDocumentLineItemsEditor.composable.d.ts +1 -1
- package/dist/ui/billing-document/table/composables/useBillingDocumentLineItemsRowMutations.composable.d.ts +2 -2
- package/dist/ui/billing-document/table/composables/useBillingDocumentLineItemsRowMutations.composable.spec.d.ts +1 -0
- package/dist/ui/billing-document/table/composables/useBillingDocumentLineItemsTableDrag.composable.d.ts +3 -1
- package/dist/ui/billing-document/table/field/BillingDocumentLineItemsTableField.vue.d.ts +2 -0
- package/dist/ui/billing-document/table/field/BillingDocumentLineItemsTableTextField.vue.d.ts +1 -0
- package/dist/ui/billing-document/table/utils/billingDocumentLineItemsEditor.util.d.ts +19 -0
- package/dist/ui/data-provider/DataProviderErrorState.vue.d.ts +7 -0
- package/dist/ui/data-provider/dataProviderErrorState.spec.d.ts +1 -0
- package/package.json +6 -1
- package/dist/DataProvider-CfHLB3rH.js +0 -48
- package/dist/DunningCaseOverviewView-Bvwaj4_y.js +0 -507
- package/dist/InvoiceDetailViewDataProvider-DfRDFCEb.js +0 -1578
- package/dist/PermissionGuard-DDw-lDGL.js +0 -301
- package/dist/ReminderSettingsViewDataProvider-C4qz2Rli.js +0 -502
- package/dist/composables/permission-guard/permissionGuard.composable.d.ts +0 -4
- package/dist/ui/permission-guard/PermissionGuard.vue.d.ts +0 -22
- /package/dist/modules/dunning-case/{api/queries/dunningCaseIndex.query.spec.d.ts → use-cases/overview/components/dunningCaseOverviewActionsCell.spec.d.ts} +0 -0
package/dist/{CreditNotePdfViewDataProvider-CDkvm-3m.js → CreditNotePdfViewDataProvider-CiWZN7Zy.js}
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { t as e } from "./DataProvider-
|
|
2
|
-
import { t } from "./InvoicePdfView-
|
|
3
|
-
import { t as n } from "./creditNoteDetail.query-
|
|
1
|
+
import { t as e } from "./DataProvider-Dj34ljUX.js";
|
|
2
|
+
import { t } from "./InvoicePdfView-ug0BiMqe.js";
|
|
3
|
+
import { t as n } from "./creditNoteDetail.query-DHP69UiB.js";
|
|
4
4
|
import { useI18n as r } from "vue-i18n";
|
|
5
5
|
import { computed as i, createBlock as a, createElementVNode as o, createVNode as s, defineComponent as c, openBlock as l, unref as u, withCtx as d } from "vue";
|
|
6
6
|
import { UIText as f } from "@wisemen/vue-core-design-system";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { I as e, t } from "./api.util-
|
|
2
|
-
import {
|
|
1
|
+
import { I as e, t } from "./api.util-BCSgCfpS.js";
|
|
2
|
+
import { h as n, m as r, s as i } from "./documentTitle.composable-4ApFl9TZ.js";
|
|
3
3
|
import { r as a } from "./useCurrencyFormat.composable-MtZaqKnO.js";
|
|
4
4
|
import { n as o } from "./dist-YTXTCfo1.js";
|
|
5
5
|
import { useI18n as s } from "vue-i18n";
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
import { useRouter as e } from "vue-router";
|
|
2
|
+
import { useI18n as t } from "vue-i18n";
|
|
3
|
+
import { computed as n, createBlock as r, createCommentVNode as i, createElementBlock as a, createVNode as o, defineComponent as s, openBlock as c, renderSlot as l, unref as u } from "vue";
|
|
4
|
+
import { ApiErrorUtil as d } from "@wisemen/vue-core-api-utils";
|
|
5
|
+
import { UIEmptyState as f } from "@wisemen/vue-core-design-system";
|
|
6
|
+
//#endregion
|
|
7
|
+
//#region src/ui/data-provider/DataProviderErrorState.vue
|
|
8
|
+
var p = /* @__PURE__ */ s({
|
|
9
|
+
__name: "DataProviderErrorState",
|
|
10
|
+
props: { error: {} },
|
|
11
|
+
setup(i) {
|
|
12
|
+
let a = i, o = t(), s = e(), l = n(() => d.isExpectedApiError(a.error) ? a.error.errors[0] ?? null : null), p = n(() => l.value?.status === "404"), m = n(() => p.value ? o.t("wise_invoicing.common.not_found.title") : l.value?.status ?? o.t("wise_invoicing.common.error")), h = n(() => p.value ? o.t("wise_invoicing.common.not_found.description") : l.value === null ? d.isExpectedApiError(a.error) ? o.t("wise_invoicing.common.error") : a.error.message : l.value.detail);
|
|
13
|
+
function g() {
|
|
14
|
+
s.back();
|
|
15
|
+
}
|
|
16
|
+
function _() {
|
|
17
|
+
s.push({ name: "invoicing-invoice-overview" });
|
|
18
|
+
}
|
|
19
|
+
return (e, t) => (c(), r(u(f), {
|
|
20
|
+
description: h.value,
|
|
21
|
+
illustration: p.value ? "cloud-search" : null,
|
|
22
|
+
"primary-action": p.value ? {
|
|
23
|
+
label: u(o).t("wise_invoicing.common.not_found.invoice_overview"),
|
|
24
|
+
onClick: _,
|
|
25
|
+
type: "button"
|
|
26
|
+
} : null,
|
|
27
|
+
"secondary-action": p.value ? {
|
|
28
|
+
label: u(o).t("wise_invoicing.common.back"),
|
|
29
|
+
onClick: g,
|
|
30
|
+
type: "button"
|
|
31
|
+
} : null,
|
|
32
|
+
title: m.value
|
|
33
|
+
}, null, 8, [
|
|
34
|
+
"description",
|
|
35
|
+
"illustration",
|
|
36
|
+
"primary-action",
|
|
37
|
+
"secondary-action",
|
|
38
|
+
"title"
|
|
39
|
+
]));
|
|
40
|
+
}
|
|
41
|
+
}), m = {
|
|
42
|
+
key: 1,
|
|
43
|
+
class: "flex h-full items-center justify-center"
|
|
44
|
+
}, h = /* @__PURE__ */ s({
|
|
45
|
+
__name: "DataProvider",
|
|
46
|
+
props: { queries: {} },
|
|
47
|
+
setup(e) {
|
|
48
|
+
let t = e, r = n(() => {
|
|
49
|
+
for (let e in t.queries) if (t.queries[e].isLoading.value) return !0;
|
|
50
|
+
return !1;
|
|
51
|
+
}), s = n(() => {
|
|
52
|
+
for (let e in t.queries) {
|
|
53
|
+
let n = t.queries[e].result.value;
|
|
54
|
+
if (n != null && n.isErr()) return n.getError();
|
|
55
|
+
}
|
|
56
|
+
return null;
|
|
57
|
+
}), u = n(() => {
|
|
58
|
+
for (let e in t.queries) {
|
|
59
|
+
let n = t.queries[e].result.value;
|
|
60
|
+
if (n == null || n.isErr()) return !1;
|
|
61
|
+
}
|
|
62
|
+
return !0;
|
|
63
|
+
}), d = n(() => {
|
|
64
|
+
let e = {};
|
|
65
|
+
for (let n in t.queries) {
|
|
66
|
+
let r = n, i = t.queries[r].result.value;
|
|
67
|
+
i == null || !i.isOk() || (e[r] = i.getValue());
|
|
68
|
+
}
|
|
69
|
+
return e;
|
|
70
|
+
});
|
|
71
|
+
return (e, t) => r.value ? l(e.$slots, "loading", {}, void 0, void 0, 0) : s.value === null ? u.value ? l(e.$slots, "default", { data: d.value }, void 0, void 0, 2) : i("", !0) : (c(), a("div", m, [o(p, { error: s.value }, null, 8, ["error"])]));
|
|
72
|
+
}
|
|
73
|
+
});
|
|
74
|
+
//#endregion
|
|
75
|
+
export { h as t };
|
|
@@ -1,73 +1,73 @@
|
|
|
1
1
|
import { t as e } from "./rolldown-runtime-Dy4uBu1J.js";
|
|
2
|
-
import
|
|
3
|
-
import "./
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import { n as a } from "./reminderConfig.query-
|
|
7
|
-
import {
|
|
8
|
-
import { a as
|
|
9
|
-
import { n as
|
|
10
|
-
import { t as d } from "./DataProvider-
|
|
11
|
-
import { useViewModels as
|
|
12
|
-
import { RouterLink as
|
|
2
|
+
import "./api.util-BCSgCfpS.js";
|
|
3
|
+
import { b as t, t as n } from "./documentTitle.composable-4ApFl9TZ.js";
|
|
4
|
+
import { r } from "./useCurrencyFormat.composable-MtZaqKnO.js";
|
|
5
|
+
import { n as i } from "./invoicingConfig.composable-BYqn1I9n.js";
|
|
6
|
+
import { n as a } from "./reminderConfig.query-B9OQY7IT.js";
|
|
7
|
+
import { Q as o, R as ee, U as s, q as te, tt as c, x as l } from "./dist-D9lp7NDv.js";
|
|
8
|
+
import { a as u, i as ne, n as re, r as ie, t as ae } from "./DunningCaseSendDialog-C47X_JjC.js";
|
|
9
|
+
import { n as oe } from "./dist-YTXTCfo1.js";
|
|
10
|
+
import { t as d } from "./DataProvider-Dj34ljUX.js";
|
|
11
|
+
import { useViewModels as se } from "@wisemen/vue-core-actions";
|
|
12
|
+
import { RouterLink as ce, useRouter as le } from "vue-router";
|
|
13
13
|
import { useI18n as f } from "vue-i18n";
|
|
14
|
-
import { Fragment as p, computed as m, createBlock as h, createCommentVNode as g, createElementBlock as _, createElementVNode as v, createTextVNode as y, createVNode as b, defineComponent as x, normalizeClass as S, normalizeStyle as
|
|
14
|
+
import { Fragment as p, computed as m, createBlock as h, createCommentVNode as g, createElementBlock as _, createElementVNode as v, createTextVNode as y, createVNode as b, defineComponent as x, normalizeClass as S, normalizeStyle as ue, openBlock as C, ref as w, renderList as T, toDisplayString as E, unref as D, withCtx as O } from "vue";
|
|
15
15
|
import { Temporal as k } from "temporal-polyfill";
|
|
16
|
-
import { UIBadge as A, UIButton as
|
|
16
|
+
import { UIBadge as A, UIButton as de, UIDashboardPage as fe, UIDashboardPageContent as pe, UIDashboardPageLoadingState as j, UITabs as me, UITabsItem as M, UITabsList as he, UITooltip as ge, UITooltipContent as _e, useOverlay as ve } from "@wisemen/vue-core-design-system";
|
|
17
17
|
//#region src/modules/dunning-case/use-cases/detail/views/DunningCaseDetailView.vue?vue&type=script&setup=true&lang.ts
|
|
18
|
-
var
|
|
18
|
+
var ye = { class: "flex flex-col gap-4xl" }, be = { class: "flex flex-col gap-lg lg:flex-row lg:items-start lg:justify-between" }, xe = { class: "flex flex-wrap items-center gap-sm" }, Se = { class: "text-lg font-semibold text-primary" }, Ce = { key: 1 }, we = { class: "inline-flex items-center gap-xs rounded-sm border border-secondary px-sm py-px text-xs text-primary" }, Te = {
|
|
19
19
|
key: 0,
|
|
20
20
|
class: "mt-xs text-xs text-secondary"
|
|
21
|
-
},
|
|
21
|
+
}, Ee = { class: "mt-xxs text-xs text-secondary" }, De = { class: "grid grid-cols-1 gap-3xl md:grid-cols-2 xl:grid-cols-[minmax(20rem,1.45fr)_minmax(10rem,0.7fr)_repeat(2,minmax(8rem,0.8fr))]" }, Oe = { class: "min-w-0 xl:col-start-1 xl:row-start-1 2xl:col-start-1 2xl:row-start-1" }, ke = { class: "text-xs font-medium text-secondary" }, Ae = { class: "mt-xs font-mono text-4xl font-semibold text-primary tabular-nums xl:text-5xl" }, je = { class: "mt-xs text-xs text-secondary" }, Me = {
|
|
22
22
|
key: 0,
|
|
23
23
|
class: "mt-xxs text-xs text-secondary"
|
|
24
|
-
},
|
|
24
|
+
}, Ne = { class: "mt-xl flex h-(--spacing-md) overflow-hidden rounded-full bg-tertiary" }, Pe = { class: "flex flex-col justify-end gap-md xl:col-start-2 xl:row-start-1 xl:pb-xs" }, Fe = ["aria-label"], Ie = { class: "flex min-w-0 items-center gap-sm" }, Le = { class: "truncate text-xs text-secondary" }, Re = { class: "shrink-0 font-mono text-xs font-medium text-primary" }, ze = { class: "flex min-w-0 items-center gap-md xl:col-start-3 xl:row-start-1" }, Be = { class: "flex size-(--spacing-5xl) shrink-0 items-center justify-center rounded-full bg-brand-100" }, Ve = { class: "min-w-0" }, He = { class: "text-xs text-secondary" }, Ue = { class: "mt-xs font-mono text-xl font-semibold whitespace-nowrap text-primary xl:text-2xl" }, We = { class: "flex min-w-0 items-center gap-md xl:col-start-4 xl:row-start-1" }, Ge = { class: "flex size-(--spacing-5xl) shrink-0 items-center justify-center rounded-full bg-brand-100" }, Ke = { class: "text-xs text-secondary" }, qe = { class: "mt-xs font-mono text-2xl font-semibold text-primary" }, Je = {
|
|
25
25
|
key: 0,
|
|
26
26
|
class: "mt-xs text-xs text-secondary"
|
|
27
|
-
},
|
|
27
|
+
}, Ye = { class: "grid gap-3xl xl:grid-cols-[minmax(0,2fr)_25.5rem]" }, Xe = { class: "min-w-0" }, Ze = { class: "overflow-hidden rounded-md border border-secondary bg-primary shadow-sm" }, Qe = { class: "border-b border-secondary px-xl pt-lg" }, $e = { class: "overflow-x-auto" }, et = {
|
|
28
28
|
key: 0,
|
|
29
29
|
class: "w-full min-w-200 table-fixed border-collapse text-left"
|
|
30
|
-
},
|
|
30
|
+
}, tt = { class: "border-b border-secondary bg-secondary" }, nt = { class: "w-[20%] px-xl py-md text-xs font-medium text-secondary" }, rt = { class: "w-[26%] px-xl py-md text-xs font-medium text-secondary" }, it = { class: "w-[14%] px-xl py-md text-xs font-medium text-secondary" }, at = { class: "w-[20%] px-xl py-md text-xs font-medium text-secondary" }, ot = { class: "w-[20%] px-xl py-md text-right text-xs font-medium text-secondary" }, st = { class: "flex items-start gap-md" }, ct = [
|
|
31
31
|
"aria-expanded",
|
|
32
32
|
"aria-label",
|
|
33
33
|
"onClick"
|
|
34
|
-
],
|
|
34
|
+
], lt = {
|
|
35
35
|
key: 1,
|
|
36
36
|
class: "size-(--spacing-xl) shrink-0"
|
|
37
|
-
},
|
|
37
|
+
}, N = { class: "min-w-0" }, ut = {
|
|
38
38
|
key: 0,
|
|
39
39
|
class: "mt-xxs truncate text-xs text-secondary"
|
|
40
|
-
},
|
|
40
|
+
}, dt = { class: "px-xl py-md font-mono text-xs" }, ft = { class: "px-xl py-md" }, pt = {
|
|
41
41
|
key: 1,
|
|
42
42
|
class: "flex items-center gap-xs text-xs text-primary"
|
|
43
|
-
},
|
|
43
|
+
}, mt = { class: "px-xl py-md" }, ht = { class: "flex flex-col items-start gap-xs" }, gt = {
|
|
44
44
|
key: 0,
|
|
45
45
|
class: "text-xs text-secondary"
|
|
46
|
-
},
|
|
46
|
+
}, _t = { class: "px-xl py-md text-right font-mono text-xs text-secondary tabular-nums" }, vt = { class: "font-medium" }, yt = {
|
|
47
47
|
key: 0,
|
|
48
48
|
class: "mt-xxs text-tertiary"
|
|
49
|
-
},
|
|
49
|
+
}, bt = ["aria-hidden"], xt = {
|
|
50
50
|
class: "p-none",
|
|
51
51
|
colspan: "5"
|
|
52
|
-
},
|
|
52
|
+
}, St = { class: "overflow-hidden" }, Ct = { class: "relative flex flex-col items-start gap-xs px-5xl py-md text-xs before:absolute before:inset-y-0 before:left-0 before:w-(--spacing-xxs) before:bg-brand-500" }, wt = {
|
|
53
53
|
key: 1,
|
|
54
54
|
class: "flex flex-col items-center justify-center gap-md px-xl py-2xl"
|
|
55
|
-
},
|
|
55
|
+
}, Tt = { class: "flex size-(--spacing-3xl) items-center justify-center rounded-md border border-secondary" }, Et = { class: "text-sm font-semibold text-secondary" }, Dt = {
|
|
56
56
|
key: 0,
|
|
57
57
|
class: "ml-auto flex w-full max-w-140 flex-col px-xl"
|
|
58
|
-
},
|
|
58
|
+
}, Ot = { class: "flex items-center justify-between gap-3xl border-b border-secondary py-lg text-sm text-primary" }, kt = { class: "shrink-0 font-mono text-2xl font-semibold tabular-nums" }, At = { class: "flex items-center justify-between gap-3xl py-lg text-sm text-primary" }, jt = { class: "shrink-0 font-mono text-sm font-medium tabular-nums" }, Mt = { class: "h-full rounded-md border border-secondary bg-primary p-xl shadow-sm" }, Nt = { class: "text-xl font-semibold text-primary" }, Pt = { class: "mt-2xl flex flex-col" }, Ft = { class: "flex w-(--spacing-3xl) shrink-0 flex-col items-center" }, It = {
|
|
59
59
|
key: 0,
|
|
60
60
|
class: "min-h-(--spacing-xl) w-px flex-1 bg-tertiary"
|
|
61
|
-
},
|
|
61
|
+
}, Lt = { class: "text-sm font-semibold text-primary" }, Rt = { class: "mt-xxs text-sm text-secondary" }, P = /* @__PURE__ */ x({
|
|
62
62
|
__name: "DunningCaseDetailView",
|
|
63
63
|
props: { dunningCase: {} },
|
|
64
64
|
setup(e) {
|
|
65
|
-
let u = e, d = f(), x =
|
|
65
|
+
let u = e, d = f(), x = ve(), j = r(), P = oe(), F = n(), I = i(), L = le(), R = w("overdue");
|
|
66
66
|
function z(e) {
|
|
67
67
|
return e.payments.length > 0 || e.creditNotes.length > 0;
|
|
68
68
|
}
|
|
69
69
|
let B = w(u.dunningCase.invoices.find(z)?.uuid ?? null);
|
|
70
|
-
F.set(() => u.dunningCase.customer.name),
|
|
70
|
+
F.set(() => u.dunningCase.customer.name), se(m(() => [{
|
|
71
71
|
key: u.dunningCase.uuid,
|
|
72
72
|
modelName: "DunningCase",
|
|
73
73
|
...u.dunningCase
|
|
@@ -105,21 +105,24 @@ var xe = { class: "flex flex-col gap-4xl" }, Se = { class: "flex flex-col gap-lg
|
|
|
105
105
|
key: `closed-${u.dunningCase.closedAt.toString()}`,
|
|
106
106
|
type: "case-closed"
|
|
107
107
|
}), e.toSorted((e, t) => t.sortDate.localeCompare(e.sortDate));
|
|
108
|
-
}), H = m(() => u.dunningCase.invoices.filter((e) => k.PlainDate.compare(e.dueOn, k.Now.plainDateISO()) < 0).toSorted((e, t) => k.PlainDate.compare(e.dueOn, t.dueOn))),
|
|
108
|
+
}), H = m(() => u.dunningCase.invoices.filter((e) => k.PlainDate.compare(e.dueOn, k.Now.plainDateISO()) < 0).toSorted((e, t) => k.PlainDate.compare(e.dueOn, t.dueOn))), zt = m(() => u.dunningCase.invoices.filter((e) => k.PlainDate.compare(e.dueOn, k.Now.plainDateISO()) >= 0).toSorted((e, t) => k.PlainDate.compare(e.dueOn, t.dueOn))), U = m(() => R.value === "overdue" ? H.value : zt.value), W = m(() => u.dunningCase.invoices.filter((e) => e.isDisputed).length), G = m(() => ie(u.dunningCase.latestCreatedReminder)), K = m(() => H.value.filter((e) => !e.isDisputed)), q = m(() => K.value.reduce((e, t) => ({
|
|
109
109
|
...e,
|
|
110
110
|
amount: e.amount + t.balanceDueAmount.amount
|
|
111
111
|
}), {
|
|
112
112
|
...u.dunningCase.outstandingBalance,
|
|
113
113
|
amount: 0
|
|
114
|
-
})), J = m(() =>
|
|
115
|
-
|
|
114
|
+
})), J = m(() => re(K.value, u.dunningCase.outstandingBalance)), Bt = m(() => J.value.map((e, t) => ({
|
|
115
|
+
amount: e,
|
|
116
|
+
level: t
|
|
117
|
+
})).toReversed());
|
|
118
|
+
function Vt(e) {
|
|
116
119
|
return q.value.amount === 0 ? 0 : e / q.value.amount * 100;
|
|
117
120
|
}
|
|
118
|
-
let Y = m(() => I.getCustomerDetailRoute(u.dunningCase.customer.uuid)),
|
|
121
|
+
let Y = m(() => I.getCustomerDetailRoute(u.dunningCase.customer.uuid)), Ht = m(() => [{
|
|
119
122
|
label: d.t("module.dunning_case.title"),
|
|
120
123
|
to: { name: "dunning-case-overview" }
|
|
121
124
|
}, { label: u.dunningCase.customer.name }]);
|
|
122
|
-
function
|
|
125
|
+
function Ut() {
|
|
123
126
|
Y.value !== null && L.push(Y.value);
|
|
124
127
|
}
|
|
125
128
|
function X(e) {
|
|
@@ -131,10 +134,10 @@ var xe = { class: "flex flex-col gap-4xl" }, Se = { class: "flex flex-col gap-lg
|
|
|
131
134
|
label: X(e)
|
|
132
135
|
});
|
|
133
136
|
}
|
|
134
|
-
function
|
|
137
|
+
function Wt(e) {
|
|
135
138
|
return e.type === "credit-note" || e.type === "payment" || e.type === "reminder-due" ? P.formatPlainDate(e.date) : P.toDateTime(e.date);
|
|
136
139
|
}
|
|
137
|
-
function
|
|
140
|
+
function Gt(e) {
|
|
138
141
|
switch (e.type) {
|
|
139
142
|
case "case-closed": return d.t("module.dunning_case.detail.case_closed");
|
|
140
143
|
case "credit-note": return d.t("module.dunning_case.detail.credit_note_activity", {
|
|
@@ -149,85 +152,82 @@ var xe = { class: "flex flex-col gap-4xl" }, Se = { class: "flex flex-col gap-lg
|
|
|
149
152
|
case "reminder-sent": return d.t("module.dunning_case.detail.reminder_sent");
|
|
150
153
|
}
|
|
151
154
|
}
|
|
152
|
-
function
|
|
155
|
+
function Kt(e) {
|
|
153
156
|
if (e.type === "reminder-due") return d.t("module.dunning_case.detail.today");
|
|
154
|
-
let
|
|
155
|
-
return e.type === "payment" && e.settlementStatus ===
|
|
157
|
+
let n = Wt(e);
|
|
158
|
+
return e.type === "payment" && e.settlementStatus === t.PARTIALLY_PAID ? d.t("module.dunning_case.detail.payment_partially_paid", { date: n }) : n;
|
|
156
159
|
}
|
|
157
160
|
function Q(e) {
|
|
158
161
|
return e.dueOn.until(k.Now.plainDateISO(), { largestUnit: "days" }).days;
|
|
159
162
|
}
|
|
160
|
-
function
|
|
163
|
+
function qt(e) {
|
|
161
164
|
let t = Q(e);
|
|
162
165
|
return t > 0 ? d.t("module.dunning_case.detail.days_ago", { count: t }) : t === 0 ? d.t("module.dunning_case.overview.due_today") : d.t("module.dunning_case.overview.due_in_days", { count: Math.abs(t) });
|
|
163
166
|
}
|
|
164
167
|
function $(e) {
|
|
165
168
|
return e === 0 ? d.t("module.dunning_case.level.none") : d.t("module.dunning_case.level.reminder", { level: e });
|
|
166
169
|
}
|
|
167
|
-
function
|
|
170
|
+
function Jt(e) {
|
|
168
171
|
switch (e) {
|
|
169
|
-
case
|
|
170
|
-
case
|
|
171
|
-
case
|
|
172
|
-
case
|
|
173
|
-
case
|
|
174
|
-
case
|
|
172
|
+
case t.PARTIALLY_PAID: return "warning";
|
|
173
|
+
case t.CREDITED:
|
|
174
|
+
case t.OVERPAID:
|
|
175
|
+
case t.PAID:
|
|
176
|
+
case t.SETTLED: return "success";
|
|
177
|
+
case t.UNPAID: return "error";
|
|
175
178
|
}
|
|
176
179
|
}
|
|
177
|
-
function
|
|
180
|
+
function Yt() {
|
|
178
181
|
x.create(ae, { props: { dunningCaseUuid: u.dunningCase.uuid } }).open();
|
|
179
182
|
}
|
|
180
|
-
function
|
|
183
|
+
function Xt(e) {
|
|
181
184
|
B.value = B.value === e ? null : e;
|
|
182
185
|
}
|
|
183
|
-
return (e, t) => (C(), h(D(
|
|
184
|
-
breadcrumbs:
|
|
186
|
+
return (e, t) => (C(), h(D(fe), {
|
|
187
|
+
breadcrumbs: Ht.value,
|
|
185
188
|
title: u.dunningCase.customer.name
|
|
186
189
|
}, {
|
|
187
|
-
default: O(() => [b(D(
|
|
188
|
-
default: O(() => [v("div",
|
|
189
|
-
v("div",
|
|
190
|
-
v("div",
|
|
191
|
-
v("h2",
|
|
190
|
+
default: O(() => [b(D(pe), null, {
|
|
191
|
+
default: O(() => [v("div", ye, [
|
|
192
|
+
v("div", be, [v("div", null, [
|
|
193
|
+
v("div", xe, [
|
|
194
|
+
v("h2", Se, [Y.value === null ? (C(), _("span", Ce, E(u.dunningCase.customer.name), 1)) : (C(), _("button", {
|
|
192
195
|
key: 0,
|
|
193
196
|
class: "hover:underline",
|
|
194
197
|
type: "button",
|
|
195
|
-
onClick:
|
|
198
|
+
onClick: Ut
|
|
196
199
|
}, E(u.dunningCase.customer.name), 1))]),
|
|
197
|
-
v("span",
|
|
198
|
-
b(
|
|
200
|
+
v("span", we, [b(a, { level: u.dunningCase.level }, null, 8, ["level"]), y(" " + E(u.dunningCase.isClosed ? D(d).t("module.dunning_case.detail.closed") : $(u.dunningCase.level)), 1)]),
|
|
201
|
+
b(ne, {
|
|
199
202
|
"blocked-reason": null,
|
|
200
203
|
status: G.value
|
|
201
204
|
}, null, 8, ["status"])
|
|
202
205
|
]),
|
|
203
|
-
u.dunningCase.customer.vatNumber || u.dunningCase.customer.email ? (C(), _("p",
|
|
204
|
-
v("p",
|
|
205
|
-
]),
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
v("p", je, E(D(d).t("module.dunning_case.detail.outstanding")), 1),
|
|
224
|
-
v("p", Me, E(D(j).formatMonetary(u.dunningCase.outstandingBalance)), 1),
|
|
225
|
-
v("p", Ne, E(D(d).t("module.dunning_case.detail.collected_summary", {
|
|
206
|
+
u.dunningCase.customer.vatNumber || u.dunningCase.customer.email ? (C(), _("p", Te, E([u.dunningCase.customer.vatNumber, u.dunningCase.customer.email].filter(Boolean).join(" · ")), 1)) : g("", !0),
|
|
207
|
+
v("p", Ee, E(D(d).t("module.dunning_case.detail.last_synced", { date: D(P).toDateTime(u.dunningCase.updatedAt) })), 1)
|
|
208
|
+
]), !u.dunningCase.isClosed && u.dunningCase.canSendReminder ? (C(), h(D(de), {
|
|
209
|
+
key: 0,
|
|
210
|
+
"icon-right": D(c),
|
|
211
|
+
"is-loading": G.value === "sending",
|
|
212
|
+
label: D(d).t("module.dunning_case.detail.send"),
|
|
213
|
+
class: "w-fit self-start lg:ml-auto",
|
|
214
|
+
size: "sm",
|
|
215
|
+
onClick: Yt
|
|
216
|
+
}, null, 8, [
|
|
217
|
+
"icon-right",
|
|
218
|
+
"is-loading",
|
|
219
|
+
"label"
|
|
220
|
+
])) : g("", !0)]),
|
|
221
|
+
v("div", De, [
|
|
222
|
+
v("div", Oe, [
|
|
223
|
+
v("p", ke, E(D(d).t("module.dunning_case.detail.outstanding")), 1),
|
|
224
|
+
v("p", Ae, E(D(j).formatMonetary(u.dunningCase.outstandingBalance)), 1),
|
|
225
|
+
v("p", je, E(D(d).t("module.dunning_case.detail.collected_summary", {
|
|
226
226
|
billed: D(j).formatMonetary(u.dunningCase.totalInvoiced),
|
|
227
227
|
collected: D(j).formatMonetary(u.dunningCase.totalPaid)
|
|
228
228
|
})), 1),
|
|
229
|
-
u.dunningCase.totalCredited.amount > 0 ? (C(), _("p",
|
|
230
|
-
v("div",
|
|
229
|
+
u.dunningCase.totalCredited.amount > 0 ? (C(), _("p", Me, E(D(d).t("module.dunning_case.detail.credited_summary", { credited: D(j).formatMonetary(u.dunningCase.totalCredited) })), 1)) : g("", !0),
|
|
230
|
+
v("div", Ne, [(C(!0), _(p, null, T(J.value, (e, t) => (C(), _("span", {
|
|
231
231
|
key: t,
|
|
232
232
|
class: S([{
|
|
233
233
|
"bg-quaternary": t === 0,
|
|
@@ -235,46 +235,46 @@ var xe = { class: "flex flex-col gap-4xl" }, Se = { class: "flex flex-col gap-lg
|
|
|
235
235
|
"bg-error-solid": t === 3,
|
|
236
236
|
"bg-warning-solid": t === 2
|
|
237
237
|
}, "h-full"]),
|
|
238
|
-
style:
|
|
238
|
+
style: ue({ width: `${Vt(e.amount)}%` })
|
|
239
239
|
}, null, 6))), 128))])
|
|
240
240
|
]),
|
|
241
|
-
v("div",
|
|
242
|
-
key:
|
|
241
|
+
v("div", Pe, [(C(!0), _(p, null, T(Bt.value, (e) => (C(), h(D(ge), {
|
|
242
|
+
key: e.level,
|
|
243
243
|
"popover-side-offset": 8,
|
|
244
244
|
"popover-align": "start",
|
|
245
245
|
"popover-side": "top"
|
|
246
246
|
}, {
|
|
247
247
|
trigger: O(() => [v("button", {
|
|
248
|
-
"aria-label": Z(
|
|
248
|
+
"aria-label": Z(e.level, e.amount),
|
|
249
249
|
class: "flex min-w-0 items-center justify-between gap-lg rounded-sm border-none bg-transparent p-none text-left hover:bg-secondary focus-visible:outline-2 focus-visible:outline-brand-500 xl:flex-row xl:items-center xl:gap-lg",
|
|
250
250
|
type: "button"
|
|
251
|
-
}, [v("span",
|
|
252
|
-
"bg-quaternary":
|
|
253
|
-
"bg-brand-500":
|
|
254
|
-
"bg-error-solid":
|
|
255
|
-
"bg-warning-solid":
|
|
256
|
-
}, "size-(--spacing-sm) shrink-0 rounded-full"]) }, null, 2), v("span",
|
|
257
|
-
content: O(() => [b(D(
|
|
258
|
-
default: O(() => [y(E(Z(
|
|
251
|
+
}, [v("span", Ie, [v("span", { class: S([{
|
|
252
|
+
"bg-quaternary": e.level === 0,
|
|
253
|
+
"bg-brand-500": e.level === 1,
|
|
254
|
+
"bg-error-solid": e.level === 3,
|
|
255
|
+
"bg-warning-solid": e.level === 2
|
|
256
|
+
}, "size-(--spacing-sm) shrink-0 rounded-full"]) }, null, 2), v("span", Le, E(X(e.level)), 1)]), v("span", Re, E(D(j).formatMonetary(e.amount)), 1)], 8, Fe)]),
|
|
257
|
+
content: O(() => [b(D(_e), { class: "max-w-80! text-sm!" }, {
|
|
258
|
+
default: O(() => [y(E(Z(e.level, e.amount)), 1)]),
|
|
259
259
|
_: 2
|
|
260
260
|
}, 1024)]),
|
|
261
261
|
_: 2
|
|
262
262
|
}, 1024))), 128))]),
|
|
263
|
-
v("div",
|
|
264
|
-
v("div",
|
|
265
|
-
v("p",
|
|
266
|
-
v("p",
|
|
267
|
-
W.value > 0 ? (C(), _("p",
|
|
263
|
+
v("div", ze, [v("span", Be, [b(D(l), { class: "size-(--spacing-xl) text-brand-700" })]), v("div", Ve, [v("p", He, E(D(d).t("module.dunning_case.detail.next_reminder")), 1), v("p", Ue, E(u.dunningCase.nextReminderOn === null ? D(d).t("module.dunning_case.overview.not_scheduled") : D(P).formatPlainDate(u.dunningCase.nextReminderOn)), 1)])]),
|
|
264
|
+
v("div", We, [v("span", Ge, [b(D(s), { class: "size-(--spacing-xl) text-brand-700" })]), v("div", null, [
|
|
265
|
+
v("p", Ke, E(D(d).t("module.dunning_case.detail.invoices")), 1),
|
|
266
|
+
v("p", qe, E(u.dunningCase.invoices.length), 1),
|
|
267
|
+
W.value > 0 ? (C(), _("p", Je, E(D(d).t("module.dunning_case.detail.protested_count", { count: W.value })), 1)) : g("", !0)
|
|
268
268
|
])])
|
|
269
269
|
]),
|
|
270
|
-
v("div",
|
|
271
|
-
v("div",
|
|
270
|
+
v("div", Ye, [v("main", Xe, [v("div", Ze, [
|
|
271
|
+
v("div", Qe, [b(D(me), {
|
|
272
272
|
modelValue: R.value,
|
|
273
273
|
"onUpdate:modelValue": t[0] ||= (e) => R.value = e,
|
|
274
274
|
"aria-label": D(d).t("module.dunning_case.detail.invoice_tabs"),
|
|
275
275
|
variant: "underline"
|
|
276
276
|
}, {
|
|
277
|
-
default: O(() => [b(D(
|
|
277
|
+
default: O(() => [b(D(he), null, {
|
|
278
278
|
default: O(() => [b(D(M), {
|
|
279
279
|
label: D(d).t("module.dunning_case.detail.overdue_invoices"),
|
|
280
280
|
value: "overdue"
|
|
@@ -286,24 +286,24 @@ var xe = { class: "flex flex-col gap-4xl" }, Se = { class: "flex flex-col gap-lg
|
|
|
286
286
|
})]),
|
|
287
287
|
_: 1
|
|
288
288
|
}, 8, ["modelValue", "aria-label"])]),
|
|
289
|
-
v("div",
|
|
290
|
-
v("th",
|
|
291
|
-
v("th",
|
|
292
|
-
v("th",
|
|
293
|
-
v("th",
|
|
294
|
-
v("th",
|
|
295
|
-
])]), v("tbody", null, [(C(!0), _(p, null, T(U.value, (e) => (C(), _(p, { key: e.uuid }, [v("tr",
|
|
289
|
+
v("div", $e, [U.value.length > 0 ? (C(), _("table", et, [v("thead", null, [v("tr", tt, [
|
|
290
|
+
v("th", nt, E(D(d).t("module.dunning_case.detail.table.invoice")), 1),
|
|
291
|
+
v("th", rt, E(D(d).t("module.dunning_case.detail.table.due_date")), 1),
|
|
292
|
+
v("th", it, E(D(d).t("module.dunning_case.detail.table.level")), 1),
|
|
293
|
+
v("th", at, E(D(d).t("module.dunning_case.detail.table.status")), 1),
|
|
294
|
+
v("th", ot, E(D(d).t("module.dunning_case.detail.table.remaining")), 1)
|
|
295
|
+
])]), v("tbody", null, [(C(!0), _(p, null, T(U.value, (e) => (C(), _(p, { key: e.uuid }, [v("tr", { class: S([{ "opacity-60": e.isDisputed }, "border-b border-secondary"]) }, [
|
|
296
296
|
v("td", { class: S([{
|
|
297
297
|
"before:opacity-0": B.value !== e.uuid,
|
|
298
298
|
"before:opacity-100": B.value === e.uuid
|
|
299
|
-
}, "relative px-xl py-md before:absolute before:inset-y-0 before:left-0 before:w-(--spacing-xxs) before:bg-brand-500"]) }, [v("div",
|
|
299
|
+
}, "relative px-xl py-md before:absolute before:inset-y-0 before:left-0 before:w-(--spacing-xxs) before:bg-brand-500"]) }, [v("div", st, [z(e) ? (C(), _("button", {
|
|
300
300
|
key: 0,
|
|
301
301
|
"aria-expanded": B.value === e.uuid,
|
|
302
302
|
"aria-label": D(d).t(B.value === e.uuid ? "module.dunning_case.detail.collapse_updates" : "module.dunning_case.detail.expand_updates", { invoice: e.sequence }),
|
|
303
303
|
class: "mt-xxs flex size-(--spacing-xl) shrink-0 items-center justify-center text-secondary hover:text-primary",
|
|
304
304
|
type: "button",
|
|
305
|
-
onClick: (t) =>
|
|
306
|
-
}, [b(D(
|
|
305
|
+
onClick: (t) => Xt(e.uuid)
|
|
306
|
+
}, [b(D(ee), { class: S([{ "rotate-180": B.value === e.uuid }, "size-(--spacing-xl) transition-transform duration-200 ease-out motion-reduce:transition-none"]) }, null, 8, ["class"])], 8, ct)) : (C(), _("span", lt)), v("div", N, [b(D(ce), {
|
|
307
307
|
to: {
|
|
308
308
|
name: "invoicing-invoice-detail",
|
|
309
309
|
params: { invoiceUuid: e.uuid }
|
|
@@ -312,31 +312,37 @@ var xe = { class: "flex flex-col gap-4xl" }, Se = { class: "flex flex-col gap-lg
|
|
|
312
312
|
}, {
|
|
313
313
|
default: O(() => [y(E(e.sequence), 1)]),
|
|
314
314
|
_: 2
|
|
315
|
-
}, 1032, ["to"]), e.subject === null ? g("", !0) : (C(), _("p",
|
|
316
|
-
v("td",
|
|
317
|
-
v("td",
|
|
315
|
+
}, 1032, ["to"]), e.subject === null ? g("", !0) : (C(), _("p", ut, E(e.subject), 1))])])], 2),
|
|
316
|
+
v("td", dt, [v("span", { class: S([e.isDisputed ? "text-secondary" : Q(e) > 0 ? "text-error-primary" : "text-primary", "inline-flex items-center gap-xs whitespace-nowrap"]) }, [y(E(D(P).formatPlainDate(e.dueOn)) + " ", 1), v("span", { class: S([!e.isDisputed && Q(e) > 0 ? "\n border-error bg-error-primary\n text-error-primary\n " : "border-secondary bg-secondary text-secondary", "rounded-sm border px-sm py-px font-sans text-xs"]) }, E(qt(e)), 3)], 2)]),
|
|
317
|
+
v("td", ft, [e.isDisputed ? (C(), h(D(A), {
|
|
318
318
|
key: 0,
|
|
319
319
|
label: D(d).t("module.dunning_case.detail.protested"),
|
|
320
320
|
color: "error",
|
|
321
321
|
size: "sm",
|
|
322
322
|
variant: "translucent"
|
|
323
|
-
}, null, 8, ["label"])) : R.value === "overdue" ? (C(), _("span",
|
|
323
|
+
}, null, 8, ["label"])) : R.value === "overdue" ? (C(), _("span", pt, [b(a, {
|
|
324
324
|
level: e.level,
|
|
325
325
|
size: "sm"
|
|
326
|
-
}, null, 8, ["level"]), y(" " + E(e.level), 1)])) : g("", !0)]),
|
|
327
|
-
v("td",
|
|
326
|
+
}, null, 8, ["level"]), y(" " + E(e.level === 0 ? "–" : e.level), 1)])) : g("", !0)]),
|
|
327
|
+
v("td", mt, [v("div", ht, [e.isDisputed ? (C(), _("p", gt, E(D(d).t("module.dunning_case.detail.excluded")), 1)) : R.value === "outstanding" ? (C(), h(D(A), {
|
|
328
328
|
key: 1,
|
|
329
|
+
label: D(d).t("module.dunning_case.detail.not_yet_due"),
|
|
330
|
+
color: "gray",
|
|
331
|
+
size: "sm",
|
|
332
|
+
variant: "translucent"
|
|
333
|
+
}, null, 8, ["label"])) : (C(), h(D(A), {
|
|
334
|
+
key: 2,
|
|
329
335
|
label: D(d).t(`module.dunning_case.settlement_status.${e.settlementStatus}`),
|
|
330
|
-
color:
|
|
336
|
+
color: Jt(e.settlementStatus),
|
|
331
337
|
size: "sm",
|
|
332
338
|
variant: "translucent"
|
|
333
339
|
}, null, 8, ["label", "color"]))])]),
|
|
334
|
-
v("td",
|
|
335
|
-
]), z(e) ? (C(), _("tr", {
|
|
340
|
+
v("td", _t, [v("p", vt, E(D(j).formatMonetary(e.balanceDueAmount)), 1), e.balanceDueAmount.amount === e.grossAmount.amount ? g("", !0) : (C(), _("p", yt, " /" + E(D(j).formatMonetary(e.grossAmount)), 1))])
|
|
341
|
+
], 2), z(e) ? (C(), _("tr", {
|
|
336
342
|
key: `${e.uuid}-updates`,
|
|
337
343
|
class: S({ "border-b border-secondary": B.value === e.uuid }),
|
|
338
344
|
"aria-hidden": B.value !== e.uuid
|
|
339
|
-
}, [v("td",
|
|
345
|
+
}, [v("td", xt, [v("div", { class: S([B.value === e.uuid ? "grid-rows-[1fr] opacity-100" : "grid-rows-[0fr] opacity-0", "grid transition-[grid-template-rows,opacity] duration-200 ease-out motion-reduce:transition-none"]) }, [v("div", St, [v("div", Ct, [(C(!0), _(p, null, T(e.payments, (e) => (C(), _("span", {
|
|
340
346
|
key: e.uuid,
|
|
341
347
|
class: "inline-flex items-center gap-sm rounded-sm bg-success-primary px-md py-sm text-success-primary"
|
|
342
348
|
}, [t[1] ||= v("span", { class: "size-(--spacing-sm) shrink-0 rounded-full bg-success-solid" }, null, -1), y(" " + E(D(d).t("module.dunning_case.detail.payment_line", {
|
|
@@ -349,12 +355,12 @@ var xe = { class: "flex flex-col gap-4xl" }, Se = { class: "flex flex-col gap-lg
|
|
|
349
355
|
amount: D(j).formatMonetary(e.grossAmount),
|
|
350
356
|
date: D(P).formatPlainDate(e.finalizedOn),
|
|
351
357
|
sequence: e.sequence
|
|
352
|
-
})), 1)]))), 128))])])], 2)])], 10,
|
|
353
|
-
R.value === "overdue" ? (C(), _("div",
|
|
354
|
-
])]), v("aside",
|
|
358
|
+
})), 1)]))), 128))])])], 2)])], 10, bt)) : g("", !0)], 64))), 128))])])) : (C(), _("div", wt, [v("span", Tt, [b(D(o), { class: "size-(--spacing-xl) text-primary" })]), v("p", Et, E(D(d).t(R.value === "overdue" ? "module.dunning_case.detail.empty_overdue" : "module.dunning_case.detail.empty_outstanding")), 1)]))]),
|
|
359
|
+
R.value === "overdue" ? (C(), _("div", Dt, [v("div", Ot, [v("span", null, E(D(d).t("module.dunning_case.detail.total_outstanding")), 1), v("span", kt, E(D(j).formatMonetary(q.value)), 1)]), v("div", At, [v("span", null, E(u.dunningCase.level === 0 ? D(d).t("module.dunning_case.detail.reminder_fee") : D(d).t("module.dunning_case.detail.fee", { level: u.dunningCase.level })), 1), v("span", jt, E(D(j).formatMonetary(u.dunningCase.totalFee)), 1)])])) : g("", !0)
|
|
360
|
+
])]), v("aside", Mt, [v("h2", Nt, E(D(d).t("module.dunning_case.detail.activity")), 1), v("ol", Pt, [(C(!0), _(p, null, T(V.value, (e, t) => (C(), _("li", {
|
|
355
361
|
key: e.key,
|
|
356
362
|
class: "flex gap-md"
|
|
357
|
-
}, [v("div",
|
|
363
|
+
}, [v("div", Ft, [v("span", { class: S([{
|
|
358
364
|
"bg-brand-100": e.type === "reminder-sent",
|
|
359
365
|
"bg-error-secondary": e.type === "reminder-due",
|
|
360
366
|
"bg-success-secondary": e.type === "payment" || e.type === "case-closed",
|
|
@@ -374,7 +380,7 @@ var xe = { class: "flex flex-col gap-4xl" }, Se = { class: "flex flex-col gap-lg
|
|
|
374
380
|
})) : e.type === "case-closed" ? (C(), h(D(o), {
|
|
375
381
|
key: 4,
|
|
376
382
|
class: "size-(--spacing-lg) text-success-primary"
|
|
377
|
-
})) : g("", !0)], 2), t < V.value.length - 1 ? (C(), _("span",
|
|
383
|
+
})) : g("", !0)], 2), t < V.value.length - 1 ? (C(), _("span", It)) : g("", !0)]), v("div", { class: S([{ "pb-xl": t < V.value.length - 1 }, "pt-xs"]) }, [v("p", Lt, E(Gt(e)), 1), v("p", Rt, E(Kt(e)), 1)], 2)]))), 128))])])])
|
|
378
384
|
])]),
|
|
379
385
|
_: 1
|
|
380
386
|
})]),
|