瀏覽代碼

Merge branch 'master' of http://110.41.163.243:9980/kd-aiot/aiot-app

huang_an 1 年之前
父節點
當前提交
48fa48fec1

+ 44 - 20
pages/pda/components/bottomOperate.vue

@@ -17,23 +17,28 @@
 
 			<view v-if='btnControlReportMethod == 2' class="list rx-bc">
 				<view class="round">{{btnList[btnState].length + 1}}</view>
-				<view class="name" @click="operate('skip', {})" skip>跳过(不报工)</view>
+				<view class="name" @click="operate('skip', {})" >跳过(不报工)</view>
 				<image class="arrow_right" src="~@/static/pda/arrow_right.svg"></image>
 			</view>
 
 
-			<view class="list rx-bc" v-if="btnState == 1">
-				<view class="list_item_btn" @click="operate('jobBooking', {})">报工</view>
-				<view class="list_item_btn" @click="operate('',item)">多工单报工</view>
-			</view>
-
+		
+		
+		<view  v-if="newTaskObj.existOutsource == 1" class="list rx-bc">
+			<view class="round">{{btnList[btnState].length + 1}}</view>
+			<view class="name" @click="operate('outPicking', {})" >委外领料</view>
+			<image class="arrow_right" src="~@/static/pda/arrow_right.svg"></image>
+		</view>
+		
+		<view  v-if="newTaskObj.existOutsource == 1" class="list rx-bc">
+			<view class="round">{{btnList[btnState].length + 2}}</view>
+			<view class="name" @click="operate('jobBooking', {})" >委外报工</view>
+			<image class="arrow_right" src="~@/static/pda/arrow_right.svg"></image>
+		</view>
+		
 
 
 
-			<view class="list rx-bc" v-if="newTaskObj.existOutsource == 1">
-				<view class="list_item_btn" @click="operate('outPicking', {})">委外领料</view>
-				<view class="list_item_btn" @click="operate('jobBooking', {})">委外报工</view>
-			</view>
 
 
 		</view>
@@ -43,7 +48,8 @@
 			<view class="btn" @click="handPause()">{{ GDStatus == 9 ?  '取消暂停' : '暂停' }}</view>
 			<view class="btn" @click="handTerminate()">终止</view>
 			<view class="btn">转派</view>
-			<view class="btn" @click="handOutsource()">委外</view>
+			<view class="btn" :style="newTaskObj.existOutsource == 1 ? 'background: #FFA929' : ''" @click="handOutsource()">委外</view>
+			<view class="btn"  @click="handHandover">交接</view>
 		</view>
 
 		<SearchPopup mode="center" v-if="outsourceShow">
@@ -76,18 +82,20 @@
 								:clear='true'></zxz-uni-data-select>
 						</u-form-item>
 
-
-						<u-form-item label="直接入库:" borderBottom prop="isInWarehouse">
-							<u-checkbox-group v-model="isInWarehouse" size="14px" v-if="clientEnvironmentId != 2 ">
+                  
+						<u-form-item label="直接入库:" borderBottom prop="isInWarehouse" >
+							<u-checkbox-group v-model="isInWarehouse" size="14px"  v-if="clientEnvironmentId != 2 " >
 								<u-checkbox labelSize="14px" iconSize="10px" activeColor="#157A2C" name="true" label="是"></u-checkbox>
 							</u-checkbox-group>
-							<view v-else>是</view>
+							<view v-if="clientEnvironmentId == 2 " >是</view>
+
+
+							<zxz-uni-data-select  style="margin-left: 10px;" v-if="clientEnvironmentId == 2 || isInWarehouse.length" :localdata="warehouseList" v-model="outsourceForm.warehouseId"
+								dataValue='id' dataKey="name" filterable format='{name}'></zxz-uni-data-select>
+
 						</u-form-item>
                
