@pisell/private-materials 6.3.103 → 6.3.105
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/build/lowcode/assets-daily.json +11 -11
- package/build/lowcode/assets-dev.json +2 -2
- package/build/lowcode/assets-prod.json +11 -11
- package/build/lowcode/index.js +1 -1
- package/build/lowcode/meta.js +2 -2
- package/build/lowcode/preview.js +152 -152
- package/build/lowcode/render/default/view.css +1 -1
- package/build/lowcode/render/default/view.js +18 -10
- package/build/lowcode/view.css +1 -1
- package/build/lowcode/view.js +18 -10
- package/es/components/booking/notes/NoteBlock/index.js +3 -2
- package/es/components/eftposPay/store/index.d.ts +1 -1
- package/es/components/eventBooking/components/ErrorTip/index.d.ts +0 -1
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/WeekItem/index.d.ts +0 -1
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/index.d.ts +0 -1
- package/es/components/pay/toC/PaymentMethods/MWCreditCard/List/index.js +32 -16
- package/es/components/pay/toC/PaymentMethods/MWCreditCard/tds2.js +16 -10
- package/es/components/shoppingCart/components/Empty/index.d.ts +0 -1
- package/es/hooks/usePaymentLogger.d.ts +1 -0
- package/es/index.d.ts +4 -2
- package/es/index.js +3 -1
- package/es/plus/contactInfo/components/SwipeAction/index.js +1 -1
- package/es/plus/orderList/components/HandleActions.d.ts +1 -0
- package/es/plus/orderList/components/HandleActions.js +5 -2
- package/es/plus/orderList/components/Toolbar.d.ts +1 -0
- package/es/plus/orderList/components/Toolbar.js +4 -2
- package/es/plus/orderList/index.d.ts +1 -0
- package/es/plus/orderList/index.js +7 -2
- package/es/plus/pisellSalesGrid/PisellSalesGrid.d.ts +5 -0
- package/es/plus/pisellSalesGrid/PisellSalesGrid.js +363 -0
- package/es/plus/pisellSalesGrid/PisellSalesGrid.less +16 -0
- package/es/plus/pisellSalesGrid/PisellSalesGrid.stories.d.ts +14 -0
- package/es/plus/pisellSalesGrid/PisellSalesGrid.stories.js +559 -0
- package/es/plus/pisellSalesGrid/hooks/useActions.d.ts +19 -0
- package/es/plus/pisellSalesGrid/hooks/useActions.js +723 -0
- package/es/plus/pisellSalesGrid/index.d.ts +4 -0
- package/es/plus/pisellSalesGrid/index.js +3 -0
- package/es/plus/pisellSalesGrid/locales.d.ts +9 -0
- package/es/plus/pisellSalesGrid/locales.js +8 -0
- package/es/plus/pisellSalesGrid/serve.d.ts +19 -0
- package/es/plus/pisellSalesGrid/serve.js +151 -0
- package/es/plus/pisellSalesGrid/types.d.ts +170 -0
- package/es/plus/pisellSalesGrid/types.js +1 -0
- package/es/plus/pisellSalesManagement/components/BookingFormsPreview.d.ts +15 -0
- package/es/plus/pisellSalesManagement/components/BookingFormsPreview.js +211 -0
- package/es/plus/pisellSalesManagement/components/BookingNotesPreview.d.ts +19 -0
- package/es/plus/pisellSalesManagement/components/BookingNotesPreview.js +167 -0
- package/es/plus/pisellSalesManagement/components/ResourceSelector.d.ts +9 -0
- package/es/plus/pisellSalesManagement/components/ResourceSelector.js +102 -0
- package/es/plus/pisellSalesManagement/config/booking.d.ts +186 -0
- package/es/plus/pisellSalesManagement/config/booking.js +380 -0
- package/es/plus/pisellSalesManagement/config/index.d.ts +2 -0
- package/es/plus/pisellSalesManagement/config/index.js +11 -0
- package/es/plus/pisellSalesManagement/config/order.d.ts +172 -0
- package/es/plus/pisellSalesManagement/config/order.js +460 -0
- package/es/plus/pisellSalesManagement/hooks/perspectiveUtils.d.ts +15 -0
- package/es/plus/pisellSalesManagement/hooks/perspectiveUtils.js +66 -0
- package/es/plus/pisellSalesManagement/hooks/useBookingPerspective.d.ts +2 -0
- package/es/plus/pisellSalesManagement/hooks/useBookingPerspective.js +651 -0
- package/es/plus/pisellSalesManagement/hooks/useOrderPerspective.d.ts +2 -0
- package/es/plus/pisellSalesManagement/hooks/useOrderPerspective.js +656 -0
- package/es/plus/pisellSalesManagement/hooks/usePerspectives.d.ts +5 -0
- package/es/plus/pisellSalesManagement/hooks/usePerspectives.js +12 -0
- package/es/plus/pisellSalesManagement/index.d.ts +10 -0
- package/es/plus/pisellSalesManagement/index.js +84 -0
- package/es/plus/pisellSalesManagement/locales.d.ts +303 -0
- package/es/plus/pisellSalesManagement/locales.js +302 -0
- package/es/plus/pisellSalesManagement/serve.d.ts +26 -0
- package/es/plus/pisellSalesManagement/serve.js +222 -0
- package/es/plus/selectHolder/components/ErrorTip/index.d.ts +0 -1
- package/lib/components/booking/notes/NoteBlock/index.js +2 -1
- package/lib/components/eftposPay/store/index.d.ts +1 -1
- package/lib/components/eventBooking/components/ErrorTip/index.d.ts +0 -1
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/WeekItem/index.d.ts +0 -1
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/index.d.ts +0 -1
- package/lib/components/pay/toC/PaymentMethods/MWCreditCard/List/index.js +19 -11
- package/lib/components/pay/toC/PaymentMethods/MWCreditCard/tds2.js +21 -22
- package/lib/components/shoppingCart/components/Empty/index.d.ts +0 -1
- package/lib/hooks/usePaymentLogger.d.ts +1 -0
- package/lib/index.d.ts +4 -2
- package/lib/index.js +8 -2
- package/lib/plus/contactInfo/components/SwipeAction/index.js +23 -23
- package/lib/plus/orderList/components/HandleActions.d.ts +1 -0
- package/lib/plus/orderList/components/HandleActions.js +2 -2
- package/lib/plus/orderList/components/Toolbar.d.ts +1 -0
- package/lib/plus/orderList/components/Toolbar.js +2 -2
- package/lib/plus/orderList/index.d.ts +1 -0
- package/lib/plus/orderList/index.js +3 -3
- package/lib/plus/pisellSalesGrid/PisellSalesGrid.d.ts +5 -0
- package/lib/plus/pisellSalesGrid/PisellSalesGrid.js +339 -0
- package/lib/plus/pisellSalesGrid/PisellSalesGrid.less +16 -0
- package/lib/plus/pisellSalesGrid/PisellSalesGrid.stories.d.ts +14 -0
- package/lib/plus/pisellSalesGrid/PisellSalesGrid.stories.js +455 -0
- package/lib/plus/pisellSalesGrid/hooks/useActions.d.ts +19 -0
- package/lib/plus/pisellSalesGrid/hooks/useActions.js +545 -0
- package/lib/plus/pisellSalesGrid/index.d.ts +4 -0
- package/lib/plus/pisellSalesGrid/index.js +42 -0
- package/lib/plus/pisellSalesGrid/locales.d.ts +9 -0
- package/lib/plus/pisellSalesGrid/locales.js +29 -0
- package/lib/plus/pisellSalesGrid/serve.d.ts +19 -0
- package/lib/plus/pisellSalesGrid/serve.js +142 -0
- package/lib/plus/pisellSalesGrid/types.d.ts +170 -0
- package/lib/plus/pisellSalesGrid/types.js +17 -0
- package/lib/plus/pisellSalesManagement/components/BookingFormsPreview.d.ts +15 -0
- package/lib/plus/pisellSalesManagement/components/BookingFormsPreview.js +250 -0
- package/lib/plus/pisellSalesManagement/components/BookingNotesPreview.d.ts +19 -0
- package/lib/plus/pisellSalesManagement/components/BookingNotesPreview.js +193 -0
- package/lib/plus/pisellSalesManagement/components/ResourceSelector.d.ts +9 -0
- package/lib/plus/pisellSalesManagement/components/ResourceSelector.js +106 -0
- package/lib/plus/pisellSalesManagement/config/booking.d.ts +186 -0
- package/lib/plus/pisellSalesManagement/config/booking.js +500 -0
- package/lib/plus/pisellSalesManagement/config/index.d.ts +2 -0
- package/lib/plus/pisellSalesManagement/config/index.js +43 -0
- package/lib/plus/pisellSalesManagement/config/order.d.ts +172 -0
- package/lib/plus/pisellSalesManagement/config/order.js +492 -0
- package/lib/plus/pisellSalesManagement/hooks/perspectiveUtils.d.ts +15 -0
- package/lib/plus/pisellSalesManagement/hooks/perspectiveUtils.js +113 -0
- package/lib/plus/pisellSalesManagement/hooks/useBookingPerspective.d.ts +2 -0
- package/lib/plus/pisellSalesManagement/hooks/useBookingPerspective.js +699 -0
- package/lib/plus/pisellSalesManagement/hooks/useOrderPerspective.d.ts +2 -0
- package/lib/plus/pisellSalesManagement/hooks/useOrderPerspective.js +700 -0
- package/lib/plus/pisellSalesManagement/hooks/usePerspectives.d.ts +5 -0
- package/lib/plus/pisellSalesManagement/hooks/usePerspectives.js +42 -0
- package/lib/plus/pisellSalesManagement/index.d.ts +10 -0
- package/lib/plus/pisellSalesManagement/index.js +113 -0
- package/lib/plus/pisellSalesManagement/locales.d.ts +303 -0
- package/lib/plus/pisellSalesManagement/locales.js +326 -0
- package/lib/plus/pisellSalesManagement/serve.d.ts +26 -0
- package/lib/plus/pisellSalesManagement/serve.js +120 -0
- package/lib/plus/selectHolder/components/ErrorTip/index.d.ts +0 -1
- package/lowcode/eco-cup-list/meta.ts +1 -1
- package/lowcode/eco-customer-list/meta.ts +1 -1
- package/lowcode/pisell-sales-management/meta.ts +88 -0
- package/package.json +3 -3
|
@@ -0,0 +1,172 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* 获取支付状态映射
|
|
3
|
+
*/
|
|
4
|
+
export declare const getPaymentStatusMap: () => Record<string, string>;
|
|
5
|
+
export declare const PAYMENT_STATUS_COLOR_MAP: Record<string, string>;
|
|
6
|
+
export declare const getPlatformMap: () => Record<string, string>;
|
|
7
|
+
/**
|
|
8
|
+
* 获取订单状态映射
|
|
9
|
+
* @param locales - 多语言对象
|
|
10
|
+
*/
|
|
11
|
+
export declare const getOrderStatusMap: () => Record<string, string>;
|
|
12
|
+
export declare const ORDER_STATUS_COLOR_MAP: Record<string, {
|
|
13
|
+
borderColor: string;
|
|
14
|
+
textColor: string;
|
|
15
|
+
}>;
|
|
16
|
+
/**
|
|
17
|
+
* 获取处理状态映射
|
|
18
|
+
*/
|
|
19
|
+
export declare const getShippingStatusMap: () => Record<string, string>;
|
|
20
|
+
export declare const FULFILLMENT_STATUS_COLOR_MAP: Record<string, {
|
|
21
|
+
borderColor: string;
|
|
22
|
+
textColor: string;
|
|
23
|
+
}>;
|
|
24
|
+
/**
|
|
25
|
+
* 获取配送方式映射
|
|
26
|
+
*/
|
|
27
|
+
export declare const getDeliveryTypeMap: () => Record<string, string>;
|
|
28
|
+
/**
|
|
29
|
+
* 获取到店服务类型映射
|
|
30
|
+
* @param locales - 多语言对象
|
|
31
|
+
*/
|
|
32
|
+
export declare const getShopServiceTypeMap: () => Record<string, string>;
|
|
33
|
+
export declare const DELIVERY_TYPE_COLOR_MAP: Record<string, string>;
|
|
34
|
+
export declare const SHOP_SERVICE_TYPE_COLOR_MAP: Record<string, string>;
|
|
35
|
+
export declare const getOrderHeaderLabels: () => Record<string, string>;
|
|
36
|
+
export declare const defaultPaymentStatusKeys: string[];
|
|
37
|
+
export declare const getFilterButtonList: () => ({
|
|
38
|
+
name: string;
|
|
39
|
+
type: string;
|
|
40
|
+
key: string;
|
|
41
|
+
label: any;
|
|
42
|
+
other: {
|
|
43
|
+
allowClear: boolean;
|
|
44
|
+
mode: string;
|
|
45
|
+
maxTagCount: string;
|
|
46
|
+
placeholder: any;
|
|
47
|
+
options: {
|
|
48
|
+
label: string;
|
|
49
|
+
value: string;
|
|
50
|
+
}[];
|
|
51
|
+
isSearchServer?: undefined;
|
|
52
|
+
showSearch?: undefined;
|
|
53
|
+
minInputNumberProps?: undefined;
|
|
54
|
+
maxInputNumberProps?: undefined;
|
|
55
|
+
};
|
|
56
|
+
} | {
|
|
57
|
+
name: string;
|
|
58
|
+
type: string;
|
|
59
|
+
key: string;
|
|
60
|
+
label: any;
|
|
61
|
+
other: {
|
|
62
|
+
allowClear: boolean;
|
|
63
|
+
isSearchServer: boolean;
|
|
64
|
+
showSearch: boolean;
|
|
65
|
+
placeholder: any;
|
|
66
|
+
options: (params?: string) => Promise<any>;
|
|
67
|
+
mode?: undefined;
|
|
68
|
+
maxTagCount?: undefined;
|
|
69
|
+
minInputNumberProps?: undefined;
|
|
70
|
+
maxInputNumberProps?: undefined;
|
|
71
|
+
};
|
|
72
|
+
} | {
|
|
73
|
+
name: string;
|
|
74
|
+
type: string;
|
|
75
|
+
key: string;
|
|
76
|
+
label: any;
|
|
77
|
+
other: {
|
|
78
|
+
allowClear: boolean;
|
|
79
|
+
mode: string;
|
|
80
|
+
maxTagCount: string;
|
|
81
|
+
placeholder: any;
|
|
82
|
+
options: () => Promise<any>;
|
|
83
|
+
isSearchServer?: undefined;
|
|
84
|
+
showSearch?: undefined;
|
|
85
|
+
minInputNumberProps?: undefined;
|
|
86
|
+
maxInputNumberProps?: undefined;
|
|
87
|
+
};
|
|
88
|
+
} | {
|
|
89
|
+
name: string;
|
|
90
|
+
type: string;
|
|
91
|
+
key: string;
|
|
92
|
+
label: any;
|
|
93
|
+
other: {
|
|
94
|
+
placeholder: any;
|
|
95
|
+
minInputNumberProps: {
|
|
96
|
+
min: number;
|
|
97
|
+
};
|
|
98
|
+
maxInputNumberProps: {
|
|
99
|
+
min: number;
|
|
100
|
+
};
|
|
101
|
+
allowClear?: undefined;
|
|
102
|
+
mode?: undefined;
|
|
103
|
+
maxTagCount?: undefined;
|
|
104
|
+
options?: undefined;
|
|
105
|
+
isSearchServer?: undefined;
|
|
106
|
+
showSearch?: undefined;
|
|
107
|
+
};
|
|
108
|
+
} | {
|
|
109
|
+
name: string;
|
|
110
|
+
type: string;
|
|
111
|
+
key: string;
|
|
112
|
+
label: any;
|
|
113
|
+
other: {
|
|
114
|
+
allowClear: boolean;
|
|
115
|
+
mode: string;
|
|
116
|
+
maxTagCount: string;
|
|
117
|
+
isSearchServer: boolean;
|
|
118
|
+
showSearch: boolean;
|
|
119
|
+
placeholder: any;
|
|
120
|
+
options: (params?: string) => Promise<any>;
|
|
121
|
+
minInputNumberProps?: undefined;
|
|
122
|
+
maxInputNumberProps?: undefined;
|
|
123
|
+
};
|
|
124
|
+
} | {
|
|
125
|
+
name: string;
|
|
126
|
+
type: string;
|
|
127
|
+
key: string;
|
|
128
|
+
label: any;
|
|
129
|
+
other: {
|
|
130
|
+
placeholder: any;
|
|
131
|
+
allowClear?: undefined;
|
|
132
|
+
mode?: undefined;
|
|
133
|
+
maxTagCount?: undefined;
|
|
134
|
+
options?: undefined;
|
|
135
|
+
isSearchServer?: undefined;
|
|
136
|
+
showSearch?: undefined;
|
|
137
|
+
minInputNumberProps?: undefined;
|
|
138
|
+
maxInputNumberProps?: undefined;
|
|
139
|
+
};
|
|
140
|
+
} | {
|
|
141
|
+
name: string;
|
|
142
|
+
type: string;
|
|
143
|
+
key: string;
|
|
144
|
+
label: any;
|
|
145
|
+
other: {
|
|
146
|
+
allowClear: boolean;
|
|
147
|
+
placeholder: any;
|
|
148
|
+
options: () => Promise<any>;
|
|
149
|
+
mode?: undefined;
|
|
150
|
+
maxTagCount?: undefined;
|
|
151
|
+
isSearchServer?: undefined;
|
|
152
|
+
showSearch?: undefined;
|
|
153
|
+
minInputNumberProps?: undefined;
|
|
154
|
+
maxInputNumberProps?: undefined;
|
|
155
|
+
};
|
|
156
|
+
})[];
|
|
157
|
+
export declare const getSortList: () => ({
|
|
158
|
+
type: string;
|
|
159
|
+
isCustom: boolean;
|
|
160
|
+
name: string;
|
|
161
|
+
label: any;
|
|
162
|
+
getSortItems: () => {
|
|
163
|
+
key: string;
|
|
164
|
+
label: any;
|
|
165
|
+
}[];
|
|
166
|
+
} | {
|
|
167
|
+
type: string;
|
|
168
|
+
isCustom: boolean;
|
|
169
|
+
name: string;
|
|
170
|
+
label: any;
|
|
171
|
+
getSortItems?: undefined;
|
|
172
|
+
})[];
|
|
@@ -0,0 +1,492 @@
|
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
+
var __export = (target, all) => {
|
|
6
|
+
for (var name in all)
|
|
7
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
8
|
+
};
|
|
9
|
+
var __copyProps = (to, from, except, desc) => {
|
|
10
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
11
|
+
for (let key of __getOwnPropNames(from))
|
|
12
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
13
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
14
|
+
}
|
|
15
|
+
return to;
|
|
16
|
+
};
|
|
17
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
18
|
+
|
|
19
|
+
// src/plus/pisellSalesManagement/config/order.ts
|
|
20
|
+
var order_exports = {};
|
|
21
|
+
__export(order_exports, {
|
|
22
|
+
DELIVERY_TYPE_COLOR_MAP: () => DELIVERY_TYPE_COLOR_MAP,
|
|
23
|
+
FULFILLMENT_STATUS_COLOR_MAP: () => FULFILLMENT_STATUS_COLOR_MAP,
|
|
24
|
+
ORDER_STATUS_COLOR_MAP: () => ORDER_STATUS_COLOR_MAP,
|
|
25
|
+
PAYMENT_STATUS_COLOR_MAP: () => PAYMENT_STATUS_COLOR_MAP,
|
|
26
|
+
SHOP_SERVICE_TYPE_COLOR_MAP: () => SHOP_SERVICE_TYPE_COLOR_MAP,
|
|
27
|
+
defaultPaymentStatusKeys: () => defaultPaymentStatusKeys,
|
|
28
|
+
getDeliveryTypeMap: () => getDeliveryTypeMap,
|
|
29
|
+
getFilterButtonList: () => getFilterButtonList,
|
|
30
|
+
getOrderHeaderLabels: () => getOrderHeaderLabels,
|
|
31
|
+
getOrderStatusMap: () => getOrderStatusMap,
|
|
32
|
+
getPaymentStatusMap: () => getPaymentStatusMap,
|
|
33
|
+
getPlatformMap: () => getPlatformMap,
|
|
34
|
+
getShippingStatusMap: () => getShippingStatusMap,
|
|
35
|
+
getShopServiceTypeMap: () => getShopServiceTypeMap,
|
|
36
|
+
getSortList: () => getSortList
|
|
37
|
+
});
|
|
38
|
+
module.exports = __toCommonJS(order_exports);
|
|
39
|
+
var import_utils = require("@pisell/utils");
|
|
40
|
+
var import_serve = require("./../../orderList/serve");
|
|
41
|
+
var getPaymentStatusMap = () => ({
|
|
42
|
+
authorized: import_utils.locales.getText("pisell2.orderList.paymentStatus.authorized"),
|
|
43
|
+
paid: import_utils.locales.getText("pisell2.orderList.paymentStatus.paid"),
|
|
44
|
+
partially_paid: import_utils.locales.getText(
|
|
45
|
+
"pisell2.orderList.paymentStatus.partially_paid"
|
|
46
|
+
),
|
|
47
|
+
partially_refunded: import_utils.locales.getText(
|
|
48
|
+
"pisell2.orderList.paymentStatus.partially_refunded"
|
|
49
|
+
),
|
|
50
|
+
refunded: import_utils.locales.getText("pisell2.orderList.paymentStatus.refunded"),
|
|
51
|
+
unpaid: import_utils.locales.getText("pisell2.orderList.paymentStatus.unpaid"),
|
|
52
|
+
voided: import_utils.locales.getText("pisell2.orderList.paymentStatus.voided"),
|
|
53
|
+
payment_processing: import_utils.locales.getText(
|
|
54
|
+
"pisell2.orderList.paymentStatus.payment_processing"
|
|
55
|
+
)
|
|
56
|
+
});
|
|
57
|
+
var PAYMENT_STATUS_COLOR_MAP = {
|
|
58
|
+
unpaid: "#B2DDFF",
|
|
59
|
+
payment_processing: "#FEDF89",
|
|
60
|
+
authorized: "#ABEFC6",
|
|
61
|
+
paid: "#ABEFC6",
|
|
62
|
+
partially_paid: "#CEEAB0",
|
|
63
|
+
refunded: "#FECDCA",
|
|
64
|
+
partially_refunded: "#FCCEEE",
|
|
65
|
+
voided: "#D0D5DD"
|
|
66
|
+
};
|
|
67
|
+
var getPlatformMap = () => ({
|
|
68
|
+
online_store: import_utils.locales.getText("pisell2.orderList.platform.online_store"),
|
|
69
|
+
wholesalebusiness: import_utils.locales.getText(
|
|
70
|
+
"pisell2.orderList.platform.wholesalebusiness"
|
|
71
|
+
),
|
|
72
|
+
"table-order": import_utils.locales.getText("pisell2.orderList.platform.table-order"),
|
|
73
|
+
mobile_order: import_utils.locales.getText("pisell2.orderList.platform.mobile_order"),
|
|
74
|
+
kiosk: import_utils.locales.getText("pisell2.orderList.platform.kiosk"),
|
|
75
|
+
pos: import_utils.locales.getText("pisell2.orderList.platform.pos")
|
|
76
|
+
});
|
|
77
|
+
var getOrderStatusMap = () => ({
|
|
78
|
+
open: import_utils.locales.getText("pisell2.orderList.orderStatus.open"),
|
|
79
|
+
completed: import_utils.locales.getText("pisell2.orderList.orderStatus.completed"),
|
|
80
|
+
cancelled: import_utils.locales.getText("pisell2.orderList.orderStatus.cancelled")
|
|
81
|
+
});
|
|
82
|
+
var ORDER_STATUS_COLOR_MAP = {
|
|
83
|
+
open: { borderColor: "#1570EF", textColor: "#175CD3" },
|
|
84
|
+
completed: { borderColor: "#079455", textColor: "#067647" },
|
|
85
|
+
cancelled: { borderColor: "#D92D20", textColor: "#B42318" }
|
|
86
|
+
};
|
|
87
|
+
var getShippingStatusMap = () => ({
|
|
88
|
+
fulfilled: import_utils.locales.getText("pisell2.orderList.shippingStatus.falseulfilled"),
|
|
89
|
+
unfulfilled: import_utils.locales.getText("pisell2.orderList.shippingStatus.unfulfilled"),
|
|
90
|
+
fulfilling: import_utils.locales.getText("pisell2.orderList.shippingStatus.fulfilling"),
|
|
91
|
+
partial_fulfilled: import_utils.locales.getText(
|
|
92
|
+
"pisell2.orderList.shippingStatus.partial_fulfilled"
|
|
93
|
+
)
|
|
94
|
+
});
|
|
95
|
+
var FULFILLMENT_STATUS_COLOR_MAP = {
|
|
96
|
+
fulfilling: { borderColor: "#DC6803", textColor: "#B54708" },
|
|
97
|
+
unfulfilled: { borderColor: "#DC6803", textColor: "#B54708" },
|
|
98
|
+
partial_fulfilled: { borderColor: "#088AB2", textColor: "#0E7090" },
|
|
99
|
+
fulfilled: { borderColor: "#475467", textColor: "#344054" }
|
|
100
|
+
};
|
|
101
|
+
var getDeliveryTypeMap = () => ({
|
|
102
|
+
nil: import_utils.locales.getText("pisell2.orderList.deliveryType.nil"),
|
|
103
|
+
shipping: import_utils.locales.getText("pisell2.orderList.deliveryType.shipping"),
|
|
104
|
+
local_delivery: import_utils.locales.getText(
|
|
105
|
+
"pisell2.orderList.deliveryType.local_delivery"
|
|
106
|
+
),
|
|
107
|
+
pickup: import_utils.locales.getText("pisell2.orderList.deliveryType.pickup"),
|
|
108
|
+
shop_service: import_utils.locales.getText("pisell2.orderList.deliveryType.shop_service")
|
|
109
|
+
});
|
|
110
|
+
var getShopServiceTypeMap = () => ({
|
|
111
|
+
"dine-in": import_utils.locales.getText("pisell2.orderList.shopServiceType.dine-in"),
|
|
112
|
+
takeaway: import_utils.locales.getText("pisell2.orderList.shopServiceType.takeaway")
|
|
113
|
+
});
|
|
114
|
+
var DELIVERY_TYPE_COLOR_MAP = {
|
|
115
|
+
shipping: "",
|
|
116
|
+
local_delivery: "orange",
|
|
117
|
+
pickup: "blue"
|
|
118
|
+
};
|
|
119
|
+
var SHOP_SERVICE_TYPE_COLOR_MAP = {
|
|
120
|
+
"dine-in": "green",
|
|
121
|
+
takeaway: "red"
|
|
122
|
+
};
|
|
123
|
+
var getOrderHeaderLabels = () => ({
|
|
124
|
+
saleBrief: import_utils.locales.getText("pisell2.salesManagement.order.column.saleBrief"),
|
|
125
|
+
customer: import_utils.locales.getText("pisell2.salesManagement.order.column.customer"),
|
|
126
|
+
contact: import_utils.locales.getText("pisell2.salesManagement.order.column.contact"),
|
|
127
|
+
paymentInfo: import_utils.locales.getText(
|
|
128
|
+
"pisell2.salesManagement.order.column.paymentInfo"
|
|
129
|
+
),
|
|
130
|
+
items: import_utils.locales.getText("pisell2.salesManagement.order.column.items"),
|
|
131
|
+
paymentStatus: import_utils.locales.getText(
|
|
132
|
+
"pisell2.salesManagement.order.column.paymentStatus"
|
|
133
|
+
),
|
|
134
|
+
orderOrigin: import_utils.locales.getText(
|
|
135
|
+
"pisell2.salesManagement.order.column.orderOrigin"
|
|
136
|
+
),
|
|
137
|
+
shippingMethod: import_utils.locales.getText(
|
|
138
|
+
"pisell2.salesManagement.order.column.shippingMethod"
|
|
139
|
+
),
|
|
140
|
+
orderStatus: import_utils.locales.getText(
|
|
141
|
+
"pisell2.salesManagement.order.column.orderStatus"
|
|
142
|
+
),
|
|
143
|
+
fulfillmentStatus: import_utils.locales.getText(
|
|
144
|
+
"pisell2.salesManagement.order.column.fulfillmentStatus"
|
|
145
|
+
),
|
|
146
|
+
updated: import_utils.locales.getText("pisell2.salesManagement.order.column.updated"),
|
|
147
|
+
orderId: import_utils.locales.getText("pisell2.salesManagement.order.column.orderId"),
|
|
148
|
+
orderNote: import_utils.locales.getText("pisell2.salesManagement.order.common.orderNote"),
|
|
149
|
+
internalNote: import_utils.locales.getText(
|
|
150
|
+
"pisell2.salesManagement.order.common.internalNote"
|
|
151
|
+
),
|
|
152
|
+
createdBy: import_utils.locales.getText("pisell2.salesManagement.order.common.createdBy"),
|
|
153
|
+
guest: import_utils.locales.getText("pisell2.salesManagement.order.common.guest"),
|
|
154
|
+
walkIn: import_utils.locales.getText("pisell2.salesManagement.order.common.walkIn")
|
|
155
|
+
});
|
|
156
|
+
var defaultPaymentStatusKeys = [
|
|
157
|
+
"payment_processing",
|
|
158
|
+
"partially_paid",
|
|
159
|
+
"paid",
|
|
160
|
+
"partially_refunded",
|
|
161
|
+
"refunded"
|
|
162
|
+
];
|
|
163
|
+
var getFilterButtonList = () => {
|
|
164
|
+
const ORDER_STATUS_MAP = getOrderStatusMap();
|
|
165
|
+
const PAYMENT_STATUS_MAP = getPaymentStatusMap();
|
|
166
|
+
const SHIPPING_STATUS_MAP = getShippingStatusMap();
|
|
167
|
+
const DELIVERY_TYPE_MAP = getDeliveryTypeMap();
|
|
168
|
+
return [
|
|
169
|
+
{
|
|
170
|
+
name: "status",
|
|
171
|
+
type: "single",
|
|
172
|
+
key: "status",
|
|
173
|
+
label: import_utils.locales.getText("pisell2.orderList.filter.orderStatus.label"),
|
|
174
|
+
other: {
|
|
175
|
+
allowClear: true,
|
|
176
|
+
mode: "multiple",
|
|
177
|
+
maxTagCount: "responsive",
|
|
178
|
+
placeholder: import_utils.locales.getText(
|
|
179
|
+
"pisell2.orderList.filter.orderStatus.placeholder"
|
|
180
|
+
),
|
|
181
|
+
options: Object.entries(ORDER_STATUS_MAP).map(([key, value]) => ({
|
|
182
|
+
label: value,
|
|
183
|
+
value: key
|
|
184
|
+
}))
|
|
185
|
+
}
|
|
186
|
+
},
|
|
187
|
+
{
|
|
188
|
+
name: "payment_status",
|
|
189
|
+
type: "single",
|
|
190
|
+
key: "payment_status",
|
|
191
|
+
label: import_utils.locales.getText("pisell2.orderList.filter.paymentStatus.label"),
|
|
192
|
+
other: {
|
|
193
|
+
allowClear: true,
|
|
194
|
+
mode: "multiple",
|
|
195
|
+
maxTagCount: "responsive",
|
|
196
|
+
placeholder: import_utils.locales.getText(
|
|
197
|
+
"pisell2.orderList.filter.paymentStatus.placeholder"
|
|
198
|
+
),
|
|
199
|
+
options: Object.entries(PAYMENT_STATUS_MAP).map(([key, value]) => ({
|
|
200
|
+
label: value,
|
|
201
|
+
value: key
|
|
202
|
+
}))
|
|
203
|
+
}
|
|
204
|
+
},
|
|
205
|
+
{
|
|
206
|
+
name: "shipping_status",
|
|
207
|
+
type: "single",
|
|
208
|
+
key: "shipping_status",
|
|
209
|
+
label: import_utils.locales.getText("pisell2.orderList.filter.shippingStatus.label"),
|
|
210
|
+
other: {
|
|
211
|
+
allowClear: true,
|
|
212
|
+
mode: "multiple",
|
|
213
|
+
maxTagCount: "responsive",
|
|
214
|
+
placeholder: import_utils.locales.getText(
|
|
215
|
+
"pisell2.orderList.filter.shippingStatus.placeholder"
|
|
216
|
+
),
|
|
217
|
+
options: Object.entries(SHIPPING_STATUS_MAP).map(([key, value]) => ({
|
|
218
|
+
label: value,
|
|
219
|
+
value: key
|
|
220
|
+
}))
|
|
221
|
+
}
|
|
222
|
+
},
|
|
223
|
+
{
|
|
224
|
+
name: "customer_id",
|
|
225
|
+
type: "single",
|
|
226
|
+
key: "customer_id",
|
|
227
|
+
label: import_utils.locales.getText("pisell2.orderList.filter.customer.label"),
|
|
228
|
+
other: {
|
|
229
|
+
allowClear: true,
|
|
230
|
+
isSearchServer: true,
|
|
231
|
+
showSearch: true,
|
|
232
|
+
placeholder: import_utils.locales.getText(
|
|
233
|
+
"pisell2.orderList.filter.customer.placeholder"
|
|
234
|
+
),
|
|
235
|
+
options: (params) => (0, import_serve.getCustomerSelectOptions)(params).then(
|
|
236
|
+
(res) => res.map((item) => ({
|
|
237
|
+
label: item.display_name,
|
|
238
|
+
value: item.id
|
|
239
|
+
}))
|
|
240
|
+
)
|
|
241
|
+
}
|
|
242
|
+
},
|
|
243
|
+
{
|
|
244
|
+
name: "order_sales_channel",
|
|
245
|
+
type: "single",
|
|
246
|
+
key: "order_sales_channel",
|
|
247
|
+
label: import_utils.locales.getText("pisell2.orderList.filter.salesChannel.label"),
|
|
248
|
+
other: {
|
|
249
|
+
allowClear: true,
|
|
250
|
+
mode: "multiple",
|
|
251
|
+
maxTagCount: "responsive",
|
|
252
|
+
placeholder: import_utils.locales.getText(
|
|
253
|
+
"pisell2.orderList.filter.salesChannel.placeholder"
|
|
254
|
+
),
|
|
255
|
+
options: () => (0, import_serve.getChannelSelectOptions)().then(
|
|
256
|
+
(res) => res.map((item) => ({
|
|
257
|
+
label: item.name,
|
|
258
|
+
value: item.code
|
|
259
|
+
}))
|
|
260
|
+
)
|
|
261
|
+
}
|
|
262
|
+
},
|
|
263
|
+
{
|
|
264
|
+
name: "payment_methods",
|
|
265
|
+
type: "single",
|
|
266
|
+
key: "payment_methods",
|
|
267
|
+
label: import_utils.locales.getText("pisell2.orderList.filter.paymentMethod.label"),
|
|
268
|
+
other: {
|
|
269
|
+
allowClear: true,
|
|
270
|
+
mode: "multiple",
|
|
271
|
+
maxTagCount: "responsive",
|
|
272
|
+
placeholder: import_utils.locales.getText(
|
|
273
|
+
"pisell2.orderList.filter.paymentMethod.placeholder"
|
|
274
|
+
),
|
|
275
|
+
options: () => (0, import_serve.getPaymentSelectOptions)().then((res) => {
|
|
276
|
+
const map = new Map(
|
|
277
|
+
res.map((item) => [
|
|
278
|
+
item.code,
|
|
279
|
+
{ label: item.name, value: item.code }
|
|
280
|
+
])
|
|
281
|
+
);
|
|
282
|
+
return Array.from(map.values());
|
|
283
|
+
})
|
|
284
|
+
}
|
|
285
|
+
},
|
|
286
|
+
{
|
|
287
|
+
name: "total_amount",
|
|
288
|
+
//max_total_amount 分两个字段
|
|
289
|
+
type: "numberRange",
|
|
290
|
+
key: "total_amount",
|
|
291
|
+
label: import_utils.locales.getText("pisell2.orderList.filter.totalAmount.label"),
|
|
292
|
+
other: {
|
|
293
|
+
placeholder: import_utils.locales.getText(
|
|
294
|
+
"pisell2.orderList.filter.totalAmount.placeholder"
|
|
295
|
+
),
|
|
296
|
+
minInputNumberProps: {
|
|
297
|
+
min: 0
|
|
298
|
+
},
|
|
299
|
+
maxInputNumberProps: {
|
|
300
|
+
min: 0
|
|
301
|
+
}
|
|
302
|
+
}
|
|
303
|
+
},
|
|
304
|
+
{
|
|
305
|
+
name: "tag_ids",
|
|
306
|
+
type: "single",
|
|
307
|
+
key: "tag_ids",
|
|
308
|
+
label: import_utils.locales.getText("pisell2.orderList.filter.tags.label"),
|
|
309
|
+
other: {
|
|
310
|
+
allowClear: true,
|
|
311
|
+
mode: "multiple",
|
|
312
|
+
maxTagCount: "responsive",
|
|
313
|
+
isSearchServer: true,
|
|
314
|
+
showSearch: true,
|
|
315
|
+
placeholder: import_utils.locales.getText(
|
|
316
|
+
"pisell2.orderList.filter.tags.placeholder"
|
|
317
|
+
),
|
|
318
|
+
options: (params) => (0, import_serve.getTagSelectOptions)(params).then(
|
|
319
|
+
(res) => res.map((item) => ({
|
|
320
|
+
label: item.name,
|
|
321
|
+
value: item.id
|
|
322
|
+
}))
|
|
323
|
+
)
|
|
324
|
+
}
|
|
325
|
+
},
|
|
326
|
+
{
|
|
327
|
+
name: "shipping_type",
|
|
328
|
+
type: "single",
|
|
329
|
+
key: "shipping_type",
|
|
330
|
+
label: import_utils.locales.getText("pisell2.orderList.filter.shippingType.label"),
|
|
331
|
+
other: {
|
|
332
|
+
allowClear: true,
|
|
333
|
+
mode: "multiple",
|
|
334
|
+
maxTagCount: "responsive",
|
|
335
|
+
placeholder: import_utils.locales.getText(
|
|
336
|
+
"pisell2.orderList.filter.shippingType.placeholder"
|
|
337
|
+
),
|
|
338
|
+
options: Object.entries(DELIVERY_TYPE_MAP).filter(([key]) => !["nil", "shop_service"].includes(key)).map(([key, value]) => ({
|
|
339
|
+
label: value,
|
|
340
|
+
value: key
|
|
341
|
+
}))
|
|
342
|
+
}
|
|
343
|
+
},
|
|
344
|
+
{
|
|
345
|
+
name: "delivery_zone_name",
|
|
346
|
+
type: "text",
|
|
347
|
+
key: "delivery_zone_name",
|
|
348
|
+
label: import_utils.locales.getText("pisell2.orderList.filter.deliveryZone.label"),
|
|
349
|
+
other: {
|
|
350
|
+
placeholder: import_utils.locales.getText(
|
|
351
|
+
"pisell2.orderList.filter.deliveryZone.placeholder"
|
|
352
|
+
)
|
|
353
|
+
}
|
|
354
|
+
},
|
|
355
|
+
{
|
|
356
|
+
name: "location_id",
|
|
357
|
+
type: "single",
|
|
358
|
+
key: "location_id",
|
|
359
|
+
label: import_utils.locales.getText("pisell2.orderList.filter.pickupLocation.label"),
|
|
360
|
+
other: {
|
|
361
|
+
allowClear: true,
|
|
362
|
+
placeholder: import_utils.locales.getText(
|
|
363
|
+
"pisell2.orderList.filter.pickupLocation.placeholder"
|
|
364
|
+
),
|
|
365
|
+
options: () => (0, import_serve.getLocationSelectOptions)().then(
|
|
366
|
+
(res) => res.map((item) => ({
|
|
367
|
+
label: item.name,
|
|
368
|
+
value: item.id
|
|
369
|
+
}))
|
|
370
|
+
)
|
|
371
|
+
}
|
|
372
|
+
},
|
|
373
|
+
{
|
|
374
|
+
name: "shipping_order_number",
|
|
375
|
+
type: "text",
|
|
376
|
+
key: "shipping_order_number",
|
|
377
|
+
label: import_utils.locales.getText("pisell2.orderList.filter.trackingNumber.label"),
|
|
378
|
+
other: {
|
|
379
|
+
placeholder: import_utils.locales.getText(
|
|
380
|
+
"pisell2.orderList.filter.trackingNumber.placeholder"
|
|
381
|
+
)
|
|
382
|
+
}
|
|
383
|
+
},
|
|
384
|
+
{
|
|
385
|
+
name: "logistics_company_id",
|
|
386
|
+
type: "single",
|
|
387
|
+
key: "logistics_company_id",
|
|
388
|
+
label: import_utils.locales.getText("pisell2.orderList.filter.logistics.label"),
|
|
389
|
+
other: {
|
|
390
|
+
allowClear: true,
|
|
391
|
+
mode: "multiple",
|
|
392
|
+
maxTagCount: "responsive",
|
|
393
|
+
placeholder: import_utils.locales.getText(
|
|
394
|
+
"pisell2.orderList.filter.logistics.placeholder"
|
|
395
|
+
),
|
|
396
|
+
options: () => (0, import_serve.getLogisticsSelectOptions)().then(
|
|
397
|
+
(res) => res.map((item) => ({
|
|
398
|
+
label: item.name,
|
|
399
|
+
value: item.id
|
|
400
|
+
}))
|
|
401
|
+
)
|
|
402
|
+
}
|
|
403
|
+
},
|
|
404
|
+
{
|
|
405
|
+
name: "zip",
|
|
406
|
+
type: "text",
|
|
407
|
+
key: "zip",
|
|
408
|
+
label: import_utils.locales.getText("pisell2.orderList.filter.zipCode.label"),
|
|
409
|
+
other: {
|
|
410
|
+
placeholder: import_utils.locales.getText(
|
|
411
|
+
"pisell2.orderList.filter.zipCode.placeholder"
|
|
412
|
+
)
|
|
413
|
+
}
|
|
414
|
+
}
|
|
415
|
+
];
|
|
416
|
+
};
|
|
417
|
+
var getSortList = () => {
|
|
418
|
+
return [
|
|
419
|
+
{
|
|
420
|
+
type: "time",
|
|
421
|
+
isCustom: true,
|
|
422
|
+
name: "created_at",
|
|
423
|
+
label: import_utils.locales.getText("pisell2.orderList.sort.createdAt"),
|
|
424
|
+
getSortItems: () => {
|
|
425
|
+
return [
|
|
426
|
+
{
|
|
427
|
+
key: "created_at:asc",
|
|
428
|
+
label: import_utils.locales.getText("pisell2.salesManagement.sort.oldestFirst")
|
|
429
|
+
},
|
|
430
|
+
{
|
|
431
|
+
key: "created_at:desc",
|
|
432
|
+
label: import_utils.locales.getText("pisell2.salesManagement.sort.newestFirst")
|
|
433
|
+
}
|
|
434
|
+
];
|
|
435
|
+
}
|
|
436
|
+
},
|
|
437
|
+
{
|
|
438
|
+
type: "time",
|
|
439
|
+
isCustom: true,
|
|
440
|
+
name: "updated_at",
|
|
441
|
+
label: import_utils.locales.getText("pisell2.orderList.sort.updatedAt"),
|
|
442
|
+
getSortItems: () => {
|
|
443
|
+
return [
|
|
444
|
+
{
|
|
445
|
+
key: "updated_at:asc",
|
|
446
|
+
label: import_utils.locales.getText("pisell2.salesManagement.sort.oldestFirst")
|
|
447
|
+
},
|
|
448
|
+
{
|
|
449
|
+
key: "updated_at:desc",
|
|
450
|
+
label: import_utils.locales.getText("pisell2.salesManagement.sort.newestFirst")
|
|
451
|
+
}
|
|
452
|
+
];
|
|
453
|
+
}
|
|
454
|
+
},
|
|
455
|
+
{
|
|
456
|
+
type: "number",
|
|
457
|
+
isCustom: false,
|
|
458
|
+
name: "total_amount",
|
|
459
|
+
label: import_utils.locales.getText("pisell2.orderList.sort.totalAmount")
|
|
460
|
+
},
|
|
461
|
+
{
|
|
462
|
+
type: "number",
|
|
463
|
+
isCustom: false,
|
|
464
|
+
name: "amount_gap",
|
|
465
|
+
label: import_utils.locales.getText("pisell2.salesManagement.sort.balanceDue")
|
|
466
|
+
},
|
|
467
|
+
{
|
|
468
|
+
type: "string",
|
|
469
|
+
isCustom: false,
|
|
470
|
+
name: "customer_name",
|
|
471
|
+
label: import_utils.locales.getText("pisell2.orderList.sort.customerName")
|
|
472
|
+
}
|
|
473
|
+
];
|
|
474
|
+
};
|
|
475
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
476
|
+
0 && (module.exports = {
|
|
477
|
+
DELIVERY_TYPE_COLOR_MAP,
|
|
478
|
+
FULFILLMENT_STATUS_COLOR_MAP,
|
|
479
|
+
ORDER_STATUS_COLOR_MAP,
|
|
480
|
+
PAYMENT_STATUS_COLOR_MAP,
|
|
481
|
+
SHOP_SERVICE_TYPE_COLOR_MAP,
|
|
482
|
+
defaultPaymentStatusKeys,
|
|
483
|
+
getDeliveryTypeMap,
|
|
484
|
+
getFilterButtonList,
|
|
485
|
+
getOrderHeaderLabels,
|
|
486
|
+
getOrderStatusMap,
|
|
487
|
+
getPaymentStatusMap,
|
|
488
|
+
getPlatformMap,
|
|
489
|
+
getShippingStatusMap,
|
|
490
|
+
getShopServiceTypeMap,
|
|
491
|
+
getSortList
|
|
492
|
+
});
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export declare const Tag: any;
|
|
2
|
+
export declare const formatAmount: (value: any, currencySymbol?: string) => string;
|
|
3
|
+
export declare const getDisplayLines: (items: Array<string | undefined | null>) => (string | null | undefined)[];
|
|
4
|
+
export declare const textStyles: {
|
|
5
|
+
text: {
|
|
6
|
+
fontSize: number;
|
|
7
|
+
color: string;
|
|
8
|
+
lineHeight: string;
|
|
9
|
+
};
|
|
10
|
+
};
|
|
11
|
+
export declare const formatDateTime: (value?: string) => string;
|
|
12
|
+
export declare const buildDateTime: (date?: string, time?: string) => string;
|
|
13
|
+
export declare const normalizeList: (value: any) => any[];
|
|
14
|
+
export declare const parseJson: (value: any) => any;
|
|
15
|
+
export declare const formatPhone: (value: any, countryCallingCode?: any) => string;
|