guoyujia 9 months ago
parent
commit
66b5c9bdec

+ 4 - 2
src/main/java/cn/ezhizao/project/business/product/controller/BizProcessInspecionController.java

@@ -970,8 +970,10 @@ public TableDataInfo examineList(@RequestBody BizProcessInspecion bizProcessInsp
         processInspecion.setReturnReceiptDetailId(bizReturnReceiptDetail.getId());
 //        processInspecion.setUserId(user == null ? 0L : user.getUserId());
 //        processInspecion.setNickName(user == null ? "" : user.getNickName());
-        processInspecion.setCarrierId(processInspecion.getLot().getCarrierId());
-        processInspecion.setCarrierCode(processInspecion.getLot().getCarrierCode());
+        if(processInspecion.getId() == null) {
+            processInspecion.setCarrierId(processInspecion.getLot().getCarrierId());
+            processInspecion.setCarrierCode(processInspecion.getLot().getCarrierCode());
+        }
         processInspecion.setDayworkId(daywork.getId());
         processInspecion.setProductionPlanId(daywork.getProductionPlanId());
         processInspecion.setDayworkItemId(dayworkItem.getId());

+ 1 - 1
src/main/resources/mybatis/business/product/BizProcessInspecionMapper.xml

@@ -55,7 +55,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="isAuto != null  ">AND t1.is_auto = #{isAuto}</if>
 
         </trim>
-        order by t1.production_plan_detail_id ,t1.lot_code
+        order by ( case when t1.status = 0 then 3 else t1.status end) desc, t1.create_time asc
     </select>
     <select id="getInfoByIds" resultMap="BizProcessInspecionResult">
         select t1.*,t3.id as process_id,t3.process_alias,t4.technology_version,t5.drawing_number from biz_process_inspecion t1