From d7355ce983c2bddcc5b95e4d84283f6631fb176a Mon Sep 17 00:00:00 2001
From: skyouc <creaycat@gmail.com>
Date: 星期四, 27 十一月 2025 13:38:46 +0800
Subject: [PATCH] 修改入出库历史的拣料类型,不上传ERP

---
 rsf-server/src/main/java/com/vincent/rsf/server/api/service/impl/PdaOutStockServiceImpl.java |  313 ++++++++++++++++++++++++++++++++++-----------------
 1 files changed, 209 insertions(+), 104 deletions(-)

diff --git a/rsf-server/src/main/java/com/vincent/rsf/server/api/service/impl/PdaOutStockServiceImpl.java b/rsf-server/src/main/java/com/vincent/rsf/server/api/service/impl/PdaOutStockServiceImpl.java
index 1d89aaa..d8b524c 100644
--- a/rsf-server/src/main/java/com/vincent/rsf/server/api/service/impl/PdaOutStockServiceImpl.java
+++ b/rsf-server/src/main/java/com/vincent/rsf/server/api/service/impl/PdaOutStockServiceImpl.java
@@ -8,20 +8,33 @@
 import com.vincent.rsf.server.api.entity.params.ContainerWaveParam;
 import com.vincent.rsf.server.api.entity.params.WavePickItemsParams;
 import com.vincent.rsf.server.api.service.PdaOutStockService;
+import com.vincent.rsf.server.common.utils.FieldsUtils;
 import com.vincent.rsf.server.manager.entity.*;
 import com.vincent.rsf.server.manager.enums.AsnExceStatus;
 import com.vincent.rsf.server.manager.enums.TaskStsType;
+import com.vincent.rsf.server.manager.enums.TaskType;
 import com.vincent.rsf.server.manager.service.*;
+import com.vincent.rsf.server.manager.service.impl.LocItemWorkingServiceImpl;
+import com.vincent.rsf.server.manager.service.impl.StockItemServiceImpl;
+import com.vincent.rsf.server.manager.service.impl.StockServiceImpl;
+import com.vincent.rsf.server.system.constant.GlobalConfigCode;
+import com.vincent.rsf.server.system.constant.SerialRuleCode;
+import com.vincent.rsf.server.system.entity.Config;
 import com.vincent.rsf.server.system.entity.Fields;
 import com.vincent.rsf.server.system.entity.FieldsItem;
 import com.vincent.rsf.server.system.service.FieldsItemService;
 import com.vincent.rsf.server.system.service.FieldsService;
+import com.vincent.rsf.server.system.service.impl.ConfigServiceImpl;
 import com.vincent.rsf.server.system.service.impl.FieldsItemServiceImpl;
 import com.vincent.rsf.server.system.service.impl.FieldsServiceImpl;
+import com.vincent.rsf.server.system.utils.SerialRuleUtils;
 import com.vincent.rsf.server.system.utils.SystemAuthUtils;
 import lombok.Synchronized;
 import org.apache.commons.lang3.StringUtils;
+import org.springframework.beans.BeanUtils;
 import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.context.annotation.Bean;
+import org.springframework.core.annotation.Order;
 import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Transactional;
 import org.springframework.web.bind.annotation.RequestBody;
@@ -50,6 +63,16 @@
     private FieldsItemService fieldsItemService;
     @Autowired
     private FieldsService fieldsService;
+    @Autowired
+    private StockService stockService;
+    @Autowired
+    private StockItemServiceImpl stockItemService;
+    @Autowired
+    private LocItemService locItemService;
+    @Autowired
+    private LocItemWorkingService locItemWorkingService;
+    @Autowired
+    private ConfigServiceImpl configService;
 
     @Override
     public R getOutStockTaskItem(String barcode) {
@@ -63,7 +86,6 @@
         if (null == taskItems || taskItems.size() <= 0) {
             return R.error("浠诲姟鍑洪敊锛屾湭鏌ヨ鍒扮浉鍏充换鍔℃槑缁�");
         }
-
 
         return R.ok(taskItems);
     }
@@ -113,8 +135,8 @@
         if (null == task) {
             throw new CoolException("鏈壘鍒板鍣ㄥ彿瀵瑰簲浠诲姟");
         }