-			<!-- 			<u-form-item label="发货仓库:" borderBottom prop="" v-if="isInWarehouse && isInWarehouse.length == 1">
-							<zxz-uni-data-select :localdata="warehouseList" v-model="outsourceForm.warehouseId"
-								dataValue='id' dataKey="name" filterable format='{name}'></zxz-uni-data-select>
-						</u-form-item> -->
+					
 
 
 						<u-form-item label="工艺路线:" borderBottom prop="produceRoutingId" v-if="clientEnvironmentId != 2 &&isInWarehouse && isInWarehouse.length == 0">
@@ -135,6 +143,7 @@
 		</SearchPopup>
 		
 		<outsourceList  ref="outsourceListRef" @close="outCancel()"></outsourceList>
+		<handover ref="handoverRef"></handover>
 
 	</view>
 </template>
@@ -154,6 +163,7 @@
 	import SearchPopup from './searchPopup.vue'
 	
 	import outsourceList from './outsourceList.vue'
+	import handover from './handover.vue'
 		
 	import {
 		EventBus
@@ -163,7 +173,8 @@
 	export default {
 		components: {
 			SearchPopup,
-			outsourceList
+			outsourceList,
+			handover
 		},
 
 		props: {
@@ -263,6 +274,15 @@
 							name: '更换周转车',
 							type: 'turnover'
 						},
+						{
+							name: '报工',
+							type: 'jobBooking'
+						},
+						// {
+						// 	name: '多工单报工',
+						// 	type: ''
+						// }
+						
 
 
 					],
@@ -446,6 +466,10 @@
 				}
 
 			},
