diff --git a/business/jxcallback/orderman/order.go b/business/jxcallback/orderman/order.go index 379fe52eb..6848b520c 100644 --- a/business/jxcallback/orderman/order.go +++ b/business/jxcallback/orderman/order.go @@ -423,6 +423,9 @@ func updateSingleOrderEarningPrice(order *model.GoodsOrder, db *dao.DaoDB) { } } if len(skuIDMap) > 0 { + if order.VendorOrderID == "5000356075877900459" { + fmt.Println("testupdateSingleOrderEarningPrice", order.VendorOrderID) + } actStoreSkuList, err := dao.GetEffectiveActStoreSkuInfo(db, 0, []int{order.VendorID}, model.ActTypeAll, []int{jxStoreID}, jxutils.IntMap2List(skuIDMap), order.OrderCreatedAt, order.OrderCreatedAt) if err != nil { globals.SugarLogger.Errorf("updateOrderSkuOtherInfo can not get sku promotion info for error:%v", err) diff --git a/business/jxstore/tempop/tempop.go b/business/jxstore/tempop/tempop.go index a9aec6206..bd170cf6f 100644 --- a/business/jxstore/tempop/tempop.go +++ b/business/jxstore/tempop/tempop.go @@ -1498,26 +1498,25 @@ func addSku(outSkuId string, cagtegoryId int, shopCategories []int64, brandId in } func UploadJdsImage(ctx *jxcontext.Context) (err error) { - fmt.Println("test11111111111111111", partner.GetMultiStoreVendorIDs()) - // db := dao.GetDB() - // result1, _ := api.JdShopAPI.GetProvince() - // for _, v := range result1 { - // place1, _ := dao.GetPlaceByName(db, v.AreaName, 1, 0) - // place1.JdsCode = v.AreaID - // dao.UpdateEntity(db, place1, "JdsCode") - // result2, _ := api.JdShopAPI.GetCity(v.AreaID) - // for _, vv := range result2 { - // place2, _ := dao.GetPlaceByName(db, vv.AreaName, 2, 0) - // place2.JdsCode = vv.AreaID - // dao.UpdateEntity(db, place2, "JdsCode") - // result3, _ := api.JdShopAPI.GetCounty(vv.AreaID) - // for _, vvv := range result3 { - // place3, _ := dao.GetPlaceByName(db, vvv.AreaName, 3, 0) - // place3.JdsCode = vvv.AreaID - // dao.UpdateEntity(db, place3, "JdsCode") - // } - // } - // } + db := dao.GetDB() + result1, _ := api.JdShopAPI.GetProvince() + for _, v := range result1 { + place1, _ := dao.GetPlaceByName(db, v.AreaName, 1, 0) + place1.JdsCode = v.AreaID + dao.UpdateEntity(db, place1, "JdsCode") + result2, _ := api.JdShopAPI.GetCity(v.AreaID) + for _, vv := range result2 { + place2, _ := dao.GetPlaceByName(db, vv.AreaName, 2, 0) + place2.JdsCode = vv.AreaID + dao.UpdateEntity(db, place2, "JdsCode") + result3, _ := api.JdShopAPI.GetCounty(vv.AreaID) + for _, vvv := range result3 { + place3, _ := dao.GetPlaceByName(db, vvv.AreaName, 3, 0) + place3.JdsCode = vvv.AreaID + dao.UpdateEntity(db, place3, "JdsCode") + } + } + } // var ( // skuNames []*model.SkuName // db = dao.GetDB() diff --git a/business/model/dao/act.go b/business/model/dao/act.go index ff5049cf4..313e6eae2 100644 --- a/business/model/dao/act.go +++ b/business/model/dao/act.go @@ -413,8 +413,8 @@ func GetEffectiveActStoreSkuInfo(db *DaoDB, actID int, vendorIDs []int, actType if globals.IsStoreSkuAct { sql += " AND t1.is_special = 0" } - // globals.SugarLogger.Debug(sql) - // globals.SugarLogger.Debug(utils.Format4Output(sqlParams, false)) + fmt.Println(sql) + fmt.Println(sqlParams) err = GetRows(db, &actStoreSkuList, sql, sqlParams...) return actStoreSkuList, err }