Browse Source

公司与人员调整

fllmoyu 4 years ago
parent
commit
ec84329c09

+ 3 - 0
common/src/main/resources/mapper/base/CompanyInfo.xml

@@ -160,6 +160,9 @@
 			<if test="searchParams.industry != null">
 				and a.industry_ = #{searchParams.industry}
 			</if>
+			<if test="searchParams.inside != null">
+				and a.inside_ = #{searchParams.inside}
+			</if>
 		</where>
 		<foreach item="sort" collection="sortList"  open="order by" separator=",">
 	        ${sort.name} ${sort.order}

+ 1 - 0
web/src/main/java/com/jpsoft/enterprise/modules/mobile/controller/CompanyInfoApiController.java

@@ -198,6 +198,7 @@ public class CompanyInfoApiController {
             if (StringUtils.isNotBlank(industry)) {
                 searchParams.put("industry", industry);
             }
+            searchParams.put("inside",0);
 
             List<Sort> sortList = new ArrayList<>();
             sortList.add(new Sort("create_time", "desc"));

+ 28 - 2
web/src/main/java/com/jpsoft/enterprise/modules/mobile/controller/PersonInfoApiController.java

@@ -182,6 +182,15 @@ public class PersonInfoApiController {
 
             String token = JwtUtil.createToken(jwtSecret, personInfo.getId() + "", DateUtil.offsetHour(new Date(), 6));
 
+
+            if (StringUtils.isNotBlank(personInfo.getRegisterType())){
+                String registerTypeName = dataDictionaryService.findNameByCatalogNameAndValue("注册用户类型", personInfo.getRegisterType());
+                personInfo.setRegisterTypeName(registerTypeName);
+            }
+            if (StringUtils.isNotBlank(personInfo.getTitle())){
+                String titleName = dataDictionaryService.findNameByCatalogNameAndValue("用户头衔",personInfo.getTitle());
+                personInfo.setTitleName(titleName);
+            }
             Map<String, Object> dataMap = new HashMap<String, Object>();
             dataMap.put("personInfo", personInfo);
             dataMap.put("token", token);
@@ -249,6 +258,15 @@ public class PersonInfoApiController {
 
                 String token = JwtUtil.createToken(jwtSecret, personInfo.getId() + "", DateUtil.offsetHour(new Date(), 6));
 
+                if (StringUtils.isNotBlank(personInfo.getRegisterType())){
+                    String registerTypeName = dataDictionaryService.findNameByCatalogNameAndValue("注册用户类型", personInfo.getRegisterType());
+                    personInfo.setRegisterTypeName(registerTypeName);
+                }
+                if (StringUtils.isNotBlank(personInfo.getTitle())){
+                    String titleName = dataDictionaryService.findNameByCatalogNameAndValue("用户头衔",personInfo.getTitle());
+                    personInfo.setTitleName(titleName);
+                }
+
                 dataMap.put("personInfo", personInfo);
                 dataMap.put("token", token);
                 dataMap.put("companyInfo", companyInfoDetailDTO);
@@ -353,8 +371,16 @@ public class PersonInfoApiController {
                 PersonInfo personInfo = personInfoService.findByOpenId(openId);
                 if (personInfo != null) {
                     String token = JwtUtil.createToken(jwtSecret, personInfo.getId() + "", DateUtil.offsetHour(new Date(), 6));
-                    String registerTypeName = dataDictionaryService.findNameByCatalogNameAndValue("注册用户类型", personInfo.getRegisterType());
-                    personInfo.setRegisterTypeName(registerTypeName);
+                    if (StringUtils.isNotBlank(personInfo.getRegisterType())){
+                        String registerTypeName = dataDictionaryService.findNameByCatalogNameAndValue("注册用户类型", personInfo.getRegisterType());
+                        personInfo.setRegisterTypeName(registerTypeName);
+                    }
+                    if (StringUtils.isNotBlank(personInfo.getTitle())){
+                        String titleName = dataDictionaryService.findNameByCatalogNameAndValue("用户头衔",personInfo.getTitle());
+                        personInfo.setTitleName(titleName);
+                    }
+
+
                     dataMap.put("personInfo", personInfo);
                     dataMap.put("token", token);
                     CompanyInfoDetailDTO companyInfoDetailDTO = new CompanyInfoDetailDTO();