zhongtianhaoyuan 3 anos atrás
pai
commit
fa8d1ad1ad

+ 30 - 8
pages/task/audit/Issueandreceipt_task_approval.vue

@@ -4,16 +4,18 @@
 			<view class="topInfo-item">
 				<view class="flex info">
 					<view class="logo">
-						<image src="../../../static/img/reject.png" mode="" v-if="OutList.taskStatus == '已驳回'"
+						<image src="../../../static/img/reject.png" mode="" v-if="OutList.taskStatus == '已驳回'||EnterList.taskStatus == '已驳回'"
 							style="height: 40rpx;"></image><!-- 驳回 -->
-						<image src="../../../static/img/tongguo.png" mode="" v-if="OutList.taskStatus == '已通过'"
+						<image src="../../../static/img/tongguo.png" mode="" v-else-if="OutList.taskStatus == '已通过'||EnterList.taskStatus == '已通过'||OutList.taskStatus == '执行中'"
 							style="height: 40rpx;"></image><!-- 通过 -->
-						<image src="../../../static/img/daishenhe.png" mode="" v-if="OutList.taskStatus == '审核中'||OutList.taskStatus == '待审核'"
+						<image src="../../../static/img/daishenhe.png" mode="" v-else-if="OutList.taskStatus == '审核中'||OutList.taskStatus == '待审核'||EnterList.taskStatus == '待审核'"
 							style="height: 40rpx;"></image><!-- 待审核 -->
 					</view>
-					<view class="infoText">{{OutList.taskStatus}}</view>
+					<view class="infoText" v-if="OutList.taskStatus">{{OutList.taskStatus}}</view>
+					<view class="infoText" v-else>{{EnterList.taskStatus}}</view>
 				</view>
-				<view class="infoData">{{OutList.updateDate}}</view>
+				<view class="infoData" v-if="OutList.updateDate">{{OutList.updateDate}}</view>
+				<view class="infoData" v-else>{{EnterList.updateDate}}</view>
 			</view>
 		</view>
 		<view class="content1">
@@ -32,7 +34,7 @@
 						</view>
 						<view class='row'>
 							<view class="left">仓库</view>
-							<view class="right">{{retreatList.sendWarehouse}}</view>
+							<view class="right">{{retreatList.warehouseName}}</view>
 						</view>
 						<view class='row'>
 							<view class="left">出库类型</view>
@@ -92,7 +94,7 @@
 						</view>
 						<view class='row'>
 							<view class="left">仓库</view>
-							<view class="right">{{OutList.sendWarehouse}}</view>
+							<view class="right">{{OutList.warehouseName}}</view>
 						</view>
 						<view class='row'>
 							<view class="left">出库类型</view>
@@ -346,6 +348,11 @@
 						this.requestadd(this.EnterList, 'repetition')
 					}
 				}
