ysy 2 лет назад
Родитель
Сommit
287375cbde
2 измененных файлов с 24 добавлено и 5 удалено
  1. 1 1
      pages/pda/components/bottomOperate.vue
  2. 23 4
      pages/pda/turnover/index/index.vue

+ 1 - 1
pages/pda/components/bottomOperate.vue

@@ -179,7 +179,7 @@
 				immediate: true,
 				deep: true,
 				handler(newVal) {
-					console.log(newVal)
+				
 					this.btnControlReportMethod = newVal
 				}
 			},

+ 23 - 4
pages/pda/turnover/index/index.vue

@@ -74,12 +74,13 @@
 					workOrderId: this.workOrderId,
 					taskId: this.taskId
 				}).then(res => {
-					console.log(33,res)
+
 					this.List = []
 
 					if (res.turnover && res.turnover.length) {
 						res.newTurnover = []
 						res.turnover.forEach(e => {
+
 							e.extInfo.positionList.length && e.extInfo.positionList.forEach(o => {
 								o['check'] = false
 								o['isend'] = false
@@ -135,9 +136,9 @@
 
 			scanItAllData(result) {
 				scanLedger(result).then(res => {
-                   
-					if (res[0].rootCategoryLevelId == 7) { // 周转车
 
+
+					if (res[0].rootCategoryLevelId == 7) { // 周转车
 						let isFals = this.List[0].turnover.some(m => m.code == result)
 						if (isFals) {
 							uni.showToast({
@@ -146,9 +147,27 @@
 							})
 							return false
 						}
-						this.List[0].turnover.push(res[0])
+
+
+						let _List = JSON.parse(JSON.stringify(this.List))
+
+						_List[0]['newTurnover'] = []
+
+
+						res[0].isOld = 1
+						res[0].extInfo.positionList.length && res[0].extInfo.positionList.forEach(o => {
+							o['check'] = false
+							o['isend'] = false
+							o['newQuantity'] = o.quantity
+						})
+						_List[0].turnover = res
+						this.List = _List
+						console.log(this.List)
+
 						this.$forceUpdate()
 
+
+
 					}
 
 				})