266ece32 by 肖初晴

【DAOP-1.0】企业认证

【功能点】测试问题处理
1 parent 0e45b599
1 package com.csbr.qingcloud.portal.domain.vo;
2
3 import csbr.cloud.entity.domain.base.vo.CsbrBaseVO;
4 import csbr.cloud.entity.domain.common.CommonJson;
5 import io.swagger.v3.oas.annotations.media.Schema;
6 import jdk.jfr.Name;
7 import lombok.Data;
8 import lombok.EqualsAndHashCode;
9 import lombok.experimental.Accessors;
10 import java.util.List;
11
12 /**
13 * 人员表 视图对象类
14 *
15 * @author xiaocq
16 * @date 2023-12-19
17 */
18 @Data
19 @Accessors(chain = true)
20 @EqualsAndHashCode(callSuper = true)
21 @Schema(name = "人员详情返回实体")
22 public class StaffRSVO extends CsbrBaseVO {
23
24 /**
25 * 上级guid
26 */
27 @Schema(description = "上级guid")
28 private String leaderGuid;
29
30 /**
31 * 用户guid
32 */
33 @Schema(description = "用户guid")
34 private String userGuid;
35
36 /**
37 * 微信小程序openId
38 */
39 @Schema(description = "微信小程序openId")
40 private String wechatOpenId;
41
42 /**
43 * 微信公众号openId
44 */
45 @Name("微信公众号openId")
46 @Schema(description = "微信公众号openId")
47 private String openId;
48
49 /**
50 * 微信唯一码
51 */
52 @Name("微信唯一码")
53 @Schema(description = "微信唯一码")
54 private String unionId;
55
56 /**
57 * 工作地
58 */
59 @Schema(description = "工作地")
60 private String workAddress;
61
62 /**
63 * 是否部门负责人
64 */
65 @Schema(description = "是否部门负责人")
66 private String isLeader;
67
68 /**
69 * 公司邮箱
70 */
71 @Schema(description = "公司邮箱")
72 private String companyEmail;
73
74 /**
75 * 姓名
76 */
77 @Schema(description = "姓名")
78 private String staffName;
79
80
81 /**
82 * 工号
83 */
84 @Schema(description = "工号")
85 private String staffNo;
86
87 /**
88 * 手机号码
89 */
90 @Schema(description = "手机号码")
91 private String mobileNo;
92
93 /**
94 * 身份证号
95 */
96 @Schema(description = "身份证号")
97 private String idCode;
98
99 /**
100 * 企业guid
101 */
102 @Schema(description = "企业guid")
103 private String tenantGuid;
104
105
106 /**
107 * 部门guidJson
108 */
109 @Schema(description = "部门guidJson")
110 private String organisationGuidJson;
111
112 /**
113 * 组织架构guid列表
114 */
115 @Schema(description = "组织架构guid列表")
116 private String organisationRelGuidJson;
117
118 /**
119 * 岗位guidJson
120 */
121 @Schema(description = "岗位guidJson")
122 private String postGuidJson;
123
124 @Schema(description = "是否管理员")
125 private String isAdmin;
126
127 /********非库表存储属性*****/
128
129
130 /** 职级名称 */
131 @Schema(description = "上级名称")
132 private String leaderName;
133
134 /** 企业名称 */
135 @Schema(description = "企业名称")
136 private String tenantName;
137
138 @Schema(description = "状态Y 期用;S 停用")
139 private String bizState;
140
141 /** 部门guid列表 */
142 @Schema(description = "部门guid列表")
143 private List<String> organisationGuidList;
144
145 /** 部门列表名称 */
146 @Schema(description = "部门列表名称")
147 private List<String> organisationNameList;
148
149 /** 岗位guid列表 */
150 @Schema(description = "岗位guid列表")
151 private List<String> postGuidList;
152
153 /** 岗位列表名称 */
154 @Schema(description = "岗位列表名称")
155 private List<String> postNameList;
156
157 /********字典类*****/
158
159 /********实体类、用户单选、组织机构单选*****/
160
161 /********范围查询*****/
162
163 /********自定义扩展*****/
164
165 /********子对象*****/
166
167 @Schema(description = "菜单模板")
168 private List<CommonJson> funcPermissionTemplateJson;
169
170
171 }
...@@ -2,14 +2,13 @@ package com.csbr.qingcloud.portal.feign; ...@@ -2,14 +2,13 @@ package com.csbr.qingcloud.portal.feign;
2 2
3 import com.csbr.cloud.common.config.FastCallFeignConfiguration; 3 import com.csbr.cloud.common.config.FastCallFeignConfiguration;
4 import com.csbr.cloud.common.response.CommonRes; 4 import com.csbr.cloud.common.response.CommonRes;
5 import com.csbr.qingcloud.portal.domain.vo.StaffRSVO;
5 import com.csbr.qingcloud.portal.domain.vo.TenantRQVO; 6 import com.csbr.qingcloud.portal.domain.vo.TenantRQVO;
6 import org.springframework.cloud.openfeign.FeignClient; 7 import org.springframework.cloud.openfeign.FeignClient;
7 import org.springframework.http.MediaType; 8 import org.springframework.http.MediaType;
8 import org.springframework.validation.annotation.Validated; 9 import org.springframework.validation.annotation.Validated;
9 import org.springframework.web.bind.annotation.GetMapping; 10 import org.springframework.web.bind.annotation.*;
10 import org.springframework.web.bind.annotation.PostMapping; 11
11 import org.springframework.web.bind.annotation.PutMapping;
12 import org.springframework.web.bind.annotation.RequestBody;
13 import java.util.Map; 12 import java.util.Map;
14 13
15 /** 14 /**
...@@ -30,4 +29,7 @@ public interface PersonelFeign { ...@@ -30,4 +29,7 @@ public interface PersonelFeign {
30 @PostMapping(value = "/tenant/check", produces = MediaType.APPLICATION_JSON_VALUE, consumes = MediaType.APPLICATION_JSON_VALUE) 29 @PostMapping(value = "/tenant/check", produces = MediaType.APPLICATION_JSON_VALUE, consumes = MediaType.APPLICATION_JSON_VALUE)
31 CommonRes<Boolean> checkTenant(@Validated @RequestBody TenantRQVO vo); 30 CommonRes<Boolean> checkTenant(@Validated @RequestBody TenantRQVO vo);
32 31
32 @GetMapping(value = "/staff/getByUserGuid", produces = MediaType.APPLICATION_JSON_VALUE, consumes = MediaType.APPLICATION_JSON_VALUE)
33 CommonRes<StaffRSVO> getByUserGuid(@RequestParam String userGuid);
34
33 } 35 }
......
...@@ -457,8 +457,11 @@ public class EnterpriseServiceImpl extends FlowAbstractImpl implements Enterpris ...@@ -457,8 +457,11 @@ public class EnterpriseServiceImpl extends FlowAbstractImpl implements Enterpris
457 dto.setLogonUser(vo.getLogonUser()); 457 dto.setLogonUser(vo.getLogonUser());
458 List<UserVO> userList = userFeign.getUserSomeInfo(dto).getData().getRecords(); 458 List<UserVO> userList = userFeign.getUserSomeInfo(dto).getData().getRecords();
459 if(CollectionUtils.isNotEmpty(userList)){ 459 if(CollectionUtils.isNotEmpty(userList)){
460 StaffRSVO staffVO = personelFeign.getByUserGuid(userList.get(0).getGuid()).getData();
461 if(staffVO != null && StringUtils.isNotBlank(staffVO.getIsAdmin()) && "Y".equals(staffVO.getIsAdmin())){
460 throw new CsbrUserException(UserError.VALIDATE_CODE_ERROR, "账号已存在!"); 462 throw new CsbrUserException(UserError.VALIDATE_CODE_ERROR, "账号已存在!");
461 } 463 }
464 }
462 465
463 dto = new UserQueryDTO(); 466 dto = new UserQueryDTO();
464 dto.setMobileNo(vo.getContactTel()); 467 dto.setMobileNo(vo.getContactTel());
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!