|
|
@@ -44,7 +44,228 @@ func (r *MQBodyReq) GetProtoBytes(serialNumber *uint32) (bytes *[]byte, err erro
|
|
|
|
|
|
// JSON -> Protobuf
|
|
|
switch int(r.FunCodeReq) {
|
|
|
- case global.ZSSellOrderListingReq: // 钻石卖挂牌接口请求
|
|
|
+ case global.ModifyPwdReq:
|
|
|
+ m := pb.ModifyPwdReq{}
|
|
|
+ if err = r.reflect(data, &m); err != nil {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ m.Header.RequestID = serialNumber
|
|
|
+ if b, e := proto.Marshal(&m); e != nil {
|
|
|
+ global.M2A_LOG.Error(e.Error(), zap.Error(e))
|
|
|
+ err = errors.New("请求信息序列化失败")
|
|
|
+ return
|
|
|
+ } else {
|
|
|
+ bytes = &b
|
|
|
+ }
|
|
|
+ case global.UserReceiveInfoReq:
|
|
|
+ m := pb.UserReceiveInfoReq{}
|
|
|
+ if err = r.reflect(data, &m); err != nil {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ m.Header.RequestID = serialNumber
|
|
|
+ if b, e := proto.Marshal(&m); e != nil {
|
|
|
+ global.M2A_LOG.Error(e.Error(), zap.Error(e))
|
|
|
+ err = errors.New("请求信息序列化失败")
|
|
|
+ return
|
|
|
+ } else {
|
|
|
+ bytes = &b
|
|
|
+ }
|
|
|
+ case global.DelUserReceiveInfoReq:
|
|
|
+ m := pb.DelUserReceiveInfoReq{}
|
|
|
+ if err = r.reflect(data, &m); err != nil {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ m.Header.RequestID = serialNumber
|
|
|
+ if b, e := proto.Marshal(&m); e != nil {
|
|
|
+ global.M2A_LOG.Error(e.Error(), zap.Error(e))
|
|
|
+ err = errors.New("请求信息序列化失败")
|
|
|
+ return
|
|
|
+ } else {
|
|
|
+ bytes = &b
|
|
|
+ }
|
|
|
+ case global.UserReceiveIsDefaultReq:
|
|
|
+ m := pb.UserReceiveIsDefaultReq{}
|
|
|
+ if err = r.reflect(data, &m); err != nil {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ m.Header.RequestID = serialNumber
|
|
|
+ if b, e := proto.Marshal(&m); e != nil {
|
|
|
+ global.M2A_LOG.Error(e.Error(), zap.Error(e))
|
|
|
+ err = errors.New("请求信息序列化失败")
|
|
|
+ return
|
|
|
+ } else {
|
|
|
+ bytes = &b
|
|
|
+ }
|
|
|
+ case global.UserReceiptInfoReq:
|
|
|
+ m := pb.UserReceiptInfoReq{}
|
|
|
+ if err = r.reflect(data, &m); err != nil {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ m.Header.RequestID = serialNumber
|
|
|
+ if b, e := proto.Marshal(&m); e != nil {
|
|
|
+ global.M2A_LOG.Error(e.Error(), zap.Error(e))
|
|
|
+ err = errors.New("请求信息序列化失败")
|
|
|
+ return
|
|
|
+ } else {
|
|
|
+ bytes = &b
|
|
|
+ }
|
|
|
+ case global.DelUserReceiptInfoReq:
|
|
|
+ m := pb.DelUserReceiptInfoReq{}
|
|
|
+ if err = r.reflect(data, &m); err != nil {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ m.Header.RequestID = serialNumber
|
|
|
+ if b, e := proto.Marshal(&m); e != nil {
|
|
|
+ global.M2A_LOG.Error(e.Error(), zap.Error(e))
|
|
|
+ err = errors.New("请求信息序列化失败")
|
|
|
+ return
|
|
|
+ } else {
|
|
|
+ bytes = &b
|
|
|
+ }
|
|
|
+ case global.T2bBankSignReq:
|
|
|
+ m := pb.T2BBankSignReq{}
|
|
|
+ if err = r.reflect(data, &m); err != nil {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ m.Header.RequestID = serialNumber
|
|
|
+ if b, e := proto.Marshal(&m); e != nil {
|
|
|
+ global.M2A_LOG.Error(e.Error(), zap.Error(e))
|
|
|
+ err = errors.New("请求信息序列化失败")
|
|
|
+ return
|
|
|
+ } else {
|
|
|
+ bytes = &b
|
|
|
+ }
|
|
|
+ case global.T2bBankCancelSignReq:
|
|
|
+ m := pb.T2BBankCancelSignReq{}
|
|
|
+ if err = r.reflect(data, &m); err != nil {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ m.Header.RequestID = serialNumber
|
|
|
+ if b, e := proto.Marshal(&m); e != nil {
|
|
|
+ global.M2A_LOG.Error(e.Error(), zap.Error(e))
|
|
|
+ err = errors.New("请求信息序列化失败")
|
|
|
+ return
|
|
|
+ } else {
|
|
|
+ bytes = &b
|
|
|
+ }
|
|
|
+ case global.T2bBankWithdrawReq:
|
|
|
+ m := pb.T2BBankWithdrawReq{}
|
|
|
+ if err = r.reflect(data, &m); err != nil {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ m.Header.RequestID = serialNumber
|
|
|
+ if b, e := proto.Marshal(&m); e != nil {
|
|
|
+ global.M2A_LOG.Error(e.Error(), zap.Error(e))
|
|
|
+ err = errors.New("请求信息序列化失败")
|
|
|
+ return
|
|
|
+ } else {
|
|
|
+ bytes = &b
|
|
|
+ }
|
|
|
+ case global.T2bBankDepositReq:
|
|
|
+ m := pb.T2BBankDepositReq{}
|
|
|
+ if err = r.reflect(data, &m); err != nil {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ m.Header.RequestID = serialNumber
|
|
|
+ if b, e := proto.Marshal(&m); e != nil {
|
|
|
+ global.M2A_LOG.Error(e.Error(), zap.Error(e))
|
|
|
+ err = errors.New("请求信息序列化失败")
|
|
|
+ return
|
|
|
+ } else {
|
|
|
+ bytes = &b
|
|
|
+ }
|
|
|
+ case global.WarehouseApplyReq:
|
|
|
+ m := pb.WarehouseApplyReq{}
|
|
|
+ if err = r.reflect(data, &m); err != nil {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ m.Header.RequestID = serialNumber
|
|
|
+ if b, e := proto.Marshal(&m); e != nil {
|
|
|
+ global.M2A_LOG.Error(e.Error(), zap.Error(e))
|
|
|
+ err = errors.New("请求信息序列化失败")
|
|
|
+ return
|
|
|
+ } else {
|
|
|
+ bytes = &b
|
|
|
+ }
|
|
|
+ case global.PerformanceContractedApplyReq:
|
|
|
+ m := pb.PerformanceContractedApplyReq{}
|
|
|
+ if err = r.reflect(data, &m); err != nil {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ m.Header.RequestID = serialNumber
|
|
|
+ if b, e := proto.Marshal(&m); e != nil {
|
|
|
+ global.M2A_LOG.Error(e.Error(), zap.Error(e))
|
|
|
+ err = errors.New("请求信息序列化失败")
|
|
|
+ return
|
|
|
+ } else {
|
|
|
+ bytes = &b
|
|
|
+ }
|
|
|
+ case global.PerformanceDelayApplyReq:
|
|
|
+ m := pb.PerformanceDelayApplyReq{}
|
|
|
+ if err = r.reflect(data, &m); err != nil {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ m.Header.RequestID = serialNumber
|
|
|
+ if b, e := proto.Marshal(&m); e != nil {
|
|
|
+ global.M2A_LOG.Error(e.Error(), zap.Error(e))
|
|
|
+ err = errors.New("请求信息序列化失败")
|
|
|
+ return
|
|
|
+ } else {
|
|
|
+ bytes = &b
|
|
|
+ }
|
|
|
+ case global.PerformanceManualConfirmReq:
|
|
|
+ m := pb.PerformanceManualConfirmReq{}
|
|
|
+ if err = r.reflect(data, &m); err != nil {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ m.Header.RequestID = serialNumber
|
|
|
+ if b, e := proto.Marshal(&m); e != nil {
|
|
|
+ global.M2A_LOG.Error(e.Error(), zap.Error(e))
|
|
|
+ err = errors.New("请求信息序列化失败")
|
|
|
+ return
|
|
|
+ } else {
|
|
|
+ bytes = &b
|
|
|
+ }
|
|
|
+ case global.PerformanceModifyContactReq:
|
|
|
+ m := pb.PerformanceModifyContactReq{}
|
|
|
+ if err = r.reflect(data, &m); err != nil {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ m.Header.RequestID = serialNumber
|
|
|
+ if b, e := proto.Marshal(&m); e != nil {
|
|
|
+ global.M2A_LOG.Error(e.Error(), zap.Error(e))
|
|
|
+ err = errors.New("请求信息序列化失败")
|
|
|
+ return
|
|
|
+ } else {
|
|
|
+ bytes = &b
|
|
|
+ }
|
|
|
+ case global.GoodsFavoriteOperateReq:
|
|
|
+ m := pb.GoodsFavoriteOperateReq{}
|
|
|
+ if err = r.reflect(data, &m); err != nil {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ m.Header.RequestID = serialNumber
|
|
|
+ if b, e := proto.Marshal(&m); e != nil {
|
|
|
+ global.M2A_LOG.Error(e.Error(), zap.Error(e))
|
|
|
+ err = errors.New("请求信息序列化失败")
|
|
|
+ return
|
|
|
+ } else {
|
|
|
+ bytes = &b
|
|
|
+ }
|
|
|
+ case global.ZSBuyOrderListingReq:
|
|
|
+ m := pb.ZSBuyOrderListingReq{}
|
|
|
+ if err = r.reflect(data, &m); err != nil {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ m.Header.RequestID = serialNumber
|
|
|
+ if b, e := proto.Marshal(&m); e != nil {
|
|
|
+ global.M2A_LOG.Error(e.Error(), zap.Error(e))
|
|
|
+ err = errors.New("请求信息序列化失败")
|
|
|
+ return
|
|
|
+ } else {
|
|
|
+ bytes = &b
|
|
|
+ }
|
|
|
+ case global.ZSSellOrderListingReq:
|
|
|
m := pb.ZSSellOrderListingReq{}
|
|
|
if err = r.reflect(data, &m); err != nil {
|
|
|
return
|
|
|
@@ -57,6 +278,97 @@ func (r *MQBodyReq) GetProtoBytes(serialNumber *uint32) (bytes *[]byte, err erro
|
|
|
} else {
|
|
|
bytes = &b
|
|
|
}
|
|
|
+ case global.ZSBuyOrderDestingReq:
|
|
|
+ m := pb.ZSBuyOrderDestingReq{}
|
|
|
+ if err = r.reflect(data, &m); err != nil {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ m.Header.RequestID = serialNumber
|
|
|
+ if b, e := proto.Marshal(&m); e != nil {
|
|
|
+ global.M2A_LOG.Error(e.Error(), zap.Error(e))
|
|
|
+ err = errors.New("请求信息序列化失败")
|
|
|
+ return
|
|
|
+ } else {
|
|
|
+ bytes = &b
|
|
|
+ }
|
|
|
+ case global.ZSSellOrderDestingApplyReq:
|
|
|
+ m := pb.ZSSellOrderDestingApplyReq{}
|
|
|
+ if err = r.reflect(data, &m); err != nil {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ m.Header.RequestID = serialNumber
|
|
|
+ if b, e := proto.Marshal(&m); e != nil {
|
|
|
+ global.M2A_LOG.Error(e.Error(), zap.Error(e))
|
|
|
+ err = errors.New("请求信息序列化失败")
|
|
|
+ return
|
|
|
+ } else {
|
|
|
+ bytes = &b
|
|
|
+ }
|
|
|
+ case global.ZSSellOrderDestingApplyOperateReq:
|
|
|
+ m := pb.ZSSellOrderDestingApplyOperateReq{}
|
|
|
+ if err = r.reflect(data, &m); err != nil {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ m.Header.RequestID = serialNumber
|
|
|
+ if b, e := proto.Marshal(&m); e != nil {
|
|
|
+ global.M2A_LOG.Error(e.Error(), zap.Error(e))
|
|
|
+ err = errors.New("请求信息序列化失败")
|
|
|
+ return
|
|
|
+ } else {
|
|
|
+ bytes = &b
|
|
|
+ }
|
|
|
+ case global.ZSBuyOrderDestingNegPriceReq:
|
|
|
+ m := pb.ZSBuyOrderDestingNegPriceReq{}
|
|
|
+ if err = r.reflect(data, &m); err != nil {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ m.Header.RequestID = serialNumber
|
|
|
+ if b, e := proto.Marshal(&m); e != nil {
|
|
|
+ global.M2A_LOG.Error(e.Error(), zap.Error(e))
|
|
|
+ err = errors.New("请求信息序列化失败")
|
|
|
+ return
|
|
|
+ } else {
|
|
|
+ bytes = &b
|
|
|
+ }
|
|
|
+ case global.ZSBuyOrderDestingNegPriceOperateReq:
|
|
|
+ m := pb.ZSBuyOrderDestingNegPriceOperateReq{}
|
|
|
+ if err = r.reflect(data, &m); err != nil {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ m.Header.RequestID = serialNumber
|
|
|
+ if b, e := proto.Marshal(&m); e != nil {
|
|
|
+ global.M2A_LOG.Error(e.Error(), zap.Error(e))
|
|
|
+ err = errors.New("请求信息序列化失败")
|
|
|
+ return
|
|
|
+ } else {
|
|
|
+ bytes = &b
|
|
|
+ }
|
|
|
+ case global.WRListingCancelOrderReq:
|
|
|
+ m := pb.WRListingCancelOrderReq{}
|
|
|
+ if err = r.reflect(data, &m); err != nil {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ m.Header.RequestID = serialNumber
|
|
|
+ if b, e := proto.Marshal(&m); e != nil {
|
|
|
+ global.M2A_LOG.Error(e.Error(), zap.Error(e))
|
|
|
+ err = errors.New("请求信息序列化失败")
|
|
|
+ return
|
|
|
+ } else {
|
|
|
+ bytes = &b
|
|
|
+ }
|
|
|
+ case global.ReceiptZSOutApplyReq:
|
|
|
+ m := pb.ReceiptZSOutApplyReq{}
|
|
|
+ if err = r.reflect(data, &m); err != nil {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ m.Header.RequestID = serialNumber
|
|
|
+ if b, e := proto.Marshal(&m); e != nil {
|
|
|
+ global.M2A_LOG.Error(e.Error(), zap.Error(e))
|
|
|
+ err = errors.New("请求信息序列化失败")
|
|
|
+ return
|
|
|
+ } else {
|
|
|
+ bytes = &b
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
return
|