update ope_reagent_status set update_time=now() where reagent_code=#{code} update ope_reagent_status set status=#{status} where reagent_code=#{code} and oa.reagent_id = #{reagentId} and oa.user_id = #{userId} and sw.department = #{department} and oa.user_id in #{item} and oa.article_number = #{articleNumber} and oa.id != #{editId} and oa.reagent_code like #{reagentCode} and oa.status = #{status} and sr.name = #{reagentName} and oa.reagent_id = #{reagentId} and oa.user_id = #{userId} and sw.department = #{department} and oa.user_id in #{item} and oa.article_number = #{articleNumber} and oa.id != #{editId} and oa.reagent_code like #{reagentCode} and oa.status = #{status} and sr.name like #{name} select oa.*, sr.*, sr.id as reagentId, su.name as userName, swc.container_code as containerCode, sw.name as houseName, ss.name as supplierName left join sys_reagent sr on oa.reagent_id = sr.id left join sys_supplier as ss on sr.supplier_id = ss.id left join sys_user as su on oa.user_id = su.id left join sys_warehouse as sw on sw.id = oa.house_id left join sys_warehouse_container as swc on swc.id = oa.container_id left join sys_laboratory as sw on sw.id = oa.house_id left join sys_laboratory_container as swc on swc.id = oa.container_id insert into ope_reagent_status(id, reagent_id, article_number, reagent_code, status, house_id, container_id, user_id, remainder, place, store_type, valid_flag, update_time,project_num) values (#{id}, #{reagentId}, #{articleNumber}, #{reagentCode}, #{status}, #{houseId}, #{containerId}, #{userId}, #{remainder}, #{place}, #{storeType}, 1, now(),#{projectNum}) insert into ope_reagent_status(id, reagent_id, article_number, reagent_code, status, house_id, container_id, user_id, remainder, place, store_type, valid_flag, update_time,project_num,apply_code,order_code) values (#{id}, #{reagentId}, #{articleNumber}, #{reagentCode}, #{status}, #{houseId}, #{containerId}, #{userId}, #{remainder}, #{place}, #{storeType}, 1, now(),#{projectNum},#{applyCode},#{orderCode}) update ope_reagent_status set status=#{status},house_id=#{houseId},container_id=#{containerId}, user_id=#{userId}, place=#{place}, update_time=now(),project_num=#{projectNum} where id=#{id} update ope_reagent_status set update_time = #{updateTime}, status = #{status}, realstatus = #{realstatus},container_id = 0, house_id = 0, user_id= #{userId} ,remainder= #{remainder} where reagent_code = #{reagentCode} update ope_reagent_status set update_time = #{updateTime}, status = #{status}, realstatus = #{realstatus},house_id= #{houseId}, container_id= #{containerId}, user_id= #{userId} ,remainder= #{remainder} where reagent_code = #{reagentCode} update ope_reagent_status set update_time = #{updateTime}, status = #{status}, realstatus = #{realstatus},house_id= #{houseId}, container_id= #{containerId}, user_id= #{userId} ,remainder= #{remainder} where reagent_code = #{reagentCode} update ope_reagent_status set update_time = #{updateTime}, status = #{status}, realstatus = #{realstatus},user_id= #{userId} ,remainder= #{remainder} where reagent_code = #{reagentCode} update ope_reagent_status set status=#{status}, user_id=#{userId}, update_time=now(), container_id=#{containerId} where reagent_code=#{reagentCode} delete from ope_reagent_status where reagent_code=#{reagentCode} left join sys_reagent sr on oa.reagent_id = sr.id and oa.reagent_code like #{reagentCode} and sr.name like concat('%',#{reagentName},'%') and userId=#{userId} select oa.*, sr.*, sr.id as reagentId, su.name as userName, swc.container_code as containerCode, sw.name as houseName, ss.name as supplierName left join sys_reagent sr on oa.reagent_id = sr.id left join sys_supplier as ss on sr.supplier_id = ss.id left join sys_user as su on oa.user_id = su.id left join sys_warehouse as sw on sw.id = oa.house_id left join sys_warehouse_container as swc on swc.id = oa.container_id left join sys_laboratory as sw on sw.id = oa.house_id left join sys_laboratory_container as swc on swc.id = oa.container_id and oa.reagent_id = #{reagentId} and oa.user_id = #{userId} and sw.department = #{department} and oa.user_id in #{item} and oa.article_number = #{articleNumber} and oa.id != #{editId} and oa.reagent_code like #{reagentCode} and sr.name like concat('%',#{reagentName},'%') update ope_reagent_status set reagent_id=#{newReId} where reagent_id=#{oldReId}