Accept Merge Request #79: (yonghui -> mark)
Merge Request: 刷新历史订单结算价返回值修改 Created By: @苏尹岚 Accepted By: @苏尹岚 URL: https://rosydev.coding.net/p/jx-callback/d/jx-callback/git/merge/79
This commit is contained in:
@@ -727,14 +727,15 @@ func (c *OrderManager) RefreshHistoryOrdersEarningPrice(ctx *jxcontext.Context,
|
|||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
dao.Commit(db)
|
dao.Commit(db)
|
||||||
retVal = num
|
retVal = []string{utils.Int64ToStr(num)}
|
||||||
return retVal, err
|
return retVal, err
|
||||||
}, orderList)
|
}, orderList)
|
||||||
tasksch.HandleTask(task, nil, true).Run()
|
tasksch.HandleTask(task, nil, true).Run()
|
||||||
if !isAsync {
|
if !isAsync {
|
||||||
resultNum, err2 := task.GetResult(0)
|
resultNum, err2 := task.GetResult(0)
|
||||||
err = err2
|
if err = err2; err == nil {
|
||||||
hint = resultNum[0].(string)
|
hint = resultNum[0].(string)
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
hint = task.GetID()
|
hint = task.GetID()
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -2381,6 +2381,7 @@ func StoreSkuNamePriceList2Map(ctx *jxcontext.Context, storeSkuNamePriceList []*
|
|||||||
}
|
}
|
||||||
|
|
||||||
func GetCellIntoStruct(rowNum int, row []string, sheetParam *SheetParam, storeSkuNamePrice *model.StoreSkuNamePrice) (errMsg string) {
|
func GetCellIntoStruct(rowNum int, row []string, sheetParam *SheetParam, storeSkuNamePrice *model.StoreSkuNamePrice) (errMsg string) {
|
||||||
|
var nameMap = make(map[string]string)
|
||||||
for k, cell := range row {
|
for k, cell := range row {
|
||||||
if k == sheetParam.OutSkuIDCol {
|
if k == sheetParam.OutSkuIDCol {
|
||||||
if IsChineseChar(cell) {
|
if IsChineseChar(cell) {
|
||||||
@@ -2399,6 +2400,14 @@ func GetCellIntoStruct(rowNum int, row []string, sheetParam *SheetParam, storeSk
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
storeSkuNamePrice.NameIDGroup = cellReplace
|
storeSkuNamePrice.NameIDGroup = cellReplace
|
||||||
|
nameIDs := strings.Split(cellReplace, ",")
|
||||||
|
for _, v := range nameIDs {
|
||||||
|
if nameMap[v] != "" {
|
||||||
|
return fmt.Sprintf("Excel中含有重复的nameID![%v]列,[%v]行,nameID [%v]", k+1, rowNum+1, v)
|
||||||
|
} else {
|
||||||
|
nameMap[v] = v
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
if k == sheetParam.SkuPriceCol {
|
if k == sheetParam.SkuPriceCol {
|
||||||
if IsChineseChar(cell) {
|
if IsChineseChar(cell) {
|
||||||
|
|||||||
Reference in New Issue
Block a user