From 8fd88cbd23f9c7ebff17b40ee63b8425f4a0ce27 Mon Sep 17 00:00:00 2001 From: kanade Date: Tue, 20 Feb 2024 10:18:08 +0800 Subject: [PATCH] =?UTF-8?q?=E8=AE=A2=E5=8D=95=E5=A6=A5=E6=8A=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- supply/channel/mq.go | 1 + supply/channel/order.go | 1 + supply/order.go | 16 ++++++++++++++++ 3 files changed, 18 insertions(+) diff --git a/supply/channel/mq.go b/supply/channel/mq.go index 4c2af00..f9e12df 100644 --- a/supply/channel/mq.go +++ b/supply/channel/mq.go @@ -11,6 +11,7 @@ const ( MqSubscribeNameSkuChange = "sku_change" // sku信息变动 MqSubscribeNameOrderSplit = "order_split" // 订单拆单 MqSubscribeNameOrderStockOut = "order_stock_out" // 订单出库 + MqSubscribeNameOrderDelivered = "order_delivered" // 订单签收 MqSubscribeNameOrderFinish = "order_finish" // 订单完成 MqSubscribeNameOrderCancel = "order_cancel" // 订单取消 MqSubscribeNameAfsDeliver = "afs_deliver" // 需要客户发货 diff --git a/supply/channel/order.go b/supply/channel/order.go index a5df18a..43ec2d5 100644 --- a/supply/channel/order.go +++ b/supply/channel/order.go @@ -205,6 +205,7 @@ type OrderItem struct { FreightFee decimal.Decimal `json:"freightFee"` OrderFee decimal.Decimal `json:"orderFee"` LadingBillAt int64 `json:"ladingBillAt"` + DeliveredAt int64 `json:"deliveredAt"` FinishAt int64 `json:"finishAt"` Status uint `json:"status"` CancelStatus uint `json:"cancelStatus"` diff --git a/supply/order.go b/supply/order.go index ed19fe8..490e24d 100644 --- a/supply/order.go +++ b/supply/order.go @@ -104,6 +104,22 @@ func (o *order) StockOut(ctx context.Context, args ArgsOrderStockOut) (err error // return //} +type ArgsOrderDelivered struct { + Source source // 商品来源 + SourceOrderSn string // 供应商订单号 +} + +// Delivered @Title 订单签收/妥投 +func (o *order) Delivered(ctx context.Context, args ArgsOrderDelivered) (err error) { + xClient, err := client.GetClient(o) + if err != nil { + return + } + reply := 0 + err = xClient.Call(ctx, "Delivered", args, &reply) + return +} + type ArgsOrderFinish struct { Source source // 商品来源 SourceOrderSn string // 供应商订单号