|
@@ -82,10 +82,14 @@
|
|
|
LEFT JOIN major m ON m.id = mp.major_id
|
|
|
WHERE
|
|
|
mp.major_id = #{production.majorId}
|
|
|
-
|
|
|
- <if test="production!=null and production.afterProduction==null and production.reportNo!=null and production.reportNo!='' ">
|
|
|
+ <if test="production!=null and production.afterProduction==null
|
|
|
+ and production.statementNo==null and production.reportNo!=null and production.reportNo!='' ">
|
|
|
and mp.report_no = #{production.reportNo}
|
|
|
</if>
|
|
|
+ <if test="production!=null and production.afterProduction==null
|
|
|
+ and production.statementNo!=null and production.statementNo!='' and production.reportNo==null ">
|
|
|
+ and mp.report_no = #{production.statementNo}
|
|
|
+ </if>
|
|
|
<if test="production!=null and production.afterProduction!=null and production.afterProduction=='REPORT' and production.reportNo!=null and production.reportNo!='' ">
|
|
|
and mp.report_no in (select report_no from major_target where major_id = #{production.majorId} and statement_no =#{production.reportNo} and deleted = 0)
|
|
|
</if>
|
|
@@ -95,10 +99,64 @@
|
|
|
<if test="production!=null and production.production!=null and production.production!='' ">
|
|
|
and mp.production = #{production.production}
|
|
|
</if>
|
|
|
+ <if test="production!=null and production.afterProduction==null and production.statementNo!=null
|
|
|
+ and production.statementNo!='' and production.reportNo!=null and production.reportNo!=''">
|
|
|
+ and mp.report_no in (#{production.statementNo},#{production.reportNo})
|
|
|
+ </if>
|
|
|
and mp.deleted = 0 and m.deleted = 0
|
|
|
order by mp.created ASC ) t where nextInstanceNodeId is null
|
|
|
</select>
|
|
|
|
|
|
+ <select id="getPendingList" parameterType="com.dayou.entity.MajorProduction" resultType="com.dayou.entity.MajorProduction">
|
|
|
+ SELECT
|
|
|
+ mp.id,
|
|
|
+ mp.major_id,
|
|
|
+ mp.report_no,
|
|
|
+ mp.production,
|
|
|
+ mp.signatory,
|
|
|
+ mp.`name`,
|
|
|
+ mp.client_name,
|
|
|
+ mp.client_tel,
|
|
|
+ mp.client_address,
|
|
|
+ mp.`owner`,
|
|
|
+ mp.value_timing,
|
|
|
+ mp.evaluate_acreage,
|
|
|
+ mp.evaluate_amount,
|
|
|
+ mp.evaluate_price,
|
|
|
+ mp.`comment`,
|
|
|
+ mp.qr_code,
|
|
|
+ mp.repertory_state,
|
|
|
+ mp.first_check,
|
|
|
+ mp.second_check,
|
|
|
+ mp.third_check,
|
|
|
+ mp.save_file_check,
|
|
|
+ mp.save_file_second_check,
|
|
|
+ mp.if_save_file,
|
|
|
+ mp.file_path,
|
|
|
+ m.`name` AS majorName,
|
|
|
+ mp.checked_file_path,
|
|
|
+ mp.validate_code
|
|
|
+ FROM
|
|
|
+ major_production mp
|
|
|
+ LEFT JOIN major m ON m.id = mp.major_id
|
|
|
+ WHERE
|
|
|
+ mp.major_id = #{production.majorId}
|
|
|
+ <if test="production!=null and production.afterProduction==null
|
|
|
+ and production.statementNo==null and production.reportNo!=null and production.reportNo!='' ">
|
|
|
+ and mp.report_no = #{production.reportNo}
|
|
|
+ </if>
|
|
|
+ <if test="production!=null and production.afterProduction==null
|
|
|
+ and production.statementNo!=null and production.statementNo!='' and production.reportNo==null ">
|
|
|
+ and mp.report_no = #{production.statementNo}
|
|
|
+ </if>
|
|
|
+ <if test="production!=null and production.afterProduction==null and production.statementNo!=null
|
|
|
+ and production.statementNo!='' and production.reportNo!=null and production.reportNo!=''">
|
|
|
+ and mp.report_no in (#{production.statementNo},#{production.reportNo})
|
|
|
+ </if>
|
|
|
+ and mp.deleted = 0 and m.deleted = 0
|
|
|
+ order by mp.created ASC
|
|
|
+ </select>
|
|
|
+
|
|
|
<select id="saveDonePage" parameterType="com.dayou.vo.MajorProductionSaveDoneVO" resultType="com.dayou.vo.MajorProductionSaveDoneVO">
|
|
|
SELECT
|
|
|
mp.id,
|