| | |
| | | t4.item_text as maintenanceMethodName, |
| | | t3.maintenance_tool as maintenanceTool, |
| | | t3.maintenance_require as maintenanceRequire, |
| | | concat(t6.code, '/', t6.name) as maintenanceCycleName, |
| | | t6.name as maintenanceCycleName, |
| | | t5.name as maintenanceSpecialtyName, |
| | | t1.daily_maintenance_order_id as dailyMaintenanceOrderId, |
| | | t1.maintenance_order_detail_uda1 as maintenanceOrderDetailUda1, |
| | | t1.maintenance_order_detail_uda2 as maintenanceOrderDetailUda2, |
| | | t7.item_text as maintenanceRole |
| | | FROM |
| | | mom_eam_daily_maintenance_order_detail t1 |
| | | LEFT JOIN mom_eam_maintenance_standard_detail t2 ON t1.maintenance_standard_detail_id = t2.id |
| | | LEFT JOIN mom_eam_maintenance_project t3 ON t1.maintenance_project_id = t3.id |
| | | LEFT JOIN ( SELECT * FROM v_sys_dict WHERE dict_code = 'maintenance_project_method' ) t4 ON t4.item_value = t3.maintenance_method |
| | | LEFT JOIN mom_eam_maintenance_specialty t5 ON t3.maintenance_specialty_id = t5.id |
| | | LEFT JOIN mom_eam_maintenance_cycle t6 ON t2.maintenance_cycle_id = t6.id |
| | | LEFT JOIN ( SELECT * FROM v_sys_dict WHERE dict_code = 'maintenance_role' ) t7 ON t7.item_value = t2.maintenance_role |
| | | WHERE t1.del_flag = 0 |
| | | <if test="params.dailyMaintenanceOrderId != null and params.dailyMaintenanceOrderId != ''"> |
| | | and t1.daily_maintenance_order_id = #{params.dailyMaintenanceOrderId} |
| | | </if> |
| | | <if test="sql != '' and sql != null"> |
| | | ${sql} |
| | | </if> |
| | | ORDER BY t1.create_time desc |
| | | </select> |
| | | <!-- and t2.del_flag = 0 and t3.del_flag = 0 --> |
| | | |
| | | <select id="get3MaintenanceOrderDetailList" parameterType="Map" resultType="Map"> |
| | | SELECT |
| | | t1.id, |
| | | t2.location, |
| | | t2.photo, |
| | | t1.maintenance_standard_detail_id as maintenanceStandardDetailId, |
| | | t3.name as maintenanceProjectNum, |
| | | t3.standard, |
| | | t3.working_hour_quota as workingHourQuota, |
| | | t4.item_text as maintenanceMethodName, |
| | | t3.maintenance_tool as maintenanceTool, |
| | | t3.maintenance_require as maintenanceRequire, |
| | | t6.name as maintenanceCycleName, |
| | | t5.name as maintenanceSpecialtyName, |
| | | t1.daily_maintenance_order_id as dailyMaintenanceOrderId, |
| | | t1.maintenance_order_detail_uda1 as maintenanceOrderDetailUda1, |
| | | t1.maintenance_order_detail_uda2 as maintenanceOrderDetailUda2 |
| | | FROM |
| | |
| | | LEFT JOIN ( SELECT * FROM v_sys_dict WHERE dict_code = 'maintenance_project_method' ) t4 ON t4.item_value = t3.maintenance_method |
| | | LEFT JOIN mom_eam_maintenance_specialty t5 ON t3.maintenance_specialty_id = t5.id |
| | | LEFT JOIN mom_eam_maintenance_cycle t6 ON t2.maintenance_cycle_id = t6.id |
| | | WHERE t1.del_flag = 0 and t2.del_flag = 0 and t3.del_flag = 0 |
| | | LEFT JOIN ( SELECT * FROM v_sys_dict WHERE dict_code = 'maintenance_role' ) t7 ON t7.item_value = t2.maintenance_role |
| | | WHERE t1.del_flag = 0 |
| | | <if test="params.dailyMaintenanceOrderId != null and params.dailyMaintenanceOrderId != ''"> |
| | | and t1.daily_maintenance_order_id = #{params.dailyMaintenanceOrderId} |
| | | </if> |
| | | <if test="sql != '' and sql != null"> |
| | | ${sql} |
| | | </if> |
| | | ORDER BY t1.create_time desc |
| | | </select> |
| | | <!-- and t2.del_flag = 0 and t3.del_flag = 0 --> |
| | | </mapper> |