@feedmepos/mf-transaction 0.0.1-beta
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 +31 -0
- package/dist/app-BOlyScCe.js +141127 -0
- package/dist/app.js +5 -0
- package/dist/favicon.ico +0 -0
- package/dist/html2canvas.esm-DgRhIRvu.js +4870 -0
- package/dist/index.es-6a79NHf-.js +5618 -0
- package/dist/purify.es-CFivMm59.js +471 -0
- package/dist/src/App.vue.d.ts +2 -0
- package/dist/src/Entry.vue.d.ts +2 -0
- package/dist/src/api/bill/index.d.ts +3 -0
- package/dist/src/api/employee/index.d.ts +13 -0
- package/dist/src/api/index.d.ts +4 -0
- package/dist/src/api/inventory/index.d.ts +5 -0
- package/dist/src/api/payment/index.d.ts +3 -0
- package/dist/src/api/role/index.d.ts +9 -0
- package/dist/src/api/team/index.d.ts +9 -0
- package/dist/src/api/timesheet/index.d.ts +6 -0
- package/dist/src/api/transaction/index.d.ts +32 -0
- package/dist/src/api/user/index.d.ts +6 -0
- package/dist/src/app.d.ts +2 -0
- package/dist/src/components/AppForm.vue.d.ts +41 -0
- package/dist/src/components/CheckboxInput.vue.d.ts +140 -0
- package/dist/src/components/FilterDialog.vue.d.ts +13 -0
- package/dist/src/components/Navigator.vue.d.ts +2 -0
- package/dist/src/components/RestaurantSelector.vue.d.ts +6 -0
- package/dist/src/composables/dateRange.d.ts +17 -0
- package/dist/src/composables/message.d.ts +4 -0
- package/dist/src/helpers/component.d.ts +12 -0
- package/dist/src/helpers/createComponent.d.ts +7 -0
- package/dist/src/helpers/createForm.d.ts +2 -0
- package/dist/src/helpers/export.d.ts +12 -0
- package/dist/src/helpers/idToDate.d.ts +1 -0
- package/dist/src/helpers/iteration.d.ts +10 -0
- package/dist/src/helpers/random.d.ts +3 -0
- package/dist/src/helpers/rule.d.ts +29 -0
- package/dist/src/helpers/string.d.ts +5 -0
- package/dist/src/helpers/time.d.ts +7 -0
- package/dist/src/helpers/utils.d.ts +5 -0
- package/dist/src/main.d.ts +2 -0
- package/dist/src/router/index.d.ts +2 -0
- package/dist/src/router/shared.d.ts +4 -0
- package/dist/src/stores/employee.d.ts +539 -0
- package/dist/src/stores/role.d.ts +205 -0
- package/dist/src/stores/timesheet.d.ts +253 -0
- package/dist/src/types/employee.d.ts +29 -0
- package/dist/src/types/permission.d.ts +68 -0
- package/dist/src/types/restaurant.d.ts +18 -0
- package/dist/src/types/role.d.ts +37 -0
- package/dist/src/types/team.d.ts +47 -0
- package/dist/src/types/timesheet.d.ts +16 -0
- package/dist/src/types/transaction.d.ts +6 -0
- package/dist/src/views/online/OnlineTransaction.vue.d.ts +2 -0
- package/dist/src/views/online/PaymentTable.vue.d.ts +112 -0
- package/dist/src/views/online/SettlementTable.vue.d.ts +66 -0
- package/dist/src/views/online/detail/FmSettlement.vue.d.ts +32 -0
- package/dist/src/views/online/detail/RmsSettlement.vue.d.ts +22 -0
- package/dist/src/views/online/detail/SettlementDetail.vue.d.ts +5 -0
- package/dist/src/views/online/settlement.d.ts +52 -0
- package/dist/src/views/receipt/ExportReceipt.vue.d.ts +36 -0
- package/dist/src/views/receipt/Receipt.vue.d.ts +2 -0
- package/dist/src/views/receipt/detail/ReceiptDetail.vue.d.ts +26 -0
- package/dist/src/views/receipt/detail/activity/ReceiptActivities.vue.d.ts +14 -0
- package/dist/src/views/receipt/detail/info/InfoBasic.vue.d.ts +20 -0
- package/dist/src/views/receipt/detail/info/InfoRow.vue.d.ts +30 -0
- package/dist/src/views/receipt/detail/info/ReceiptInfo.vue.d.ts +14 -0
- package/dist/src/views/receipt/detail/info/ReceiptItem.vue.d.ts +14 -0
- package/dist/src/views/receipt/detail/info/ReceiptPreview.vue.d.ts +14 -0
- package/dist/src/views/receipt/detail/info/ReceiptSubItem.vue.d.ts +24 -0
- package/dist/src/views/receipt/detail/item/ReceiptGroupItem.vue.d.ts +14 -0
- package/dist/src/views/receipt/form.d.ts +3 -0
- package/dist/src/views/receipt/receipt.d.ts +118 -0
- package/dist/src/views/team/TeamMemberList.vue.d.ts +2 -0
- package/dist/src/views/team/components/AddMemberForm.vue.d.ts +40 -0
- package/dist/src/views/team/components/PortalPermissionEditor.vue.d.ts +38 -0
- package/dist/src/views/team/components/PortalUserSearcher.vue.d.ts +40 -0
- package/dist/src/views/team/components/TeamMemberBasePermission.vue.d.ts +36 -0
- package/dist/src/views/team/components/TeamMemberConditionPermission.vue.d.ts +50 -0
- package/dist/src/views/team/components/TeamMemberMasterUser.vue.d.ts +836 -0
- package/dist/src/views/team/components/TeamMemberRolePermission.vue.d.ts +46 -0
- package/dist/style.css +1 -0
- package/dist/tsconfig.app.tsbuildinfo +1 -0
- package/package.json +79 -0
|
@@ -0,0 +1,140 @@
|
|
|
1
|
+
import { type PropType } from "vue";
|
|
2
|
+
export interface CheckboxOption {
|
|
3
|
+
key?: string;
|
|
4
|
+
label: string;
|
|
5
|
+
value: any;
|
|
6
|
+
disable?: boolean;
|
|
7
|
+
suffix?: {
|
|
8
|
+
text: string;
|
|
9
|
+
class: string;
|
|
10
|
+
};
|
|
11
|
+
}
|
|
12
|
+
declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
13
|
+
options: {
|
|
14
|
+
type: PropType<CheckboxOption[]>;
|
|
15
|
+
required: true;
|
|
16
|
+
};
|
|
17
|
+
title: {
|
|
18
|
+
type: StringConstructor;
|
|
19
|
+
required: true;
|
|
20
|
+
};
|
|
21
|
+
modelValue: {
|
|
22
|
+
type: PropType<unknown[]>;
|
|
23
|
+
required: true;
|
|
24
|
+
};
|
|
25
|
+
showAllToggle: {
|
|
26
|
+
type: (BooleanConstructor | StringConstructor)[];
|
|
27
|
+
default: boolean;
|
|
28
|
+
};
|
|
29
|
+
disable: {
|
|
30
|
+
type: BooleanConstructor;
|
|
31
|
+
default: boolean;
|
|
32
|
+
};
|
|
33
|
+
min: {
|
|
34
|
+
type: NumberConstructor;
|
|
35
|
+
default: number;
|
|
36
|
+
};
|
|
37
|
+
max: {
|
|
38
|
+
type: NumberConstructor;
|
|
39
|
+
default: undefined;
|
|
40
|
+
};
|
|
41
|
+
showIntermediate: {
|
|
42
|
+
type: BooleanConstructor;
|
|
43
|
+
default: boolean;
|
|
44
|
+
};
|
|
45
|
+
gutter: {
|
|
46
|
+
type: NumberConstructor;
|
|
47
|
+
default: undefined;
|
|
48
|
+
};
|
|
49
|
+
falsyShowSlot: {
|
|
50
|
+
type: BooleanConstructor;
|
|
51
|
+
default: boolean;
|
|
52
|
+
};
|
|
53
|
+
bottomSlotIndent: {
|
|
54
|
+
type: StringConstructor;
|
|
55
|
+
default: string;
|
|
56
|
+
};
|
|
57
|
+
alignCenter: {
|
|
58
|
+
type: BooleanConstructor;
|
|
59
|
+
default: boolean;
|
|
60
|
+
};
|
|
61
|
+
}, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
62
|
+
"update:model-value": (value: any[]) => void;
|
|
63
|
+
}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
64
|
+
options: {
|
|
65
|
+
type: PropType<CheckboxOption[]>;
|
|
66
|
+
required: true;
|
|
67
|
+
};
|
|
68
|
+
title: {
|
|
69
|
+
type: StringConstructor;
|
|
70
|
+
required: true;
|
|
71
|
+
};
|
|
72
|
+
modelValue: {
|
|
73
|
+
type: PropType<unknown[]>;
|
|
74
|
+
required: true;
|
|
75
|
+
};
|
|
76
|
+
showAllToggle: {
|
|
77
|
+
type: (BooleanConstructor | StringConstructor)[];
|
|
78
|
+
default: boolean;
|
|
79
|
+
};
|
|
80
|
+
disable: {
|
|
81
|
+
type: BooleanConstructor;
|
|
82
|
+
default: boolean;
|
|
83
|
+
};
|
|
84
|
+
min: {
|
|
85
|
+
type: NumberConstructor;
|
|
86
|
+
default: number;
|
|
87
|
+
};
|
|
88
|
+
max: {
|
|
89
|
+
type: NumberConstructor;
|
|
90
|
+
default: undefined;
|
|
91
|
+
};
|
|
92
|
+
showIntermediate: {
|
|
93
|
+
type: BooleanConstructor;
|
|
94
|
+
default: boolean;
|
|
95
|
+
};
|
|
96
|
+
gutter: {
|
|
97
|
+
type: NumberConstructor;
|
|
98
|
+
default: undefined;
|
|
99
|
+
};
|
|
100
|
+
falsyShowSlot: {
|
|
101
|
+
type: BooleanConstructor;
|
|
102
|
+
default: boolean;
|
|
103
|
+
};
|
|
104
|
+
bottomSlotIndent: {
|
|
105
|
+
type: StringConstructor;
|
|
106
|
+
default: string;
|
|
107
|
+
};
|
|
108
|
+
alignCenter: {
|
|
109
|
+
type: BooleanConstructor;
|
|
110
|
+
default: boolean;
|
|
111
|
+
};
|
|
112
|
+
}>> & {
|
|
113
|
+
"onUpdate:model-value"?: ((value: any[]) => any) | undefined;
|
|
114
|
+
}, {
|
|
115
|
+
min: number;
|
|
116
|
+
max: number;
|
|
117
|
+
showAllToggle: string | boolean;
|
|
118
|
+
disable: boolean;
|
|
119
|
+
showIntermediate: boolean;
|
|
120
|
+
gutter: number;
|
|
121
|
+
falsyShowSlot: boolean;
|
|
122
|
+
bottomSlotIndent: string;
|
|
123
|
+
alignCenter: boolean;
|
|
124
|
+
}, {}>, Partial<Record<`checkbox-${any}-end`, (_: {
|
|
125
|
+
option: CheckboxOption;
|
|
126
|
+
value: boolean;
|
|
127
|
+
disable: boolean | undefined;
|
|
128
|
+
}) => any>> & Partial<Record<`checkbox-${any}-bottom`, (_: {
|
|
129
|
+
option: CheckboxOption;
|
|
130
|
+
disable: boolean | undefined;
|
|
131
|
+
value: boolean;
|
|
132
|
+
}) => any>> & {
|
|
133
|
+
top?(_: {}): any;
|
|
134
|
+
}>;
|
|
135
|
+
export default _default;
|
|
136
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
137
|
+
new (): {
|
|
138
|
+
$slots: S;
|
|
139
|
+
};
|
|
140
|
+
};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { type PropType } from "vue";
|
|
2
|
+
declare const _default: import("vue").DefineComponent<{
|
|
3
|
+
selectedRestaurants: {
|
|
4
|
+
type: PropType<string[]>;
|
|
5
|
+
required: true;
|
|
6
|
+
};
|
|
7
|
+
}, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
8
|
+
selectedRestaurants: {
|
|
9
|
+
type: PropType<string[]>;
|
|
10
|
+
required: true;
|
|
11
|
+
};
|
|
12
|
+
}>>, {}, {}>;
|
|
13
|
+
export default _default;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
declare const _default: import("vue").DefineComponent<{
|
|
2
|
+
modelValue: import("vue").PropType<string>;
|
|
3
|
+
}, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
4
|
+
modelValue: import("vue").PropType<string>;
|
|
5
|
+
}>>, {}, {}>;
|
|
6
|
+
export default _default;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
export declare function useDateRange(): {
|
|
2
|
+
dateRange: import("vue").Ref<{
|
|
3
|
+
startDate: string;
|
|
4
|
+
endDate: string;
|
|
5
|
+
}, {
|
|
6
|
+
startDate: string;
|
|
7
|
+
endDate: string;
|
|
8
|
+
} | {
|
|
9
|
+
startDate: string;
|
|
10
|
+
endDate: string;
|
|
11
|
+
}>;
|
|
12
|
+
parsedDateRange: import("vue").ComputedRef<{
|
|
13
|
+
startDate: Date;
|
|
14
|
+
endDate: Date;
|
|
15
|
+
}>;
|
|
16
|
+
dateRangeLabel: import("vue").ComputedRef<string>;
|
|
17
|
+
};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export type MenuActionProps = {
|
|
2
|
+
label: string;
|
|
3
|
+
color: string;
|
|
4
|
+
};
|
|
5
|
+
export declare enum MenuActionEnum {
|
|
6
|
+
Update = "Update",
|
|
7
|
+
Remove = "Remove"
|
|
8
|
+
}
|
|
9
|
+
export declare const DefaultMenuActions: Record<MenuActionEnum, MenuActionProps>;
|
|
10
|
+
export declare function createContextMenuComponents(actions: MenuActionProps[], onClick: (action: string) => void): import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
11
|
+
[key: string]: any;
|
|
12
|
+
}>;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { type ComponentInternalInstance } from "vue";
|
|
2
|
+
export declare const createComponentProgrammatically: <Component extends abstract new (...args: any) => any>(component: Component, currentInstance: ComponentInternalInstance | null, props: InstanceType<Component>["$props"]) => {
|
|
3
|
+
container: HTMLDivElement;
|
|
4
|
+
vNode: import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
5
|
+
[key: string]: any;
|
|
6
|
+
}>;
|
|
7
|
+
};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export interface ExportExcelCol<T> {
|
|
2
|
+
name: string;
|
|
3
|
+
selector: keyof T | ((v: T) => ExcelColValue);
|
|
4
|
+
}
|
|
5
|
+
export interface ExportExcelSheet<T> {
|
|
6
|
+
name: string;
|
|
7
|
+
data: T[];
|
|
8
|
+
columns: ExportExcelCol<T>[];
|
|
9
|
+
}
|
|
10
|
+
type ExcelColValue = string | number | Date | null;
|
|
11
|
+
export declare function exportExcel<T>(sheets: ExportExcelSheet<T>[], fileName: string): Promise<void>;
|
|
12
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default function idToDate(id: any): string | null;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export declare function clone<T>(value: T, exceptKey?: string[]): T;
|
|
2
|
+
type Selector<T> = keyof T | ((item: T) => string);
|
|
3
|
+
export declare function sort<T>(arr: T[], option?: {
|
|
4
|
+
selector?: Selector<T>;
|
|
5
|
+
descending?: boolean;
|
|
6
|
+
} | undefined): T[];
|
|
7
|
+
export declare function group<T>(arr: T[], by: Selector<T>): {
|
|
8
|
+
[key: string]: T[];
|
|
9
|
+
};
|
|
10
|
+
export {};
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { F_RULE_SUBJECT, type FdoPermissionRule } from "@feedmepos/core/entity";
|
|
2
|
+
import type { Rule } from "../types/role";
|
|
3
|
+
import type { RawRule } from "@casl/ability";
|
|
4
|
+
export declare function filterPermissions(permissions: FdoPermissionRule[], subject: F_RULE_SUBJECT): string;
|
|
5
|
+
export declare function ruleExtension(rule: FdoPermissionRule): {
|
|
6
|
+
condition: any;
|
|
7
|
+
isDiscountOperation: boolean;
|
|
8
|
+
isOrderOperation: boolean;
|
|
9
|
+
isReportPermission: boolean;
|
|
10
|
+
formatted: string;
|
|
11
|
+
label: string;
|
|
12
|
+
value: string;
|
|
13
|
+
reason?: string | null | undefined;
|
|
14
|
+
conditions?: any;
|
|
15
|
+
fields?: string[] | null | undefined;
|
|
16
|
+
inverted?: boolean | null | undefined;
|
|
17
|
+
subject: string;
|
|
18
|
+
actions: ("delete" | "manage" | "create" | "read" | "update")[];
|
|
19
|
+
};
|
|
20
|
+
export declare function getMaxDiscount(rules: FdoPermissionRule[]): number;
|
|
21
|
+
export declare function getManagableRestaurantIds(rules: RawRule[]): string[] | null;
|
|
22
|
+
export declare function hasAdminRule(rules: FdoPermissionRule[]): boolean;
|
|
23
|
+
export declare function usableRoleIds(rules: RawRule[]): string[] | null;
|
|
24
|
+
export declare function fromValue(values: string[], maxDiscountPercentage: number): {
|
|
25
|
+
subject: string;
|
|
26
|
+
actions: ("delete" | "manage" | "create" | "read" | "update")[];
|
|
27
|
+
conditions: object;
|
|
28
|
+
}[];
|
|
29
|
+
export declare function toRule(v: string): Rule;
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { type FdoDinero } from "@feedmepos/core-dart";
|
|
2
|
+
export declare function idToDate(id: string): string | null;
|
|
3
|
+
export declare function formatDuration(totalMinutes: number): string;
|
|
4
|
+
export declare function sentenceCase(s: string): string;
|
|
5
|
+
export declare function formatCurrency(value: FdoDinero, withSymbol?: boolean): string;
|