+			
+			handHandover() {
+				this.$refs.handoverRef.open()
+			},
 
 			handTerminate() {
 

+ 74 - 0
pages/pda/components/handover.vue

@@ -0,0 +1,74 @@
+<template>
+	<view>
+		<u-popup :show="show" :mode='mode' :closeOnClickOverlay='false'>
+			<view class="popup_list">
+
+				<u-form labelPosition="left" :model="form" labelWidth="180" labelAlign="left" class="">
+					<u-form-item label="交接班组:" borderBottom prop="">
+						<zxz-uni-data-select :localdata="bzList" v-model="form.bz" dataValue='id' dataKey="name"
+							filterable format='{name}'></zxz-uni-data-select>
+					</u-form-item>
+				</u-form>
+			</view>
+
+
+			<view class="operate_box  rx-bc">
+				<u-button size="small" class="u-reset-button" @click="close">
+					取消
+				</u-button>
+				<u-button type="success" size="small" class="u-reset-button" @click="handOK">
+					提交
+				</u-button>
+
+			</view>
+		</u-popup>
+	</view>
+</template>
+
+<script>
+	import SearchPopup from './searchPopup.vue'
+	export default {
+		components: {},
+
+		data() {
+			return {
+				mode: 'center',
+				show: false,
+				topHight: 20 || 20,
+
+				form: {},
+				bzList: []
+			}
+		},
+		methods: {
+			open(obj) {
+
+
+				this.show = true
+			},
+
+			close() {},
+
+			handOK() {},
+		}
+
+	}
+</script>
+
+<style lang="scss" scoped>
+	.popup_list {
+		width: 78vw;
+		min-height: 360rpx;
+		padding: 0 32rpx;
+
+
+	}
+
+	.operate_box {
+		padding: 10rpx 32rpx;
+
+		/deep/ .u-button {
+			width: 40%;
+		}
+	}
+</style>

+ 7 - 2
pages/pda/components/outsourceList.vue

@@ -24,7 +24,7 @@
 					
 					<view class="item_one  perce50 rx-sc">
 						<view class="lable">直接入库:</view>
-						<view style="color: #157A2C">{{ outObj.isStraight == 1 ? '是' : '否' }}</view>
+						<view style="color: #157A2C">{{ outObj.isInWarehouse == 1 ? '是' : '否' }}</view>
 					</view>
 
 				</view>
@@ -167,7 +167,7 @@
 											<text>数量</text>{{ item.count * ( checkListLen || 1 )    }}
 										</view>
 										<view class="items content_num" v-if="!item.isDemandQuantity && clientEnvironmentId != 2">
-											<text>数量</text> <input style="8rpx !important"
+											<text>数量</text> <input style="8px !important"
 												v-model="item.demandQuantity"></input>
 										</view>
 										
@@ -229,6 +229,11 @@
 											class="items" v-if="!itm.formatter">
 											<text>{{ itm.label }}</text>{{ item[itm.prop] }}
 										</view>
+										
+										<view class="items content_num">
+											<text>数量</text> <input style="8rpx !important"
+												v-model="item.demandQuantity"></input>
+										</view>
 
 
 

+ 24 - 1
pages/pda/components/workCard.vue

@@ -1,10 +1,33 @@
 <template>
 
 	<view class="card_box" @click="handleDetail">
-		<view class="item_box rx-sc">
+		<view class="item_box rx-sc" v-if="item.workOrderType == 1">
 			<view class="round" v-if='item.index'>{{item.index}}</view>
 			<view class="orderId">{{item.code}}  </view>
 		</view>
+		
+		<view class="item_box rx-sc" v-if="item.workOrderType == 2">
+			<view class="round" v-if='item.index'>{{item.index}}</view>
+			<view class="orderId">{{item.outsourceCode}}  </view>
+		</view>
+		
+		<view class="item_box rx-bc"  v-if="item.workOrderType == 2">
+			<view class="item_one  rx-sc">
+				<view class="lable">委外名称:</view>
+				<view>{{item.outsourceName}}</view>
+			</view>
+		
+		</view>
+		
+		<view class="item_box rx-bc"  v-if="item.workOrderType == 2">
+			<view class="item_one  rx-sc">
+				<view>工单来源:</view>
+				<view>{{item.code}}</view>
+			</view>
+		</view>
+		
+		
+		
 
 		<view class="item_box rx-bc">
 			<view class="item_one perce50 rx-sc">

+ 15 - 4
pages/pda/sample/inspection/index.vue

@@ -27,6 +27,7 @@
 					</view>
 
 
+
 					<diagramLast v-if="item && Object.prototype.hasOwnProperty.call(item, 'lastObj') &&
 						item.workOrderType !=2" :item="item.lastObj"></diagramLast>
 
@@ -116,7 +117,7 @@
 
 				List: [],
 				qualityShow: false,
-				
+
 				qualityForm: {
 					num: null,
 				}
@@ -294,15 +295,25 @@
 			},
 
 			handQuality() {
+				if (Object.prototype.hasOwnProperty.call(this.List[0], 'lastObj') && this.List[0].lastObj.formedNum >
+					0) {} else {
+					uni.showToast({
+						icon: "none",
+						title: "暂无质检合格数",
+					});
+					return false
+				}
 				this.qualityShow = true
 			},
 
 			cancel() {
 				this.qualityShow = false
 			},
-			
+
 			qualityOk() {
-				if(!this.qualityForm.num && this.qualityForm.num < 1) {
+		
+
+				if (!this.qualityForm.num && this.qualityForm.num < 1) {
 					uni.showToast({
 						icon: "none",
 						title: "请先输入质检取样数",
@@ -314,7 +325,7 @@
 					workOrderId: this.id,
 					quantity: this.qualityForm.num
 				}
-				
+
 				qualityQy(param).then(res => {
 					this.$set(this.List[0], 'semiProductList', res)
 					this.qualityShow = false

+ 1 - 1
pages/pda/workOrder/index/index.vue

@@ -19,7 +19,7 @@
 
 		<view class="list_box">
 
-			<u-list @scrolltolower="scrolltolower" key="list" :preLoadScreen="page * 10">
+			<u-list @scrolltolower="scrolltolower" key="list"  lowerThreshold="100" preLoadScreen="1.5">
 				<u-list-item v-for="(item, index) in dataList" :key="index">
 					<workCard :item="item" @handleDetail="handleDetail"></workCard>
 				</u-list-item>