测试
This commit is contained in:
@@ -869,11 +869,13 @@ func UpdateStoresSkus(ctx *jxcontext.Context, causeFlag int, storeIDs []int, sku
|
|||||||
if err != nil {
|
if err != nil {
|
||||||
return "", err
|
return "", err
|
||||||
}
|
}
|
||||||
|
fmt.Println("test12")
|
||||||
isAsync = asyncStoreSkuOpFilter(ctx, isAsync)
|
isAsync = asyncStoreSkuOpFilter(ctx, isAsync)
|
||||||
num = int64(len(skuIDs))
|
num = int64(len(skuIDs))
|
||||||
if num > 0 {
|
if num > 0 {
|
||||||
hint, err = CurVendorSync.SyncStoresSkus(ctx, nil, causeFlag, db, nil, storeIDs, skuIDs, false, isAsync, isContinueWhenError)
|
hint, err = CurVendorSync.SyncStoresSkus(ctx, nil, causeFlag, db, nil, storeIDs, skuIDs, false, isAsync, isContinueWhenError)
|
||||||
}
|
}
|
||||||
|
fmt.Println("test22")
|
||||||
if num == 0 || !isAsync || hint == "" {
|
if num == 0 || !isAsync || hint == "" {
|
||||||
hint = utils.Int64ToStr(num)
|
hint = utils.Int64ToStr(num)
|
||||||
}
|
}
|
||||||
@@ -1020,7 +1022,6 @@ func updateStoresSkusWithoutSync(ctx *jxcontext.Context, db *dao.DaoDB, storeIDs
|
|||||||
if user := ctx.GetFullUser(); user != nil {
|
if user := ctx.GetFullUser(); user != nil {
|
||||||
isUserCanDirectChangePrice = user.Type&model.UserTypeOperator != 0
|
isUserCanDirectChangePrice = user.Type&model.UserTypeOperator != 0
|
||||||
}
|
}
|
||||||
fmt.Println("test1")
|
|
||||||
userName := ctx.GetUserName()
|
userName := ctx.GetUserName()
|
||||||
needSyncIDMap := make(map[int]int)
|
needSyncIDMap := make(map[int]int)
|
||||||
dao.Begin(db)
|
dao.Begin(db)
|
||||||
@@ -1037,7 +1038,6 @@ func updateStoresSkusWithoutSync(ctx *jxcontext.Context, db *dao.DaoDB, storeIDs
|
|||||||
dao.Rollback(db)
|
dao.Rollback(db)
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
fmt.Println("test2")
|
|
||||||
scaleFactor := float64(1)
|
scaleFactor := float64(1)
|
||||||
if isScale {
|
if isScale {
|
||||||
scaleFactor = 100 / float64(jxutils.ConstrainPayPercentage(storeDetail.PayPercentage))
|
scaleFactor = 100 / float64(jxutils.ConstrainPayPercentage(storeDetail.PayPercentage))
|
||||||
@@ -1084,7 +1084,6 @@ func updateStoresSkusWithoutSync(ctx *jxcontext.Context, db *dao.DaoDB, storeIDs
|
|||||||
sqlParams = append(sqlParams, skuBindInfo.NameID, utils.DefaultTimeValue)
|
sqlParams = append(sqlParams, skuBindInfo.NameID, utils.DefaultTimeValue)
|
||||||
// globals.SugarLogger.Debug(sql)
|
// globals.SugarLogger.Debug(sql)
|
||||||
if err = dao.GetRows(db, &allBinds, sql, sqlParams...); err == nil {
|
if err = dao.GetRows(db, &allBinds, sql, sqlParams...); err == nil {
|
||||||
fmt.Println("test3")
|
|
||||||
if len(allBinds) > 0 {
|
if len(allBinds) > 0 {
|
||||||
// globals.SugarLogger.Debug(utils.Format4Output(allBinds, false))
|
// globals.SugarLogger.Debug(utils.Format4Output(allBinds, false))
|
||||||
inSkuBinsMap := make(map[int]*StoreSkuBindSkuInfo, len(inSkuBinds))
|
inSkuBinsMap := make(map[int]*StoreSkuBindSkuInfo, len(inSkuBinds))
|
||||||
|
|||||||
Reference in New Issue
Block a user