- timer task shceuled to order goroutine to avoid concurrent problem.
This commit is contained in:
@@ -23,14 +23,14 @@ func init() {
|
||||
}
|
||||
|
||||
func (c *WaybillController) OnWaybillMsg(msg *mtpsapi.CallbackOrderMsg) (retVal *mtpsapi.CallbackResponse) {
|
||||
controller.CallMsgHandler(func() {
|
||||
jxutils.CallMsgHandler(func() {
|
||||
retVal = c.onWaybillMsg(msg)
|
||||
}, msg.OrderID)
|
||||
return retVal
|
||||
}
|
||||
|
||||
func (c *WaybillController) OnWaybillExcept(msg *mtpsapi.CallbackOrderExceptionMsg) (retVal *mtpsapi.CallbackResponse) {
|
||||
controller.CallMsgHandler(func() {
|
||||
jxutils.CallMsgHandler(func() {
|
||||
order := &model.Waybill{
|
||||
VendorWaybillID: msg.MtPeisongID,
|
||||
VendorWaybillID2: utils.Int64ToStr(msg.DeliveryID),
|
||||
|
||||
Reference in New Issue
Block a user