@pisell/private-materials 6.4.6 → 6.4.7
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/meta.js +1 -1
- package/build/lowcode/render/default/view.js +1 -1
- package/build/lowcode/view.js +1 -1
- package/es/businessModel/SalesModel/index.d.ts +0 -1
- package/es/components/Sales/Summary/utils.d.ts +1 -1
- package/es/components/appointmentBooking/components/Cart/Item/index.d.ts +1 -0
- package/es/components/appointmentBooking/components/Header/index.d.ts +0 -1
- package/es/components/appointmentBooking/components/Voucher/index.d.ts +0 -1
- package/es/components/appointmentBooking/deposit/index.d.ts +0 -1
- package/es/components/booking/addons/model.d.ts +10 -1
- package/es/components/booking/components/reloadResourceModal/index.d.ts +0 -1
- package/es/components/booking/deposit/index.d.ts +0 -1
- package/es/components/booking/forms/footer.d.ts +1 -0
- package/es/components/booking/forms/model.d.ts +10 -1
- package/es/components/booking/hooks/useQuotation.d.ts +0 -1
- package/es/components/booking/info/addServiceVariant/index.d.ts +0 -1
- package/es/components/booking/info/header/index.d.ts +0 -1
- package/es/components/booking/info/hooks/useInfoHolder.d.ts +0 -1
- package/es/components/booking/info/index.d.ts +0 -1
- package/es/components/booking/info/model.d.ts +10 -1
- package/es/components/booking/info/notes/index.d.ts +0 -1
- package/es/components/booking/info/service/Lists.d.ts +0 -1
- package/es/components/booking/info/service/addService/utils.d.ts +1 -1
- package/es/components/booking/info/service/editService/BookingList/index.d.ts +0 -1
- package/es/components/booking/info/service/serviceItem/index.d.ts +0 -1
- package/es/components/booking/info/service/serviceList/index.d.ts +0 -1
- package/es/components/booking/info/service2/Lists.d.ts +0 -1
- package/es/components/booking/info2/service/addService/index.d.ts +0 -1
- package/es/components/booking/info2/service/addService/utils.d.ts +1 -1
- package/es/components/booking/info2/service/serviceItem/index.d.ts +0 -1
- package/es/components/booking/info2/service/serviceList/index.d.ts +0 -1
- package/es/components/booking/model.d.ts +9 -1
- package/es/components/booking/notes/NoteBlock/index.d.ts +0 -1
- package/es/components/booking/notes/addNote/index.d.ts +0 -1
- package/es/components/booking/notes/model.d.ts +10 -1
- package/es/components/booking/payments/model.d.ts +10 -1
- package/es/components/booking/utils.d.ts +2 -2
- package/es/components/checkout/PaymentModal.js +2 -2
- package/es/components/checkout/PaymentPlugin.d.ts +0 -1
- package/es/components/checkout/components/SearchAndClientModule/index.d.ts +0 -1
- package/es/components/checkout/components/WalletPassModule/components/DiscountWallet/index.d.ts +0 -1
- package/es/components/checkout/utils/PaymentResultToastUtils.js +2 -1
- package/es/components/eftpos/surcharge/index.d.ts +0 -1
- package/es/components/eftposPay/app.d.ts +0 -1
- package/es/components/eftposPay/component/fail/failCustom.d.ts +1 -0
- package/es/components/eftposPay/component/fail/index.d.ts +1 -0
- package/es/components/eftposPay/component/fail/unknow.d.ts +1 -0
- package/es/components/eftposPay/hooks.d.ts +2 -2
- package/es/components/eftposPay/linkly/index.d.ts +0 -1
- package/es/components/eftposPay/pay.d.ts +1 -0
- package/es/components/eftposPay/store/index.d.ts +6 -6
- package/es/components/eventBooking/components/Provider/Cart/Item/Total.d.ts +0 -1
- package/es/components/eventBooking/components/Provider/Information/index.d.ts +1 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/CallToBook/index.d.ts +0 -1
- package/es/components/eventBooking/components/scheduleCalendar/calendarItem.d.ts +0 -1
- package/es/components/eventBooking/index.d.ts +0 -1
- package/es/components/pay/toB/components/Cache/index.d.ts +0 -1
- package/es/components/pay/toB/components/Card/index.d.ts +0 -1
- package/es/components/pay/toB/components/CardGroup/index.d.ts +0 -1
- package/es/components/pay/toB/components/Content/Footer.d.ts +0 -1
- package/es/components/pay/toB/components/Content/Header.d.ts +0 -1
- package/es/components/pay/toC/PaymentMethods/MWCreditCard/TDSPay/ThreedsLoading/index.d.ts +0 -1
- package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/Finish/index.d.ts +0 -1
- package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/StripeSDK/SDK.d.ts +0 -1
- package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/components/PageLoading/index.d.ts +0 -1
- package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/components/SetupForm/PaymentRequestForm.d.ts +0 -1
- package/es/components/pay/toC/model.d.ts +9 -1
- package/es/components/pisellSelectCustomerModal/RightPanel/Add/PhoneField/index.d.ts +0 -1
- package/es/components/pisellSelectCustomerModal/RightPanel/index.d.ts +0 -1
- package/es/components/pisellSelectCustomerModal/index.d.ts +0 -1
- package/es/components/productExtension/index.d.ts +0 -1
- package/es/components/productSelect/components/TabProduct/index.d.ts +0 -1
- package/es/components/productSelect/components/productGroup/index.d.ts +0 -1
- package/es/components/schedules/components/ScheduleList/RenderScheduleItem/index.d.ts +0 -1
- package/es/components/schedules/model.d.ts +9 -1
- package/es/components/schedules/products/ProductDetailDrawer/ProductDetail/SchedulesModule/AddSchedules/index.d.ts +0 -1
- package/es/components/schedules/products/ProductDetailDrawer/ProductDetail/SchedulesModule/index.d.ts +0 -1
- package/es/components/taxSelect/index.d.ts +0 -1
- package/es/components/ticketBooking/components/addServiceVariant/index.d.ts +0 -1
- package/es/components/ticketBooking/components/menuBar/index.d.ts +0 -1
- package/es/components/ticketBooking/components/timeBar/index.d.ts +0 -1
- package/es/components/ticketBooking/index.d.ts +0 -1
- package/es/components/ticketBooking/utils/index.d.ts +1 -1
- package/es/components/wallet/Detail/model.d.ts +13 -1
- package/es/components/wallet/DiscountCard/model.d.ts +14 -1
- package/es/components/wallet/PointCard/model.d.ts +13 -1
- package/es/components/wallet/RechargeableCard/model.d.ts +29 -1
- package/es/components/wallet/Voucher/model.d.ts +13 -1
- package/es/components/wallet/model.d.ts +9 -1
- package/es/hooks/usePaymentLogger.d.ts +0 -1
- package/es/plus/clientName/index.d.ts +0 -1
- package/es/plus/clinetSearch/Add/BirthdayField/index.d.ts +0 -1
- package/es/plus/clinetSearch/Add/GenderField/index.d.ts +0 -1
- package/es/plus/clinetSearch/Add/PhoneField/index.d.ts +0 -1
- package/es/plus/noteModal/AddTempModal.d.ts +0 -1
- package/es/plus/saasCreateOrganization/index.d.ts +0 -1
- package/es/pro/pisellPhoneKeyboard/index.d.ts +0 -1
- package/lib/businessModel/SalesModel/index.d.ts +0 -1
- package/lib/components/Sales/Summary/utils.d.ts +1 -1
- package/lib/components/appointmentBooking/components/Cart/Item/index.d.ts +1 -0
- package/lib/components/appointmentBooking/components/Header/index.d.ts +0 -1
- package/lib/components/appointmentBooking/components/Voucher/index.d.ts +0 -1
- package/lib/components/appointmentBooking/deposit/index.d.ts +0 -1
- package/lib/components/booking/addons/model.d.ts +10 -1
- package/lib/components/booking/components/reloadResourceModal/index.d.ts +0 -1
- package/lib/components/booking/deposit/index.d.ts +0 -1
- package/lib/components/booking/forms/footer.d.ts +1 -0
- package/lib/components/booking/forms/model.d.ts +10 -1
- package/lib/components/booking/hooks/useQuotation.d.ts +0 -1
- package/lib/components/booking/info/addServiceVariant/index.d.ts +0 -1
- package/lib/components/booking/info/header/index.d.ts +0 -1
- package/lib/components/booking/info/hooks/useInfoHolder.d.ts +0 -1
- package/lib/components/booking/info/index.d.ts +0 -1
- package/lib/components/booking/info/model.d.ts +10 -1
- package/lib/components/booking/info/notes/index.d.ts +0 -1
- package/lib/components/booking/info/service/Lists.d.ts +0 -1
- package/lib/components/booking/info/service/addService/utils.d.ts +1 -1
- package/lib/components/booking/info/service/editService/BookingList/index.d.ts +0 -1
- package/lib/components/booking/info/service/serviceItem/index.d.ts +0 -1
- package/lib/components/booking/info/service/serviceList/index.d.ts +0 -1
- package/lib/components/booking/info/service2/Lists.d.ts +0 -1
- package/lib/components/booking/info2/service/addService/index.d.ts +0 -1
- package/lib/components/booking/info2/service/addService/utils.d.ts +1 -1
- package/lib/components/booking/info2/service/serviceItem/index.d.ts +0 -1
- package/lib/components/booking/info2/service/serviceList/index.d.ts +0 -1
- package/lib/components/booking/model.d.ts +9 -1
- package/lib/components/booking/notes/NoteBlock/index.d.ts +0 -1
- package/lib/components/booking/notes/addNote/index.d.ts +0 -1
- package/lib/components/booking/notes/model.d.ts +10 -1
- package/lib/components/booking/payments/model.d.ts +10 -1
- package/lib/components/booking/utils.d.ts +2 -2
- package/lib/components/checkout/PaymentModal.js +2 -1
- package/lib/components/checkout/PaymentPlugin.d.ts +0 -1
- package/lib/components/checkout/components/SearchAndClientModule/index.d.ts +0 -1
- package/lib/components/checkout/components/WalletPassModule/components/DiscountWallet/index.d.ts +0 -1
- package/lib/components/checkout/utils/PaymentResultToastUtils.js +2 -1
- package/lib/components/eftpos/surcharge/index.d.ts +0 -1
- package/lib/components/eftposPay/app.d.ts +0 -1
- package/lib/components/eftposPay/component/fail/failCustom.d.ts +1 -0
- package/lib/components/eftposPay/component/fail/index.d.ts +1 -0
- package/lib/components/eftposPay/component/fail/unknow.d.ts +1 -0
- package/lib/components/eftposPay/hooks.d.ts +2 -2
- package/lib/components/eftposPay/linkly/index.d.ts +0 -1
- package/lib/components/eftposPay/pay.d.ts +1 -0
- package/lib/components/eftposPay/store/index.d.ts +6 -6
- package/lib/components/eventBooking/components/Provider/Cart/Item/Total.d.ts +0 -1
- package/lib/components/eventBooking/components/Provider/Information/index.d.ts +1 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/CallToBook/index.d.ts +0 -1
- package/lib/components/eventBooking/components/scheduleCalendar/calendarItem.d.ts +0 -1
- package/lib/components/eventBooking/index.d.ts +0 -1
- package/lib/components/pay/toB/components/Cache/index.d.ts +0 -1
- package/lib/components/pay/toB/components/Card/index.d.ts +0 -1
- package/lib/components/pay/toB/components/CardGroup/index.d.ts +0 -1
- package/lib/components/pay/toB/components/Content/Footer.d.ts +0 -1
- package/lib/components/pay/toB/components/Content/Header.d.ts +0 -1
- package/lib/components/pay/toC/PaymentMethods/MWCreditCard/TDSPay/ThreedsLoading/index.d.ts +0 -1
- package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/Finish/index.d.ts +0 -1
- package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/StripeSDK/SDK.d.ts +0 -1
- package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/components/PageLoading/index.d.ts +0 -1
- package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/components/SetupForm/PaymentRequestForm.d.ts +0 -1
- package/lib/components/pay/toC/model.d.ts +9 -1
- package/lib/components/pisellSelectCustomerModal/RightPanel/Add/PhoneField/index.d.ts +0 -1
- package/lib/components/pisellSelectCustomerModal/RightPanel/index.d.ts +0 -1
- package/lib/components/pisellSelectCustomerModal/index.d.ts +0 -1
- package/lib/components/productExtension/index.d.ts +0 -1
- package/lib/components/productSelect/components/TabProduct/index.d.ts +0 -1
- package/lib/components/productSelect/components/productGroup/index.d.ts +0 -1
- package/lib/components/schedules/components/ScheduleList/RenderScheduleItem/index.d.ts +0 -1
- package/lib/components/schedules/model.d.ts +9 -1
- package/lib/components/schedules/products/ProductDetailDrawer/ProductDetail/SchedulesModule/AddSchedules/index.d.ts +0 -1
- package/lib/components/schedules/products/ProductDetailDrawer/ProductDetail/SchedulesModule/index.d.ts +0 -1
- package/lib/components/taxSelect/index.d.ts +0 -1
- package/lib/components/ticketBooking/components/addServiceVariant/index.d.ts +0 -1
- package/lib/components/ticketBooking/components/menuBar/index.d.ts +0 -1
- package/lib/components/ticketBooking/components/timeBar/index.d.ts +0 -1
- package/lib/components/ticketBooking/index.d.ts +0 -1
- package/lib/components/ticketBooking/utils/index.d.ts +1 -1
- package/lib/components/wallet/Detail/model.d.ts +13 -1
- package/lib/components/wallet/DiscountCard/model.d.ts +14 -1
- package/lib/components/wallet/PointCard/model.d.ts +13 -1
- package/lib/components/wallet/RechargeableCard/model.d.ts +29 -1
- package/lib/components/wallet/Voucher/model.d.ts +13 -1
- package/lib/components/wallet/model.d.ts +9 -1
- package/lib/hooks/usePaymentLogger.d.ts +0 -1
- package/lib/plus/clientName/index.d.ts +0 -1
- package/lib/plus/clinetSearch/Add/BirthdayField/index.d.ts +0 -1
- package/lib/plus/clinetSearch/Add/GenderField/index.d.ts +0 -1
- package/lib/plus/clinetSearch/Add/PhoneField/index.d.ts +0 -1
- package/lib/plus/noteModal/AddTempModal.d.ts +0 -1
- package/lib/plus/saasCreateOrganization/index.d.ts +0 -1
- package/lib/pro/pisellPhoneKeyboard/index.d.ts +0 -1
- package/package.json +1 -1
@@ -41,7 +41,7 @@ declare type ScanData = {
|
|
41
41
|
};
|
42
42
|
};
|
43
43
|
export declare const formatScanCustomer: (data: ScanData) => {
|
44
|
-
searchType: "
|
44
|
+
searchType: "customer" | "product" | "wallet" | "walletPass" | "local_product";
|
45
45
|
data: any;
|
46
46
|
scanCode: string;
|
47
47
|
} | null;
|
@@ -1 +1,13 @@
|
|
1
|
-
|
1
|
+
/// <reference types="react" />
|
2
|
+
interface RechargeState {
|
3
|
+
addWalletCard: any;
|
4
|
+
}
|
5
|
+
export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
|
6
|
+
walletDetailState: RechargeState;
|
7
|
+
} & {
|
8
|
+
dispatch: (params: {
|
9
|
+
type: string;
|
10
|
+
payload: any;
|
11
|
+
}) => void;
|
12
|
+
}>;
|
13
|
+
export {};
|
@@ -1 +1,14 @@
|
|
1
|
-
|
1
|
+
/// <reference types="react" />
|
2
|
+
interface RechargeState {
|
3
|
+
total: number;
|
4
|
+
setup?: 'menu' | 'list' | 'detail' | string;
|
5
|
+
}
|
6
|
+
export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
|
7
|
+
state: RechargeState;
|
8
|
+
} & {
|
9
|
+
dispatch: (params: {
|
10
|
+
type: string;
|
11
|
+
payload: any;
|
12
|
+
}) => void;
|
13
|
+
}>;
|
14
|
+
export {};
|
@@ -1 +1,13 @@
|
|
1
|
-
|
1
|
+
/// <reference types="react" />
|
2
|
+
interface RechargeState {
|
3
|
+
total: number;
|
4
|
+
}
|
5
|
+
export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
|
6
|
+
state: RechargeState;
|
7
|
+
} & {
|
8
|
+
dispatch: (params: {
|
9
|
+
type: string;
|
10
|
+
payload: any;
|
11
|
+
}) => void;
|
12
|
+
}>;
|
13
|
+
export {};
|
@@ -1 +1,29 @@
|
|
1
|
-
|
1
|
+
/// <reference types="react" />
|
2
|
+
interface RechargeState {
|
3
|
+
selectedGiftOptionId: string | null;
|
4
|
+
cardList: Array<{
|
5
|
+
id: string;
|
6
|
+
name: string;
|
7
|
+
price: number;
|
8
|
+
}>;
|
9
|
+
selectedItem: {
|
10
|
+
id?: string;
|
11
|
+
gift_price?: number;
|
12
|
+
price?: number;
|
13
|
+
name?: string;
|
14
|
+
variant_id?: string;
|
15
|
+
};
|
16
|
+
productId?: string;
|
17
|
+
detailId?: string;
|
18
|
+
total: string | number;
|
19
|
+
rechargeModalOpen: boolean;
|
20
|
+
}
|
21
|
+
export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
|
22
|
+
state: RechargeState;
|
23
|
+
} & {
|
24
|
+
dispatch: (params: {
|
25
|
+
type: string;
|
26
|
+
payload: any;
|
27
|
+
}) => void;
|
28
|
+
}>;
|
29
|
+
export {};
|
@@ -1 +1,13 @@
|
|
1
|
-
|
1
|
+
/// <reference types="react" />
|
2
|
+
interface RechargeState {
|
3
|
+
total: 0;
|
4
|
+
}
|
5
|
+
export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
|
6
|
+
state: RechargeState;
|
7
|
+
} & {
|
8
|
+
dispatch: (params: {
|
9
|
+
type: string;
|
10
|
+
payload: any;
|
11
|
+
}) => void;
|
12
|
+
}>;
|
13
|
+
export {};
|
@@ -1,3 +1,4 @@
|
|
1
|
+
/// <reference types="react" />
|
1
2
|
import { IWalletListItemProps } from './serve';
|
2
3
|
export interface WalletCardItemProps {
|
3
4
|
id: string;
|
@@ -26,4 +27,11 @@ export interface WalletListProps {
|
|
26
27
|
currentSearchListItemCode?: string;
|
27
28
|
[key: string]: any;
|
28
29
|
}
|
29
|
-
export declare const Provider: any, Context:
|
30
|
+
export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
|
31
|
+
global_wallet: WalletListProps;
|
32
|
+
} & {
|
33
|
+
dispatch: (params: {
|
34
|
+
type: string;
|
35
|
+
payload: any;
|
36
|
+
}) => void;
|
37
|
+
}>;
|
@@ -30,7 +30,7 @@ export declare const calculateSubtotal: (items: CartItem[]) => string;
|
|
30
30
|
* @return {*}
|
31
31
|
* @Author: xiangfeng.xue
|
32
32
|
*/
|
33
|
-
export declare const calculateTaxFee: (shopInfo: any, items: CartItem[]) => "0.00"
|
33
|
+
export declare const calculateTaxFee: (shopInfo: any, items: CartItem[]) => Decimal | "0.00";
|
34
34
|
/**
|
35
35
|
* 计算所有价格明细
|
36
36
|
* @param items - 购物车商品数组
|
@@ -1 +1,10 @@
|
|
1
|
-
|
1
|
+
/// <reference types="react" />
|
2
|
+
import { FormState } from "../model";
|
3
|
+
export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
|
4
|
+
state: FormState;
|
5
|
+
} & {
|
6
|
+
dispatch: (params: {
|
7
|
+
type: string;
|
8
|
+
payload: any;
|
9
|
+
}) => void;
|
10
|
+
}>;
|
@@ -1 +1,10 @@
|
|
1
|
-
|
1
|
+
/// <reference types="react" />
|
2
|
+
import { FormState } from "../model";
|
3
|
+
export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
|
4
|
+
state: FormState;
|
5
|
+
} & {
|
6
|
+
dispatch: (params: {
|
7
|
+
type: string;
|
8
|
+
payload: any;
|
9
|
+
}) => void;
|
10
|
+
}>;
|
@@ -1,5 +1,14 @@
|
|
1
|
+
/// <reference types="react" />
|
2
|
+
import { FormState } from '../model';
|
1
3
|
export declare const walkInData: {
|
2
4
|
id: number;
|
3
5
|
nickname: string;
|
4
6
|
};
|
5
|
-
export declare const Provider: any, Context:
|
7
|
+
export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
|
8
|
+
state: FormState;
|
9
|
+
} & {
|
10
|
+
dispatch: (params: {
|
11
|
+
type: string;
|
12
|
+
payload: any;
|
13
|
+
}) => void;
|
14
|
+
}>;
|
@@ -1,3 +1,4 @@
|
|
1
|
+
/// <reference types="react" />
|
1
2
|
export interface FormState {
|
2
3
|
amountSymbol: string;
|
3
4
|
apis: {
|
@@ -105,4 +106,11 @@ export declare const walkInData: {
|
|
105
106
|
id: number;
|
106
107
|
nickname: string;
|
107
108
|
};
|
108
|
-
export declare const Provider: any, Context:
|
109
|
+
export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
|
110
|
+
state: FormState;
|
111
|
+
} & {
|
112
|
+
dispatch: (params: {
|
113
|
+
type: string;
|
114
|
+
payload: any;
|
115
|
+
}) => void;
|
116
|
+
}>;
|
@@ -1 +1,10 @@
|
|
1
|
-
|
1
|
+
/// <reference types="react" />
|
2
|
+
import { FormState } from "../model";
|
3
|
+
export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
|
4
|
+
state: FormState;
|
5
|
+
} & {
|
6
|
+
dispatch: (params: {
|
7
|
+
type: string;
|
8
|
+
payload: any;
|
9
|
+
}) => void;
|
10
|
+
}>;
|
@@ -1 +1,10 @@
|
|
1
|
-
|
1
|
+
/// <reference types="react" />
|
2
|
+
import { FormState } from "../model";
|
3
|
+
export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
|
4
|
+
state: FormState;
|
5
|
+
} & {
|
6
|
+
dispatch: (params: {
|
7
|
+
type: string;
|
8
|
+
payload: any;
|
9
|
+
}) => void;
|
10
|
+
}>;
|
@@ -165,10 +165,10 @@ export declare const getProductTotalPrice: (item: any) => number;
|
|
165
165
|
export declare const getDuration: (duration: number | {
|
166
166
|
type: string;
|
167
167
|
value: number;
|
168
|
-
}) => number | {
|
168
|
+
}) => number | "flexible" | {
|
169
169
|
type: string;
|
170
170
|
value: number;
|
171
|
-
}
|
171
|
+
};
|
172
172
|
export declare const isWalkIn: (customer_id?: number | string) => boolean;
|
173
173
|
export declare const getIsEdit: (state: any) => boolean;
|
174
174
|
export {};
|
@@ -1145,6 +1145,7 @@ var PaymentModal = ({
|
|
1145
1145
|
const responseData = (_a3 = data2.response) == null ? void 0 : _a3.data;
|
1146
1146
|
const paymentStatus = responseData == null ? void 0 : responseData.payment_status;
|
1147
1147
|
const orderTotalAmount = Number((responseData == null ? void 0 : responseData.total_amount) || 0);
|
1148
|
+
const gapAmount = Number((responseData == null ? void 0 : responseData.amount_gap) || 0);
|
1148
1149
|
const currentChangeGivenAmount = Number(
|
1149
1150
|
((_b3 = responseData == null ? void 0 : responseData.payment_info) == null ? void 0 : _b3.current_change_given_amount) || 0
|
1150
1151
|
);
|
@@ -1159,7 +1160,7 @@ var PaymentModal = ({
|
|
1159
1160
|
{
|
1160
1161
|
paymentStatus,
|
1161
1162
|
orderTotalAmount,
|
1162
|
-
gapAmount: currentChangeGivenAmount,
|
1163
|
+
gapAmount: paymentStatus === "partially_paid" ? gapAmount : currentChangeGivenAmount,
|
1163
1164
|
failureReason,
|
1164
1165
|
autoCloseConfig,
|
1165
1166
|
actionButtons: generateActionButtons(paymentStatus)
|
@@ -40,6 +40,7 @@ __export(PaymentResultToastUtils_exports, {
|
|
40
40
|
module.exports = __toCommonJS(PaymentResultToastUtils_exports);
|
41
41
|
var import_react = __toESM(require("react"));
|
42
42
|
var import_utils = require("@pisell/utils");
|
43
|
+
var import_decimal = __toESM(require("decimal.js"));
|
43
44
|
var import_PaymentResultToast = require("../components/PaymentResultToast");
|
44
45
|
var formatCurrency = (amount, amountSymbol = "$") => {
|
45
46
|
return (0, import_utils.formatAmount)(amount, 2, amountSymbol);
|
@@ -76,7 +77,7 @@ var calculateSubtitle = (status, amount, gapAmount, getData) => {
|
|
76
77
|
}
|
77
78
|
break;
|
78
79
|
case "partially_paid":
|
79
|
-
const displayAmount = gapAmount ??
|
80
|
+
const displayAmount = new import_decimal.default(amount).minus(gapAmount ?? 0).toNumber();
|
80
81
|
text = `${import_utils.locales.getText("payment.result.partiallyPaid") || "Partially Paid"} ${formatCurrency(displayAmount, amountSymbol)}`;
|
81
82
|
colorClass = "partially-paid";
|
82
83
|
break;
|
@@ -1,4 +1,3 @@
|
|
1
|
-
/// <reference types="react" />
|
2
1
|
import { PosProps, RouteType } from './const';
|
3
2
|
declare const App: ({ action, api, device_number, terminal, tyroUrl, tyroVersion, onChangeParams, isMobile, channel, formatAmount, ...props }: Omit<PosProps, "type" | "mode" | "getApi"> & {
|
4
3
|
action: RouteType;
|
@@ -15,11 +15,11 @@ export declare const useStoreRef: <T extends {
|
|
15
15
|
readonly numRef: React.MutableRefObject<string | number | undefined>;
|
16
16
|
readonly orderIdRef: React.MutableRefObject<string | number>;
|
17
17
|
readonly modeRef: React.MutableRefObject<ModeEnum>;
|
18
|
-
readonly statusRef: React.MutableRefObject<"loading" | "
|
18
|
+
readonly statusRef: React.MutableRefObject<"loading" | "success" | "warn" | "fail" | "pedding" | "resove" | "reject" | "question">;
|
19
19
|
readonly netRef: React.MutableRefObject<boolean | undefined>;
|
20
20
|
readonly symbolRef: React.MutableRefObject<string>;
|
21
21
|
readonly amountRef: React.MutableRefObject<string | number>;
|
22
|
-
readonly eftposRef: React.MutableRefObject<"
|
22
|
+
readonly eftposRef: React.MutableRefObject<"stripe" | "payo" | "tyro" | "windcave" | "linkly">;
|
23
23
|
readonly clientRef: React.MutableRefObject<ClientEnum>;
|
24
24
|
readonly dataRef: React.MutableRefObject<import("./store").State>;
|
25
25
|
};
|