sangwenwei 1 年之前
父节点
当前提交
02e821b46e

+ 10 - 0
jeeplus-modules/jeeplus-business/src/main/java/com/jeeplus/business/humanResources/controller/StaffUserInfoController.java

@@ -279,6 +279,16 @@ public class StaffUserInfoController {
         return JSON.toJSONString(pageList);
     }
 
+    /**
+     * 根据联系电话进行判重
+     */
+    @ApiOperation(value = "根据联系电话进行判重")
+    @GetMapping(value = "/getByPhone")
+    public boolean getByPhone(String mobilePhone) {
+        boolean data=staffUserInfoService.getByPhone(mobilePhone);
+        return data;
+    }
+
 
 
 

+ 2 - 0
jeeplus-modules/jeeplus-business/src/main/java/com/jeeplus/business/humanResources/mapper/StaffUserInfoMapper.java

@@ -37,4 +37,6 @@ public interface StaffUserInfoMapper extends BaseMapper<StaffUserInfo> {
     Integer findIsExit(@Param("id") String id, @Param("name")String name);
 
     List<WorkAttachmentInfo> findFiles(@Param("id") String id);
+
+    List<StaffUserInfoDTO> getByPhone(@Param("mobilePhone") String mobilePhone);
 }

+ 6 - 0
jeeplus-modules/jeeplus-business/src/main/java/com/jeeplus/business/humanResources/mapper/xml/StaffUserInfoMapper.xml

@@ -257,6 +257,12 @@
 			AND attachment_id = #{id}
 	</select>
 
+    <select id="getByPhone" resultType="com.jeeplus.business.humanResources.service.dto.StaffUserInfoDTO">
+        select
+            id
+        from staff_user_info where mobile_phone = #{mobilePhone} and del_flag = '0'
+    </select>
+
 
 
 </mapper>

+ 12 - 0
jeeplus-modules/jeeplus-business/src/main/java/com/jeeplus/business/humanResources/service/StaffDimissionService.java

@@ -24,11 +24,14 @@ import com.jeeplus.business.project.mapper.JyProjectMemberMapper;
 import com.jeeplus.business.project.service.JyProjectService;
 import com.jeeplus.business.project.service.dto.JyProjectDTO;
 import com.jeeplus.common.TokenProvider;
+import com.jeeplus.common.constant.CacheNames;
+import com.jeeplus.common.redis.RedisUtils;
 import com.jeeplus.core.query.QueryWrapperGenerator;
 import com.jeeplus.sys.domain.WorkAttachmentInfo;
 import com.jeeplus.sys.feign.IUserApi;
 import com.jeeplus.sys.feign.IWorkAttachmentApi;
 import com.jeeplus.sys.service.dto.UserDTO;
+import com.jeeplus.sys.utils.UserUtils;
 import com.jeeplus.utils.StringUtils;
 import org.springframework.beans.BeanUtils;
 import org.springframework.stereotype.Service;
@@ -352,6 +355,15 @@ public class StaffDimissionService {
     }
 
     public void updateUserById(String id, String loginFlag) {
+        //冻结员工账号
         staffHeirMapper.updateUserById(id,loginFlag);
+
+        UserDTO userDTO = SpringUtil.getBean(IUserApi.class).getById(id);
+        //将该员工的信息从redis删除
+        UserUtils.getOnlineUsers().forEach(dto ->{
+            if (userDTO.getTenantDTO().getId().equals(dto.getTenantDTO().getId()) && userDTO.getName().equals(dto.getName())) {
+                RedisUtils.getInstance ( ).delete ( CacheNames.USER_CACHE_ONLINE_USERS, dto.getToken ( ) );
+            }
+        });
     }
 }

+ 12 - 0
jeeplus-modules/jeeplus-business/src/main/java/com/jeeplus/business/humanResources/service/StaffUserInfoService.java

@@ -607,4 +607,16 @@ public class StaffUserInfoService {
         List<StaffUserInfoDTO> list=staffUserInfoMapper.getList();
         return list;
     }
+
+    /**
+     * 根据联系电话进行判重
+     * @return
+     */
+    public boolean getByPhone(String mobilePhone) {
+        List<StaffUserInfoDTO> userInfoDTO = staffUserInfoMapper.getByPhone(mobilePhone);
+        if (CollectionUtils.isNotEmpty(userInfoDTO)){
+            return true;
+        }
+        return false;
+    }
 }

