update customer package
This commit is contained in:
@@ -1,8 +1,7 @@
|
||||
import type { Attachment, Model, PageResult, User } from "timi-web-api";
|
||||
import type { Customer } from "@/types/Customer";
|
||||
|
||||
export type FulfillmentType = "PACKAGE_ENTITLEMENT" | "DIRECT_PRODUCT";
|
||||
export type FulfillmentStatus = "WAITING_STOCK" | "PENDING" | "VERIFIED" | "REJECTED" | "CANCELLED" | "REVOKED";
|
||||
export type GaoFulfillmentStatus = "WAITING_STOCK" | "PENDING" | "VERIFIED" | "REJECTED" | "CANCELLED" | "REVOKED";
|
||||
|
||||
export type OrderFulfillmentItem = {
|
||||
fulfillmentId?: string;
|
||||
@@ -10,7 +9,6 @@ export type OrderFulfillmentItem = {
|
||||
productUnitId?: string;
|
||||
attachmentList?: Attachment[];
|
||||
sourceOrderItemId?: string;
|
||||
sourceCustomerPackageItemId?: string;
|
||||
quantity?: number | string;
|
||||
baseQuantity?: number | string;
|
||||
reservedBefore?: number | string;
|
||||
@@ -26,8 +24,7 @@ export type OrderFulfillment = {
|
||||
salesOrderId?: string;
|
||||
storeId?: string;
|
||||
customerId?: string;
|
||||
fulfillmentType?: FulfillmentType;
|
||||
status?: FulfillmentStatus;
|
||||
status?: GaoFulfillmentStatus;
|
||||
requestNo?: string;
|
||||
operatorUserId?: string;
|
||||
customer?: Customer;
|
||||
@@ -49,8 +46,7 @@ export type FulfillmentPage = {
|
||||
storeId?: string;
|
||||
salesOrderId?: string;
|
||||
customerId?: string;
|
||||
fulfillmentType?: FulfillmentType;
|
||||
status?: FulfillmentStatus;
|
||||
status?: GaoFulfillmentStatus;
|
||||
beginAt?: number;
|
||||
endAt?: number;
|
||||
index: number;
|
||||
@@ -61,14 +57,13 @@ export type OrderFulfillmentCreateRequest = {
|
||||
salesOrderId: string;
|
||||
requestNo: string;
|
||||
deliveredAt?: number;
|
||||
itemList: OrderFulfillmentItemRequest[];
|
||||
itemList: GaoOrderFulfillmentItemRequest[];
|
||||
attachmentList?: Partial<Attachment>[];
|
||||
remark?: string | null;
|
||||
};
|
||||
|
||||
export type OrderFulfillmentItemRequest = {
|
||||
sourceOrderItemId?: string;
|
||||
sourceCustomerPackageItemId?: string;
|
||||
export type GaoOrderFulfillmentItemRequest = {
|
||||
sourceOrderItemId: string;
|
||||
quantity: number | string;
|
||||
};
|
||||
|
||||
|
||||
+6
-23
@@ -2,9 +2,9 @@ import type { Attachment, Model, PageResult, User } from "timi-web-api";
|
||||
import type { Customer } from "@/types/Customer";
|
||||
import type { OrderFulfillment } from "@/types/Fulfillment";
|
||||
import type { Product } from "@/types/Product";
|
||||
import type { GaoSalesOrderItem, GaoSalesOrderStatus, SalesOrder } from "@/types/SalesOrder";
|
||||
|
||||
export type PackageConfigStatus = "DRAFT" | "ACTIVE" | "INACTIVE";
|
||||
export type CustomerPackageStatus = "ACTIVE" | "FULFILLED" | "CANCELLED";
|
||||
|
||||
export type PackageConfigItem = {
|
||||
packageConfigId?: string;
|
||||
@@ -34,24 +34,6 @@ export type GaoPackageConfig = {
|
||||
|
||||
export type PackageConfigPage = { storeId?: string; keyword?: string; status?: PackageConfigStatus; index: number; size: number };
|
||||
|
||||
export type CustomerPackageItem = {
|
||||
customerPackageId?: string;
|
||||
productId?: string;
|
||||
productUnitId?: string;
|
||||
attachmentList?: Attachment[];
|
||||
productNameSnapshot?: string;
|
||||
unitSnapshot?: string;
|
||||
baseQuantityPerUnitSnapshot?: number | string;
|
||||
totalQuantity: number | string;
|
||||
reservedQuantity: number | string;
|
||||
fulfilledQuantity: number | string;
|
||||
pendingQuantity: number | string;
|
||||
availableQuantity: number | string;
|
||||
remainingQuantity: number | string;
|
||||
sort?: number;
|
||||
remark?: string | null;
|
||||
} & Model;
|
||||
|
||||
export type GaoCustomerPackage = {
|
||||
storeId?: string;
|
||||
salesOrderId?: string;
|
||||
@@ -59,18 +41,19 @@ export type GaoCustomerPackage = {
|
||||
packageConfigId?: string;
|
||||
packageNameSnapshot?: string;
|
||||
standardAmountSnapshot?: number;
|
||||
status?: CustomerPackageStatus;
|
||||
status?: GaoSalesOrderStatus;
|
||||
cancelledAt?: number | null;
|
||||
cancelOperatorUserId?: string;
|
||||
cancelReason?: string | null;
|
||||
remark?: string | null;
|
||||
customer?: Customer;
|
||||
cancelOperator?: Partial<User>;
|
||||
itemList?: CustomerPackageItem[];
|
||||
salesOrder?: SalesOrder;
|
||||
itemList?: GaoSalesOrderItem[];
|
||||
fulfillmentList?: OrderFulfillment[];
|
||||
} & Model;
|
||||
|
||||
export type CustomerPackagePage = { storeId?: string; customerId?: string; keyword?: string; status?: CustomerPackageStatus; beginAt?: number; endAt?: number; index: number; size: number };
|
||||
export type CustomerPackagePage = { storeId?: string; customerId?: string; keyword?: string; status?: GaoSalesOrderStatus; beginAt?: number; endAt?: number; index: number; size: number };
|
||||
|
||||
export type PackagePurchaseItem = {
|
||||
productId: string;
|
||||
@@ -88,7 +71,7 @@ export type PackagePurchaseRequest = {
|
||||
customerId: string;
|
||||
saleAmount: number;
|
||||
purchasedAt?: number;
|
||||
itemList: PackagePurchaseItem[];
|
||||
itemList?: PackagePurchaseItem[];
|
||||
attachmentList?: PackageAttachment[];
|
||||
remark?: string | null;
|
||||
};
|
||||
|
||||
+21
-17
@@ -2,16 +2,18 @@ import type { Attachment, Model, PageResult, User } from "timi-web-api";
|
||||
import type { Customer } from "@/types/Customer";
|
||||
import type { EventRecord } from "@/types/EventRecord";
|
||||
|
||||
export type SalesOrderType = "PACKAGE" | "DIRECT_PRODUCT";
|
||||
export type SalesOrderStatus = "ACTIVE" | "FULFILLED" | "CANCELLED";
|
||||
export type SalesPaymentStatus = "UNPAID" | "PARTIALLY_PAID" | "PAID";
|
||||
export type SalesRefundStatus = "NOT_REQUIRED" | "PENDING" | "REFUNDED";
|
||||
export type GaoSalesOrderType = "PACKAGE" | "DIRECT_PRODUCT";
|
||||
export type GaoSalesOrderStatus = "ACTIVE" | "FULFILLED" | "CANCELLED";
|
||||
export type GaoSalesOrderItemType = "PACKAGE_ENTITLEMENT" | "DIRECT_PRODUCT";
|
||||
export type GaoSalesPaymentStatus = "UNPAID" | "PARTIALLY_PAID" | "PAID";
|
||||
export type GaoSalesRefundStatus = "NOT_REQUIRED" | "PENDING" | "REFUNDED";
|
||||
export type FundBizType = "SALES_ORDER";
|
||||
export type FundOperationType = "RECEIVE" | "REFUND" | "CONFIRM_NO_REFUND" | "REVOKE";
|
||||
export type FundRecordStatus = "PENDING" | "VERIFIED" | "REJECTED" | "CANCELLED";
|
||||
|
||||
export type SalesOrderItem = {
|
||||
export type GaoSalesOrderItem = {
|
||||
salesOrderId?: string;
|
||||
itemType?: GaoSalesOrderItemType;
|
||||
productId?: string;
|
||||
productUnitId?: string;
|
||||
attachmentList?: Attachment[];
|
||||
@@ -21,8 +23,11 @@ export type SalesOrderItem = {
|
||||
quantity?: number | string;
|
||||
reservedQuantity?: number | string;
|
||||
fulfilledQuantity?: number | string;
|
||||
unitPrice?: number;
|
||||
lineAmount?: number;
|
||||
unitPrice?: number | null;
|
||||
lineAmount?: number | null;
|
||||
pendingQuantity?: number | string;
|
||||
availableQuantity?: number | string;
|
||||
remainingQuantity?: number | string;
|
||||
sort?: number;
|
||||
remark?: string | null;
|
||||
} & Model;
|
||||
@@ -31,10 +36,10 @@ export type SalesOrder = {
|
||||
storeId?: string;
|
||||
customerId?: string;
|
||||
orderNo?: string;
|
||||
orderType?: SalesOrderType;
|
||||
status?: SalesOrderStatus;
|
||||
paymentStatus?: SalesPaymentStatus;
|
||||
refundStatus?: SalesRefundStatus;
|
||||
orderType?: GaoSalesOrderType;
|
||||
status?: GaoSalesOrderStatus;
|
||||
paymentStatus?: GaoSalesPaymentStatus;
|
||||
refundStatus?: GaoSalesRefundStatus;
|
||||
saleAmount?: number;
|
||||
pendingPaidAmount?: number;
|
||||
paidAmount?: number;
|
||||
@@ -52,7 +57,7 @@ export type SalesOrder = {
|
||||
customer?: Customer;
|
||||
operator?: Partial<User>;
|
||||
cancelOperator?: Partial<User>;
|
||||
itemList?: SalesOrderItem[];
|
||||
itemList?: GaoSalesOrderItem[];
|
||||
fundRecordList?: FundRecord[];
|
||||
sourceEventRecord?: EventRecord;
|
||||
attachmentList?: Partial<Attachment>[];
|
||||
@@ -61,10 +66,10 @@ export type SalesOrder = {
|
||||
export type SalesOrderPage = {
|
||||
storeId?: string;
|
||||
customerId?: string;
|
||||
orderType?: SalesOrderType;
|
||||
status?: SalesOrderStatus;
|
||||
paymentStatus?: SalesPaymentStatus;
|
||||
refundStatus?: SalesRefundStatus;
|
||||
orderType?: GaoSalesOrderType;
|
||||
status?: GaoSalesOrderStatus;
|
||||
paymentStatus?: GaoSalesPaymentStatus;
|
||||
refundStatus?: GaoSalesRefundStatus;
|
||||
pendingReceive?: boolean;
|
||||
fulfilledButUnpaid?: boolean;
|
||||
keyword?: string;
|
||||
@@ -122,7 +127,6 @@ export type OrderPaymentRefundRequest = {
|
||||
|
||||
export type OrderPaymentNoRefundRequest = {
|
||||
salesOrderId: string;
|
||||
requestNo: string;
|
||||
occurredAt?: number;
|
||||
reason: string;
|
||||
remark?: string | null;
|
||||
|
||||
Reference in New Issue
Block a user