|
@@ -168,93 +168,7 @@
|
|
|
ORDER BY a.create_time DESC
|
|
|
</select>
|
|
|
|
|
|
- <select id="findPageList2" resultType="com.jeeplus.business.project.domain.JyProject">
|
|
|
- SELECT
|
|
|
- distinct
|
|
|
- a.id,
|
|
|
- a.create_by_id as create_by,
|
|
|
- a.create_time,
|
|
|
- a.update_by_id,
|
|
|
- a.update_time,
|
|
|
- a.del_flag,
|
|
|
- a.name,
|
|
|
- a.no,
|
|
|
- a.contract_id,
|
|
|
- a.contract_name,
|
|
|
- a.client,
|
|
|
- a.client_name,
|
|
|
- a.status,
|
|
|
- a.report_issuance,
|
|
|
- a.contract_status,
|
|
|
- a.project_place,
|
|
|
- a.build_place,
|
|
|
- a.project_overview,
|
|
|
- a.special,
|
|
|
- a.contract_project_no,
|
|
|
- (select name from sys_user where id=a.project_leader) as projectLeader,
|
|
|
- a.proc_ins_id,
|
|
|
- a.process_definition_id,
|
|
|
- b.name AS create_by_id,
|
|
|
- art.ID_ as taskId,
|
|
|
- wci.primary_linkman as primaryLinkman,
|
|
|
- wci.contract_type_first as contractTypeFirst,
|
|
|
- wci.no as contractNo,
|
|
|
- wci.contract_amount as contractAmount,
|
|
|
- pa1.status as firstInstanceStatus,
|
|
|
- pa1.id as auditId1,
|
|
|
- pa1.proc_ins_id as procInsId1,
|
|
|
- pa1.exceed_time_status as exceedTimeStatus,
|
|
|
- pa2.status as secondInstanceStatus,
|
|
|
- pa2.id as auditId2,
|
|
|
- pa2.proc_ins_id as procInsId2,
|
|
|
- pa3.status as thirdInstanceStatus,
|
|
|
- pa3.id as auditId3,
|
|
|
- pa3.proc_ins_id as procInsId3,
|
|
|
- art1.ID_ as task_id_audit1,
|
|
|
- art2.ID_ as task_id_audit2,
|
|
|
- art3.ID_ as task_id_audit3,
|
|
|
- po.status as outInstance,
|
|
|
- po.id as outInstanceId,
|
|
|
- po.proc_ins_id as procInsIdOut,
|
|
|
- art4.ID_ as task_id_out,
|
|
|
- par.status as reviewStatus,
|
|
|
- par.id as archiveId,
|
|
|
- par.proc_ins_id as procInsIdArchive,
|
|
|
- art5.ID_ as task_id_archive,
|
|
|
- peq.status as eiaStatus,
|
|
|
- peq.id as eiaId,
|
|
|
- peq.proc_ins_id as procInsIdEia,
|
|
|
- art6.ID_ as task_id_Eia,
|
|
|
- bc.member_count
|
|
|
- FROM
|
|
|
- jy_project_record a
|
|
|
- LEFT JOIN sys_user b ON a.create_by_id = b.id
|
|
|
- LEFT JOIN sys_user c ON a.project_leader = c.id
|
|
|
- LEFT JOIN jy_work_contract_info wci ON wci.id = a.contract_id and wci.del_flag = '0'
|
|
|
- LEFT JOIN act_ru_task art ON a.proc_ins_id = art.PROC_INST_ID_
|
|
|
- left join jy_project_audit pa1 on pa1.project_id = a.id and pa1.audit_level = '1' and pa1.del_flag = '0'
|
|
|
- LEFT JOIN jy_project_audit pa2 ON pa2.project_id = a.id and pa2.audit_level = '2' and pa2.del_flag = '0'
|
|
|
- LEFT JOIN jy_project_audit pa3 ON pa3.project_id = a.id and pa3.audit_level = '3' and pa3.del_flag = '0'
|
|
|
- LEFT JOIN act_ru_task art1 ON pa1.proc_ins_id = art1.PROC_INST_ID_
|
|
|
- LEFT JOIN act_ru_task art2 ON pa2.proc_ins_id = art2.PROC_INST_ID_
|
|
|
- LEFT JOIN act_ru_task art3 ON pa3.proc_ins_id = art3.PROC_INST_ID_
|
|
|
- left join jy_project_outinstance po on a.id=po.project_id
|
|
|
- LEFT JOIN act_ru_task art4 ON po.proc_ins_id = art4.PROC_INST_ID_
|
|
|
- left join jy_project_archive par on a.id=par.project_id
|
|
|
- LEFT JOIN act_ru_task art5 ON par.proc_ins_id = art5.PROC_INST_ID_
|
|
|
- left join jy_project_eia_qualification peq on a.id=peq.project_id
|
|
|
- LEFT JOIN act_ru_task art6 ON peq.proc_ins_id = art6.PROC_INST_ID_
|
|
|
- left join (select rec.id,count(cw_pm.id) as member_count
|
|
|
- from jy_project_record rec
|
|
|
- left join jy_project_members cw_pm on cw_pm.project_id = rec.id and cw_pm.del_flag = '0'
|
|
|
- group by rec.id
|
|
|
- ) bc on bc.id = a.id
|
|
|
- left join jy_project_members pm on a.id = pm.project_id
|
|
|
- left join sys_user sub on pm.user_id = sub.id
|
|
|
- left join sys_user_manage_office sumo on sumo.office_id = sub.office_id
|
|
|
- ${ew.customSqlSegment}
|
|
|
- ORDER BY a.create_time DESC
|
|
|
- </select>
|
|
|
+
|
|
|
|
|
|
<select id="getById" resultType="com.jeeplus.business.project.domain.JyProject">
|
|
|
SELECT
|