-- 添加权限项：法律实体/hbss_lawentity、招聘场景/hbss_recruscene
DELETE FROM t_hrcs_permrelat WHERE FID = 1510889896556994560;
INSERT INTO t_hrcs_permrelat(FID,FCREATETIME,FPERMITEMID,FMODIFIERID,FMODIFYTIME,FAPPID,FDESCRIPTION,FCREATORID,FENTITYTYPEID) VALUES (1510889896556994560,{ts'2022-09-16  00:00:00'},'QXX0001',1285511430891740160,{ts'2022-09-16  00:00:00'},'XYRL3+A8Z+Z','预置数据专用-基础中台',1285511430891740160,'hbss_lawentity'); 
DELETE FROM t_hrcs_permrelat WHERE FID = 1510890536330961920;
INSERT INTO t_hrcs_permrelat(FID,FCREATETIME,FPERMITEMID,FMODIFIERID,FMODIFYTIME,FAPPID,FDESCRIPTION,FCREATORID,FENTITYTYPEID) VALUES (1510890536330961920,{ts'2022-09-16  00:00:00'},'QXX0001',1285511430891740160,{ts'2022-09-16  00:00:00'},'XYRL3+A8Z+Z','预置数据专用-基础中台',1285511430891740160,'hbss_recruscene'); 

DELETE FROM t_hrcs_permrelatentry WHERE FENTRYID = 1510889896556994561;
INSERT INTO t_hrcs_permrelatentry(FID,FISSYSPRESET,FPERMITEMID,FENTRYID,FSEQ,FAPPID,FENTITYTYPEID) VALUES (1510889896556994560,'0','QXX0001',1510889896556994561,1,'XYRL3+A8Z+Z','hbss_basedatalist'); 
DELETE FROM t_hrcs_permrelatentry WHERE FENTRYID = 1510890536330961921;
INSERT INTO t_hrcs_permrelatentry(FID,FISSYSPRESET,FPERMITEMID,FENTRYID,FSEQ,FAPPID,FENTITYTYPEID) VALUES (1510890536330961920,'0','QXX0001',1510890536330961921,1,'XYRL3+A8Z+Z','hbss_basedatalist'); 


-- 删除权限项1：涉及到关联了HR基础资料，但已经不存在的基础资料的权限项
delete from t_hrcs_permrelatentry where fid in (select fid from t_hrcs_permrelat where fid = 1357951224044861130 and fentitytypeid = 'hbss_workexp');
delete from t_hrcs_permrelatentry where fid in (select fid from t_hrcs_permrelat where fid = 1357951224044861157 and fentitytypeid = 'hbss_practquallevel');
delete from t_hrcs_permrelatentry where fid in (select fid from t_hrcs_permrelat where fid = 1357951224044861166 and fentitytypeid = 'hbss_corporateorg');
delete from t_hrcs_permrelatentry where fid in (select fid from t_hrcs_permrelat where fid = 1357951224044861170 and fentitytypeid = 'hbss_periodicalcategory');
delete from t_hrcs_permrelatentry where fid in (select fid from t_hrcs_permrelat where fid = 1357951224044861171 and fentitytypeid = 'hbss_periodicalgrade');

delete from t_hrcs_permrelat where fid = 1357951224044861130 and fentitytypeid = 'hbss_workexp';
delete from t_hrcs_permrelat where fid = 1357951224044861157 and fentitytypeid = 'hbss_practquallevel';
delete from t_hrcs_permrelat where fid = 1357951224044861166 and fentitytypeid = 'hbss_corporateorg';
delete from t_hrcs_permrelat where fid = 1357951224044861170 and fentitytypeid = 'hbss_periodicalcategory';
delete from t_hrcs_permrelat where fid = 1357951224044861171 and fentitytypeid = 'hbss_periodicalgrade';

-- 删除权限项2：已经不再需要关联HR基础资料的基础资料的权限项
delete from t_hrcs_permrelatentry where fid =1357951224044861134 and fentitytypeid ='hbss_basedatalist';
delete from t_hrcs_permrelatentry where fid =1357951224044861138 and fentitytypeid ='hbss_basedatalist';
delete from t_hrcs_permrelatentry where fid =1357951224044861139 and fentitytypeid ='hbss_basedatalist';
delete from t_hrcs_permrelatentry where fid =1357951224044861140 and fentitytypeid ='hbss_basedatalist';
delete from t_hrcs_permrelatentry where fid =1357951224044861153 and fentitytypeid ='hbss_basedatalist';
delete from t_hrcs_permrelatentry where fid =1357951224044861154 and fentitytypeid ='hbss_basedatalist';
delete from t_hrcs_permrelatentry where fid =1357951224044861179 and fentitytypeid ='hbss_basedatalist';
delete from t_hrcs_permrelatentry where fid =1357951224044861182 and fentitytypeid ='hbss_basedatalist';
delete from t_hrcs_permrelatentry where fid =1357951224044861184 and fentitytypeid ='hbss_basedatalist';
delete from t_hrcs_permrelatentry where fid =1357951224044861185 and fentitytypeid ='hbss_basedatalist';

delete from t_hrcs_permrelat where fid =1357951224044861134 and fentitytypeid ='hbpm_reportcoreltype';
delete from t_hrcs_permrelat where fid =1357951224044861138 and fentitytypeid ='hbss_action';
delete from t_hrcs_permrelat where fid =1357951224044861139 and fentitytypeid ='hbss_actiontype';
delete from t_hrcs_permrelat where fid =1357951224044861140 and fentitytypeid ='hrcs_msgcreatebo';
delete from t_hrcs_permrelat where fid =1357951224044861153 and fentitytypeid ='hbss_hrbusinessfield';
delete from t_hrcs_permrelat where fid =1357951224044861154 and fentitytypeid ='hbss_numberprefix';
delete from t_hrcs_permrelat where fid =1357951224044861179 and fentitytypeid ='hbss_recrutyp';
delete from t_hrcs_permrelat where fid =1357951224044861182 and fentitytypeid ='hbss_teamtype';
delete from t_hrcs_permrelat where fid =1357951224044861184 and fentitytypeid ='hbss_resacqmthd';
delete from t_hrcs_permrelat where fid =1357951224044861185 and fentitytypeid ='hbss_bussinessfield';



    
