编制信息导入问题处理 岗位数据重复
This commit is contained in:
parent
4d2e8a8035
commit
5ed00c6a24
|
|
@ -141,7 +141,7 @@ public interface JobMapper {
|
|||
* @param parentJob
|
||||
* @return
|
||||
*/
|
||||
Long getIdByNameAndPid(@Param("jobName") String jobName, @Param("parentCompany") Integer parentCompany, @Param("parentDepartment") Integer parentDepartment, @Param("parentJob") Long parentJob,
|
||||
List<JobPO> getIdByNameAndPid(@Param("jobName") String jobName, @Param("parentCompany") Integer parentCompany, @Param("parentDepartment") Integer parentDepartment, @Param("parentJob") Long parentJob,
|
||||
@Param("jobactivitymark") String jobactivitymark,@Param("jobgroupremark") String jobgroupremark);
|
||||
|
||||
int updateJobCompany(@Param("ids") Collection<Long> ids, @Param("parentCompany") Integer parentCompany, @Param("ecCompany") Integer ecCompany);
|
||||
|
|
|
|||
|
|
@ -482,8 +482,10 @@
|
|||
and delete_type = 0
|
||||
</select>
|
||||
|
||||
<select id="getIdByNameAndPid" resultType="java.lang.Long">
|
||||
select t.id from jcl_org_job t
|
||||
<select id="getIdByNameAndPid" resultMap="BaseResultMap">
|
||||
select
|
||||
<include refid="baseColumns"/>
|
||||
from jcl_org_job t
|
||||
left join hrmjobtitles h on t.ec_jobTitle = h.id
|
||||
left join hrmjobactivities j on h.jobactivityid = j.id
|
||||
left join hrmjobgroups f on j.jobgroupid = f.id
|
||||
|
|
|
|||
|
|
@ -222,9 +222,15 @@ public class StaffInfoImportUtil {
|
|||
continue nextRow;
|
||||
}
|
||||
for (String s : split) {
|
||||
parentJobId = MapperProxyFactory.getProxy(JobMapper.class).getIdByNameAndPid(s, parentCompanyId, parentDepartmentId == null ? 0 : parentDepartmentId, parentJobId == null ? 0 : parentJobId
|
||||
List<JobPO> jobPList = MapperProxyFactory.getProxy(JobMapper.class).getIdByNameAndPid(s, parentCompanyId, parentDepartmentId == null ? 0 : parentDepartmentId, parentJobId == null ? 0 : parentJobId
|
||||
,jobactivitymark,jobgroupremark);
|
||||
if (null == parentJobId) {
|
||||
if (jobPList.size() > 1) {
|
||||
historyDetailPO.setOperateDetail(s + "岗位在岗位管理中存在重复数据,请先处理");
|
||||
historyDetailPO.setStatus("0");
|
||||
OrgImportUtil.saveImportDetailLog(historyDetailPO);
|
||||
continue nextRow;
|
||||
}
|
||||
if (jobPList.size() == 0) {
|
||||
historyDetailPO.setOperateDetail(s + "岗位未找到对应数据");
|
||||
historyDetailPO.setStatus("0");
|
||||
OrgImportUtil.saveImportDetailLog(historyDetailPO);
|
||||
|
|
|
|||
Loading…
Reference in New Issue