1
This commit is contained in:
@@ -2152,8 +2152,7 @@ func RefreshOrderSkuInfo(ctx *jxcontext.Context, vendorOrderID string, vendorID,
|
||||
return fmt.Errorf("未找到此门店商品!")
|
||||
}
|
||||
storeSku := storeSkus[0]
|
||||
//if v.ShopPrice == v.EarningPrice {
|
||||
if beego.BConfig.RunMode == "jxgy" || beego.BConfig.RunMode == "jxpet" {
|
||||
if beego.BConfig.RunMode == model.ServerTypeFruits || beego.BConfig.RunMode == model.ServerTypePet {
|
||||
if v.SalePrice > v.ShopPrice {
|
||||
v.EarningPrice = int64(math.Round(float64(storeSku.Price) * float64(order.OrderPayPercentage) / 100))
|
||||
} else {
|
||||
@@ -2162,7 +2161,6 @@ func RefreshOrderSkuInfo(ctx *jxcontext.Context, vendorOrderID string, vendorID,
|
||||
} else {
|
||||
v.EarningPrice = int64(math.Round(float64(storeSku.Price) * float64(order.OrderPayPercentage) / 100))
|
||||
}
|
||||
//}
|
||||
v.ShopPrice = int64(storeSku.Price)
|
||||
dao.UpdateEntity(db, v, "ShopPrice", "EarningPrice")
|
||||
return err
|
||||
|
||||
@@ -471,7 +471,7 @@ func (c *OrderManager) ExportOrders(ctx *jxcontext.Context, fromDateStr, toDateS
|
||||
}
|
||||
if v.SkuCount2 > 0 {
|
||||
var skuStr string
|
||||
if beego.BConfig.RunMode == "jxgy" || beego.BConfig.RunMode == "jxpet" {
|
||||
if beego.BConfig.RunMode == model.ServerTypeFruits || beego.BConfig.RunMode == model.ServerTypePet {
|
||||
skuStr = strings.Join([]string{
|
||||
utils.Int2Str(v.SkuID),
|
||||
utils.Int2Str(v.SkuCount2),
|
||||
@@ -1676,9 +1676,9 @@ func RefreshJdShopOrdersEarningPrice(ctx *jxcontext.Context, orderStartTime, ord
|
||||
db = dao.GetDB()
|
||||
appOrgCode string
|
||||
)
|
||||
if beego.BConfig.RunMode == "jxgy" {
|
||||
if beego.BConfig.RunMode == model.ServerTypeFruits {
|
||||
appOrgCode = "339032"
|
||||
} else if beego.BConfig.RunMode == "jxpet" {
|
||||
} else if beego.BConfig.RunMode == model.ServerTypePet {
|
||||
appOrgCode = "jxpet_apporg_code"
|
||||
} else {
|
||||
appOrgCode = "320406"
|
||||
|
||||
Reference in New Issue
Block a user