|
@@ -383,6 +383,36 @@
|
|
</trim>
|
|
</trim>
|
|
ORDER BY create_time DESC
|
|
ORDER BY create_time DESC
|
|
</select>
|
|
</select>
|
|
|
|
+ <select id="getAssistList" parameterType="BizDayworkItem" resultMap="BizDayworkItemResult">
|
|
|
|
+ SELECT * FROM biz_daywork_item
|
|
|
|
+ <trim prefix=" WHERE" suffix="" suffixOverrides="AND">
|
|
|
|
+ deleted = 0
|
|
|
|
+ <if test="type != null">AND status < 4</if>
|
|
|
|
+ <if test="dayworkId != null and dayworkId != ''">AND daywork_id = #{dayworkId}</if>
|
|
|
|
+ <if test="processId != null and processId != ''">AND process_id = #{processId}</if>
|
|
|
|
+ <if test="technologicalProcessDetailId != null and technologicalProcessDetailId != ''">AND
|
|
|
|
+ technological_process_detail_id = #{technologicalProcessDetailId}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="status != null and status != ''">AND status = #{status}</if>
|
|
|
|
+ <if test="turnoverType != null">AND turnover_type != #{turnoverType}</if>
|
|
|
|
+ <if test="userStatus != null and userStatus != ''">AND `status` < 5</if>
|
|
|
|
+ <if test="tenantId != null and tenantId != 0">AND tenant_id = #{tenantId}</if>
|
|
|
|
+ <if test="updaterId != null and updaterId != 0">AND updater_id = #{updaterId}</if>
|
|
|
|
+ <if test="turnoverId != null and turnoverId != ''">AND turnover_id = #{turnoverId}</if>
|
|
|
|
+ <if test="workshopId != null">AND exists (select 1 from biz_workshop_turnover where biz_workshop_turnover.id
|
|
|
|
+ = biz_daywork_item.turnover_id and biz_workshop_turnover.deleted = 0 and
|
|
|
|
+ biz_workshop_turnover.workshop_id = #{workshopId})
|
|
|
|
+ </if>
|
|
|
|
+ <if test="id != null">AND id = #{id}</if>
|
|
|
|
+ <if test="ids != null and ids.size > 0">
|
|
|
|
+ AND id in
|
|
|
|
+ <foreach collection="ids" index="index" item="item" separator="," open="(" close=")">
|
|
|
|
+ #{item,jdbcType=BIGINT}
|
|
|
|
+ </foreach>
|
|
|
|
+ </if>
|
|
|
|
+ </trim>
|
|
|
|
+ ORDER BY create_time DESC
|
|
|
|
+ </select>
|
|
<select id="getOutListByDeptId" resultType="cn.ezhizao.project.business.product.domain.BizDaywork">
|
|
<select id="getOutListByDeptId" resultType="cn.ezhizao.project.business.product.domain.BizDaywork">
|
|
SELECT distinct
|
|
SELECT distinct
|
|
t1.id,t2.dept_name,t3.product_description,t4.lot_code,t1.is_amend,t1.is_waste_recycling,t1.technological_process_id
|
|
t1.id,t2.dept_name,t3.product_description,t4.lot_code,t1.is_amend,t1.is_waste_recycling,t1.technological_process_id
|