- all call CallFuncLogError add order info
- callLegacyMsgHandler, callNewMsgHandler and generateLegacyJxOrder config - call legacy lefted msg handler in new process(elm urge order and bad comment on jd)
This commit is contained in:
@@ -28,15 +28,19 @@ func (c *ELMOrderController) URLMapping() {
|
||||
func (c *ELMOrderController) MsgPost() {
|
||||
obj, callbackResponse := api.ElmAPI.GetCallbackMsg(c.Ctx.Input.RequestBody)
|
||||
if callbackResponse == nil {
|
||||
if globals.CallLegacy {
|
||||
if globals.CallLegacyMsgHandler {
|
||||
cc := &controller.OrderController{}
|
||||
callbackResponse = cc.OrderMessage(obj)
|
||||
}
|
||||
if globals.CallNew {
|
||||
utils.CallFuncAsync(func() {
|
||||
cc2 := &elm.Controller{}
|
||||
cc2.OnCallbackMsg(obj)
|
||||
})
|
||||
if globals.CallNewMsgHandler {
|
||||
cc2 := &elm.Controller{}
|
||||
if globals.CallLegacyMsgHandler {
|
||||
utils.CallFuncAsync(func() {
|
||||
cc2.OnCallbackMsg(obj)
|
||||
})
|
||||
} else {
|
||||
callbackResponse = cc2.OnCallbackMsg(obj)
|
||||
}
|
||||
}
|
||||
}
|
||||
c.Data["json"] = callbackResponse
|
||||
|
||||
Reference in New Issue
Block a user