Преглед изворни кода

feat: 小程序放开全角色

shc пре 1 година
родитељ
комит
65067083c6

+ 3 - 7
hnqz-upms/hnqz-upms-biz/src/main/java/com/qunzhixinxi/hnqz/admin/controller/ApiController.java

@@ -953,12 +953,8 @@ public class ApiController {
                 management = agent.getManagement();
             }
 
-            // 小程序角色:5-全职学术信息沟通专员, 6-兼职学术信息沟通专员, 10-兼职CRC, 13-HCP, 31-招商经理
-            List<Integer> roleIdList =
-                    sysU.getRoleList().stream()
-                            .filter(item -> item.getRoleId() == 5 || item.getRoleId() == 6 || item.getRoleId() == 10
-                                    || item.getRoleId() == 13 || item.getRoleId() == 31)
-                            .map(SysRole::getRoleId).collect(Collectors.toList());
+            // 小程序全角色列表放开
+            List<Integer> roleIdList = sysU.getRoleList().stream().map(SysRole::getRoleId).collect(Collectors.toList());
 
             boolean managementFlag = ("2".equals(management) && roleIdList.contains(5))
                     || ("3".equals(management) && (roleIdList.contains(6) || roleIdList.contains(10)))
@@ -1007,7 +1003,7 @@ public class ApiController {
             mapOne.put("packageList", listMap);
             mapOne.put("waitApprove", String.valueOf(waitApprove));
             mapOne.put("onTheWay", String.valueOf(onTheWay));
-            mapOne.put("jumpFlag", "北京遥领医疗科技有限公司".equals(sysDept.getName()) ? "1" : "0");
+            mapOne.put("jumpFlag", "0");
 
             // 查询配置了任务类型模板的任务类型
             mapOne.put("hasTaskTypeTemplate", wmDeptTaskTypeTemplateService.listTaskTypeByDeptId(sysU.getDeptId()));

+ 1 - 4
hnqz-upms/hnqz-upms-biz/src/main/java/com/qunzhixinxi/hnqz/admin/controller/SysUserController.java

@@ -37,7 +37,6 @@ import com.qunzhixinxi.hnqz.admin.service.SysUserAreaService;
 import com.qunzhixinxi.hnqz.admin.service.SysUserService;
 import com.qunzhixinxi.hnqz.admin.service.WmPlatformQuizTestResultService;
 import com.qunzhixinxi.hnqz.common.core.constant.CommonConstants;
-import com.qunzhixinxi.hnqz.common.core.constant.SecurityConstants;
 import com.qunzhixinxi.hnqz.common.core.entity.BaseEntity;
 import com.qunzhixinxi.hnqz.common.core.util.R;
 import com.qunzhixinxi.hnqz.common.log.annotation.SysLog;
@@ -57,7 +56,6 @@ import org.springframework.web.bind.annotation.PathVariable;
 import org.springframework.web.bind.annotation.PostMapping;
 import org.springframework.web.bind.annotation.PutMapping;
 import org.springframework.web.bind.annotation.RequestBody;
-import org.springframework.web.bind.annotation.RequestHeader;
 import org.springframework.web.bind.annotation.RequestMapping;
 import org.springframework.web.bind.annotation.RequestParam;
 import org.springframework.web.bind.annotation.RestController;
@@ -385,8 +383,7 @@ public class SysUserController {
 
         SysDept sysDept = sysDeptService.getById(userDto.getDeptId());
 
-        List<SysUser> queryUserByPhoneList =
-                userService.list(Wrappers.<SysUser>lambdaQuery().eq(SysUser::getUsername, userDto.getUsername()));
+        List<SysUser> queryUserByPhoneList = userService.list(Wrappers.<SysUser>lambdaQuery().eq(SysUser::getUsername, userDto.getUsername()));
         if (CollUtil.isNotEmpty(queryUserByPhoneList)) {
             SysUser queryUserByPhone = queryUserByPhoneList.get(0);
             if (!StrUtil.equals(queryUserByPhone.getRealname(), userDto.getRealname())) {

+ 1 - 2
hnqz-upms/hnqz-upms-biz/src/main/java/com/qunzhixinxi/hnqz/admin/controller/WmDaAgentController.java

@@ -445,8 +445,7 @@ public class WmDaAgentController {
         }
 
         // 查询当前企业的csm维护人
-        List<SysDeptCsm> deptCsms = sysDeptCsmMapper.selectList(Wrappers.<SysDeptCsm>lambdaQuery()
-                .eq(SysDeptCsm::getDeptId, deptId));
+        List<SysDeptCsm> deptCsms = sysDeptCsmMapper.selectList(Wrappers.<SysDeptCsm>lambdaQuery().eq(SysDeptCsm::getDeptId, deptId));
         if (CollUtil.isNotEmpty(deptCsms)) {
             deptCsms.forEach(csm -> {
                 // CSM创建的企业,在创建cso时, 负责人默认是该CSM