+ 2 - 2
jeeplus-modules/jeeplus-business/src/main/java/com/jeeplus/business/monthly/service/MonthlyService.java

@@ -149,7 +149,7 @@ public class MonthlyService {
                         item.setProcess("三级校审完成");
                         item.setProcessTime(item.getAudit3UpdateTime());
                     }
-                    if (StringUtils.isNotBlank(item.getReportStatus()) && !item.getReportStatus().equals("5")){
+                    if ((StringUtils.isNotBlank(item.getReportStatus()) && !item.getReportStatus().equals("5")) || StringUtils.isBlank(item.getReportsStatus())){
                         item.setProcess("三级校审完成");
                         item.setProcessTime(item.getAudit3UpdateTime());
                         continue;
@@ -165,7 +165,7 @@ public class MonthlyService {
                         item.setProcess("外审完成");
                         item.setProcessTime(item.getOutTime());
                     }
-                    if (StringUtils.isNotBlank(item.getReportsStatus()) && !item.getReportsStatus().equals("5")){
+                    if ((StringUtils.isNotBlank(item.getReportsStatus()) && !item.getReportsStatus().equals("5")) || StringUtils.isBlank(item.getReportsStatus())){
                         item.setProcess("外审完成");
                         item.setProcessTime(item.getOutTime());
                         continue;

+ 3 - 2
jeeplus-modules/jeeplus-business/src/main/java/com/jeeplus/business/project/domain/JyProject.java

@@ -285,11 +285,12 @@ public class JyProject extends BaseEntity implements Serializable {
     private String auditOffice;
 
     /**
-     * 用印id
+     * 报告签发信息
      */
     @TableField(exist = false)
     private String sealId;
-
+    @TableField(exist = false)
+    private String procInsReportIssuance;
     /**
      * 外审信息
      */

+ 1 - 3
jeeplus-modules/jeeplus-business/src/main/java/com/jeeplus/business/project/mapper/xml/ProjectListMapper.xml

@@ -17,9 +17,7 @@
        a.effective_date,
        a.closing_date,
        a.contract_type as contractType,
-       (SELECT dv.label FROM `sys_dict_value` dv
-       LEFT JOIN sys_dict_type dt on dt.id=dv.dict_type_id
-       where dt.type='jy_contract_type_up' and a.contract_type_first=dv.value) as contractTypeFirst,
+       a.contract_type_first as contractTypeFirst,
        a.contract_amount_type,
        a.contract_amount,
        a.contract_opposite,

+ 9 - 4
jeeplus-modules/jeeplus-business/src/main/java/com/jeeplus/business/project/service/JyProjectService.java

@@ -204,6 +204,8 @@ public class JyProjectService {
                                 //用印类型为报告,则获取报告签发
                                 if ( s.equals(item.getId()) && signet.getTypeStatus().equals("1") ){
                                     item.setSealId(signet.getId());
+                                    item.setProcInsReportIssuance(signet.getProcInsId());
+                                    item.setReportIssuance(signet.getStatus());
                                 }
                                 if (s.equals(item.getId()) && signet.getTypeStatus().equals("2")){
                                     //用印类型为报批,则设置报批签发所需信息
@@ -238,20 +240,23 @@ public class JyProjectService {
         //合同类型查询
         StringBuffer stringBuffer = new StringBuffer();
         String newType="";
-        if (StringUtils.isNotEmpty(i.getContractType())){
+            if (StringUtils.isNotBlank(i.getContractTypeFirst())){
+                newType = jyWorkContractInfoMapper.findType(i.getContractTypeFirst());
+
+            }
+        if (StringUtils.isNotBlank(i.getContractType())){
             if (!i.getContractType().contains(",")){
-                String type= jyWorkContractInfoMapper.findType(i.getContractType());
-                i.setContractType(type);
+                newType= jyWorkContractInfoMapper.findType2(i.getContractType());
             }else {
                 String[] split = i.getContractType().split(",");
                 for (String s : split) {
                     String type= jyWorkContractInfoMapper.findType2(s);
                     stringBuffer.append(type+",");
                     newType=stringBuffer.substring(0,stringBuffer.lastIndexOf(","));
-                    i.setContractType(newType);
                 }
             }
         }
+            i.setContractType(newType);
         //主委托方联系人信息查询
             List<JyWorkClientLinkman> jyWorkClientLinkmen=jyWorkClientInfoMapper.getByNameInfo(i.getLinkmanId());
             i.setLinkmanList(jyWorkClientLinkmen);