|
|
|
@ -312,7 +312,7 @@ insert into jcl_org_map
|
|
|
|
|
(id,ftype,fobjid,fecid,uuid,fclass,fclassname,fnumber,fname,fleader,fleaderimg,
|
|
|
|
|
fleadername,fleaderjobid,fleaderjob,fleaderlv,fleaderst,fparentid,fobjparentid,
|
|
|
|
|
fplan,fonjob,fisvitual,fdatebegin,fdateend)
|
|
|
|
|
select 0,0,0,1,uuid,0,'行政维度','00',companyname,0,'','',0,'','','',-1,0,0,0,0,to_date(sysdate),to_date('2099-12-31','yyyy-mm-dd') from HrmCompany;
|
|
|
|
|
select 0,0,0,1,uuid,0,'行政维度','00',companyname,0,'','',0,'','','',-1,0,0,0,0,to_date(sysdate),to_date('2099-12-31','yyyy-mm-dd') from HrmCompany
|
|
|
|
|
/
|
|
|
|
|
|
|
|
|
|
insert into jcl_org_map
|
|
|
|
@ -334,7 +334,7 @@ from
|
|
|
|
|
left join (select subcompanyid1,count(1) fcnt from hrmresource where status<=3 group by subcompanyid1) f
|
|
|
|
|
on f.subcompanyid1=b.id
|
|
|
|
|
left join cus_fielddata g on c.id=g.id and g.scope='HrmCustomFieldByInfoType' and g.scopeid=3
|
|
|
|
|
where nvl(a.delete_type,0) <>1 and nvl(a.forbidden_tag,0) <>1;
|
|
|
|
|
where nvl(a.delete_type,0) <>1 and nvl(a.forbidden_tag,0) <>1
|
|
|
|
|
/
|
|
|
|
|
|
|
|
|
|
insert into jcl_org_map
|
|
|
|
@ -357,7 +357,7 @@ from
|
|
|
|
|
group by dept_id) e on a.id=e.dept_id
|
|
|
|
|
left join (select departmentid,count(1) fcnt from hrmresource where status<=3 group by departmentid) f on f.departmentid=b.id
|
|
|
|
|
left join cus_fielddata g on c.id=g.id and g.scope='HrmCustomFieldByInfoType' and g.scopeid=3
|
|
|
|
|
where nvl(a.delete_type,0) <>1 and nvl(a.forbidden_tag,0) <>1;
|
|
|
|
|
where nvl(a.delete_type,0) <>1 and nvl(a.forbidden_tag,0) <>1
|
|
|
|
|
/
|
|
|
|
|
|
|
|
|
|
insert into jcl_org_map
|
|
|
|
@ -380,10 +380,10 @@ from JCL_ORG_job a
|
|
|
|
|
inner join jcl_org_dept d on a.uuid=b.uuid
|
|
|
|
|
group by d.id,b.jobtitlename) f
|
|
|
|
|
on f.id=a.parent_dept and a.job_name=f.jobtitlename
|
|
|
|
|
where nvl(a.delete_type,0) <>1 and nvl(a.forbidden_tag,0) <>1;
|
|
|
|
|
where nvl(a.delete_type,0) <>1 and nvl(a.forbidden_tag,0) <>1
|
|
|
|
|
/
|
|
|
|
|
|
|
|
|
|
delete from cus_fielddata where scopeid=-1;
|
|
|
|
|
delete from cus_fielddata where scopeid=-1
|
|
|
|
|
/
|
|
|
|
|
insert into cus_fielddata(scope, scopeid, id, field100002)
|
|
|
|
|
select 'HrmCustomFieldByInfoType',-1,a.id,'199_'||to_char(e.id)
|
|
|
|
@ -391,7 +391,7 @@ from hrmresource a
|
|
|
|
|
left join HrmJobTitles b on a.jobtitle=b.id
|
|
|
|
|
left join hrmdepartment c on a.departmentid=c.id
|
|
|
|
|
left join JCL_ORG_DEPT d on c.uuid=d.uuid
|
|
|
|
|
left join jcl_org_job e on d.id=e.parent_dept and e.job_name=b.jobtitlename;
|
|
|
|
|
left join jcl_org_job e on d.id=e.parent_dept and e.job_name=b.jobtitlename
|
|
|
|
|
/
|
|
|
|
|
|
|
|
|
|
insert into jcl_org_map
|
|
|
|
@ -406,5 +406,5 @@ select a.id+300000000,4,a.id,a.id,a.uuid,0,'行政维度',a.workcode,a.lastname,
|
|
|
|
|
from hrmresource a
|
|
|
|
|
left join hrmjobtitles b on a.jobtitle=b.id
|
|
|
|
|
left join cus_fielddata c on a.id=c.id and c.scope='HrmCustomFieldByInfoType' and c.scopeid=-1
|
|
|
|
|
where a.status<4;
|
|
|
|
|
where a.status<4
|
|
|
|
|
/
|