企业注册问题调整

This commit is contained in:
mythxb 2023-07-18 17:26:43 +08:00
parent 075674c02f
commit c9ee1f056e
5 changed files with 59 additions and 16 deletions

View File

@ -1,9 +1,11 @@
package com.rzyc.mapper.user; package com.rzyc.mapper.user;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.rzyc.bean.UserDepart; import com.rzyc.bean.UserDepart;
import com.rzyc.bean.bigdata.user.UnitList; import com.rzyc.bean.bigdata.user.UnitList;
import com.rzyc.bean.user.PerformNum; import com.rzyc.bean.user.PerformNum;
import com.rzyc.bean.user.PerformRecord; import com.rzyc.bean.user.PerformRecord;
import com.rzyc.model.ent.SysEnterprise;
import com.rzyc.model.user.ListPerform; import com.rzyc.model.user.ListPerform;
import com.rzyc.model.user.ListPerformExample; import com.rzyc.model.user.ListPerformExample;
import org.apache.ibatis.annotations.Param; import org.apache.ibatis.annotations.Param;
@ -12,7 +14,7 @@ import org.springframework.stereotype.Repository;
import java.util.List; import java.util.List;
@Repository @Repository
public interface ListPerformMapper { public interface ListPerformMapper extends BaseMapper<SysEnterprise> {
long countByExample(ListPerformExample example); long countByExample(ListPerformExample example);
int deleteByExample(ListPerformExample example); int deleteByExample(ListPerformExample example);

View File

@ -125,6 +125,38 @@ public class ListPerform implements Serializable {
private static final long serialVersionUID = 1L; private static final long serialVersionUID = 1L;
public String getAreaCode() {
return areaCode;
}
public void setAreaCode(String areaCode) {
this.areaCode = areaCode;
}
public String getAreaPath() {
return areaPath;
}
public void setAreaPath(String areaPath) {
this.areaPath = areaPath;
}
public String getAreaPathName() {
return areaPathName;
}
public void setAreaPathName(String areaPathName) {
this.areaPathName = areaPathName;
}
public Integer getPositionType() {
return positionType;
}
public void setPositionType(Integer positionType) {
this.positionType = positionType;
}
public String getParentPath() { public String getParentPath() {
return parentPath; return parentPath;
} }

View File

@ -13,6 +13,10 @@
<result column="SupClassCode" jdbcType="VARCHAR" property="supclasscode" /> <result column="SupClassCode" jdbcType="VARCHAR" property="supclasscode" />
<result column="viewJurisdiction" jdbcType="VARCHAR" property="viewJurisdiction" /> <result column="viewJurisdiction" jdbcType="VARCHAR" property="viewJurisdiction" />
<result column="SupClassName" jdbcType="VARCHAR" property="supclassname" /> <result column="SupClassName" jdbcType="VARCHAR" property="supclassname" />
<result column="area_code" jdbcType="VARCHAR" property="areaCode" />
<result column="area_path" jdbcType="VARCHAR" property="areaPath" />
<result column="area_path_name" jdbcType="VARCHAR" property="areaPathName" />
<result column="position_type" jdbcType="INTEGER" property="positionType" />
<result column="CreatedOn" jdbcType="TIMESTAMP" property="createdon" /> <result column="CreatedOn" jdbcType="TIMESTAMP" property="createdon" />
<result column="CreatedBy" jdbcType="VARCHAR" property="createdby" /> <result column="CreatedBy" jdbcType="VARCHAR" property="createdby" />
<result column="ModifiedOn" jdbcType="TIMESTAMP" property="modifiedon" /> <result column="ModifiedOn" jdbcType="TIMESTAMP" property="modifiedon" />
@ -84,7 +88,7 @@
<sql id="Base_Column_List"> <sql id="Base_Column_List">
ListPerformId, PerformClassCode, PerformClassName, SortId, SysLevel, SupClassId, ListPerformId, PerformClassCode, PerformClassName, SortId, SysLevel, SupClassId,
completion,parent_path,parent_name, completion,parent_path,parent_name,
performName, performName,area_code,area_path,area_path_name,position_type,
SupClassCode, viewJurisdiction,SupClassName, CreatedOn, CreatedBy, ModifiedOn, ModifiedBy SupClassCode, viewJurisdiction,SupClassName, CreatedOn, CreatedBy, ModifiedOn, ModifiedBy
</sql> </sql>
<sql id="Blob_Column_List"> <sql id="Blob_Column_List">

View File

@ -1091,25 +1091,25 @@ public class PcCompanyController extends BaseController{
} }
}else{ }else{
enterprise.setSysenterpriseid(RandomNumber.getUUid()); enterprise.setSysenterpriseid(RandomNumber.getUUid());
getEntAreaCode(enterprise.getAreaCode(),sysEnterprise); getEntAreaCode(enterprise.getAreaCode(),enterprise);
sysEnterprise.setCreatedon(new Date()); enterprise.setCreatedon(new Date());
sysEnterprise.setModifiedon(new Date()); enterprise.setModifiedon(new Date());
sysEnterprise.setState("启用"); enterprise.setState("启用");
sysEnterprise.setAuditStatus(2); enterprise.setAuditStatus(2);
sysEnterprise.setDynamicRiskLevel("100");//新建企业默认100分数 enterprise.setDynamicRiskLevel("100");//新建企业默认100分数
sysEnterprise.setQrCode(entQrCode(sysEnterprise.getSysenterpriseid())); enterprise.setQrCode(entQrCode(enterprise.getSysenterpriseid()));
sysEnterpriseMapper.insert(sysEnterprise); sysEnterpriseMapper.insert(enterprise);
//生成行业对应的企业责任清单不包括岗位的清单只包括行业公共 //生成行业对应的企业责任清单不包括岗位的清单只包括行业公共
SaveEntListThread saveEntListThread = new SaveEntListThread(inListItemMapper,inEntListMapper,getUserId(),sysEnterprise.getWorkClassId(),sysEnterprise.getSysenterpriseid()); SaveEntListThread saveEntListThread = new SaveEntListThread(inListItemMapper,inEntListMapper,getUserId(),enterprise.getWorkClassId(),enterprise.getSysenterpriseid());
Thread thread = new Thread(saveEntListThread); Thread thread = new Thread(saveEntListThread);
thread.start(); thread.start();
thread.join(); thread.join();
//创建多个行业岗位 //创建多个行业岗位
SaveIndustryPostThread saveIndustryPost = new SaveIndustryPostThread(sysEnterprise.getWorkClassId(),sysEnterprise.getSysenterpriseid(),inPostMapper,inPostItemMapper,inPostListMapper,inListItemMapper,sysEnterpriseMapper,entPostMapper, entPostDutyMapper,false); SaveIndustryPostThread saveIndustryPost = new SaveIndustryPostThread(enterprise.getWorkClassId(),enterprise.getSysenterpriseid(),inPostMapper,inPostItemMapper,inPostListMapper,inListItemMapper,sysEnterpriseMapper,entPostMapper, entPostDutyMapper,false);
Thread saveIndustryPostThread = new Thread(saveIndustryPost); Thread saveIndustryPostThread = new Thread(saveIndustryPost);
saveIndustryPostThread.start(); saveIndustryPostThread.start();
@ -1117,11 +1117,11 @@ public class PcCompanyController extends BaseController{
CopyOnWriteArrayList copyOnWriteArrayList = new CopyOnWriteArrayList(); CopyOnWriteArrayList copyOnWriteArrayList = new CopyOnWriteArrayList();
String entUserId = RandomNumber.getUUid(); String entUserId = RandomNumber.getUUid();
String postId = RandomNumber.getUUid(); String postId = RandomNumber.getUUid();
SaveEntPostAndUserThread SaveEntPostAndUserThread = new SaveEntPostAndUserThread(sysEnterprise.getSysenterpriseid(),getUserId(),sysEnterprise.getWorkClassId(),entPostMapper,entUserMapper,constantsConfigure,sysEnterprise.getLegalrepre(),sysEnterprise.getLrlinktel(),sysEnterprise.getEntname(),entUserId,postId,copyOnWriteArrayList,inListMapper,inListItemMapper,entPostDutyMapper); SaveEntPostAndUserThread SaveEntPostAndUserThread = new SaveEntPostAndUserThread(enterprise.getSysenterpriseid(),getUserId(),enterprise.getWorkClassId(),entPostMapper,entUserMapper,constantsConfigure,enterprise.getLegalrepre(),enterprise.getLrlinktel(),enterprise.getEntname(),entUserId,postId,copyOnWriteArrayList,inListMapper,inListItemMapper,entPostDutyMapper);
Thread t = new Thread(SaveEntPostAndUserThread); Thread t = new Thread(SaveEntPostAndUserThread);
//法人履职清单和履职任务 //法人履职清单和履职任务
AssignmentTaskThread textThread = new AssignmentTaskThread(entUserId,sysEnterprise.getSysenterpriseid(),postId,entPostListMapper,entPostTaskMapper,inEntListMapper,getUserId(),inPostListMapper,inPostItemMapper,entUserMapper,entPostMapper); AssignmentTaskThread textThread = new AssignmentTaskThread(entUserId,enterprise.getSysenterpriseid(),postId,entPostListMapper,entPostTaskMapper,inEntListMapper,getUserId(),inPostListMapper,inPostItemMapper,entUserMapper,entPostMapper);
Thread ttThread=new Thread(textThread); Thread ttThread=new Thread(textThread);
ttThread.start(); ttThread.start();
t.start(); t.start();

View File

@ -62,7 +62,12 @@ public class SaveEntListThread implements Runnable{
in.setCreateBy(userId); in.setCreateBy(userId);
in.setCreateTime(new Date()); in.setCreateTime(new Date());
} }
int deleteNumber = inEntListMapper.deleteByEnterpriseId(companyId);
int result = inEntListMapper.insertList(entLists); inEntListMapper.deleteByEnterpriseId(companyId);
if(null != entLists && entLists.size() > 0){
inEntListMapper.insertList(entLists);
}
} }
} }