|
@@ -293,7 +293,6 @@
|
|
crb.proc_ins_id as procInsId2,
|
|
crb.proc_ins_id as procInsId2,
|
|
b.signature_annotator1_name,
|
|
b.signature_annotator1_name,
|
|
b.signature_annotator2_name,
|
|
b.signature_annotator2_name,
|
|
- su3.name as projectCreateName,
|
|
|
|
cwci.contract_no as contractNo,
|
|
cwci.contract_no as contractNo,
|
|
cwci.contract_name as contractName,
|
|
cwci.contract_name as contractName,
|
|
pr.business_type as businessType,
|
|
pr.business_type as businessType,
|
|
@@ -302,7 +301,8 @@
|
|
cw_pa.approved_including_tax as approvedIncludingTax,
|
|
cw_pa.approved_including_tax as approvedIncludingTax,
|
|
cw_pa.contract,
|
|
cw_pa.contract,
|
|
cprr.proc_ins_id as cprrProcInsId,
|
|
cprr.proc_ins_id as cprrProcInsId,
|
|
- cw_pa.audit_date as auditDate
|
|
|
|
|
|
+ cw_pa.audit_date as auditDate,
|
|
|
|
+ cw_pa.entrust_type as entrustType
|
|
from cw_project_report_archive cw_pa
|
|
from cw_project_report_archive cw_pa
|
|
left join cw_project_report_borrow crb on crb.archive_id = cw_pa.id and crb.del_flag = '0'
|
|
left join cw_project_report_borrow crb on crb.archive_id = cw_pa.id and crb.del_flag = '0'
|
|
left join cw_work_client_base cw_wcb on cw_pa.audited_units = cw_wcb.id and cw_wcb.del_flag = '0'
|
|
left join cw_work_client_base cw_wcb on cw_pa.audited_units = cw_wcb.id and cw_wcb.del_flag = '0'
|
|
@@ -315,15 +315,11 @@
|
|
left join cw_project_members cpm on cw_pr.id = cpm.project_id
|
|
left join cw_project_members cpm on cw_pr.id = cpm.project_id
|
|
left join sys_user sub on cpm.user_id = sub.id
|
|
left join sys_user sub on cpm.user_id = sub.id
|
|
left join sys_user_manage_office sumo on sumo.office_id = sub.office_id
|
|
left join sys_user_manage_office sumo on sumo.office_id = sub.office_id
|
|
-
|
|
|
|
left join act_ru_task art ON cw_pa.proc_ins_id = art.PROC_INST_ID_
|
|
left join act_ru_task art ON cw_pa.proc_ins_id = art.PROC_INST_ID_
|
|
-
|
|
|
|
left join cw_project_report pr on cw_pa.report_id=pr.id and pr.del_flag = '0'
|
|
left join cw_project_report pr on cw_pa.report_id=pr.id and pr.del_flag = '0'
|
|
left join cw_project_report_review cprr on cprr.report_id=pr.id and cprr.del_flag = '0'
|
|
left join cw_project_report_review cprr on cprr.report_id=pr.id and cprr.del_flag = '0'
|
|
left join cw_work_contract_info cwci on cwci.id=cw_pr.contract_id and cwci.del_flag = '0'
|
|
left join cw_work_contract_info cwci on cwci.id=cw_pr.contract_id and cwci.del_flag = '0'
|
|
left join cw_work_contract_file_paper cwcfp on cwcfp.contract_info_id=cwci.id and cwcfp.del_flag = '0'
|
|
left join cw_work_contract_file_paper cwcfp on cwcfp.contract_info_id=cwci.id and cwcfp.del_flag = '0'
|
|
- left join sys_user su3 on su3.id = cw_pr.create_by_id and su3.del_flag = '0'
|
|
|
|
-
|
|
|
|
left join(
|
|
left join(
|
|
select
|
|
select
|
|
cw_prr.id as report_id,
|
|
cw_prr.id as report_id,
|
|
@@ -425,12 +421,17 @@
|
|
b.report_create_name,
|
|
b.report_create_name,
|
|
b.signature_annotator1_name,
|
|
b.signature_annotator1_name,
|
|
b.signature_annotator2_name,
|
|
b.signature_annotator2_name,
|
|
|
|
+ b.signature_annotator1,
|
|
|
|
+ b.signature_annotator2,
|
|
b.report_no,
|
|
b.report_no,
|
|
|
|
+ su3.id as projectMaster,
|
|
|
|
+ su4.id as realHeader,
|
|
b.approved_no_including_tax as approvedNoIncludingTaxBak,
|
|
b.approved_no_including_tax as approvedNoIncludingTaxBak,
|
|
b.approved_including_tax as approvedIncludingTaxBak,
|
|
b.approved_including_tax as approvedIncludingTaxBak,
|
|
|
|
+ b.proc_ins_id as cprrProcInsId,
|
|
prnl.report_no as "connectReport",
|
|
prnl.report_no as "connectReport",
|
|
pr.business_type as businessType,
|
|
pr.business_type as businessType,
|
|
- su1.name as projectCreateName,
|
|
|
|
|
|
+ su1.id as projectManager,
|
|
cwci.contract_no as contractNo,
|
|
cwci.contract_no as contractNo,
|
|
cwci.contract_name as contractName,
|
|
cwci.contract_name as contractName,
|
|
cwci.client_contacts as clientContacts,
|
|
cwci.client_contacts as clientContacts,
|
|
@@ -440,6 +441,7 @@
|
|
cw_pa.approved_no_including_tax as approvedNoIncludingTax,
|
|
cw_pa.approved_no_including_tax as approvedNoIncludingTax,
|
|
cw_pa.approved_including_tax as approvedIncludingTax,
|
|
cw_pa.approved_including_tax as approvedIncludingTax,
|
|
cw_pa.contract,
|
|
cw_pa.contract,
|
|
|
|
+ cw_pa.entrust_type as entrustType,
|
|
cw_pa.approve_remarks as approveRemarks
|
|
cw_pa.approve_remarks as approveRemarks
|
|
from cw_project_report_archive cw_pa
|
|
from cw_project_report_archive cw_pa
|
|
left join cw_project_report_new_line prnl on cw_pa.connect_report_id=prnl.report_id
|
|
left join cw_project_report_new_line prnl on cw_pa.connect_report_id=prnl.report_id
|
|
@@ -451,11 +453,15 @@
|
|
left join sys_user su on su.id = cw_pa.create_by_id and su.del_flag = '0'
|
|
left join sys_user su on su.id = cw_pa.create_by_id and su.del_flag = '0'
|
|
left join sys_user su1 on su1.id = prs.create_by_id and su1.del_flag = '0'
|
|
left join sys_user su1 on su1.id = prs.create_by_id and su1.del_flag = '0'
|
|
left join sys_user su2 on su2.id = cwci.create_by_id and su2.del_flag = '0'
|
|
left join sys_user su2 on su2.id = cwci.create_by_id and su2.del_flag = '0'
|
|
|
|
+ left join sys_user su3 on prs.project_master_id = su3.id and su3.del_flag = '0'
|
|
|
|
+ left join sys_user su4 on prs.real_header = su4.id and su4.del_flag = '0'
|
|
left join(
|
|
left join(
|
|
select
|
|
select
|
|
<include refid="prnl_column"></include>
|
|
<include refid="prnl_column"></include>
|
|
|
|
+ ,cprr.proc_ins_id
|
|
from cw_project_report_new_line cw_prnl
|
|
from cw_project_report_new_line cw_prnl
|
|
left join cw_project_report cw_pr on cw_pr.id = cw_prnl.report_id and cw_pr.del_flag = '0'
|
|
left join cw_project_report cw_pr on cw_pr.id = cw_prnl.report_id and cw_pr.del_flag = '0'
|
|
|
|
+ left join cw_project_report_review cprr on cprr.report_id = cw_prnl.report_id
|
|
left join sys_user su on su.id = cw_prnl.create_by_id and su.del_flag = '0'
|
|
left join sys_user su on su.id = cw_prnl.create_by_id and su.del_flag = '0'
|
|
left join sys_user su1 on su1.id = cw_pr.signature_annotator1 and su1.del_flag = '0'
|
|
left join sys_user su1 on su1.id = cw_pr.signature_annotator1 and su1.del_flag = '0'
|
|
left join sys_user su2 on su2.id = cw_pr.signature_annotator2 and su2.del_flag = '0'
|
|
left join sys_user su2 on su2.id = cw_pr.signature_annotator2 and su2.del_flag = '0'
|
|
@@ -602,6 +608,9 @@
|
|
<if test="contract != null and contract != ''">
|
|
<if test="contract != null and contract != ''">
|
|
contract = #{contract},
|
|
contract = #{contract},
|
|
</if>
|
|
</if>
|
|
|
|
+ <if test="entrustType != null and entrustType != ''">
|
|
|
|
+ entrust_type = #{entrustType},
|
|
|
|
+ </if>
|
|
update_by_id = #{updateById},
|
|
update_by_id = #{updateById},
|
|
update_time = #{updateTime}
|
|
update_time = #{updateTime}
|
|
where id = #{id} ;
|
|
where id = #{id} ;
|
|
@@ -722,4 +731,19 @@
|
|
where cw_pa.report_id = #{reportId} and cw_pa.del_flag = 0
|
|
where cw_pa.report_id = #{reportId} and cw_pa.del_flag = 0
|
|
order by cw_pa.audit_date desc,cw_pa.update_time desc
|
|
order by cw_pa.audit_date desc,cw_pa.update_time desc
|
|
</select>
|
|
</select>
|
|
|
|
+
|
|
|
|
+
|
|
|
|
+ <select id="findByEntrustType" resultType="com.jeeplus.finance.projectReportArchive.service.dto.CwProjectReportArchiveDTO">
|
|
|
|
+ select
|
|
|
|
+ a.number,
|
|
|
|
+ cw_prnl.report_no AS reportNo
|
|
|
|
+ from cw_project_report_archive a
|
|
|
|
+ left join cw_project_report_new_line cw_prnl on a.report_id = cw_prnl.report_id and cw_prnl.del_flag = '0'
|
|
|
|
+ where a.entrust_type = #{entrustType}
|
|
|
|
+ and a.del_flag = '0'
|
|
|
|
+ and a.status = '5'
|
|
|
|
+ order by
|
|
|
|
+ a.update_time DESC
|
|
|
|
+ limit 1
|
|
|
|
+ </select>
|
|
</mapper>
|
|
</mapper>
|