ysy 1 år sedan
förälder
incheckning
df1aa497c3
2 ändrade filer med 63 tillägg och 36 borttagningar
  1. 50 34
      pages/pda/components/outsourceList.vue
  2. 13 2
      pages/pda/workOrder/search/index.vue

+ 50 - 34
pages/pda/components/outsourceList.vue

@@ -30,7 +30,6 @@
 			<view class="box_list">
 
 
-
 				<u-list @scrolltolower="scrolltolower" class="z_list">
 
 					<view v-if="actTab == '物品清单'">
@@ -85,17 +84,6 @@
 										</view>
 
 
-
-
-
-
-
-
-
-
-
-
-
 									</view>
 
 								</view>
@@ -121,33 +109,56 @@
 
 					<view v-if="actTab  == '产出清单'">
 
+		             <view class="title_box rx-bc">
+							<view></view>
+							<view class="right_box rx-ec">
+								<u-button type="success" size="small" class="u-reset-button" @click="addPicking(3)"
+									text="添加产出"></u-button>
+							</view>
+						</view>
+						
+						<view v-for="(item, index) in standardOutputList" :key="index">
+							<label class="listBox rx-bs">
 
-						<view v-for="(item, index) in pickOutInVOList" :key="index">
-							<view class="listBox rx-bs">
+						
+						<view class="listBox-sel">
+				  
+						</view>
 
-								<view class="listBox-bottom rx">
+								<view class="listBox-con">
+							
 
-									<view class="items">
-										<text>名称</text>{{ item.name }}
-									</view>
+									<view class="listBox-bottom rx">
+										
+										<view 
+											class="items">
+											<text>名称</text>{{ item.name  }}
+										</view>
+										
+										
+										<view
+											class="items">
+											<text>编码</text>{{ item.code  }}
+										</view>
+										
+										
+										<view v-for="(itm, index) in tableH(item.rootCategoryLevelId)" :key="index"
+											class="items" v-if="!itm.formatter">
+											<text>{{ itm.label }}</text>{{ item[itm.prop] }}
+										</view>
 
-									<view class="items">
-										<text>编码</text>{{ item.code }}
-									</view>
 
 
 
-									<view v-for="(itm, index) in tableH(item.rootCategoryLevelId)" :key="index"
-										class="items" v-if="!itm.formatter">
-										<text>{{ itm.label }}</text>{{ item[itm.prop] }}
 									</view>
 
-
 								</view>
 
-							</view>
-						</view>
 
+							</label>
+
+						</view>
+						
 					</view>
 
 
@@ -208,7 +219,7 @@
 				bomMaterialList: [],
 				pickOutInList: [],
 				materialList: [],
-				pickOutInVOList: []
+				standardOutputList: []
 			}
 		},
 
@@ -235,7 +246,7 @@
 
 					this.pickOutInList = res.pickOutInList
 					this.bomMaterialList = res.bomMaterialList
-					this.pickOutInVOList = res.pickOutInVOList
+					this.standardOutputList = res.standardOutputList
 					this.$forceUpdate()
 				})
 			},
@@ -248,8 +259,10 @@
 				this.show = false
 			},
 
-			handleEvent(data) {
-				console.log('Received event with data:', data);
+			handleEvent({ message }) {
+			     if(message.pid == 3) {
+					 this.standardOutputList = message.memoList
+				 }
 
 			},
 
@@ -262,11 +275,14 @@
 
 			addPicking(id) {
 				const storageKey = Date.now() + "";
-
-				let arr = []
+				let arr = [
+					{
+						standardOutputList: this.standardOutputList
+					}
+				]
 				uni.setStorageSync(storageKey, arr);
 				uni.navigateTo({
-					url: `/pages/pda/workOrder/search/index?id=${id}&storageKey=${storageKey}&isType=zdy&taskId=${this.outObj.taskId}&classIds=[1,9]`
+					url: `/pages/pda/workOrder/search/index?id=${id}&storageKey=${storageKey}&isType=zdy&taskId=${this.outObj.taskId}&classIds=[1,23,9]`
 				})
 			},
 

+ 13 - 2
pages/pda/workOrder/search/index.vue

@@ -350,6 +350,8 @@
 						this.memoList = this.memoList.concat(_arr[0].turnover)
 					} else if (_arr.length != 0 && Object.prototype.hasOwnProperty.call(_arr[0], 'equipmentList')) {
 						this.memoList = this.memoList.concat(_arr[0].equipmentList)
+					} else if (_arr.length != 0 && Object.prototype.hasOwnProperty.call(_arr[0], 'standardOutputList')) {
+						this.memoList = this.memoList.concat(_arr[0].standardOutputList)
 					}
 
 				}
@@ -599,10 +601,19 @@
 			jumpAdd(type) {
 				if (type == 1) {
 					if (this.isType == 'pick' || this.isType == 'feed' || this.isType == 'job' || this.isType == 'zdy') {
-						uni.$emit('setSelectList', this.memoList, this.pid)
 						
 						
-						EventBus.$emit('outEvent', { message: 'Hello from AnotherComponent!' });
+						if(this.isType == 'zdy' && ( this.pid == 2 ||  this.pid == 3 )) {
+							let param = {
+								memoList: this.memoList,
+								pid:this.pid
+							}
+							EventBus.$emit('outEvent', { message: param });
+						} else {
+							uni.$emit('setSelectList', this.memoList, this.pid)
+						}
+						
+						
 						
 						uni.navigateBack()
 					}