diff --git a/app/hdl/institutional_management/public_platoon/hdl_basic.go b/app/hdl/institutional_management/public_platoon/hdl_basic.go index 219fa99..16280f8 100644 --- a/app/hdl/institutional_management/public_platoon/hdl_basic.go +++ b/app/hdl/institutional_management/public_platoon/hdl_basic.go @@ -1,6 +1,7 @@ package public_platoon import ( + "applet/app/cfg" "applet/app/db" "applet/app/e" md "applet/app/md/institutional_management/public_platoon" @@ -8,6 +9,7 @@ import ( "applet/app/utils" "code.fnuoos.com/EggPlanet/egg_models.git/src/implement" "code.fnuoos.com/EggPlanet/egg_models.git/src/model" + rule "code.fnuoos.com/EggPlanet/egg_system_rules.git" ruleSvc "code.fnuoos.com/EggPlanet/egg_system_rules.git/rule/egg_energy" "errors" "github.com/gin-gonic/gin" @@ -656,6 +658,8 @@ func AddCommunityDividends(c *gin.Context) { e.OutErr(c, e.ERR_DB_ORM, err1.Error()) return } + + rule.Init(cfg.RedisAddr) err2 := ruleSvc.AddCommunityDividends(db.Db, req.Amount, req.Name, *basic) if err2 != nil { e.OutErr(c, e.ERR_DB_ORM, err2.Error())