|
@@ -118,7 +118,6 @@
|
|
|
t4.production_plan_no as productionPlanNo,
|
|
|
t4.company_alias as companyAlias,
|
|
|
t2.description,
|
|
|
- t3.lot_code ,
|
|
|
t4.furnace_number,
|
|
|
t3.production_quantity,
|
|
|
t4.technology_version as technologyVersion,
|
|
@@ -145,46 +144,58 @@
|
|
|
</trim>
|
|
|
ORDER BY t1.create_time DESC
|
|
|
</select>
|
|
|
+<!-- 之前遗留暂时注释-->
|
|
|
+<!-- <select id="getItemList" parameterType="BizDayworkItem" resultMap="BizDayworkItemResult">-->
|
|
|
+<!-- SELECT-->
|
|
|
+<!-- DISTINCT-->
|
|
|
+<!-- t1.id,-->
|
|
|
+<!-- t1.start_time,-->
|
|
|
+<!-- t1.end_time,-->
|
|
|
+<!-- t1.daywork_id,-->
|
|
|
+<!-- t1.working_hours,-->
|
|
|
+<!-- t1.status,-->
|
|
|
+<!-- t1.prod_num,-->
|
|
|
+<!-- t1.qualified_num,-->
|
|
|
+<!-- t2.nick_name,-->
|
|
|
+<!-- t1.process_id,-->
|
|
|
+<!-- t2.user_name,-->
|
|
|
+<!-- t4.process_alias ,-->
|
|
|
+<!-- t4.process_code,-->
|
|
|
+<!-- t1.equipment_detail_id,-->
|
|
|
+<!-- t1.equipment_detail_code,-->
|
|
|
+<!-- t4.technological_process_id-->
|
|
|
+<!-- FROM biz_daywork_item t1-->
|
|
|
+<!-- LEFT JOIN sys_user t2 ON t1.user_id = t2.user_id-->
|
|
|
+<!-- LEFT JOIN biz_technological_process_detail t4 ON t1.technological_process_id = t4.technological_process_id and-->
|
|
|
+<!-- t1.process_id = t4.process_id-->
|
|
|
|
|
|
+<!-- <trim prefix=" WHERE" suffix="" suffixOverrides="AND">-->
|
|
|
+<!-- t1.deleted = 0 and t1.status < 4-->
|
|
|
+<!-- <if test="dayworkId != null and dayworkId != 0">AND t1.daywork_id = #{dayworkId}</if>-->
|
|
|
+<!-- <if test="tenantId != null and tenantId != 0">AND t1.tenant_id = #{tenantId}</if>-->
|
|
|
+<!-- <if test="processId != null and processId != 0">AND t1.process_id = #{processId}</if>-->
|
|
|
+<!-- # and t4.process_id = t1.process_id-->
|
|
|
+<!-- </trim>-->
|
|
|
+<!-- ORDER BY t4.process_step_number ASC ,t1.start_time DESC-->
|
|
|
+<!-- </select>-->
|
|
|
<select id="getItemList" parameterType="BizDayworkItem" resultMap="BizDayworkItemResult">
|
|
|
- SELECT
|
|
|
- DISTINCT
|
|
|
- t1.id,
|
|
|
- t1.start_time,
|
|
|
- t1.end_time,
|
|
|
- t1.daywork_id,
|
|
|
- t1.working_hours,
|
|
|
- t1.status,
|
|
|
- t1.prod_num,
|
|
|
- t1.qualified_num,
|
|
|
- t2.nick_name,
|
|
|
- t1.process_id,
|
|
|
- t2.user_name,
|
|
|
- t4.process_alias ,
|
|
|
- t4.process_code,
|
|
|
- t1.equipment_detail_id,
|
|
|
- t1.equipment_detail_code,
|
|
|
- t4.technological_process_id
|
|
|
- FROM biz_daywork_item t1
|
|
|
+ SELECT t1.*,t2.user_name FROM biz_daywork_item t1
|
|
|
LEFT JOIN sys_user t2 ON t1.user_id = t2.user_id
|
|
|
- LEFT JOIN biz_technological_process_detail t4 ON t1.technological_process_id = t4.technological_process_id and
|
|
|
- t1.process_id = t4.process_id
|
|
|
-
|
|
|
<trim prefix=" WHERE" suffix="" suffixOverrides="AND">
|
|
|
- t1.deleted = 0 and t1.status < 4
|
|
|
- <if test="dayworkId != null and dayworkId != 0">AND t1.daywork_id = #{dayworkId}</if>
|
|
|
- <if test="tenantId != null and tenantId != 0">AND t1.tenant_id = #{tenantId}</if>
|
|
|
- <if test="processId != null and processId != 0">AND t1.process_id = #{processId}</if>
|
|
|
- # and t4.process_id = t1.process_id
|
|
|
+ t1.deleted = 0 and t1.status < 4
|
|
|
+ <if test="dayworkId != null and dayworkId != 0">AND t1.daywork_id = #{dayworkId}</if>
|
|
|
+ <if test="isAmend != null and isAmend != 0">AND t1.form_daywork_item_id !=0 </if>
|
|
|
+ ORDER BY t1.process_step_number ASC ,t1.start_time DESC
|
|
|
</trim>
|
|
|
- ORDER BY t4.process_step_number ASC ,t1.start_time DESC
|
|
|
</select>
|
|
|
+
|
|
|
<select id="getDeptList" resultType="cn.ezhizao.project.system.domain.SysDept">
|
|
|
select distinct t3.dept_id as Value,t3.dept_name as Label from biz_daywork t1 left join
|
|
|
biz_production_plan_detail t2 on t2.id = t1.production_plan_detail_id
|
|
|
left join sys_dept t3 on t1.dept_id = t3.dept_id
|
|
|
where t2.production_plan_no = #{productionPlanNo} and t2.line_number = #{lineNumber}
|
|
|
</select>
|
|
|
+
|
|
|
<select id="getDayworkProcessList" resultType="cn.ezhizao.project.business.domain.BizProcess">
|
|
|
select distinct t3.id as Value,t3.process_alias as Label from biz_daywork t1 left join biz_daywork_item t2 on
|
|
|
t1.id = t2.daywork_id left join biz_process t3 on t2.process_id =
|