-        if (!task.getTaskStatus().equals(TaskStsType.AWAIT.id)) {
-            return R.error("浠诲姟鐘舵�佷笉鏄瓑寰呯‘璁�");
+        if (!task.getTaskStatus().equals(TaskStsType.WAVE_SEED.id)) {
+            return R.error("浠诲姟鐘舵�佷笉鏄弨鏂欑媭鎱�");
         }
         List<TaskItem> taskItems = taskItemService.list(new LambdaQueryWrapper<TaskItem>().eq(TaskItem::getTaskId, task.getId()));
         Set<Long> longSet = taskItems.stream().map(TaskItem::getSourceId).collect(Collectors.toSet());
@@ -240,8 +262,8 @@
         if (null == task) {
             return R.error("鏈壘鍒版墭鐩樺搴旂殑浠诲姟");
         }
-        if (!task.getTaskStatus().equals(TaskStsType.AWAIT.id)) {
-            return R.error("浠诲姟鐘舵�佷笉鏄瓑寰呯‘璁�");
+        if (!task.getTaskStatus().equals(TaskStsType.WAVE_SEED.id)) {
+            return R.error("浠诲姟鐘舵�佷笉鏄弨鏂欑媭鎱�");
         }
         WkOrder order = asnOrderService.getById(params.getOrderId());
         if (Objects.isNull(order)) {
@@ -258,43 +280,185 @@
             if (Objects.isNull(orderItem)) {
                 throw new CoolException("鏁版嵁閿欒锛屾嫞鏂欎笉鍦ㄥ崟鎹渶姹備腑锛侊紒");
             }
+            //taskItems涓烘嫞璐ф槑缁嗭紝浣滃弬鏁颁笂鎶�
             Double summed = items.stream().mapToDouble(TaskItem::getAnfme).sum();
             //鍔犱笂鍘嗗彶鎷f枡鏁伴噺
-            Double pickQty = Math.round((orderItem.getQty() + summed) * 10000) / 10000.0;
-            if (pickQty.compareTo(orderItem.getAnfme()) > 0.0) {
-                throw new CoolException("鎾鏁伴噺涓嶈兘瓒呭嚭璁㈠崟闇�姹傛暟閲�");
+            Double pickQty = Math.round((orderItem.getQty() + summed) * 100) / 100.0;
+            Config config = configService.getOne(new LambdaQueryWrapper<Config>().eq(Config::getFlag, GlobalConfigCode.ALLOW_OVER_CHANGE));
+            //鍒ゆ柇鏄惁鍏佽瓒呮敹锛屼笉鍏佽瓒呮敹娣诲姞鎷掓敹鍒ゆ柇
+            if (!Objects.isNull(config)) {
+                if (!Boolean.parseBoolean(config.getVal())) {
+                    if (pickQty.compareTo(orderItem.getAnfme()) > 0.0) {
+                        throw new CoolException("鎾鏁伴噺涓嶈兘瓒呭嚭璁㈠崟闇�姹傛暟閲�");
+                    }
+                }
             }
+
             orderItem.setQty(pickQty);
 
             if (!asnOrderItemService.updateById(orderItem)) {
                 throw new CoolException("鍑哄簱鍗曟槑缁嗘洿鏂板け璐ワ紒锛�");
             }
 
+            Stock stock = new Stock();
+            String ruleCode = SerialRuleUtils.generateRuleCode(SerialRuleCode.SYS_STOCK_CODE, null);
+            if (StringUtils.isBlank(ruleCode)) {
+                throw new CoolException("褰撳墠涓氬姟锛�" + SerialRuleCode.SYS_STOCK_CODE + "锛岀紪鐮佽鍒欎笉瀛樺湪锛侊紒");
+            }
+            Double sum = taskItems.stream().mapToDouble(TaskItem::getAnfme).sum();
+            stock.setCode(ruleCode)
+                    .setUpdateBy(SystemAuthUtils.getLoginUserId())
+                    .setBarcode(task.getBarcode())
+                    .setLocCode(task.getOrgLoc())
+                    .setType(order.getType())
+                    .setWkType(Short.parseShort(order.getWkType()))
+                    .setSourceId(orderItem.getOrderId())
+                    .setSourceCode(orderItem.getOrderCode())
+                    .setUpdateTime(new Date())
+                    .setAnfme(sum);
+
+            if (!stockService.save(stock)) {
+                throw new CoolException("鍑哄叆搴撳巻鍙蹭繚瀛樺け璐ワ紒锛�");
+            }
+
+           List<StockItem> stockItems = new ArrayList<>();
             items.forEach(taskItem -> {
-                taskItem.setQty(taskItem.getAnfme());
-                if (!taskItemService.updateById(taskItem)) {
+                TaskItem item = taskItemService.getById(taskItem.getId());
+                //鍒ゆ柇鏄惁鍏佽瓒呮敹锛屼笉鍏佽瓒呮敹娣诲姞鎷掓敹鍒ゆ柇
+                if (!Objects.isNull(config)) {
+                    LocItemWorking serviceOne = locItemWorkingService.getOne(new LambdaQueryWrapper<LocItemWorking>().eq(LocItemWorking::getFieldsIndex, item.getFieldsIndex()));
+                    if (Objects.isNull(serviceOne)) {
+                        throw new CoolException("缂撳瓨鏁版嵁涓㈠け锛侊紒");
+                    }
+                    //涓嶇鏄惁鍏佽瓒呮敹锛岄兘闇�鍒ゆ柇鏄惁瓒呭嚭搴撳瓨鑼冨洿
+                    if (taskItem.getAnfme().compareTo(serviceOne.getAnfme()) > 0) {
+                        throw new CoolException("鎷h揣鏁伴噺瓒呭嚭褰撳墠绁ㄥ彿搴撳瓨鏁伴噺锛侊紒");
+                    }
+                    if (!Boolean.parseBoolean(config.getVal())) {
+                        if (item.getAnfme().compareTo(item.getQty() + taskItem.getAnfme()) < 0.0) {
+                            throw new CoolException("鍓嶅綋鐗╂枡宸茶秴鍑哄彲鎷h寖鍥达紝璇锋牳瀵瑰悗鍐嶆搷浣滐紒锛�");
+                        }
+                    }
+                }
+
+                item.setQty(item.getQty() + taskItem.getAnfme()).setOrderId(order.getId()).setOrderItemId(orderItem.getId());
+                if (!taskItemService.updateById(item)) {
                     throw new CoolException("鐘舵�佸畬鎴愬け璐ワ紒锛�");
                 }
+                StockItem stockItem = new StockItem();
+                BeanUtils.copyProperties(item, stockItem);
+                //taskItem涓轰笂鎶ユ暟鎹�
+                stockItem.setStockId(stock.getId()).setAnfme(taskItem.getAnfme()).setStockCode(stock.getCode()).setSourceItemId(orderItem.getId());
+                stockItems.add(stockItem);
             });
+            if (!stockItemService.saveBatch(stockItems)) {
+                throw new CoolException("鍑哄叆搴撳巻鍙叉槑缁嗕繚瀛樺け璐ワ紒锛�");
+            }
         });
 
         List<WkOrderItem> orderItems = asnOrderItemService.list(new LambdaQueryWrapper<WkOrderItem>().eq(WkOrderItem::getOrderId, params.getOrderId()));
         double total = orderItems.stream().mapToDouble(WkOrderItem::getQty).sum();
-        double wkQty = orderItems.stream().mapToDouble(WkOrderItem::getWorkQty).sum();
-        order.setQty(total).setWorkQty(order.getWorkQty() - wkQty);
+        Double wkQty = orderItems.stream().mapToDouble(WkOrderItem::getWorkQty).sum();
+        order.setQty(total).setWorkQty(order.getWorkQty().compareTo(wkQty) < 0 ? 0.0 : (total - wkQty));
         if (!asnOrderService.updateById(order)) {
             throw new CoolException("璁㈠崟鏁伴噺鏇存柊澶辫触锛侊紒");
         }
-        //妫�鏌ュ崟鎹槸鍚﹀畬鎴�
-        if (order.getAnfme().compareTo(order.getQty()) == 0) {
-            order.setExceStatus(AsnExceStatus.OUT_STOCK_STATUS_TASK_DONE.val);
-            if (!asnOrderService.updateById(order)) {
-                throw new CoolException("鍑哄簱鍗曟洿鏂扮姸鎬佸け璐�");
-            }
-        }
-
+//        //妫�鏌ュ崟鎹槸鍚﹀畬鎴�
+//        if (order.getAnfme().compareTo(order.getQty()) == 0) {
+//            order.setExceStatus(AsnExceStatus.OUT_STOCK_STATUS_TASK_DONE.val);
+//            if (!asnOrderService.updateById(order)) {
+//                throw new CoolException("鍑哄簱鍗曟洿鏂扮姸鎬佸け璐�");
+//            }
+//        }
         return R.ok();
     }
+
+    /**
+     * @author Ryan
+     * @date 2025/11/19
+     * @description: 鑾峰彇鍑哄簱浠诲姟鎷h揣鏄庣粏
+     * @version 1.0
+     */
+    @Override
+    public R getTaskItems(Map<String, String> params) {
+        if (Objects.isNull(params.get("barcode"))) {
+            throw new CoolException("鎷栫洏鐮佷笉鑳戒负绌猴紒锛�");
+        }
+        List<Integer> integers = Arrays.asList(TaskType.TASK_TYPE_OUT.type, TaskType.TASK_TYPE_EMPITY_OUT.type, TaskType.TASK_TYPE_PICK_AGAIN_OUT.type, TaskType.TASK_TYPE_CHECK_OUT.type);
+        Task task = taskService.getOne(new LambdaQueryWrapper<Task>()
+                .in(Task::getTaskType, integers)
+                .eq(Task::getBarcode, params.get("barcode")), false);
+        if (Objects.isNull(task)) {
+            return R.error("鎵樼洏鎵�鍦ㄤ换鍔′笉瀛樺湪锛侊紒");
+        }
+        List<TaskItem> taskItems = taskItemService.list(new LambdaQueryWrapper<TaskItem>().eq(TaskItem::getTaskId, task.getId()));
+        taskItems.forEach(taskItem -> {
+            if (!Objects.isNull(taskItem.getFieldsIndex())) {
+                Map<String, String> fields = FieldsUtils.getFields(taskItem.getFieldsIndex());
+                taskItem.setExtendFields(fields);
+            }
+        });
+        return R.ok().add(taskItems);
+    }
+
+    /**
+     * @author Ryan
+     * @date 2025/11/19
+     * @description: 淇敼鍑哄簱浠诲姟妗f槑缁嗙エ鍙�
+     * @version 1.0
+     */
+    @Override
+    @Transactional(rollbackFor = Exception.class)
+    public R modifyTaskItem(List<TaskItem> items) {
+        if (Objects.isNull(items) || items.isEmpty()) {
+            return R.error("鍙傛暟涓嶈兘涓虹┖锛侊紒");
+        }
+        for (TaskItem item : items) {
+            if (Objects.isNull(item.getCrushNo())) {
+                continue;
+            }
+            TaskItem byId = taskItemService.getById(item.getId());
+            if (!Objects.isNull(byId.getFieldsIndex())) {
+                Map<String, String> fields = FieldsUtils.getFields(byId.getFieldsIndex());
+                byId.setExtendFields(fields);
+            }
+            if (byId.getExtendFields().get("crushNo").equals(item.getCrushNo())) {
+                continue;
+            }
+            FieldsItem fieldsItem = fieldsItemService.getOne(new LambdaQueryWrapper<FieldsItem>()
+                    .eq(FieldsItem::getValue, item.getCrushNo())
+                    .last("limit 1"));
+            if (Objects.isNull(fieldsItem)) {
+                throw new CoolException("搴撳瓨涓嶅瓨鍦�!!");
+            }
+            String uuid = fieldsItem.getUuid();
+            item.setFieldsIndex(uuid).setExtendFields(null);
+            if (!taskItemService.updateById(item)) {
+               throw new CoolException("浠诲姟鏄庣粏淇敼澶辫触");
+            }
+            LocItemWorking oldOne = locItemWorkingService.getOne(new LambdaQueryWrapper<LocItemWorking>()
+                    .eq(LocItemWorking::getMatnrCode, byId.getMatnrCode())
+                    .eq(LocItemWorking::getFieldsIndex, byId.getFieldsIndex()));
+            if (Objects.isNull(oldOne)) {
+                throw new CoolException("鏄庣粏涓嶅瓨鍦ㄦ垨宸插嚭搴擄紒锛�");
+            }
+            LocItemWorking one = locItemWorkingService.getOne(new LambdaQueryWrapper<LocItemWorking>()
+                            .eq(LocItemWorking::getMatnrCode, byId.getMatnrCode())
+                    .eq(LocItemWorking::getFieldsIndex, uuid));
+            if (Objects.isNull(one)) {
+                throw new CoolException("鏄庣粏涓嶅瓨鍦ㄦ垨宸插嚭搴擄紒锛�");
+            }
+            one.setWorkQty(oldOne.getWorkQty());
+            oldOne.setWorkQty(0.0);
+
+            //鏇存柊搴撲綅淇℃伅
+            locItemWorkingService.updateById(oldOne);
+            locItemWorkingService.updateById(one);
+
+        }
+        return R.ok();
+    }
+
 
     /**
      * @author Ryan
@@ -318,95 +482,36 @@
         if (null == task) {
             return R.error("鏈壘鍒版墭鐩樺搴旂殑浠诲姟");
         }
-        if (!task.getTaskStatus().equals(TaskStsType.AWAIT.id)) {
-            return R.error("浠诲姟鐘舵�佷笉鏄瓑寰呯‘璁�");
+        if (!task.getTaskStatus().equals(TaskStsType.WAVE_SEED.id)) {
+            return R.error("浠诲姟鐘舵�佷笉鏄緟鎻�鐙�鎱�");
         }
 
-        List<TaskItem> taskItems = taskItemService.list(new LambdaQueryWrapper<TaskItem>().eq(TaskItem::getTaskId, task.getId()));
-        taskItems.forEach(taskItem -> {
-           if (!(taskItem.getQty().compareTo(taskItem.getAnfme()) == 0)) {
-               throw new CoolException("鏈夊崟鎹墿鏂欐湭鎷o紝璇锋嫞瀹屽悗鍐嶇‘璁わ紒锛�");
-           }
-        });
-
-        orderItems.forEach(orderItem -> {
-            try {
-                taskService.saveOutStockItem(taskItems, orderItem, null, null, SystemAuthUtils.getLoginUserId());
-            } catch (Exception e) {
-                throw new RuntimeException(e);
+        Config config = configService.getOne(new LambdaQueryWrapper<Config>().eq(Config::getFlag, GlobalConfigCode.ALLOW_OVER_CHANGE));
+        //鍒ゆ柇鏄惁鍏佽瓒呮敹锛屼笉鍏佽瓒呮敹娣诲姞鎷掓敹鍒ゆ柇
+        if (!Objects.isNull(config)) {
+            if (!Boolean.parseBoolean(config.getVal())) {
+                List<TaskItem> taskItems = taskItemService.list(new LambdaQueryWrapper<TaskItem>().eq(TaskItem::getTaskId, task.getId()));
+                taskItems.forEach(taskItem -> {
+                    if ((taskItem.getQty().compareTo(taskItem.getAnfme()) < 0)) {
+                        throw new CoolException("鏈夊崟鎹墿鏂欐湭鎷o紝璇锋嫞瀹屽悗鍐嶇‘璁わ紒锛�");
+                    }
+                });
             }
-        });
-
-//        containerWaveParam.getOrderItems().forEach(orderItem -> {
-//
-//        });
-//        for (ContainerWaveDto containerWaveDto : containerWaveParam.getContainerWaveDtos()) {
-//            //鍋氫竴娆℃牎楠岋紝鍒ゆ柇鍓嶇鎵�鏈夊嚭搴撴暟閲忔槸鍚﹁秴杩囨湰鎵樺嚭搴撴暟閲�
-//            double sum = containerWaveDto.getWkOrderItems().stream().mapToDouble(WkOrderItem::getDemandQty).sum();
-//            BigDecimal total = new BigDecimal(String.valueOf(sum));
-//            BigDecimal anfme = new BigDecimal(containerWaveDto.getTaskItem().getAnfme().toString());
-//            if (!anfme.equals(total)) {
-//                throw new CoolException("鎾鏁伴噺涓嶇瓑浜庡鍣ㄥ嚭搴撴暟閲忥紝璇锋鏌�");
-//            }
-//            for (WkOrderItem oldOrderItem : containerWaveDto.getWkOrderItems()) {
-//                if (Double.compare(oldOrderItem.getDemandQty(), 0.0) == 0) {
-//                    continue;
-//                }
-//                WkOrderItem orderItem = asnOrderItemService.getById(oldOrderItem.getId());
-//                BigDecimal num = new BigDecimal(orderItem.getWorkQty().toString()).subtract(new BigDecimal(orderItem.getQty().toString()));
-//                BigDecimal orderDemandQty = new BigDecimal(oldOrderItem.getDemandQty().toString());
-//                if (num.compareTo(orderDemandQty) < 0) {
-//                    throw new CoolException("鎾鏁伴噺澶т簬鍗曟嵁鍑哄簱鏁伴噺锛岃妫�鏌�");
-//                }
-//                WkOrder wkOrder = asnOrderService.getById(orderItem.getOrderId());
-//                if (Cools.isEmpty(wkOrder)) {
-//                    throw new CoolException("鍑哄簱鍗曚富鍗曟湭鎵惧埌");
-//                }
-//                wkOrder.setQty(new BigDecimal(wkOrder.getQty().toString()).add(orderDemandQty).doubleValue());
-//                if (!asnOrderService.updateById(wkOrder)) {
-//                    throw new CoolException("鍑哄簱鍗曟洿鏂扮姸鎬佸け璐�");
-//                }
-//
-//                if (Objects.isNull(oldOrderItem.getFieldsIndex())) {
-//                    throw new CoolException("绁ㄥ彿涓嶈兘涓虹┖锛侊紒");
-//                }
-//                //Fix 杩欓噷鍙拡瀵瑰笇鏃ラ」鐩殑绁ㄥ彿鍔熻兘锛岀エ鍙峰拰uuid涓轰竴瀵逛竴鐨勬儏鍐碉紝涓嶄細鍑虹幇閲嶅鐨勬儏鍐�
-//                FieldsItem fieldsItem = fieldsItemService.getOne(new LambdaQueryWrapper<FieldsItem>().eq(FieldsItem::getValue, oldOrderItem.getFieldsIndex()).last("limit 1"));
-//                if (!Objects.isNull(fieldsItem)) {
-//                    orderItem.setFieldsIndex(fieldsItem.getUuid());
-//                }
-//                orderItem.setQty(new BigDecimal(orderItem.getQty().toString()).add(orderDemandQty).doubleValue());
-//                if (!asnOrderItemService.updateById(orderItem)) {
-//                    throw new CoolException("鍗曟嵁鏄庣粏鏇存柊澶辫触");
-//                }
-//                //妫�鏌ュ崟鎹槸鍚﹀畬鎴�
-//                Boolean orderChecked = checkOrderComplete(orderItem);
-//                if (orderChecked) {
-//                    wkOrder.setExceStatus(AsnExceStatus.OUT_STOCK_STATUS_TASK_DONE.val);
-//                    if (!asnOrderService.updateById(wkOrder)) {
-//                        throw new CoolException("鍑哄簱鍗曟洿鏂扮姸鎬佸け璐�");
-//                    }
-//                }
-//            }
-//        //妫�鏌ユ尝娆℃槸鍚﹀畬鎴�
-////            Boolean waveChecked = checkWaveComplete(containerWaveDto.getTaskItem());
-////            if (waveChecked){
-////                Wave wave = waveService.getById(containerWaveDto.getTaskItem().getSourceId());
-////                if (null == wave){
-////                    throw new CoolException("鏈壘鍒板鍣ㄥ彿瀵瑰簲娉㈡");
-////                }
-////                wave.setExceStatus(WaveExceStatus.WAVE_EXCE_STATUS_TASK.val);
-////                if (!waveService.updateById(wave)){
-////                    throw new CoolException("娉㈡鍗曟洿鏂扮姸鎬佸け璐�");
-////                }
-////            }
-//        }
-
-        task.setTaskStatus(TaskStsType.COMPLETE_OUT.id);
-        if (!taskService.updateById(task)) {
-            throw new CoolException("浠诲姟鐘舵�佹洿鏂板け璐�");
         }
 
+
+        try {
+            if (task.getTaskType().equals(TaskType.TASK_TYPE_PICK_AGAIN_OUT.type) || task.getTaskType().equals(TaskType.TASK_TYPE_CHECK_OUT.type)) {
+                taskService.pickOrCheckTask(task.getId(), "");
+            } else {
+                task.setTaskStatus(TaskStsType.UPDATED_OUT.id);
+                if (!taskService.updateById(task)) {
+                    throw new CoolException("浠诲姟鐘舵�佹洿鏂板け璐�");
+                }
+            }
+        } catch (Exception e) {
+            throw new CoolException("鍒嗘嫞澶辫触");
+        }
         return R.ok();
     }
 

--
Gitblit v1.9.1