Commit 5336fa0f by 杨铁龙

适配接口修改

parent 214700eb
Showing with 20 additions and 8 deletions
...@@ -54,6 +54,10 @@ export interface OrderTableListItem { ...@@ -54,6 +54,10 @@ export interface OrderTableListItem {
RefundedAmount: number; RefundedAmount: number;
remarkTitle: string; remarkTitle: string;
remarkContent: string; remarkContent: string;
chatTypeCode: string;
lastMsgContent: string;
lastMsgTime: string;
unreadCount: number;
} }
export const orderPredict = { export const orderPredict = {
...@@ -64,14 +68,17 @@ export const orderPredict = { ...@@ -64,14 +68,17 @@ export const orderPredict = {
status: "Status_label", status: "Status_label",
remark: "Remark", remark: "Remark",
time: "CreatedDate", time: "CreatedDate",
createTime: "CreatedDate",
PayAmount: "PayAmount", PayAmount: "PayAmount",
PaidAmount: "PaidAmount", PaidAmount: "PaidAmount",
RefundAmount: "RefundAmount", RefundAmount: "RefundAmount",
RefundedAmount: "RefundedAmount", RefundedAmount: "RefundedAmount",
chat: "UniplatImChatId", chat: "UniplatImChatId",
remarkTitle: "Title", remarkTitle: "Title",
remarkContent: "Remark" remarkContent: "Remark",
chatTypeCode: "UniplatChatTypeCode",
lastMsgContent: "UniplatLastMsgContent",
lastMsgTime: "UniplatLastMsgTime",
unreadCount: 0
}; };
export const enum PayStatus { export const enum PayStatus {
......
...@@ -28,7 +28,7 @@ class OrderService { ...@@ -28,7 +28,7 @@ class OrderService {
} }
public openOrder(params: { public openOrder(params: {
productId: string | number; productCode: string;
srcPlatform: SrcPlatform; srcPlatform: SrcPlatform;
createdType: OperationType; createdType: OperationType;
}) { }) {
...@@ -36,7 +36,7 @@ class OrderService { ...@@ -36,7 +36,7 @@ class OrderService {
.model(this.generalOrder) .model(this.generalOrder)
.action("addOrder") .action("addOrder")
.addInputs_parameter({ .addInputs_parameter({
ProductId: params.productId, ProductCode: params.productCode,
SrcPlatform: params.srcPlatform, SrcPlatform: params.srcPlatform,
CreatedType: params.createdType, CreatedType: params.createdType,
}) })
...@@ -59,16 +59,21 @@ class OrderService { ...@@ -59,16 +59,21 @@ class OrderService {
.execute(); .execute();
} }
public getOrders(index: number) { public getOrders(productId: number, index: number, size = 100) {
return this.getSdk() return this.getSdk()
.model(this.generalOrder) .model(this.generalOrder)
.list("userOrderList") .list("userOrderList")
.query({ item_size: 100, pageIndex: index }) .addPrefilter({ ProductId: productId })
.then((r) => .query({ item_size: size, pageIndex: index })
this.handler.buildRows<OrderTableListItem>( .then((r) => {
return {
total: r.pageData.record_count,
list: this.handler.buildRows<OrderTableListItem>(
r.pageData.rows, r.pageData.rows,
orderPredict orderPredict
) )
}
}
); );
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment