Browse Source

立库、海康-料箱回库bug修复

zhaohuanhuan 3 weeks ago
parent
commit
d4ab2cd4e7
1 changed files with 7 additions and 8 deletions
  1. 7 8
      src/views/haikang/putaway/putaway/index.vue

+ 7 - 8
src/views/haikang/putaway/putaway/index.vue

@@ -502,18 +502,17 @@ const setGoBack=async (item)=>{
       showLoading()
       const apiCall = mode.value ? boxReturn : taskContinue
       const params = mode.value
-        ? {warehouse,container,boxCode,externalCode:asnCode,stationCode,locationId,taskType:'ASRS'}
-        : {warehouse, boxCode, stationCode, externalCode: asnCode, emptyRobot: false}
-      const boxRes= await apiCall(params).then(res=>{
-        if(!mode.value && stationCode && dataList.value[0]?.remainBoxCount==1 ){
-          const params = {warehouse, stationCode, taskCode: equipment}
-          releaseCustomTaskStation(params).then(res=>{})
-        }
-      }).catch(err=>{
+        ? {warehouse,container,boxCode:workBinNo.value,externalCode:asnCode,stationCode,locationId,taskType:'ASRS'}
+        : {warehouse, boxCode:workBinNo.value, stationCode, externalCode: asnCode, emptyRobot: false}
+      const boxRes= await apiCall(params).catch(err=>{
         closeLoading()
       })
       closeLoading()
       if(boxRes){
+        if(!mode.value && stationCode && dataList.value[0]?.remainBoxCount==1 ){
+          const params = {warehouse, stationCode, taskCode: equipment}
+          releaseCustomTaskStation(params).then(res=>{})
+        }
         reset()
         barcodeActive.value={}
         workBinNo.value=''