|
|
|
@ -33,11 +33,13 @@ import com.engine.organization.util.tree.SearchTreeUtil;
|
|
|
|
|
import com.engine.organization.util.word.CustomXWPFDocument;
|
|
|
|
|
import com.engine.organization.util.word.WordUtil;
|
|
|
|
|
import org.apache.commons.collections.CollectionUtils;
|
|
|
|
|
import org.apache.commons.lang3.StringUtils;
|
|
|
|
|
import org.apache.poi.xwpf.usermodel.Document;
|
|
|
|
|
import org.apache.poi.xwpf.usermodel.XWPFParagraph;
|
|
|
|
|
import org.apache.poi.xwpf.usermodel.XWPFPictureData;
|
|
|
|
|
import org.apache.xmlbeans.XmlOptions;
|
|
|
|
|
import org.openxmlformats.schemas.wordprocessingml.x2006.main.CTBody;
|
|
|
|
|
import weaver.conn.RecordSet;
|
|
|
|
|
import weaver.general.GCONST;
|
|
|
|
|
import weaver.general.StringUtil;
|
|
|
|
|
import weaver.general.Util;
|
|
|
|
@ -587,7 +589,10 @@ public class PersonnelResumeServiceImpl extends Service implements PersonnelResu
|
|
|
|
|
|
|
|
|
|
// 补充人员所有岗位,关联人员及聚才林岗位
|
|
|
|
|
for (ResourcePO resource : resourcePOS) {
|
|
|
|
|
JobPO jobByResource = getJobMapper().getJobByResource(resource);
|
|
|
|
|
if (null == resource) {
|
|
|
|
|
continue;
|
|
|
|
|
}
|
|
|
|
|
JobPO jobByResource = getJobByResource(resource);
|
|
|
|
|
if (null != jobByResource) {
|
|
|
|
|
resource.setJobId(jobByResource.getId());
|
|
|
|
|
builderJobs.add(jobByResource);
|
|
|
|
@ -676,7 +681,10 @@ public class PersonnelResumeServiceImpl extends Service implements PersonnelResu
|
|
|
|
|
|
|
|
|
|
// 补充人员所有岗位,关联人员及聚才林岗位
|
|
|
|
|
for (ResourcePO resource : resourcePOS) {
|
|
|
|
|
JobPO jobByResource = getJobMapper().getJobByResource(resource);
|
|
|
|
|
if (null == resource) {
|
|
|
|
|
continue;
|
|
|
|
|
}
|
|
|
|
|
JobPO jobByResource = getJobByResource(resource);
|
|
|
|
|
if (null != jobByResource) {
|
|
|
|
|
resource.setJobId(jobByResource.getId());
|
|
|
|
|
builderJobs.add(jobByResource);
|
|
|
|
@ -760,4 +768,87 @@ public class PersonnelResumeServiceImpl extends Service implements PersonnelResu
|
|
|
|
|
buildParentComps(parentComp, builderComps, allMaps);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private JobPO getJobByResource(ResourcePO resourcePO) {
|
|
|
|
|
RecordSet rs = new RecordSet();
|
|
|
|
|
String sql = "select\n" +
|
|
|
|
|
" t.id,\n" +
|
|
|
|
|
" t.job_no,\n" +
|
|
|
|
|
" h.jobtitlename,\n" +
|
|
|
|
|
" t.ec_jobTitle,\n" +
|
|
|
|
|
" t.ec_company,\n" +
|
|
|
|
|
" t.ec_department,\n" +
|
|
|
|
|
" t.sequence_id,\n" +
|
|
|
|
|
" t.scheme_id,\n" +
|
|
|
|
|
" t.parent_job,\n" +
|
|
|
|
|
" t.is_key,\n" +
|
|
|
|
|
" t.workplace,\n" +
|
|
|
|
|
" t.description,\n" +
|
|
|
|
|
" t.work_duty,\n" +
|
|
|
|
|
" t.work_authority,\n" +
|
|
|
|
|
" t.show_order,\n" +
|
|
|
|
|
" t.forbidden_tag,\n" +
|
|
|
|
|
" t.grade_id,\n" +
|
|
|
|
|
" t.level_id\n" +
|
|
|
|
|
" from jcl_org_job t\n" +
|
|
|
|
|
" left join hrmjobtitles h on t.ec_jobTitle = h.id\n" +
|
|
|
|
|
" where t.delete_type = 0 ";
|
|
|
|
|
if (null != resourcePO.getSubcompanyid1()) {
|
|
|
|
|
sql += " and t.ec_company = '" + resourcePO.getSubcompanyid1() + "'";
|
|
|
|
|
}
|
|
|
|
|
if (null == resourcePO.getSubcompanyid1()) {
|
|
|
|
|
sql += " and t.ec_company is null";
|
|
|
|
|
}
|
|
|
|
|
if (null != resourcePO.getDepartmentid()) {
|
|
|
|
|
sql += " and t.ec_department = '" + resourcePO.getDepartmentid() + "'";
|
|
|
|
|
}
|
|
|
|
|
if (null != resourcePO.getDepartmentid()) {
|
|
|
|
|
sql += " and t.ec_department is null";
|
|
|
|
|
}
|
|
|
|
|
if (null != resourcePO.getJobtitle()) {
|
|
|
|
|
sql += " and t.ec_jobTitle = '" + resourcePO.getJobtitle() + "'";
|
|
|
|
|
}
|
|
|
|
|
rs.executeQuery(sql);
|
|
|
|
|
if (rs.next()) {
|
|
|
|
|
String id = rs.getString("id");
|
|
|
|
|
String job_no = rs.getString("job_no");
|
|
|
|
|
String jobtitlename = rs.getString("jobtitlename");
|
|
|
|
|
String ec_jobTitle = rs.getString("ec_jobTitle");
|
|
|
|
|
String ec_company = rs.getString("ec_company");
|
|
|
|
|
String ec_department = rs.getString("ec_department");
|
|
|
|
|
String sequence_id = rs.getString("sequence_id");
|
|
|
|
|
String scheme_id = rs.getString("scheme_id");
|
|
|
|
|
String parent_job = rs.getString("parent_job");
|
|
|
|
|
String is_key = rs.getString("is_key");
|
|
|
|
|
String workplace = rs.getString("workplace");
|
|
|
|
|
String description = rs.getString("description");
|
|
|
|
|
String work_duty = rs.getString("work_duty");
|
|
|
|
|
String work_authority = rs.getString("work_authority");
|
|
|
|
|
String show_order = rs.getString("show_order");
|
|
|
|
|
String forbidden_tag = rs.getString("forbidden_tag");
|
|
|
|
|
String grade_id = rs.getString("grade_id");
|
|
|
|
|
String level_id = rs.getString("level_id");
|
|
|
|
|
JobPO jobPO = new JobPO();
|
|
|
|
|
jobPO.setId(StringUtils.isBlank(id) ? null : Long.parseLong(id));
|
|
|
|
|
jobPO.setJobNo(job_no);
|
|
|
|
|
jobPO.setJobTitleName(jobtitlename);
|
|
|
|
|
jobPO.setEcJobTitle(StringUtils.isBlank(ec_jobTitle) ? null : Integer.parseInt(ec_jobTitle));
|
|
|
|
|
jobPO.setEcCompany(StringUtils.isBlank(ec_company) ? null : Integer.parseInt(ec_company));
|
|
|
|
|
jobPO.setEcDepartment(StringUtils.isBlank(ec_department) ? null : Integer.parseInt(ec_department));
|
|
|
|
|
jobPO.setSequenceId(StringUtils.isBlank(sequence_id) ? null : Long.parseLong(sequence_id));
|
|
|
|
|
jobPO.setSchemeId(StringUtils.isBlank(scheme_id) ? null : Long.parseLong(scheme_id));
|
|
|
|
|
jobPO.setParentJob(StringUtils.isBlank(parent_job) ? null : Long.parseLong(parent_job));
|
|
|
|
|
jobPO.setIsKey(StringUtils.isBlank(is_key) ? null : Integer.parseInt(is_key));
|
|
|
|
|
jobPO.setWorkplace(workplace);
|
|
|
|
|
jobPO.setDescription(description);
|
|
|
|
|
jobPO.setWorkDuty(work_duty);
|
|
|
|
|
jobPO.setWorkAuthority(work_authority);
|
|
|
|
|
jobPO.setShowOrder(StringUtils.isBlank(show_order) ? null : Integer.parseInt(show_order));
|
|
|
|
|
jobPO.setForbiddenTag(StringUtils.isBlank(forbidden_tag) ? null : Integer.parseInt(forbidden_tag));
|
|
|
|
|
jobPO.setGradeId(grade_id);
|
|
|
|
|
jobPO.setLevelId(level_id);
|
|
|
|
|
return jobPO;
|
|
|
|
|
}
|
|
|
|
|
return null;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|