+				if(this.retreatList.taskTypeKey == 1 || this.retreatList.taskTypeKey == 2){
+					this.requestadd(this.retreatList)
+				}else if(this.retreatList.taskTypeKey == 3 || this.retreatList.taskTypeKey == 4){
+					this.requestadd(this.retreatList, 'repetition')
+				}
 			},
 			rejectSubmit() {
 				// (1出库2入库3移库4退库并出库)
@@ -353,7 +360,7 @@
 					this.$api.msg('驳回原因不能为空!')
 				} else {
 					this.show1 = false
-					if (this.OutList.taskTypeKey == 1) {
+					if (this.OutList.taskTypeKey == 1 ) {
 						this.requestaudit(this.OutList)
 					} else if (this.OutList.taskTypeKey == 2) {
 						this.requestaudit(this.OutList)
@@ -366,6 +373,21 @@
 							this.requestaudit(this.OutList, 'repetition')
 						}
 					}
+					if(this.EnterList.taskTypeKey){
+						if(this.EnterList.taskTypeKey == 1 || this.EnterList.taskTypeKey == 2){
+						this.requestaudit(this.EnterList)
+					}else if(this.EnterList.taskTypeKey == 3 || this.EnterList.taskTypeKey == 4){
+						this.requestaudit(this.EnterList, 'repetition')
+					}
+					}
+					
+					if(this.retreatList.taskTypeKey){
+						if(this.retreatList.taskTypeKey == 1 || this.retreatList.taskTypeKey == 2){
+							this.requestaudit(this.retreatList)
+						}else if(this.retreatList.taskTypeKey == 3 || this.retreatList.taskTypeKey == 4){
+							this.requestaudit(this.retreatList, 'repetition')
+						}
+					}
 				}
 			},
 			requestadd(list, status) {

+ 34 - 27
pages/task/audit/Issueandreceipt_task_details.vue

@@ -4,16 +4,18 @@
 			<view class="topInfo-item">
 				<view class="flex info">
 					<view class="logo">
-						<image src="../../../static/img/reject.png" mode="" v-if="OutList.taskStatus == '已驳回'"
+						<image src="../../../static/img/reject.png" mode="" v-if="OutList.taskStatus == '已驳回'||EnterList.taskStatus == '已驳回'"
 							style="height: 40rpx;"></image><!-- 驳回 -->
-						<image src="../../../static/img/tongguo.png" mode="" v-if="OutList.taskStatus == '已通过'"
+						<image src="../../../static/img/tongguo.png" mode="" v-else-if="OutList.taskStatus == '已通过'||EnterList.taskStatus == '已通过'||OutList.taskStatus == '执行中'"
 							style="height: 40rpx;"></image><!-- 通过 -->
-						<image src="../../../static/img/daishenhe.png" mode="" v-if="OutList.taskStatus == '审核中'"
+						<image src="../../../static/img/daishenhe.png" mode="" v-else-if="OutList.taskStatus == '审核中'||OutList.taskStatus == '待审核'||EnterList.taskStatus == '待审核'"
 							style="height: 40rpx;"></image><!-- 待审核 -->
 					</view>
-					<view class="infoText">{{OutList.taskStatus}}</view>
+					<view class="infoText" v-if="OutList.taskStatus">{{OutList.taskStatus}}</view>
+					<view class="infoText" v-else>{{EnterList.taskStatus}}</view>
 				</view>
-				<view class="infoData">{{OutList.updateDate}}</view>
+				<view class="infoData" v-if="OutList.updateDate">{{OutList.updateDate}}</view>
+				<view class="infoData" v-else>{{EnterList.updateDate}}</view>
 			</view>
 		</view>
 		<view class="content1">
@@ -32,7 +34,7 @@
 						</view>
 						<view class='row'>
 							<view class="left">仓库</view>
-							<view class="right">{{retreatList.sendWarehouse}}</view>
+							<view class="right">{{retreatList.warehouseName}}</view>
 						</view>
 						<view class='row'>
 							<view class="left">出库类型</view>
@@ -92,7 +94,7 @@
 						</view>
 						<view class='row'>
 							<view class="left">仓库</view>
-							<view class="right">{{OutList.sendWarehouse}}</view>
+							<view class="right">{{OutList.warehouseName}}</view>
 						</view>
 						<view class='row'>
 							<view class="left">出库类型</view>
@@ -229,22 +231,6 @@
 				</view>
 			</u-form>
 		</view>
-		<u-popup v-model="show1" mode="center">
-			<view style="width: 300px;padding: 30rpx 10rpx;border-radius: 20rpx;">
-				<view class="rejectText">驳回原因</view>
-				<u-input v-model="rejectInfo" type="textarea" :border="border" class="rejectInfoCss"
-					placeholder="请输入驳回原因" />
-				<view class="flex">
-					<u-button @click="show1 = false" class="submit">取消</u-button>
-					<u-button @click="rejectSubmit()" class="submit">确定</u-button>
-				</view>
-			</view>
-		</u-popup>
-		<u-toast ref="uToast" />
-		<!-- <view style='padding:10px;' class='flex bottom-btn'>
-			<u-button @click='show1 = true' type="error" class="btn1" hover-class='none'>驳回</u-button>
-			<u-button @click='passSubmit()' type="success" class="btn2">通过</u-button>
-		</view> -->
 	</view>
 
 </template>
@@ -346,6 +332,11 @@
 						this.requestadd(this.EnterList, 'repetition')
 					}
 				}
+				if(this.retreatList.taskTypeKey == 1 || this.retreatList.taskTypeKey == 2){
+					this.requestadd(this.retreatList)
+				}else if(this.retreatList.taskTypeKey == 3 || this.retreatList.taskTypeKey == 4){
+					this.requestadd(this.retreatList, 'repetition')
+				}
 			},
 			rejectSubmit() {
 				// (1出库2入库3移库4退库并出库)
@@ -353,7 +344,7 @@
 					this.$api.msg('驳回原因不能为空!')
 				} else {
 					this.show1 = false
-					if (this.OutList.taskTypeKey == 1) {
+					if (this.OutList.taskTypeKey == 1 ) {
 						this.requestaudit(this.OutList)
 					} else if (this.OutList.taskTypeKey == 2) {
 						this.requestaudit(this.OutList)
@@ -366,9 +357,25 @@
 							this.requestaudit(this.OutList, 'repetition')
 						}
 					}
+					if(this.EnterList){
+						if(this.EnterList.taskTypeKey == 1 || this.EnterList.taskTypeKey == 2){
+						this.requestaudit(this.EnterList)
+					}else if(this.EnterList.taskTypeKey == 3 || this.EnterList.taskTypeKey == 4){
+						this.requestaudit(this.EnterList, 'repetition')
+					}
+					}
+					
+					if(this.retreatList){
+						if(this.retreatList.taskTypeKey == 1 || this.retreatList.taskTypeKey == 2){
+							this.requestaudit(this.retreatList)
+						}else if(this.retreatList.taskTypeKey == 3 || this.retreatList.taskTypeKey == 4){
+							this.requestaudit(this.retreatList, 'repetition')
+						}
+					}
 				}
 			},
 			requestadd(list, status) {
+				
 				list.compId = sessionStorage.getItem('ws-pf_compId')
 				list.publisher = this.userInfo.userName
 				this.$api.doRequest('post', '/inOutWarehouseTask/api/checkOrUpdateInOutTask', list).then(res => {
@@ -381,7 +388,7 @@
 						}).then(res => {
 							if (res.data.code == 200) {
 								this.$api.msg('审核成功!')
-								this.setTimeout(function() {
+								setTimeout(function() {
 										uni.navigateBack()
 								}, 1000);
 							}
@@ -402,7 +409,7 @@
 						}).then(res => {
 							if (res.data.code == 200) {
 								this.$api.msg('驳回成功!')
-								this.setTimeout(function() {
+								setTimeout(function() {
 										uni.navigateBack()
 								}, 1000);
 							}
@@ -461,7 +468,7 @@
 	}
 
 	.submit {
-		width: 40%;
+		width: 50%;
 		background: #22C572;
 		border-radius: 10rpx;
 	}