@feedmepos/mf-transaction 0.0.4-beta → 0.0.5-2.beta-0
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/README.md +7 -28
- package/dist/App-CQTRq8SY.js +208521 -0
- package/dist/app-CBundCUB.js +348 -0
- package/dist/app.js +4 -3
- package/dist/{src → apps/mf-transaction/src}/App.vue.d.ts +1 -1
- package/dist/{src → apps/mf-transaction/src}/Entry.vue.d.ts +1 -1
- package/dist/apps/mf-transaction/src/api/bill/index.d.ts +5 -0
- package/dist/{src → apps/mf-transaction/src}/api/transaction/index.d.ts +7 -5
- package/dist/apps/mf-transaction/src/app.d.ts +844 -0
- package/dist/{src → apps/mf-transaction/src}/composables/dateRange.d.ts +1 -0
- package/dist/apps/mf-transaction/src/helpers/canvas.d.ts +11 -0
- package/dist/{src → apps/mf-transaction/src}/helpers/utils.d.ts +1 -1
- package/dist/apps/mf-transaction/src/types/item.interface.d.ts +187 -0
- package/dist/{src → apps/mf-transaction/src}/views/receipt/ExportReceipt.vue.d.ts +4 -4
- package/dist/{src → apps/mf-transaction/src}/views/receipt/Receipt.vue.d.ts +1 -1
- package/dist/{src → apps/mf-transaction/src}/views/receipt/detail/ReceiptDetail.vue.d.ts +4 -4
- package/dist/apps/mf-transaction/src/views/receipt/detail/activity/ReceiptActivities.vue.d.ts +14 -0
- package/dist/apps/mf-transaction/src/views/receipt/detail/info/InfoBasic.vue.d.ts +20 -0
- package/dist/{src → apps/mf-transaction/src}/views/receipt/detail/info/InfoRow.vue.d.ts +4 -4
- package/dist/apps/mf-transaction/src/views/receipt/detail/info/ReceiptInfo.vue.d.ts +14 -0
- package/dist/apps/mf-transaction/src/views/receipt/detail/info/ReceiptItem.vue.d.ts +14 -0
- package/dist/apps/mf-transaction/src/views/receipt/detail/info/ReceiptPreview.vue.d.ts +14 -0
- package/dist/{src → apps/mf-transaction/src}/views/receipt/detail/info/ReceiptSubItem.vue.d.ts +5 -5
- package/dist/apps/mf-transaction/src/views/receipt/detail/item/ReceiptGroupItem.vue.d.ts +14 -0
- package/dist/apps/mf-transaction/src/views/receipt/detail/transaction/ReceiptTransaction.vue.d.ts +14 -0
- package/dist/{src → apps/mf-transaction/src}/views/receipt/receipt.d.ts +10 -7
- package/dist/apps/mf-transaction/tsconfig.app.tsbuildinfo +1 -0
- package/dist/{index.es-iKFS-t0L.js → index.es-K0vZLW_s.js} +1342 -1358
- package/dist/packages/shared/src/api/index.d.ts +3 -0
- package/dist/packages/shared/src/api/public.d.ts +5 -0
- package/dist/packages/shared/src/components/button/ResponsiveFabButton.vue.d.ts +12 -0
- package/dist/packages/shared/src/components/dialog/ConfirmActionDialog.vue.d.ts +30 -0
- package/dist/packages/shared/src/components/form/DynamicSheet.vue.d.ts +19 -0
- package/dist/packages/shared/src/components/form/FormLabel.vue.d.ts +33 -0
- package/dist/packages/shared/src/components/form/ImageDropField.vue.d.ts +46 -0
- package/dist/packages/shared/src/components/form/SelectFilter.vue.d.ts +121 -0
- package/dist/packages/shared/src/components/info/CustomAttributeChip.vue.d.ts +29 -0
- package/dist/packages/shared/src/components/info/InfoBasic.vue.d.ts +20 -0
- package/dist/packages/shared/src/components/info/Summary.vue.d.ts +19 -0
- package/dist/packages/shared/src/components/info/TextChip.vue.d.ts +36 -0
- package/dist/packages/shared/src/components/layout/FormColumn.vue.d.ts +21 -0
- package/dist/packages/shared/src/components/layout/FormItem.vue.d.ts +23 -0
- package/dist/packages/shared/src/components/layout/FormRow.vue.d.ts +9 -0
- package/dist/packages/shared/src/components/layout/FormSection.vue.d.ts +24 -0
- package/dist/packages/shared/src/components/layout/FullScreenForm.vue.d.ts +45 -0
- package/dist/packages/shared/src/components/layout/FullWrapper.vue.d.ts +9 -0
- package/dist/{src/views/online/OnlineTransaction.vue.d.ts → packages/shared/src/components/layout/HorizontalSplitter.vue.d.ts} +1 -1
- package/dist/packages/shared/src/components/layout/Indent.vue.d.ts +9 -0
- package/dist/{src/components/Navigator.vue.d.ts → packages/shared/src/components/layout/ListLayout.vue.d.ts} +1 -1
- package/dist/packages/shared/src/components/layout/LottieAnimation.vue.d.ts +39 -0
- package/dist/packages/shared/src/components/layout/MobileXScrollable.vue.d.ts +9 -0
- package/dist/packages/shared/src/components/layout/PageLayout.vue.d.ts +24 -0
- package/dist/packages/shared/src/components/loading/AppLoading.vue.d.ts +20 -0
- package/dist/packages/shared/src/components/loading/PageLoading.vue.d.ts +2 -0
- package/dist/packages/shared/src/components/loading/index.d.ts +1 -0
- package/dist/packages/shared/src/components/map/GoogleMap.vue.d.ts +79 -0
- package/dist/packages/shared/src/components/menu/BottomSheetMenu.vue.d.ts +10 -0
- package/dist/packages/shared/src/components/menu/BottomSheetMenuItem.vue.d.ts +24 -0
- package/dist/packages/shared/src/components/menu/ResponsiveContextMenu.vue.d.ts +22 -0
- package/dist/packages/shared/src/components/table/EmptyDataTemplate/Icon.vue.d.ts +2 -0
- package/dist/packages/shared/src/components/table/EmptyDataTemplate/index.d.ts +1 -0
- package/dist/packages/shared/src/components/table/EmptyDataTemplate/index.vue.d.ts +27 -0
- package/dist/packages/shared/src/components/types.d.ts +95 -0
- package/dist/packages/shared/src/composable/clipboard.d.ts +3 -0
- package/dist/packages/shared/src/composable/dateRange.d.ts +18 -0
- package/dist/packages/shared/src/composable/discardConfirm.d.ts +1 -0
- package/dist/packages/shared/src/composable/elementPosition.d.ts +17 -0
- package/dist/packages/shared/src/composable/filterSelector.d.ts +12 -0
- package/dist/packages/shared/src/composable/loading.d.ts +29 -0
- package/dist/packages/shared/src/composable/prompt.d.ts +9 -0
- package/dist/packages/shared/src/composable/search.d.ts +5 -0
- package/dist/packages/shared/src/composable/sheet.d.ts +17 -0
- package/dist/packages/shared/src/feature/featureMinVersion.d.ts +34 -0
- package/dist/packages/shared/src/helpers/actionButton.d.ts +8 -0
- package/dist/packages/shared/src/helpers/browser.d.ts +1 -0
- package/dist/packages/shared/src/helpers/contextMenu.d.ts +13 -0
- package/dist/packages/shared/src/helpers/createComponent.d.ts +7 -0
- package/dist/packages/shared/src/helpers/createForm.d.ts +2 -0
- package/dist/packages/shared/src/helpers/iteration.d.ts +11 -0
- package/dist/packages/shared/src/helpers/map.d.ts +370 -0
- package/dist/packages/shared/src/helpers/object.d.ts +6 -0
- package/dist/packages/shared/src/helpers/rules.d.ts +1 -0
- package/dist/packages/shared/src/helpers/string.d.ts +12 -0
- package/dist/packages/shared/src/permission/posPermission.d.ts +6 -0
- package/dist/packages/shared/src/stores/app.d.ts +217 -0
- package/dist/packages/shared/src/types/types.d.ts +5 -0
- package/dist/{purify.es-CFivMm59.js → purify.es-CKk_t3XZ.js} +57 -57
- package/package.json +35 -34
- package/dist/app-U6otHOqe.js +0 -144269
- package/dist/html2canvas.esm-DgRhIRvu.js +0 -4870
- package/dist/src/api/bill/index.d.ts +0 -3
- package/dist/src/api/employee/index.d.ts +0 -13
- package/dist/src/api/inventory/index.d.ts +0 -5
- package/dist/src/api/payment/index.d.ts +0 -3
- package/dist/src/api/role/index.d.ts +0 -9
- package/dist/src/api/team/index.d.ts +0 -9
- package/dist/src/api/timesheet/index.d.ts +0 -6
- package/dist/src/api/user/index.d.ts +0 -6
- package/dist/src/app.d.ts +0 -2
- package/dist/src/components/AppForm.vue.d.ts +0 -41
- package/dist/src/components/CheckboxInput.vue.d.ts +0 -140
- package/dist/src/components/FilterDialog.vue.d.ts +0 -13
- package/dist/src/components/RestaurantSelector.vue.d.ts +0 -6
- package/dist/src/helpers/rule.d.ts +0 -29
- package/dist/src/router/index.d.ts +0 -2
- package/dist/src/router/shared.d.ts +0 -4
- package/dist/src/stores/employee.d.ts +0 -539
- package/dist/src/stores/role.d.ts +0 -205
- package/dist/src/stores/timesheet.d.ts +0 -253
- package/dist/src/types/employee.d.ts +0 -29
- package/dist/src/types/permission.d.ts +0 -68
- package/dist/src/types/role.d.ts +0 -37
- package/dist/src/types/team.d.ts +0 -47
- package/dist/src/types/timesheet.d.ts +0 -16
- package/dist/src/views/online/PaymentTable.vue.d.ts +0 -112
- package/dist/src/views/online/SettlementTable.vue.d.ts +0 -66
- package/dist/src/views/online/detail/FmSettlement.vue.d.ts +0 -32
- package/dist/src/views/online/detail/RmsSettlement.vue.d.ts +0 -22
- package/dist/src/views/online/detail/SettlementDetail.vue.d.ts +0 -5
- package/dist/src/views/online/settlement.d.ts +0 -52
- package/dist/src/views/receipt/detail/activity/ReceiptActivities.vue.d.ts +0 -14
- package/dist/src/views/receipt/detail/info/InfoBasic.vue.d.ts +0 -20
- package/dist/src/views/receipt/detail/info/ReceiptInfo.vue.d.ts +0 -14
- package/dist/src/views/receipt/detail/info/ReceiptItem.vue.d.ts +0 -14
- package/dist/src/views/receipt/detail/info/ReceiptPreview.vue.d.ts +0 -14
- package/dist/src/views/receipt/detail/item/ReceiptGroupItem.vue.d.ts +0 -14
- package/dist/src/views/team/TeamMemberList.vue.d.ts +0 -2
- package/dist/src/views/team/components/AddMemberForm.vue.d.ts +0 -40
- package/dist/src/views/team/components/PortalPermissionEditor.vue.d.ts +0 -38
- package/dist/src/views/team/components/PortalUserSearcher.vue.d.ts +0 -40
- package/dist/src/views/team/components/TeamMemberBasePermission.vue.d.ts +0 -36
- package/dist/src/views/team/components/TeamMemberConditionPermission.vue.d.ts +0 -50
- package/dist/src/views/team/components/TeamMemberMasterUser.vue.d.ts +0 -836
- package/dist/src/views/team/components/TeamMemberRolePermission.vue.d.ts +0 -46
- package/dist/style.css +0 -1
- package/dist/tsconfig.app.tsbuildinfo +0 -1
- /package/dist/{src → apps/mf-transaction/src}/api/index.d.ts +0 -0
- /package/dist/{src → apps/mf-transaction/src}/composables/message.d.ts +0 -0
- /package/dist/{src → apps/mf-transaction/src}/helpers/component.d.ts +0 -0
- /package/dist/{src → apps/mf-transaction/src}/helpers/createComponent.d.ts +0 -0
- /package/dist/{src → apps/mf-transaction/src}/helpers/createForm.d.ts +0 -0
- /package/dist/{src → apps/mf-transaction/src}/helpers/export.d.ts +0 -0
- /package/dist/{src → apps/mf-transaction/src}/helpers/idToDate.d.ts +0 -0
- /package/dist/{src → apps/mf-transaction/src}/helpers/iteration.d.ts +0 -0
- /package/dist/{src → apps/mf-transaction/src}/helpers/random.d.ts +0 -0
- /package/dist/{src → apps/mf-transaction/src}/helpers/string.d.ts +0 -0
- /package/dist/{src → apps/mf-transaction/src}/helpers/time.d.ts +0 -0
- /package/dist/{src → apps/mf-transaction/src}/main.d.ts +0 -0
- /package/dist/{src → apps/mf-transaction/src}/types/restaurant.d.ts +0 -0
- /package/dist/{src → apps/mf-transaction/src}/types/transaction.d.ts +0 -0
- /package/dist/{src → apps/mf-transaction/src}/views/receipt/form.d.ts +0 -0
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export interface CompressionOptions {
|
|
2
|
+
quality?: number;
|
|
3
|
+
format?: "jpeg" | "png";
|
|
4
|
+
}
|
|
5
|
+
/**
|
|
6
|
+
* Compress canvas image to reduce file size
|
|
7
|
+
* @param originalCanvas - The original canvas element
|
|
8
|
+
* @param options - Compression options
|
|
9
|
+
* @returns Compressed image data URL
|
|
10
|
+
*/
|
|
11
|
+
export declare function compressCanvas(originalCanvas: HTMLCanvasElement, options?: CompressionOptions): string;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { type FdoDinero } from "@feedmepos/core
|
|
1
|
+
import { type FdoDinero } from "@feedmepos/core/entity";
|
|
2
2
|
export declare function idToDate(id: string): string | null;
|
|
3
3
|
export declare function formatDuration(totalMinutes: number): string;
|
|
4
4
|
export declare function sentenceCase(s: string): string;
|
|
@@ -0,0 +1,187 @@
|
|
|
1
|
+
import type { FdoBillCustomerRef, FdoBillItemTax, FdoDinero, FdoPosUserRef, FdoStockChange } from "@feedmepos/core-dart";
|
|
2
|
+
/** what kind of product status */
|
|
3
|
+
export declare enum F_BILL_ITEM_STATUS {
|
|
4
|
+
draft = "DRAFT",
|
|
5
|
+
sent = "SENT",
|
|
6
|
+
refunded = "REFUNDED",
|
|
7
|
+
voided = "VOIDED"
|
|
8
|
+
}
|
|
9
|
+
/** who created bill item */
|
|
10
|
+
export declare enum BillItemCreatedByType {
|
|
11
|
+
employee = "EMPLOYEE",
|
|
12
|
+
customer = "CUSTOMER"
|
|
13
|
+
}
|
|
14
|
+
declare global {
|
|
15
|
+
/** Item price adjustment */
|
|
16
|
+
interface IFdoItemAdjustment {
|
|
17
|
+
/** will update base price instead of final price */
|
|
18
|
+
excludeAddonPrice?: boolean;
|
|
19
|
+
}
|
|
20
|
+
interface IFdoKitchenStation {
|
|
21
|
+
startAt?: string;
|
|
22
|
+
finishAt?: string;
|
|
23
|
+
completedAt?: string;
|
|
24
|
+
}
|
|
25
|
+
interface IFdoBillSubItemRef {
|
|
26
|
+
/**
|
|
27
|
+
* if the sub item linked to product, copy the id here.
|
|
28
|
+
* <br> used for printing, saperate the sub item from main item.
|
|
29
|
+
* <br> if null, the sub item will be attach to bill item
|
|
30
|
+
*/
|
|
31
|
+
productId?: string;
|
|
32
|
+
product?: IFdoBillItemRef;
|
|
33
|
+
/** If the selection is dynamic addon */
|
|
34
|
+
/** @mockType {commerce.color} */
|
|
35
|
+
dynamic?: Record<string, any>;
|
|
36
|
+
/** if the linked product have variant */
|
|
37
|
+
variantSelected?: IFdoBillItemVariantSelected;
|
|
38
|
+
price?: FdoDinero;
|
|
39
|
+
name: string;
|
|
40
|
+
name2?: string;
|
|
41
|
+
/**
|
|
42
|
+
* how to refer back on addon selection dialog
|
|
43
|
+
* <br> syntax: '{addonGroupId}/{addonId}'
|
|
44
|
+
* <br> in case of custom addon, the selection will be null or custom-group
|
|
45
|
+
*/
|
|
46
|
+
selection: string;
|
|
47
|
+
quantity: number;
|
|
48
|
+
kitchenStation?: {
|
|
49
|
+
[stationName: string]: IFdoKitchenStation;
|
|
50
|
+
};
|
|
51
|
+
servedAt?: string;
|
|
52
|
+
/** v4, addon addon */
|
|
53
|
+
/** @mockType {commerce.color} */
|
|
54
|
+
subItems: IFdoBillSubItemRef[];
|
|
55
|
+
}
|
|
56
|
+
interface IFdoBillItemVariantSelected {
|
|
57
|
+
/** Name of the selected, position is sensitive, for reprint and report recombine */
|
|
58
|
+
name: string[];
|
|
59
|
+
/** For backtrack and report */
|
|
60
|
+
combinationKey: string;
|
|
61
|
+
}
|
|
62
|
+
interface IFdoBillItemTaxRef {
|
|
63
|
+
systemCode: string;
|
|
64
|
+
taxCode: string;
|
|
65
|
+
inclusive?: boolean;
|
|
66
|
+
}
|
|
67
|
+
interface IFdoBillItemRef {
|
|
68
|
+
code: string;
|
|
69
|
+
unit?: string;
|
|
70
|
+
perXUnit?: number | string;
|
|
71
|
+
/** origin price */
|
|
72
|
+
price: FdoDinero;
|
|
73
|
+
/** Added 13/07/2022: for future original price reference use */
|
|
74
|
+
originalPrice?: FdoDinero;
|
|
75
|
+
/** The name for display */
|
|
76
|
+
name: string;
|
|
77
|
+
/** The internal name for printing */
|
|
78
|
+
name2?: string;
|
|
79
|
+
/** Added 13/04/2020: can compute takeaway price */
|
|
80
|
+
takeawayPrice?: FdoDinero;
|
|
81
|
+
/** Added 30/11/2020: used by advance selector */
|
|
82
|
+
takeawayId?: string;
|
|
83
|
+
/** Added 30/11/2020: used by printer */
|
|
84
|
+
takeawayName?: string;
|
|
85
|
+
/** Added 03/12/2020: for report use */
|
|
86
|
+
categoryName?: string;
|
|
87
|
+
taxes?: IFdoBillItemTaxRef[];
|
|
88
|
+
/** Added 13/07/2022: for open price validation use */
|
|
89
|
+
openPrice?: boolean;
|
|
90
|
+
/**
|
|
91
|
+
@deprecated 23/11/2020 (4.0): replace by taxes
|
|
92
|
+
*/
|
|
93
|
+
noSst?: boolean;
|
|
94
|
+
/**
|
|
95
|
+
@deprecated 7/04/2020: no needed
|
|
96
|
+
*/
|
|
97
|
+
cost?: FdoDinero;
|
|
98
|
+
/**
|
|
99
|
+
@deprecated 05/11/2020: replaced by catalog
|
|
100
|
+
*/
|
|
101
|
+
deliveryPrice?: FdoDinero;
|
|
102
|
+
}
|
|
103
|
+
interface IFdoBillItemIs {
|
|
104
|
+
takeaway: boolean;
|
|
105
|
+
/**
|
|
106
|
+
@deprecated 26/04/2020: causing ambigious
|
|
107
|
+
*/
|
|
108
|
+
delivery?: boolean;
|
|
109
|
+
}
|
|
110
|
+
interface IFdoBillItem {
|
|
111
|
+
parent?: IFdoBillItem;
|
|
112
|
+
/** which product being ordered, null if custom product */
|
|
113
|
+
productId?: string;
|
|
114
|
+
/** a copy of product for bill calculation and display */
|
|
115
|
+
product: IFdoBillItemRef;
|
|
116
|
+
subItems: IFdoBillSubItemRef[];
|
|
117
|
+
status: F_BILL_ITEM_STATUS;
|
|
118
|
+
/** from seat identification */
|
|
119
|
+
is: IFdoBillItemIs;
|
|
120
|
+
/** if the product have variant */
|
|
121
|
+
variantSelected?: IFdoBillItemVariantSelected;
|
|
122
|
+
/** only exist if product is unit */
|
|
123
|
+
unitQuantity?: number;
|
|
124
|
+
/** normal product quantity */
|
|
125
|
+
quantity: number;
|
|
126
|
+
/** remark to attach */
|
|
127
|
+
remark?: string;
|
|
128
|
+
/** link to billItem in bill refundedFrom */
|
|
129
|
+
refundedFrom?: string;
|
|
130
|
+
/** link to user */
|
|
131
|
+
refundBy?: FdoPosUserRef;
|
|
132
|
+
/** link to user */
|
|
133
|
+
refundApprovedBy?: FdoPosUserRef;
|
|
134
|
+
voidAt?: string;
|
|
135
|
+
/** link to user */
|
|
136
|
+
voidBy?: FdoPosUserRef;
|
|
137
|
+
voidReason?: string;
|
|
138
|
+
/** link to user */
|
|
139
|
+
voidApprovedBy?: FdoPosUserRef;
|
|
140
|
+
/** link to user */
|
|
141
|
+
createdBy?: FdoPosUserRef;
|
|
142
|
+
sentAt?: string;
|
|
143
|
+
/** link to user */
|
|
144
|
+
sentBy?: FdoPosUserRef;
|
|
145
|
+
servedAt?: string;
|
|
146
|
+
printReceiptAt?: string;
|
|
147
|
+
printBy?: IFdoPrintBy[];
|
|
148
|
+
kitchenStation?: {
|
|
149
|
+
[stationName: string]: IFdoKitchenStation;
|
|
150
|
+
};
|
|
151
|
+
customer?: FdoBillCustomerRef;
|
|
152
|
+
/** @mockType {commerce.color} */
|
|
153
|
+
adjustments: {
|
|
154
|
+
[created: string]: IFdoItemAdjustment;
|
|
155
|
+
};
|
|
156
|
+
/** timestamp when product deleted */
|
|
157
|
+
deletedAt?: string;
|
|
158
|
+
/** computed field, the taxes needed to calculate this item */
|
|
159
|
+
/** @mockType {commerce.color} */
|
|
160
|
+
taxes: {
|
|
161
|
+
[created: string]: FdoBillItemTax;
|
|
162
|
+
};
|
|
163
|
+
/** gross price + adjustment */
|
|
164
|
+
nettTotal: FdoDinero;
|
|
165
|
+
stockChange?: FdoStockChange;
|
|
166
|
+
/**
|
|
167
|
+
@deprecated 30/12/2020: cause confusion when discount before/after addon, shouldn't presist on database, change to pure function
|
|
168
|
+
*/
|
|
169
|
+
baseTotal?: FdoDinero;
|
|
170
|
+
/**
|
|
171
|
+
@deprecated 05/12/2019: internal used only
|
|
172
|
+
*/
|
|
173
|
+
addonTotal?: FdoDinero;
|
|
174
|
+
/**
|
|
175
|
+
@deprecated 05/12/2019: internal used only
|
|
176
|
+
*/
|
|
177
|
+
grossTotal?: FdoDinero;
|
|
178
|
+
/**
|
|
179
|
+
@deprecated 05/12/2019: internal used only
|
|
180
|
+
*/
|
|
181
|
+
adjustmentTotal?: FdoDinero;
|
|
182
|
+
}
|
|
183
|
+
interface IFdoPrintBy {
|
|
184
|
+
user: FdoPosUserRef;
|
|
185
|
+
printAt: string;
|
|
186
|
+
}
|
|
187
|
+
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { PropType } from "vue";
|
|
1
|
+
import { type PropType } from "vue";
|
|
2
2
|
import { type Receipt } from "@/views/receipt/receipt";
|
|
3
|
-
declare const _default: import("vue").DefineComponent<{
|
|
3
|
+
declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
4
4
|
dateRange: {
|
|
5
5
|
type: PropType<{
|
|
6
6
|
startDate: string;
|
|
@@ -16,7 +16,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
16
16
|
type: PropType<Receipt[]>;
|
|
17
17
|
required: true;
|
|
18
18
|
};
|
|
19
|
-
}
|
|
19
|
+
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
20
20
|
dateRange: {
|
|
21
21
|
type: PropType<{
|
|
22
22
|
startDate: string;
|
|
@@ -32,5 +32,5 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
32
32
|
type: PropType<Receipt[]>;
|
|
33
33
|
required: true;
|
|
34
34
|
};
|
|
35
|
-
}
|
|
35
|
+
}>> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
36
36
|
export default _default;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").
|
|
1
|
+
declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
2
2
|
export default _default;
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
import { type PropType } from "vue";
|
|
2
2
|
import type { Receipt } from "../receipt";
|
|
3
|
-
declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
3
|
+
declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
4
4
|
receipt: {
|
|
5
5
|
type: PropType<Receipt>;
|
|
6
6
|
required: true;
|
|
7
7
|
};
|
|
8
|
-
}
|
|
8
|
+
}>, {
|
|
9
9
|
show: import("vue").Ref<boolean, boolean>;
|
|
10
10
|
trigger: (event?: any) => void;
|
|
11
|
-
},
|
|
11
|
+
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
12
12
|
receipt: {
|
|
13
13
|
type: PropType<Receipt>;
|
|
14
14
|
required: true;
|
|
15
15
|
};
|
|
16
|
-
}
|
|
16
|
+
}>> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>, {
|
|
17
17
|
default?(_: {
|
|
18
18
|
trigger: (event?: any) => void;
|
|
19
19
|
}): any;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { type PropType } from "vue";
|
|
2
|
+
import type { Receipt } from "@/views/receipt/receipt";
|
|
3
|
+
declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
4
|
+
receipt: {
|
|
5
|
+
type: PropType<Receipt>;
|
|
6
|
+
required: true;
|
|
7
|
+
};
|
|
8
|
+
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
9
|
+
receipt: {
|
|
10
|
+
type: PropType<Receipt>;
|
|
11
|
+
required: true;
|
|
12
|
+
};
|
|
13
|
+
}>> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
14
|
+
export default _default;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
2
|
+
name: {
|
|
3
|
+
type: StringConstructor;
|
|
4
|
+
required: true;
|
|
5
|
+
};
|
|
6
|
+
value: {
|
|
7
|
+
type: StringConstructor;
|
|
8
|
+
required: true;
|
|
9
|
+
};
|
|
10
|
+
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
11
|
+
name: {
|
|
12
|
+
type: StringConstructor;
|
|
13
|
+
required: true;
|
|
14
|
+
};
|
|
15
|
+
value: {
|
|
16
|
+
type: StringConstructor;
|
|
17
|
+
required: true;
|
|
18
|
+
};
|
|
19
|
+
}>> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
20
|
+
export default _default;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
declare const _default: import("vue").DefineComponent<{
|
|
1
|
+
declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
2
2
|
name: {
|
|
3
3
|
type: StringConstructor;
|
|
4
4
|
required: true;
|
|
@@ -11,7 +11,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
11
11
|
type: BooleanConstructor;
|
|
12
12
|
default: boolean;
|
|
13
13
|
};
|
|
14
|
-
}
|
|
14
|
+
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
15
15
|
name: {
|
|
16
16
|
type: StringConstructor;
|
|
17
17
|
required: true;
|
|
@@ -24,7 +24,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
24
24
|
type: BooleanConstructor;
|
|
25
25
|
default: boolean;
|
|
26
26
|
};
|
|
27
|
-
}
|
|
27
|
+
}>> & Readonly<{}>, {
|
|
28
28
|
strong: boolean;
|
|
29
|
-
}, {}>;
|
|
29
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
30
30
|
export default _default;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { type PropType } from "vue";
|
|
2
|
+
import { type Receipt } from "@/views/receipt/receipt";
|
|
3
|
+
declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
4
|
+
receipt: {
|
|
5
|
+
type: PropType<Receipt>;
|
|
6
|
+
required: true;
|
|
7
|
+
};
|
|
8
|
+
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
9
|
+
receipt: {
|
|
10
|
+
type: PropType<Receipt>;
|
|
11
|
+
required: true;
|
|
12
|
+
};
|
|
13
|
+
}>> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
14
|
+
export default _default;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { type PropType } from "vue";
|
|
2
|
+
import type { ReceiptItem } from "@/views/receipt/receipt";
|
|
3
|
+
declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
4
|
+
item: {
|
|
5
|
+
type: PropType<ReceiptItem>;
|
|
6
|
+
required: true;
|
|
7
|
+
};
|
|
8
|
+
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
9
|
+
item: {
|
|
10
|
+
type: PropType<ReceiptItem>;
|
|
11
|
+
required: true;
|
|
12
|
+
};
|
|
13
|
+
}>> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
14
|
+
export default _default;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { type PropType } from "vue";
|
|
2
|
+
import { type Receipt } from "@/views/receipt/receipt";
|
|
3
|
+
declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
4
|
+
receipt: {
|
|
5
|
+
type: PropType<Receipt>;
|
|
6
|
+
required: true;
|
|
7
|
+
};
|
|
8
|
+
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
9
|
+
receipt: {
|
|
10
|
+
type: PropType<Receipt>;
|
|
11
|
+
required: true;
|
|
12
|
+
};
|
|
13
|
+
}>> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
14
|
+
export default _default;
|
package/dist/{src → apps/mf-transaction/src}/views/receipt/detail/info/ReceiptSubItem.vue.d.ts
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { PropType } from "vue";
|
|
1
|
+
import { type PropType } from "vue";
|
|
2
2
|
import type { ReceiptSubItem } from "@/views/receipt/receipt";
|
|
3
|
-
declare const _default: import("vue").DefineComponent<{
|
|
3
|
+
declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
4
4
|
subItem: {
|
|
5
5
|
type: PropType<ReceiptSubItem>;
|
|
6
6
|
required: true;
|
|
@@ -9,7 +9,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
9
9
|
type: BooleanConstructor;
|
|
10
10
|
default: boolean;
|
|
11
11
|
};
|
|
12
|
-
}
|
|
12
|
+
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
13
13
|
subItem: {
|
|
14
14
|
type: PropType<ReceiptSubItem>;
|
|
15
15
|
required: true;
|
|
@@ -18,7 +18,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
18
18
|
type: BooleanConstructor;
|
|
19
19
|
default: boolean;
|
|
20
20
|
};
|
|
21
|
-
}
|
|
21
|
+
}>> & Readonly<{}>, {
|
|
22
22
|
indent: boolean;
|
|
23
|
-
}, {}>;
|
|
23
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
24
24
|
export default _default;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { type PropType } from "vue";
|
|
2
|
+
import type { Receipt } from "@/views/receipt/receipt";
|
|
3
|
+
declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
4
|
+
receipt: {
|
|
5
|
+
type: PropType<Receipt>;
|
|
6
|
+
required: true;
|
|
7
|
+
};
|
|
8
|
+
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
9
|
+
receipt: {
|
|
10
|
+
type: PropType<Receipt>;
|
|
11
|
+
required: true;
|
|
12
|
+
};
|
|
13
|
+
}>> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
14
|
+
export default _default;
|
package/dist/apps/mf-transaction/src/views/receipt/detail/transaction/ReceiptTransaction.vue.d.ts
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { type PropType } from "vue";
|
|
2
|
+
import type { Receipt } from "@/views/receipt/receipt";
|
|
3
|
+
declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
4
|
+
receipt: {
|
|
5
|
+
type: PropType<Receipt>;
|
|
6
|
+
required: true;
|
|
7
|
+
};
|
|
8
|
+
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
9
|
+
receipt: {
|
|
10
|
+
type: PropType<Receipt>;
|
|
11
|
+
required: true;
|
|
12
|
+
};
|
|
13
|
+
}>> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
14
|
+
export default _default;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { Dayjs } from "dayjs";
|
|
2
2
|
import { type BillVariable, type OrderReceiptTemplateVariable } from "@feedmepos/print/dist/core/src/modules/printer/templateVariable";
|
|
3
|
-
import { type
|
|
3
|
+
import { type Bill } from "@/api/transaction";
|
|
4
4
|
import type { ExtendedRestaurant } from "@/types/restaurant";
|
|
5
5
|
import type { ReceiptDetailViewer } from "@/views/receipt/form";
|
|
6
|
-
export interface Receipt extends
|
|
6
|
+
export interface Receipt extends Bill {
|
|
7
7
|
createdAt: string;
|
|
8
8
|
createdBy: string;
|
|
9
9
|
_completedAt: string;
|
|
@@ -28,7 +28,7 @@ export interface Receipt extends FdoBill {
|
|
|
28
28
|
feedmeDelivery: ReceiptInfo[];
|
|
29
29
|
_delivery: ReceiptInfo[];
|
|
30
30
|
_pickup: ReceiptInfo[];
|
|
31
|
-
|
|
31
|
+
toCanvas: () => Promise<HTMLCanvasElement>;
|
|
32
32
|
getActivities: (receipt: Receipt) => ReceiptActivity[];
|
|
33
33
|
groupItems: GroupItemsByUser;
|
|
34
34
|
}
|
|
@@ -52,9 +52,9 @@ interface ReceiptInfo {
|
|
|
52
52
|
name: string;
|
|
53
53
|
value: string;
|
|
54
54
|
}
|
|
55
|
-
export declare function billToReceipt(bill:
|
|
56
|
-
export declare function transformTemplateVariable(bill:
|
|
57
|
-
export declare function receiptStatus(bill:
|
|
55
|
+
export declare function billToReceipt(bill: Bill, restaurant: ExtendedRestaurant, refundedFromBill?: Bill): Receipt;
|
|
56
|
+
export declare function transformTemplateVariable(bill: Bill, restaurant: ExtendedRestaurant): OrderReceiptTemplateVariable;
|
|
57
|
+
export declare function receiptStatus(bill: Bill, refundedFromBill?: Bill): {
|
|
58
58
|
label: string;
|
|
59
59
|
icon: {
|
|
60
60
|
name: string;
|
|
@@ -93,7 +93,10 @@ export declare function transformPickup({ pickup }: BillVariable): {
|
|
|
93
93
|
name: string;
|
|
94
94
|
value: string;
|
|
95
95
|
}[];
|
|
96
|
-
export declare
|
|
96
|
+
export declare const RECEIPT_PREVIEW_WIDTH = "370px";
|
|
97
|
+
export declare const RECEIPT_PREVIEW_HEIGHT = "90dvh";
|
|
98
|
+
export declare function exportPDF(receipts: Receipt[], filename: string, onProgress?: (current: number, total: number) => void): Promise<void>;
|
|
99
|
+
export declare function previewPDF(receipts: Receipt[]): Promise<void>;
|
|
97
100
|
interface GroupItem {
|
|
98
101
|
name: string;
|
|
99
102
|
quantity: number;
|