select record_id, check_no, income_batch_no, order_no, material_code, material_name, quality, unit, supplier_code, supplier_name, income_time, check_loc, check_status, check_man_code, check_man_name, check_time, check_result, status, attr1, attr2, attr3, attr4, create_by, create_time, update_by, update_time, factory_code, del_flag , check_type,sample_quality, noOk_quality, order_type,order_type_desc,remark from qc_check_task insert into qc_check_task record_id, check_no, income_batch_no, order_no, material_code, material_name, quality, noOk_quality, unit, supplier_code, supplier_name, income_time, check_loc, check_status, check_man_code, check_man_name, check_time, check_result, status, attr1, attr2, attr3, attr4, create_by, create_time, update_by, update_time, factory_code, del_flag, check_type, type_code, sample_quality, order_type, order_type_desc, sample_code, #{recordId}, #{checkNo}, #{incomeBatchNo}, #{orderNo}, #{materialCode}, #{materialName}, #{quality}, #{noOkQuality}, #{unit}, #{supplierCode}, #{supplierName}, #{incomeTime}, #{checkLoc}, #{checkStatus}, #{checkManCode}, #{checkManName}, #{checkTime}, #{checkResult}, #{status}, #{attr1}, #{attr2}, #{attr3}, #{attr4}, #{createBy}, #{createTime}, #{updateBy}, #{updateTime}, #{factoryCode}, #{delFlag}, #{checkType}, #{typeCode}, #{sampleQuality}, #{orderType}, #{orderTypeDesc}, #{sampleCode}, update qc_check_task check_no = #{checkNo}, income_batch_no = #{incomeBatchNo}, order_no = #{orderNo}, material_code = #{materialCode}, material_name = #{materialName}, quality = #{quality}, noOk_quality = #{noOkQuality}, unit = #{unit}, supplier_code = #{supplierCode}, supplier_name = #{supplierName}, income_time = #{incomeTime}, check_loc = #{checkLoc}, check_status = #{checkStatus}, check_man_code = #{checkManCode}, check_man_name = #{checkManName}, check_time = #{checkTime}, check_result = #{checkResult}, status = #{status}, attr1 = #{attr1}, attr2 = #{attr2}, attr3 = #{attr3}, attr4 = #{attr4}, create_by = #{createBy}, create_time = #{createTime}, update_by = #{updateBy}, update_time = #{updateTime}, factory_code = #{factoryCode}, del_flag = #{delFlag}, check_type = #{checkType}, sample_quality = #{sampleQuality}, sample_code = #{sampleCode}, where record_id = #{recordId} update qc_check_task set check_status = #{checkStatus}, check_man_code = #{checkManCode}, check_man_name =#{checkManName}, check_time = #{checkTime}, sample_quality = #{sampleQuality}, noOk_quality = #{noOkQuality}, aNoOkquality = #{aNoOkquality}, bNoOkquality = #{bNoOkquality}, cNoOkquality = #{cNoOkquality}, income_batch_no = #{incomeBatchNo}, remark = #{remark}, remark_code = #{remarkCode}, reason = #{reason}, bz = #{bz}, cxzz = #{cxzz}, jgy = #{jgy}, pgy = #{pgy}, check_result = #{checkResult}, update_by = #{updateBy}, update_time = #{updateTime} where record_id = #{recordId} insert into qc_check_task_cg record_id, check_no, income_batch_no, order_no, material_code, material_name, quality, noOk_quality, unit, supplier_code, supplier_name, income_time, check_loc, check_status, check_man_code, check_man_name, check_time, check_result, status, attr1, attr2, attr3, attr4, create_by, create_time, update_by, update_time, factory_code, del_flag, check_type, type_code, sample_quality, order_type, order_type_desc, remark, remark_code, reason, bz, start_oA, oa_factory, material_type, material_from, czbjr, zcf, zcoemcm, qczg, sqr, sqbm, oa_factory_f, sfxyzg, pgzg, pgzr, sfgyswt, sccj, aNoOkquality, bNoOkquality, cNoOkquality, #{recordId}, #{checkNo}, #{incomeBatchNo}, #{orderNo}, #{materialCode}, #{materialName}, #{quality}, #{noOkQuality}, #{unit}, #{supplierCode}, #{supplierName}, #{incomeTime}, #{checkLoc}, #{checkStatus}, #{checkManCode}, #{checkManName}, #{checkTime}, #{checkResult}, #{status}, #{attr1}, #{attr2}, #{attr3}, #{attr4}, #{createBy}, #{createTime}, #{updateBy}, #{updateTime}, #{factoryCode}, #{delFlag}, #{checkType}, #{typeCode}, #{sampleQuality}, #{orderType}, #{orderTypeDesc}, #{remark}, #{remarkCode}, #{reason}, #{bz}, #{startOA}, #{oaFactory}, #{materialType}, #{materialFrom}, #{czbjr}, #{zcf}, #{zcoemcm}, #{qczg}, #{sqr}, #{sqbm}, #{oaFactoryF}, #{sfxyzg}, #{pgzg}, #{pgzr}, #{sfgyswt}, #{sccj}, #{aNoOkquality}, #{bNoOkquality}, #{cNoOkquality}, update qc_check_task_cg set check_status = #{checkStatus}, check_man_code = #{checkManCode}, check_man_name =#{checkManName}, check_time = #{checkTime}, sample_quality = #{sampleQuality}, noOk_quality = #{noOkQuality}, aNoOkquality = #{aNoOkquality}, bNoOkquality = #{bNoOkquality}, cNoOkquality = #{cNoOkquality}, income_batch_no = #{incomeBatchNo}, remark = #{remark}, remark_code = #{remarkCode}, reason = #{reason}, bz = #{bz}, start_oA = #{startOA}, oa_factory = #{oaFactory}, material_type = #{materialType}, material_from = #{materialFrom}, czbjr = #{czbjr}, zcf = #{zcf}, zcoemcm = #{zcoemcm}, qczg = #{qczg}, sqr = #{sqr}, quality = #{quality}, unit = #{unit}, sqbm = #{sqbm}, check_loc = #{checkLoc}, oa_factory_f = #{oaFactoryF}, sfxyzg = #{sfxyzg}, pgzg = #{pgzg}, pgzr = #{pgzr}, sfgyswt = #{sfgyswt}, sccj = #{sccj}, check_result = #{checkResult}, update_by = #{updateBy}, update_time = #{updateTime} where record_id = #{recordId} update qc_check_task_detail set actual_value = #{item.actualValue}, status = #{item.status}, update_by = #{item.updateBy}, update_time = #{item.updateTime}, remark = #{item.remark}, sample_code = #{item.sampleCode}, sample_quality = #{item.sampleQuality}, sample_aql = #{item.sampleAql}, check_level = #{item.checkLevel}, defect_code = #{item.defectCode}, defect_quality = #{item.defectQuality} where record_id = #{item.recordId} update qc_check_task set del_flag = '1' where record_id = #{recordId} delete from qc_check_task where record_id in #{recordId} delete from qc_check_task_defect where belong_to = #{belongId} update qc_check_task set del_flag = '1', together_flag = '2' where record_id in(${deleteIds}) update qc_check_task_detail set del_flag = '1' where belong_to in(${deleteIds}) update qc_check_task_user set del_flag = '1' where belong_to in(${deleteIds}) insert into qc_check_task_user( record_id,belong_to,check_no, check_man_code,check_man_name, create_by,create_time,factory_code ) values ( #{item.id},#{item.belongTo},#{item.checkNo}, #{item.userCode},#{item.userName}, #{item.createBy},#{item.createTime},#{item.factoryCode} ) insert into qc_check_task_defect( record_id,belong_to,belong_to_detail, defect_code,defect_subclass, noOk_quality,class_id, create_by,create_time,factory_code ) values ( #{item.recordId},#{item.belongTo},#{item.belongToDetail}, #{item.defectCode},#{item.defectSubclass}, #{item.noOkQuality},#{item.classId}, #{item.createBy},#{item.createTime},#{item.factoryCode} ) update qc_income_original set check_status = '1', check_time = #{time} where record_id = #{item} update qc_check_task set quality = #{quality}, together_flag = '1' where record_id = #{recordId}