1
This commit is contained in:
@@ -10,7 +10,6 @@ import (
|
|||||||
"git.rosy.net.cn/jx-callback/business/model/dao"
|
"git.rosy.net.cn/jx-callback/business/model/dao"
|
||||||
"git.rosy.net.cn/jx-callback/business/partner"
|
"git.rosy.net.cn/jx-callback/business/partner"
|
||||||
"git.rosy.net.cn/jx-callback/globals/api"
|
"git.rosy.net.cn/jx-callback/globals/api"
|
||||||
"strings"
|
|
||||||
"time"
|
"time"
|
||||||
)
|
)
|
||||||
|
|
||||||
@@ -113,16 +112,20 @@ func GetMerchantInfo(merchantNo string) (*lakala.MerchantObj, error) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if merchantInfo.TermNo == "" {
|
if merchantInfo.TermNo == "" {
|
||||||
termNo := make([]string, 0, 0)
|
//termNo := make([]string, 0, 0)
|
||||||
for _, v := range result.TerminalInfo {
|
//for _, v := range result.TerminalInfo {
|
||||||
termNo = append(termNo, v.TermNoList...)
|
// termNo = append(termNo, v.TermNoList...)
|
||||||
}
|
//}
|
||||||
if len(termNo) != model.NO {
|
//if len(termNo) != model.NO {
|
||||||
merchantInfo.TermNo = strings.Join(termNo, ",")
|
// merchantInfo.TermNo = strings.Join(termNo, ",")
|
||||||
dao.UpdateEntity(db, merchantInfo, "TermNo")
|
// dao.UpdateEntity(db, merchantInfo, "TermNo")
|
||||||
}
|
//}
|
||||||
|
merchantInfo.TermNo = result.Customer.TermNo
|
||||||
}
|
}
|
||||||
merchantInfo.MerchantStatus = result.Customer.CustomerStatus
|
merchantInfo.MerchantStatus = result.Customer.CustomerStatus
|
||||||
|
if merchantInfo.MerchantNo2 == "" {
|
||||||
|
merchantInfo.MerchantNo2 = result.Customer.ExternalCustomerNo
|
||||||
|
}
|
||||||
dao.UpdateEntity(db, merchantInfo, "TermNo", "MerchantStatus")
|
dao.UpdateEntity(db, merchantInfo, "TermNo", "MerchantStatus")
|
||||||
|
|
||||||
return result, err
|
return result, err
|
||||||
|
|||||||
@@ -57,6 +57,7 @@ type LakalaIncoming struct {
|
|||||||
ModelIDCUL
|
ModelIDCUL
|
||||||
StoreId int `orm:"column(store_id);size(16)" json:"storeId"` // 京西门店ID
|
StoreId int `orm:"column(store_id);size(16)" json:"storeId"` // 京西门店ID
|
||||||
MerchantNo string `orm:"column(merchant_no);size(20)" json:"merchantNo"` // 拉卡拉进件商户号
|
MerchantNo string `orm:"column(merchant_no);size(20)" json:"merchantNo"` // 拉卡拉进件商户号
|
||||||
|
MerchantNo2 string `orm:"column(merchant_no2);size(20)" json:"merchantNo2"` // 银联商户号
|
||||||
TermNo string `orm:"column(term_no);size(256)" json:"termNo"` // 终端号 M String(32) 拉卡拉分配的业务终端号
|
TermNo string `orm:"column(term_no);size(256)" json:"termNo"` // 终端号 M String(32) 拉卡拉分配的业务终端号
|
||||||
MerchantStatus string `orm:"column(merchant_status);size(80)" json:"merchantStatus"` // 拉卡拉进件状态
|
MerchantStatus string `orm:"column(merchant_status);size(80)" json:"merchantStatus"` // 拉卡拉进件状态
|
||||||
FeeId string `orm:"column(fee_id);size(80)" json:"feeId"` // 拉卡拉费率变更ID
|
FeeId string `orm:"column(fee_id);size(80)" json:"feeId"` // 拉卡拉费率变更ID
|
||||||
|
|||||||
@@ -28,7 +28,7 @@ func pay4OrderByLaKaLa(ctx *jxcontext.Context, order *model.GoodsOrder, payType
|
|||||||
}
|
}
|
||||||
|
|
||||||
param := &lakala.AggregatePayReq{
|
param := &lakala.AggregatePayReq{
|
||||||
MerchantNo: merchantObj.MerchantNo,
|
MerchantNo: merchantObj.MerchantNo2,
|
||||||
TermNo: merchantObj.TermNo,
|
TermNo: merchantObj.TermNo,
|
||||||
OutTradeNo: order.VendorOrderID,
|
OutTradeNo: order.VendorOrderID,
|
||||||
TotalAmount: utils.Int64ToStr(order.ActualPayPrice),
|
TotalAmount: utils.Int64ToStr(order.ActualPayPrice),
|
||||||
|
|||||||
Reference in New Issue
Block a user