insert into mes_next_machine
record_id,
rfid,
next_machine_code,
status,
remark,
attr1,
attr2,
attr3,
attr4,
create_by,
create_time,
update_by,
update_time,
factory_code,
#{recordId},
#{rfid},
#{nextMachineCode},
#{status},
#{remark},
#{attr1},
#{attr2},
#{attr3},
#{attr4},
#{createBy},
#{createTime},
#{updateBy},
#{updateTime},
#{factoryCode},
select
bucket_code loadNo
from pro_wet_material_plan_detail
where material_code = #{sku} and CONVERT(varchar(10),plan_time, 120) = CONVERT(varchar(10),#{reqTime}, 120)
and del_flag = '0'
select equipment_id equipmentId,
equipment_code equipmentCode,
equipment_name equipmentName,
equipment_type_code equipmentTypeCode,
equipment_type_name equipmentTypeName
from base_equipment
where del_flag = '0'
and status = '1'
and equipment_type_code = #{equipmentTypeCode}
and equipment_code like concat('%', #{equipmentCode}, '%')
and equipment_name like concat('%', #{equipmentName}, '%')
select count(0) totalNum,
equ.equipment_type_code equTypeCode,
equ.equipment_type_name equTypeName
from mes_material_transfer_result mt
left join base_equipment equ on mt.equipmentCode = equ.equipment_code
where CONVERT(varchar(10),mt.create_time, 120) = #{ymd} and equ.equipment_name is not null
group by equ.equipment_type_code,
equ.equipment_type_name
select count(0) totalNum,
mt.equipmentCode equCode,
equ.equipment_name equName,
equ.equipment_type_code equTypeCode
from mes_material_transfer_result mt
left join base_equipment equ on mt.equipmentCode = equ.equipment_code
where CONVERT(varchar(10),mt.create_time, 120) = #{ymd} and equ.equipment_name is not null
group by mt.equipmentCode,
equ.equipment_name,
equ.equipment_type_code
select dept_id parentName,
dept_name deptName
from sys_dept where parent_id = '1' and del_flag = '0'