|
@@ -12,8 +12,6 @@ import (
|
|
|
"strings"
|
|
|
|
|
|
"app.yhyue.com/moapp/jybase/common"
|
|
|
-
|
|
|
- . "app.yhyue.com/moapp/jypkg/ent/entity"
|
|
|
"bp.jydev.jianyu360.cn/BaseService/gateway/core/router"
|
|
|
"github.com/gogf/gf/v2/net/ghttp"
|
|
|
"github.com/gogf/gf/v2/util/gconv"
|
|
@@ -192,23 +190,6 @@ func (s *sussBi) Filter(r *ghttp.Request) error {
|
|
|
"jyEntUserName": ctx.Sess.EntUserName,
|
|
|
"jyEntUserId": ctx.Sess.EntUserId,
|
|
|
}
|
|
|
- //role//角色,0:个人版1:企业版-企业管理员2:企业版-部门管理员3:企业版-员工
|
|
|
- //entDeptId//部门id
|
|
|
- currentUser := VarCurrentUser.EntInfo(common.IntAll(ctx.Sess.EntId), common.IntAll(ctx.Sess.EntUserId))
|
|
|
- role := 0
|
|
|
- deptId := 0
|
|
|
- if ctx.Sess.PositionType == 1 {
|
|
|
- if currentUser.Role_admin_department {
|
|
|
- role = 2
|
|
|
- }
|
|
|
- if currentUser.Role_admin_system {
|
|
|
- role = 1
|
|
|
- }
|
|
|
- role = 3
|
|
|
- deptId = currentUser.Dept.Id
|
|
|
- }
|
|
|
- replaceMap["jyRole"] = role
|
|
|
- replaceMap["jyEntDeptId"] = deptId
|
|
|
if r.Request.Method == http.MethodPost {
|
|
|
bodyBytes, err := io.ReadAll(r.Request.Body)
|
|
|
if err != nil {
|