diff --git a/lib/comm_plan/init.go b/lib/comm_plan/init.go index 5599b26..deb3c04 100644 --- a/lib/comm_plan/init.go +++ b/lib/comm_plan/init.go @@ -3,17 +3,18 @@ package comm_plan import "xorm.io/xorm" var Fn = map[string]func(opt *PlanOpt, totalAmt, integralTotalAmt float64, userList *LvUser, pvd string, sysFee float64, integralSysFee float64, level, levelWeight int, eg *xorm.Engine) error{ - "lv_all": CalcAll, - "niubei_commission": NiuBeiCalcAll, - "niubei_amount": NiuBeiCalcAll, - "lv_self": CalcSelf, - "lv_subsidy": CalcAll, - "lv_price": CalcAll, - "lv_price_public_platoon": CalcAll, - "lv_winery": CalcWinery, - "lv_winery_adv": CalcAdv, - "lv_price_other": CalcOther, - "lv_ds_check": CalcDsCheck, + "lv_all": CalcAll, + "niubei_commission": NiuBeiCalcAll, + "niubei_amount": NiuBeiCalcAll, + "lv_self": CalcSelf, + "lv_subsidy": CalcAll, + "lv_price": CalcAll, + "lv_price_public_platoon": CalcAll, + "lv_commission_public_platoon": CalcAll, + "lv_winery": CalcWinery, + "lv_winery_adv": CalcAdv, + "lv_price_other": CalcOther, + "lv_ds_check": CalcDsCheck, } type NiuBeiIntegralReleaseO2oRatio struct { diff --git a/svc/get_plan_cfg.go b/svc/get_plan_cfg.go index e52d2d8..fe9953a 100644 --- a/svc/get_plan_cfg.go +++ b/svc/get_plan_cfg.go @@ -219,7 +219,7 @@ func GetPlanCfg(eg *xorm.Engine, pvd, masterId string, rewardOpts map[string]*mo return opt, nil } - if zhios_order_relate_utils.InArr(commissionOpt.Mode, []string{"lv_price_public_platoon"}) { + if zhios_order_relate_utils.InArr(commissionOpt.Mode, []string{"lv_price_public_platoon", "lv_commission_public_platoon"}) { if err := json.Unmarshal([]byte(commissionOpt.Data), &subsidyTmpPricePublic); err != nil { return nil, zhios_order_relate_logx.Warn(fmt.Sprintf("%s:分佣方案数据设置错误", masterId)) } diff --git a/svc/reward_commission.go b/svc/reward_commission.go index 2687fe4..3501ad8 100644 --- a/svc/reward_commission.go +++ b/svc/reward_commission.go @@ -261,7 +261,7 @@ func GetRewardCommission(engine *xorm.Engine, rmd *md.CommissionParam, isShare b if ulink == nil { return 0, 0, 0, 0, nil, nil } - if cfg.Mode == "lv_price_public_platoon" { + if cfg.Mode == "lv_price_public_platoon" || cfg.Mode == "lv_commission_public_platoon" { ulink = public(engine, ulink, cfg, newProvider, uid, comf, price, rmd) } comm(commArr, ulink)