From 6f45f4a29ce38525f3f9e3931bcedfc77bde765e Mon Sep 17 00:00:00 2001
From: jiazx0107@163.com <jiazx0107@163.com>
Date: 星期六, 24 六月 2023 18:07:43 +0800
Subject: [PATCH] 出入库流程优化-入库详单优化

---
 igds-inout/src/main/java/com/ld/igds/inout/service/InoutService.java |  120 +++++++++++++++++++++++++++++++++++++++---------------------
 1 files changed, 78 insertions(+), 42 deletions(-)

diff --git a/igds-inout/src/main/java/com/ld/igds/inout/service/InoutService.java b/igds-inout/src/main/java/com/ld/igds/inout/service/InoutService.java
index d329fa8..23e0fca 100644
--- a/igds-inout/src/main/java/com/ld/igds/inout/service/InoutService.java
+++ b/igds-inout/src/main/java/com/ld/igds/inout/service/InoutService.java
@@ -1,8 +1,8 @@
 package com.ld.igds.inout.service;
 
-import com.ld.igds.check.dto.CheckItemData;
 import com.ld.igds.data.Page;
 import com.ld.igds.inout.dto.*;
+import com.ld.igds.models.InoutPrice;
 
 import java.util.Date;
 import java.util.List;
@@ -47,7 +47,7 @@
      * @return
      * @throws Exception
      */
-    String inoutStop(InoutParam param);
+    String inoutStop(InoutParam param) throws Exception;
 
     /**
      * 鏍规嵁鏁版嵁娣诲姞锛�
@@ -56,7 +56,7 @@
      * @return 杩斿洖寮傚父淇℃伅锛屾甯歌繑鍥瀗ull
      * @throws Exception
      */
-    String insertData(InoutData data) throws Exception;
+    String insertData(InoutData data);
 
     /**
      * 鏇存柊鏁版嵁
@@ -66,6 +66,14 @@
      * @throws Exception
      */
     String updateData(InoutData data) throws Exception;
+
+    /**
+     * 鍊间粨鐜妭鎻愪氦鏁版嵁锛屽彧鏇存柊閮ㄥ垎淇℃伅
+     *
+     * @param data
+     * @return
+     */
+    String updateDataByHandle(InoutData data);
 
     /**
      * 鍒嗛〉鑾峰彇浣忎俊鎭�
@@ -101,28 +109,12 @@
     String toComplete(InoutParam param) throws Exception;
 
     /**
-     * 灏嗗嚭鍏ュ簱淇℃伅瀛樻斁鍒颁复鏃剁紦瀛樹腑锛岃繖涓紦瀛橀粯璁ゅ彧淇濈暀2澶╂椂闂�
-     *
-     * @param data
-     */
-    void addInoutCache(InoutData data);
-
-    /**
-     * 鏇存柊鍑哄叆搴撶紦瀛樹俊鎭�
+     * 灏嗗嚭鍏ュ簱娴佹按淇℃伅鏀惧埌缂撳瓨涓紝鍖呮嫭杩涜涓殑鍜屽凡缁忓畬鎴愮殑
      *
      * @param data
      */
     void updateInoutCache(InoutData data);
 
-    /**
-     * 浠庣紦瀛樹腑鍒犻櫎鍑哄叆搴撶紦瀛�
-     *
-     * @param deptId
-     * @param type
-     * @param id
-     * @param addToComplete
-     */
-    void delInoutFromCache(String deptId, String type, String id, boolean addToComplete);
 
     /**
      * 鑾峰彇鍑哄叆搴撳垪琛ㄤ俊鎭紝缂撳瓨鏃堕棿鏄�48灏忔椂
@@ -140,20 +132,15 @@
      */
     InoutData getFromInoutCache(InoutParam param);
 
+
     /**
-     * 鍒濆鍖栧嚭鍏ュ簱澶у睆鏁版嵁锛屼粎浠呭彂閫�
+     * 鎺ㄩ�佸ぇ灞�
      *
+     * @param companyId
      * @param deptId
+     * @param progress  鍙互涓虹┖
      */
-    void initInoutScreen(String deptId);
-
-
-    /**
-     * 鏍规嵁鏁版嵁杩涜鎺ㄩ��
-     *
-     * @param result
-     */
-    void notifyWeb(InoutData result);
+    void notifyToScreen(String companyId, String deptId, String progress);
 
     /**
      * 蹇�熷畬鎴愭祦绋嬩腑鐨勮鍗�
@@ -183,11 +170,10 @@
     /**
      * 鑾峰彇褰撳墠浠撳簱涓嬫渶鍚庝竴鏉¤褰曚俊鎭�
      *
-     * @param companyId
-     * @param depotId
+     * @param param
      * @return
      */
-    InoutData getLastRecord(String companyId, String depotId);
+    InoutData getLastRecord(InoutParam param);
 
     /**
      * 鏍规嵁鎹熸孩璁板綍锛屾坊鍔犲嚭鍏ュ簱璁板綍淇℃伅
@@ -212,15 +198,6 @@
     void setCheckCache(InoutData data);
 
     /**
-     * 鏍规嵁缁勭粐缂栫爜鍜屽寲楠岋缉锛よ幏鍙栧寲楠岀粨鏋滀俊鎭�
-     *
-     * @param companyId
-     * @param checkId
-     * @return
-     */
-    List<CheckItemData> getCheckCache(String companyId, String checkId);
-
-    /**
      * 鑾峰彇鍑哄叆搴撴祦姘碔D搴忓彿
      *
      * @param registerTime
@@ -236,4 +213,63 @@
      * @return
      */
     double sumRecordWeight(InoutParam param);
+
+    /**
+     * 鏁版嵁搴撴牴鎹溅鐗屽彿鍜屾櫤鎱у崱鍙锋槸鍚﹀凡缁忓瓨鍦�
+     *
+     * @param param
+     * @return
+     */
+    int checkExist(InoutParam param);
+
+    /**
+     * 鍒嗛〉鑾峰彇鎵︽牱鏁版嵁
+     *
+     * @param param
+     * @return
+     */
+    Page<InoutCheckData> pageSampleData(InoutCheckParam param);
+
+    /**
+     * 鏇存柊鎵︽牱淇℃伅
+     *
+     * @param data
+     * @return
+     * @throws Exception
+     */
+    String updateSampleData(InoutCheckData data);
+
+    /**
+     * 鍒嗛〉鑾峰彇鍖栭獙鏁版嵁
+     *
+     * @param param
+     * @return
+     */
+    Page<InoutCheckData> pageCheckData(InoutCheckParam param);
+
+    /**
+     * 鏇存柊鍖栭獙淇℃伅
+     *
+     * @param data
+     * @return
+     * @throws Exception
+     */
+    String updateCheckData(InoutData data);
+
+    /**
+     * 鑾峰彇绮瀹氫环
+     *
+     * @param param
+     * @return
+     */
+    List<InoutPrice> getPrice(InoutCheckParam param);
+
+    /**
+     * 浠庣紦瀛樹腑鍒犻櫎
+     *
+     * @param deptId
+     * @param type
+     * @param id
+     */
+    void delFromCache(String deptId, String type, String id);
 }

--
Gitblit v1.9.3