ソースを参照

前端小程序 sdy

zhongtianhaoyuan 3 年 前
コミット
1921b68690

+ 1 - 1
config/index.js

@@ -1,6 +1,6 @@
 const dev = {
 	baseUrl: 'https://www.zthymaoyi.com',
-	baseUrlNew: 'http://192.168.1.115:8090/',
+	baseUrlNew: 'http://192.168.1.102:8090/',
 	// baseUrlNew: 'http://api1.eliangeyun.com/',
 	h5Appid: 'wxb66b599f7f61b46f',
 	debug: false

+ 126 - 51
pages/task/audit/Issueandreceipt_task_approval.vue

@@ -3,10 +3,71 @@
 		<view class="content1">
 			<u-form :model="purchaseOrder" ref="uForm" class="uForm">
 				<u-form-item label="任务类型" prop="receivingAddress" label-width="140">
-					<u-input v-model="OutList.inOutType" input-align="right" placeholder="" disabled />
+					<u-input v-model="OutList.inOutType" input-align="right" placeholder="" disabled v-if="OutList.inOutType"/>
+					<u-input v-model="EnterList.inOutType" input-align="right" placeholder="" disabled v-else/>
 				</u-form-item>
-				<!-- <view v-if="type=='移库'" class="title part2">移库出库</view>
-				<view v-if="type=='退库'" class="title part2">退库</view> -->
+				<view v-if="retreatList.judge == 3">
+					<!-- 退库 -->
+					<view class="title part2">{{retreatList.inOutType}}</view>
+					<view class='row'>
+						<view class="left">编号</view>
+						<view class="right">{{retreatList.inOutType}} {{retreatList.inOutTaskNo}}</view>
+					</view>
+					<view class='row'>
+						<view class="left">仓库</view>
+						<view class="right">{{retreatList.sendWarehouse}}</view>
+					</view>
+					<view class='row'>
+						<view class="left">出库类型</view>
+						<view class="right">{{retreatList.inOutType}}</view>
+					</view>
+					<view class='row' v-if="retreatList.inOutType == '移库出库'">
+						<view class="left">移库任务编号</view>
+						<view class="right">{{retreatList.moveTaskNo}}</view>
+					</view>
+					<view class='row' v-if="retreatList.inOutType != '移库出库'">
+						<view class="left">合同编号</view>
+						<view class="right">{{retreatList.contractNo}}</view>
+					</view>
+					<view class='row'>
+						<view class="left">货名</view>
+						<view class="right">{{retreatList.goodsName}}</view>
+					</view>
+					<view class='row'>
+						<view class="left">重量(吨)</view>
+						<view class="right">{{retreatList.weight}}</view>
+					</view>
+					<view class='row'>
+						<view class="left">预计出库日期</view>
+						<view class="right">{{retreatList.predictDate}}</view>
+					</view>
+					<view class='row'>
+						<view class="left">出库经办人</view>
+						<view class="right">{{retreatList.publisher}}</view>
+					</view>
+					<view class="title part2">可编辑项</view>
+					<u-form-item label="品级" prop="grade" label-width="150">
+						<u-input v-model="retreatList.grade" input-align="right" placeholder="" @click='show=true'
+							disabled />
+						<u-picker :range="pjList" range-key="type" @confirm='pjPicker($event)' v-model="show"
+							mode="selector">
+						</u-picker>
+					</u-form-item>
+					<u-form-item label="容重(克/升)>=" prop="bulkDensity" label-width="190">
+						<u-input v-model="retreatList.bulkDensity" input-align="right" placeholder="" />
+					</u-form-item>
+					<u-form-item label="水分(%)<=" prop="waterContent" label-width="160">
+						<u-input v-model="retreatList.waterContent" input-align="right" placeholder="" />
+					</u-form-item>
+					<u-form-item label="单价(元/吨)" prop="unitPrice" label-width="160">
+						<u-input v-model="retreatList.unitPrice" input-align="right" placeholder="" />
+					</u-form-item>
+					
+				</view>
+				
+				
+				
+				
 				<view v-if="OutList.judge == 1">
 					<!-- 出库 -->
 					<view class="title part2">{{OutList.inOutType}}</view>
@@ -22,10 +83,6 @@
 						<view class="left">出库类型</view>
 						<view class="right">{{OutList.inOutType}}</view>
 					</view>
-				<!-- <view class='row'>
-						<view class="left">出库类型</view>
-						<view class="right">{{OutList.inOutType}}</view>
-					</view> -->
 					<view class='row' v-if="OutList.inOutType == '移库出库'">
 						<view class="left">移库任务编号</view>
 						<view class="right">{{OutList.moveTaskNo}}</view>
@@ -46,10 +103,6 @@
 						<view class="left">预计出库日期</view>
 						<view class="right">{{OutList.predictDate}}</view>
 					</view>
-					<!-- 	<view class='row'>
-					<view class="left">预计入库日期</view>
-					<view class="right">{{OutList.inOutDate}}</view>
-				</view> -->
 					<view class='row'>
 						<view class="left">出库经办人</view>
 						<view class="right">{{OutList.publisher}}</view>
@@ -71,12 +124,10 @@
 					<u-form-item label="单价(元/吨)" prop="unitPrice" label-width="160">
 						<u-input v-model="OutList.unitPrice" input-align="right" placeholder="" />
 					</u-form-item>
-					<u-form-item v-if="type!='移库'&&type!='退库'" label="业务描述" prop="businessDescribe" label-width="160"
-						label-position="top">
-						<u-input v-model="OutList.businessDescribe" input-align="left" placeholder="" type="textarea"
-							class="textarea" />
+					<u-form-item  label="业务描述" prop="businessDescribe" label-width="160"label-position="top" v-if="OutList.inOutType != '移库出库'">
+						<u-input v-model="OutList.businessDescribe" input-align="left" placeholder="" type="textarea" class="textarea" />
 					</u-form-item>
-					<u-form-item v-if="type!='退库'" label="仓位号(选填)" prop="binNumber" label-width="170">
+					<u-form-item v-if="OutList.inOutType!='退库'" label="仓位号(选填)" prop="binNumber" label-width="170">
 						<u-input v-model="OutList.binNumber" input-align="right" placeholder="未指定" />
 					</u-form-item>
 				</view>
@@ -120,28 +171,24 @@
 						<view class="right">{{EnterList.publisher}}</view>
 					</view>
 					<view class="title part2">可编辑项</view>
-					<u-form-item label="品级" prop="grade" label-width="150">
-						<u-input v-model="EnterList.grade" input-align="right" placeholder="" @click='show=true'
-							disabled />
-						<u-picker :range="pjList" range-key="type" @confirm='pjPicker1($event)' v-model="show"
-							mode="selector">
+					<u-form-item label="品级" prop="grade" label-width="150" v-if="EnterList.inOutType != '移库入库'">
+						<u-input v-model="EnterList.grade" input-align="right" placeholder="请选择品级" @click='show=true'disabled />
+						<u-picker :range="pjList" range-key="type" @confirm='pjPicker1($event)' v-model="show" mode="selector">
 						</u-picker>
 					</u-form-item>
-					<u-form-item label="容重(克/升)>=" prop="bulkDensity" label-width="190">
-						<u-input v-model="EnterList.bulkDensity" input-align="right" placeholder="" />
+					<u-form-item label="容重(克/升)>=" prop="bulkDensity" label-width="190" v-if="EnterList.inOutType != '移库入库'">
+						<u-input v-model="EnterList.bulkDensity" input-align="right" placeholder="请输入容重占比" />
 					</u-form-item>
-					<u-form-item label="水分(%)<=" prop="waterContent" label-width="160">
-						<u-input v-model="EnterList.waterContent" input-align="right" placeholder="" />
+					<u-form-item label="水分(%)<=" prop="waterContent" label-width="160" v-if="EnterList.inOutType != '移库入库'">
+						<u-input v-model="EnterList.waterContent" input-align="right" placeholder="请输入水分占比" />
 					</u-form-item>
-					<u-form-item label="单价(元/吨)" prop="unitPrice" label-width="160">
-						<u-input v-model="EnterList.unitPrice" input-align="right" placeholder="" />
+					<u-form-item label="单价(元/吨)" prop="unitPrice" label-width="160" v-if="EnterList.inOutType != '移库入库'">
+						<u-input v-model="EnterList.unitPrice" input-align="right" placeholder="请输入单价" />
 					</u-form-item>
-					<u-form-item v-if="type!='移库'&&type!='退库'" label="业务描述" prop="businessDescribe" label-width="160"
-						label-position="top">
-						<u-input v-model="EnterList.businessDescribe" input-align="left" placeholder="" type="textarea"
-							class="textarea" />
+					<u-form-item label="业务描述" prop="businessDescribe" label-width="160" label-position="top">
+						<u-input v-model="EnterList.businessDescribe" input-align="left" placeholder="请输入业务描述" type="textarea" class="textarea" />
 					</u-form-item>
-					<u-form-item v-if="type!='退库'" label="仓位号(选填)" prop="binNumber" label-width="170">
+					<u-form-item v-if="OutList.inOutType!='退库'" label="仓位号(选填)" prop="binNumber" label-width="170">
 						<u-input v-model="EnterList.binNumber" input-align="right" placeholder="未指定" />
 					</u-form-item>
 				</view>
@@ -243,11 +290,26 @@
 				</view> -->
 			</u-form>
 		</view>
+		<u-popup v-model="show1" mode="center" class="popup">
+			<view >
+				<view>驳回原因</view>
+					<view style="width:80%;height: 300rpx;padding: 20rpx;border: 2rpx solid #D8DCE6;margin: 0 auto;">
+						<u-input v-model="rejectInfo" :type="textarea" :border="border" height="340rpx" focus />
+					</view>
+					<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" />
 		<!-- <u-modal v-model="show" content="确定通过出入库任务?" showCancelButton></u-modal> -->
 		<view class="bottom-btn">
-			<u-button type="primary" class="submit" hover-class="none" @click="rejectSubmit()">驳回</u-button>
+			<u-button type="primary" class="submit" hover-class="none" @click="show1 = true">驳回</u-button>
 			<u-button type="primary" class="submit" hover-class="none" @click="passSubmit()">通过</u-button>
+				<!-- <u-button type="primary" class="submit" hover-class="none" @click="passSubmit()">{{OutList.taskStatus}}</u-button> -->
+			
 		</view>
 	</view>
 
@@ -261,16 +323,19 @@
 		data() {
 			return {
 				id: "",
-				OutList: {},
-				EnterList: {},
+				OutList: {},//出
+				EnterList: {},//入
+				retreatList:{},//退
 				type: '移库',
 				show: false,
+				show1:false,
+				border:false,
+				rejectInfo:"",
 				purchaseOrder: {
 					freightUnitPrice: "123",
 					receivingAddress: '出库',
 					grade: "1"
 				},
-
 				pjList: [{
 						type: '一等品'
 					},
@@ -329,13 +394,15 @@
 										res.data.data[i].inOutType == "暂存出库") {
 										this.OutList = res.data.data[i]
 										this.OutList.judge = 1
-									}
-									if (res.data.data[i].inOutType == "移库入库" || res.data.data[i]
-										.inOutType == "暂存入库" || res.data.data[i].inOutType == "退库" || res
+									}else if (res.data.data[i].inOutType == "移库入库" || res.data.data[i]
+										.inOutType == "暂存入库" || res
 										.data.data[i].inOutType == "采购入库" || res.data.data[i].inOutType ==
 										"贸易服务入库") {
 										this.EnterList = res.data.data[i]
 										this.EnterList.judge = 2
+									}else if(res.data.data[i].inOutType == "退库"){
+										this.retreatList = res.data.data[i]
+										this.retreatList.judge = 3
 									}
 								}
 							}
@@ -369,18 +436,22 @@
 				}
 			},
 			rejectSubmit() {
-				if (this.EnterList.taskTypeKey == 1) {
-					this.requestaudit(this.EnterList)
-				} else if (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.deletetask) {
+				if(!this.rejectInfo){
+					this.$api.msg('驳回原因不能为空!')
+				}else{
+					if (this.EnterList.taskTypeKey == 1) {
+						this.requestaudit(this.EnterList)
+					} else if (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.deletetask) {
+							this.requestaudit(this.EnterList, 'repetition')
+						}
+					}	
 				}
 			},
 			requestadd(list, status) {
@@ -409,7 +480,7 @@
 						this.$api.doRequest('post', '/inOutWarehouseTask/api/checkOrUpdateInOutTask', {
 							taskId: list.taskId,
 							approved: false,
-							auditMind: "驳回原因",
+							auditMind: this.rejectInfo,
 							needReapply: true
 						}).then(res => {
 							if (res.data.code == 200) {
@@ -481,4 +552,8 @@
 			color: #333333;
 		}
 	}
+	//弹出框
+	.popup{
+		padding: 30rpx;
+		}
 </style>

+ 469 - 5
pages/task/audit/Issueandreceipt_task_details.vue

@@ -1,22 +1,486 @@
 <template>
-	<view>
-		出入库任务详情
+	<view class="warp">
+		<view class="content1">
+			<u-form :model="purchaseOrder" ref="uForm" class="uForm">
+				<u-form-item label="任务类型" prop="receivingAddress" label-width="140">
+					<u-input v-model="OutList.inOutType" input-align="right" placeholder="" disabled />
+				</u-form-item>
+				<!-- <view v-if="type=='移库'" class="title part2">移库出库</view>
+				<view v-if="type=='退库'" class="title part2">退库</view> -->
+				<view v-if="OutList.judge == 1">
+					<!-- 出库 -->
+					<view class="title part2">{{OutList.inOutType}}</view>
+					<view class='row'>
+						<view class="left">编号</view>
+						<view class="right">{{OutList.inOutType}} {{OutList.inOutTaskNo}}</view>
+					</view>
+					<view class='row'>
+						<view class="left">仓库</view>
+						<view class="right">{{OutList.sendWarehouse}}</view>
+					</view>
+					<view class='row'>
+						<view class="left">出库类型</view>
+						<view class="right">{{OutList.inOutType}}</view>
+					</view>
+				<!-- <view class='row'>
+						<view class="left">出库类型</view>
+						<view class="right">{{OutList.inOutType}}</view>
+					</view> -->
+					<view class='row' v-if="OutList.inOutType == '移库出库'">
+						<view class="left">移库任务编号</view>
+						<view class="right">{{OutList.moveTaskNo}}</view>
+					</view>
+					<view class='row' v-if="OutList.inOutType != '移库出库'">
+						<view class="left">合同编号</view>
+						<view class="right">{{OutList.contractNo}}</view>
+					</view>
+					<view class='row'>
+						<view class="left">货名</view>
+						<view class="right">{{OutList.goodsName}}</view>
+					</view>
+					<view class='row'>
+						<view class="left">重量(吨)</view>
+						<view class="right">{{OutList.weight}}</view>
+					</view>
+					<view class='row'>
+						<view class="left">预计出库日期</view>
+						<view class="right">{{OutList.predictDate}}</view>
+					</view>
+					<!-- 	<view class='row'>
+					<view class="left">预计入库日期</view>
+					<view class="right">{{OutList.inOutDate}}</view>
+				</view> -->
+					<view class='row'>
+						<view class="left">出库经办人</view>
+						<view class="right">{{OutList.publisher}}</view>
+					</view>
+					<view class="title part2">可编辑项</view>
+					<u-form-item label="品级" prop="grade" label-width="150">
+						<u-input v-model="OutList.grade" input-align="right" placeholder="" @click='show=true'
+							disabled />
+						<u-picker :range="pjList" range-key="type" @confirm='pjPicker($event)' v-model="show"
+							mode="selector">
+						</u-picker>
+					</u-form-item>
+					<u-form-item label="容重(克/升)>=" prop="bulkDensity" label-width="190">
+						<u-input v-model="OutList.bulkDensity" input-align="right" placeholder="" />
+					</u-form-item>
+					<u-form-item label="水分(%)<=" prop="waterContent" label-width="160">
+						<u-input v-model="OutList.waterContent" input-align="right" placeholder="" />
+					</u-form-item>
+					<u-form-item label="单价(元/吨)" prop="unitPrice" label-width="160">
+						<u-input v-model="OutList.unitPrice" input-align="right" placeholder="" />
+					</u-form-item>
+					<u-form-item v-if="type!='移库'&&type!='退库'" label="业务描述" prop="businessDescribe" label-width="160"
+						label-position="top">
+						<u-input v-model="OutList.businessDescribe" input-align="left" placeholder="" type="textarea"
+							class="textarea" />
+					</u-form-item>
+					<u-form-item v-if="type!='退库'" label="仓位号(选填)" prop="binNumber" label-width="170">
+						<u-input v-model="OutList.binNumber" input-align="right" placeholder="未指定" />
+					</u-form-item>
+				</view>
+				<view v-if="EnterList.judge == 2">
+					<!-- 入库 -->
+					<view class="title part2">{{EnterList.inOutType}}</view>
+					<view class='row'>
+						<view class="left">编号</view>
+						<view class="right">{{EnterList.inOutType}} {{EnterList.inOutTaskNo}}</view>
+					</view>
+					<view class='row'>
+						<view class="left">仓库</view>
+						<view class="right">{{EnterList.warehouseName}}</view>
+					</view>
+					<view class='row'>
+						<view class="left">入库类型</view>
+						<view class="right">{{EnterList.inOutType}}</view>
+					</view>
+					<view class='row' v-if="EnterList.inOutType == '移库入库'">
+						<view class="left">移库任务编号</view>
+						<view class="right">{{EnterList.moveTaskNo}}</view>
+					</view>
+					<view class='row' v-if="EnterList.inOutType != '移库入库'">
+						<view class="left">合同编号</view>
+						<view class="right">{{EnterList.contractNo}}</view>
+					</view>
+					<view class='row'>
+						<view class="left">货名</view>
+						<view class="right">{{EnterList.goodsName}}</view>
+					</view>
+					<view class='row'>
+						<view class="left">重量(吨)</view>
+						<view class="right">{{EnterList.weight}}</view>
+					</view>
+					<view class='row'>
+						<view class="left">预计入库日期</view>
+						<view class="right">{{EnterList.predictDate}}</view>
+					</view>
+					<view class='row'>
+						<view class="left">出库经办人</view>
+						<view class="right">{{EnterList.publisher}}</view>
+					</view>
+					<view class="title part2">可编辑项</view>
+					<u-form-item label="品级" prop="grade" label-width="150">
+						<u-input v-model="EnterList.grade" input-align="right" placeholder="" @click='show=true'
+							disabled />
+						<u-picker :range="pjList" range-key="type" @confirm='pjPicker1($event)' v-model="show"
+							mode="selector">
+						</u-picker>
+					</u-form-item>
+					<u-form-item label="容重(克/升)>=" prop="bulkDensity" label-width="190">
+						<u-input v-model="EnterList.bulkDensity" input-align="right" placeholder="" />
+					</u-form-item>
+					<u-form-item label="水分(%)<=" prop="waterContent" label-width="160">
+						<u-input v-model="EnterList.waterContent" input-align="right" placeholder="" />
+					</u-form-item>
+					<u-form-item label="单价(元/吨)" prop="unitPrice" label-width="160">
+						<u-input v-model="EnterList.unitPrice" input-align="right" placeholder="" />
+					</u-form-item>
+					<u-form-item v-if="type!='移库'&&type!='退库'" label="业务描述" prop="businessDescribe" label-width="160"
+						label-position="top">
+						<u-input v-model="EnterList.businessDescribe" input-align="left" placeholder="" type="textarea"
+							class="textarea" />
+					</u-form-item>
+					<u-form-item v-if="type!='退库'" label="仓位号(选填)" prop="binNumber" label-width="170">
+						<u-input v-model="EnterList.binNumber" input-align="right" placeholder="未指定" />
+					</u-form-item>
+				</view>
+				<!-- <view v-if="type=='移库'">
+					<view class="title part2">移库入库</view>
+					<u-form-item label="编号" prop="receivingAddress" label-width="140">
+						<u-input v-model="purchaseOrder.receivingAddress" input-align="right" placeholder="" disabled/>
+					</u-form-item>
+					<u-form-item label="仓库" prop="receivingAddress" label-width="140">
+						<u-input v-model="purchaseOrder.receivingAddress" input-align="right" placeholder="" disabled/>
+					</u-form-item>
+					<u-form-item label="入库类型" prop="receivingAddress" label-width="140">
+						<u-input v-model="purchaseOrder.receivingAddress" input-align="right" placeholder="" disabled/>
+					</u-form-item>
+					<u-form-item label="移库任务编号" prop="receivingAddress" label-width="180">
+						<u-input v-model="purchaseOrder.receivingAddress" input-align="right" placeholder="" disabled/>
+					</u-form-item>
+					<u-form-item label="货名" prop="receivingAddress" label-width="140">
+						<u-input v-model="purchaseOrder.receivingAddress" input-align="right" placeholder="" disabled/>
+					</u-form-item>
+					<u-form-item label="重量(吨)" prop="receivingAddress" label-width="140">
+						<u-input v-model="purchaseOrder.receivingAddress" input-align="right" placeholder="" disabled/>
+					</u-form-item>
+					<u-form-item label="预计入库时间" prop="receivingAddress" label-width="180">
+						<u-input v-model="purchaseOrder.receivingAddress" input-align="right" placeholder="" disabled/>
+					</u-form-item>
+					<u-form-item label="入库经办人" prop="receivingAddress" label-width="150">
+						<u-input v-model="purchaseOrder.receivingAddress" input-align="right" placeholder="" disabled/>
+					</u-form-item>
+					<u-form-item label="品级" prop="receivingAddress" label-width="150">
+						<u-input v-model="purchaseOrder.receivingAddress" input-align="right" placeholder="" @click='show=true' disabled/>
+						<u-picker :range="pjList" range-key="type" @confirm='pjPicker($event)' v-model="show" mode="selector">
+						</u-picker>
+					</u-form-item>
+					<u-form-item label="容重(克/升)>=" prop="receivingAddress" label-width="190">
+						<u-input v-model="purchaseOrder.receivingAddress" input-align="right" placeholder=""/>
+					</u-form-item>
+					<u-form-item label="水分(%)<=" prop="receivingAddress" label-width="160">
+						<u-input v-model="purchaseOrder.receivingAddress" input-align="right" placeholder=""/>
+					</u-form-item>
+					<u-form-item label="单价(元/吨)" prop="receivingAddress" label-width="160">
+						<u-input v-model="purchaseOrder.receivingAddress" input-align="right" placeholder=""/>
+					</u-form-item>
+					<view class="title part2">可编辑项</view>
+					<u-form-item label="业务描述" prop="receivingAddress" label-width="160" label-position="top">
+						<u-input v-model="purchaseOrder.receivingAddress" input-align="left" placeholder="" type="textarea" class="textarea"/>
+					</u-form-item>
+					<u-form-item label="仓位号(选填)" prop="receivingAddress" label-width="170">
+						<u-input v-model="purchaseOrder.receivingAddress" input-align="right" placeholder="未指定"/>
+					</u-form-item>
+				</view>
+				<view v-if="type=='退库'">
+					<view class="title part2">出</view>
+					<u-form-item label="编号" prop="receivingAddress" label-width="140">
+						<u-input v-model="purchaseOrder.receivingAddress" input-align="right" placeholder="" disabled/>
+					</u-form-item>
+					<u-form-item label="仓库" prop="receivingAddress" label-width="140">
+						<u-input v-model="purchaseOrder.receivingAddress" input-align="right" placeholder="" disabled/>
+					</u-form-item>
+					<u-form-item label="出库类型" prop="receivingAddress" label-width="140">
+						<u-input v-model="purchaseOrder.receivingAddress" input-align="right" placeholder="" disabled/>
+					</u-form-item>
+					<u-form-item label="合同编号" prop="receivingAddress" label-width="180">
+						<u-input v-model="purchaseOrder.receivingAddress" input-align="right" placeholder="" disabled/>
+					</u-form-item>
+					<u-form-item label="货名" prop="receivingAddress" label-width="140">
+						<u-input v-model="purchaseOrder.receivingAddress" input-align="right" placeholder="" disabled/>
+					</u-form-item>
+					<u-form-item label="重量(吨)" prop="receivingAddress" label-width="140">
+						<u-input v-model="purchaseOrder.receivingAddress" input-align="right" placeholder="" disabled/>
+					</u-form-item>
+					<u-form-item label="预计出库时间" prop="receivingAddress" label-width="180">
+						<u-input v-model="purchaseOrder.receivingAddress" input-align="right" placeholder="" disabled/>
+					</u-form-item>
+					<u-form-item label="出库经办人" prop="receivingAddress" label-width="150">
+						<u-input v-model="purchaseOrder.receivingAddress" input-align="right" placeholder="" disabled/>
+					</u-form-item>
+					<u-form-item label="品级" prop="receivingAddress" label-width="150">
+						<u-input v-model="purchaseOrder.receivingAddress" input-align="right" placeholder="" @click='show=true' disabled/>
+						<u-picker :range="pjList" range-key="type" @confirm='pjPicker($event)' v-model="show" mode="selector">
+						</u-picker>
+					</u-form-item>
+					<u-form-item label="容重(克/升)>=" prop="receivingAddress" label-width="190">
+						<u-input v-model="purchaseOrder.receivingAddress" input-align="right" placeholder=""/>
+					</u-form-item>
+					<u-form-item label="水分(%)<=" prop="receivingAddress" label-width="160">
+						<u-input v-model="purchaseOrder.receivingAddress" input-align="right" placeholder=""/>
+					</u-form-item>
+					<u-form-item label="单价(元/吨)" prop="receivingAddress" label-width="160">
+						<u-input v-model="purchaseOrder.receivingAddress" input-align="right" placeholder=""/>
+					</u-form-item>
+					<view class="title part2">可编辑项</view>
+					<u-form-item label="业务描述" prop="receivingAddress" label-width="160" label-position="top">
+						<u-input v-model="purchaseOrder.receivingAddress" input-align="left" placeholder="" type="textarea" class="textarea"/>
+					</u-form-item>
+					<u-form-item label="仓位号(选填)" prop="receivingAddress" label-width="170">
+						<u-input v-model="purchaseOrder.receivingAddress" input-align="right" placeholder="未指定"/>
+					</u-form-item>
+				</view> -->
+			</u-form>
+		</view>
+		<u-toast ref="uToast" />
+		<!-- <u-modal v-model="show" content="确定通过出入库任务?" showCancelButton></u-modal> -->
+		<view class="bottom-btn">
+		<!-- 	<u-button type="primary" class="submit" hover-class="none" @click="rejectSubmit()">驳回</u-button>
+			<u-button type="primary" class="submit" hover-class="none" @click="passSubmit()">通过</u-button> -->
+				<u-button type="primary" class="submit" hover-class="none" @click="passSubmit()">{{OutList.taskStatus}}</u-button>
+			
+		</view>
 	</view>
+
 </template>
 
 <script>
+	import {
+		mapState
+	} from 'vuex';
 	export default {
 		data() {
 			return {
-				
+				id: "",
+				OutList: {},
+				EnterList: {},
+				type: '移库',
+				show: false,
+				purchaseOrder: {
+					freightUnitPrice: "123",
+					receivingAddress: '出库',
+					grade: "1"
+				},
+
+				pjList: [{
+						type: '一等品'
+					},
+					{
+						type: '二等品'
+					},
+					{
+						type: '三等品'
+					},
+					{
+						type: '等外'
+					}
+				],
+				rules: {
+					freightUnitPrice: [{
+							validator: (rule, value, callback) => {
+								return !this.$u.test.isEmpty(value)
+							},
+							message: '运费不能为空',
+							trigger: ['change', 'blur']
+						},
+						{
+							validator: (rule, value, callback) => {
+								return this.$u.test.amount(value)
+							},
+							message: '数值类型,最多保留两位小数',
+							trigger: ['change', 'blur'],
+						}
+					]
+				}
 			}
 		},
+		onReady() {
+			this.$refs.uForm.setRules(this.rules);
+		},
+		onLoad(options) {
+			this.id = options.id
+			this.getList()
+		},
+		computed: {
+			...mapState(['hasLogin', 'userInfo']),
+		},
 		methods: {
-			
+			getList() {
+				this.$api.doRequest('get', '/inOutWarehouseTask/getTask', {
+					id: this.id
+				}).then(res => {
+					if (res.data.code == 200) {
+						this.$api.doRequest('get', '/inOutWarehouseTask/getInOutWarehouseTask', {
+							relevanceId: res.data.data.relevanceId
+						}).then(res => {
+							if (res.data.code == 200) {
+								for (let i = 0; i < res.data.data.length; i++) {
+									if (res.data.data[i].inOutType == "移库出库" || res.data.data[i]
+										.inOutType == "贸易服务出库" || res.data.data[i].inOutType == "销售出库" ||
+										res.data.data[i].inOutType == "暂存出库") {
+										this.OutList = res.data.data[i]
+										this.OutList.judge = 1
+									}
+									if (res.data.data[i].inOutType == "移库入库" || res.data.data[i]
+										.inOutType == "暂存入库" || res.data.data[i].inOutType == "退库" || res
+										.data.data[i].inOutType == "采购入库" || res.data.data[i].inOutType ==
+										"贸易服务入库") {
+										this.EnterList = res.data.data[i]
+										this.EnterList.judge = 2
+									}
+								}
+							}
+						})
+					}
+				})
+			},
+			pjPicker(e) {
+				this.OutList.grade = this.pjList[e[0]].type
+				this.OutList.gradeKey = e[0] + 1
+			},
+			pjPicker1(e) {
+				this.EnterList.grade = this.pjList[e[0]].type
+				this.EnterList.gradeKey = e[0] + 1
+			},
+			passSubmit() {
+				this.OutList.inOutFlag = 1
+				this.EnterList.inOutFlag = 2
+				if (this.OutList.taskTypeKey == 1) {
+					this.requestadd(this.OutList)
+				} else if (this.EnterList.taskTypeKey == 2) {
+					this.requestadd(this.EnterList)
+				} else if (
+					this.OutList.taskTypeKey == 3 ||
+					this.OutList.taskTypeKey == 4
+				) {
+					this.requestadd(this.OutList, 'repetition')
+					if (!this.deletetask) {
+						this.requestadd(this.EnterList, 'repetition')
+					}
+				}
+			},
+			rejectSubmit() {
+				if (this.EnterList.taskTypeKey == 1) {
+					this.requestaudit(this.EnterList)
+				} else if (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.deletetask) {
+						this.requestaudit(this.EnterList, '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 => {
+					if (res.data.code == 200) {
+						this.$api.doRequest('post', '/inOutWarehouseTask/api/checkOrUpdateInOutTask', {
+							taskId: list.taskId,
+							approved: true,
+							auditMind: '34',
+							needReapply: false
+						}).then(res => {
+							if (res.data.code == 200) {
+								this.$api.msg('审核成功!')
+							}
+						})
+					}
+				})
+			},
+			requestaudit(list, status) {
+				list.compId = '2710b21efc1e4393930c5dc800010dc4'
+				list.publisher = this.userInfo.userName
+				this.$api.doRequest('post', '/inOutWarehouseTask/api/checkOrUpdateInOutTask', list).then(res => {
+					if (res.data.code == 200) {
+						this.$api.doRequest('post', '/inOutWarehouseTask/api/checkOrUpdateInOutTask', {
+							taskId: list.taskId,
+							approved: false,
+							auditMind: "驳回原因",
+							needReapply: true
+						}).then(res => {
+							if (res.data.code == 200) {
+								this.$api.msg('驳回成功!')
+							}
+						})
+					}
+				})
+			},
 		}
 	}
 </script>
 
-<style>
+<style scoped lang="scss">
+	.content1,
+	.content2 {
+		background-color: #FFFFFF;
+		margin: 10rpx;
+		padding-bottom: 10rpx;
+		border-radius: 20rpx;
 
+		.title {
+			font-size: 28rpx;
+			font-weight: 600;
+			color: #333333;
+			text-align: center;
+		}
+	}
+
+	.uForm {
+		padding: 0 40rpx;
+	}
+
+	.u-form-item {
+		padding: 0;
+	}
+
+	.bottom-btn {
+		width: 100%;
+		position: fixed;
+		bottom: 40rpx;
+		display: flex;
+		z-index: 2;
+	}
+
+	.submit {
+		width: 40%;
+		background: #22C572;
+		border-radius: 10rpx;
+	}
+
+	.part2 {
+		margin-top: 20rpx;
+	}
+
+	.textarea {
+		border: 1px solid #ccc;
+	}
+
+	.row {
+		display: flex;
+		justify-content: space-between;
+		border-bottom: 1px solid #EEEEEE;
+		padding: 21rpx 0;
+
+		.right,
+		input {
+			font-size: 28rpx;
+			color: #333333;
+		}
+	}
 </style>

+ 23 - 23
pages/task/audit/acquisition_settlement_approval.vue

@@ -67,35 +67,35 @@
 					}
 				})
 			},
-			//
+			//
 			rejectSubmit() {
-				if(this.List.length > 0){
+				var that = this
+				if (this.List.length > 0) {
 					uni.showModal({
-						content: "确定驳回付款申请?",
-						success(res) {
-							// this.$api.doRequest('get', '/paymentManagement/api/openAuditFlow', {
-							// 	compId: "2710b21efc1e4393930c5dc800010dc4",
-							// 	id: item.id
-							// }).then(res => {
-							// 	if (res.data.code == 200) {
-							// 		this.List = res.data.data.records
-							// 	}
-							// })
-							 this.audit(this.List[0], 0, false, '', '')
+						content: "确定驳回付款申请?",
+						showCancel: true,
+						confirmText: '确定',
+						success: function(res) {
+							if (res.confirm) {
+								that.audit(that.List[0], 0, false, '', '')
+							}
 						}
 					})
 				}
 			},
 			//通過
 			passSubmit() {
-				if(this.List.length > 0){
-					uni.showModal({
-					content: "确定通过付款申请?",
-					success(res) {
-						 this.audit(this.List[0], 0, true)
+				var that = this
+				uni.showModal({
+					content: "确定通过付款申请?",
+					showCancel: true,
+					confirmText: '确定',
+					success: function(res) {
+						if (res.confirm) {
+							that.audit(that.List[0], 0, true)
+						}
 					}
 				})
-				}
 			},
 			audit(item, index, status, status2, reason) {
 				if (this.List.length > 0) {
@@ -112,8 +112,8 @@
 						this.$api.doRequest('get', '/workflow/api/handle', {
 							taskId: item.taskId,
 							approved: status,
-							auditMind: reason != undefined ? '已驳回' : '34',
-							needReapply: status2 != undefined ? true : false
+							auditMind: reason  ? '已驳回' : '34',
+							needReapply: status2  ? true : false
 						}).then(res => {
 							if (res.data.code == 200) {
 								this.audit(this.List[index + 1], index + 1, status, status2, reason)
@@ -122,10 +122,10 @@
 					}
 				} else {
 					if (status == true) {
-						this.$message.success('通过成功')
+						that.$api.msg('通过成功')
 						this.getList()
 					} else if (status == false) {
-						this.$message.success('驳回成功')
+						that.$api.msg('驳回成功')
 						this.getList()
 					}
 				}

+ 110 - 48
pages/task/audit/acquisition_settlement_details.vue

@@ -5,74 +5,131 @@
 				<view class="left">仓库</view>
 				<view class="right">鲅鱼圈一号库</view>
 			</view>
-			<view v-for="(item,index) in 4">
+			<view v-for="(item,index) in List">
 				<view class='row row1'>
-					<view class="left">SG11111111111</view>
-					<view class="right">辽H12345</view>
+					<view class="left">{{item.paymentNo}}</view>
+					<view class="right">{{item.carNo}}</view>
 				</view>
 				<view class='row'>
-					<view class="left">玉米(150000kg-2.58)</view>
-					<view class="right">100000元</view>
+					<view class="left">{{item.goodsName}}({{item.netWeight}} - {{item.tidalGrainPrice}})</view>
+					<view class="right">{{item.amountIngPayable}}</view>
 				</view>
 			</view>
-			
+
 		</view>
 		<u-toast ref="uToast" />
 		<view class="bottom-btn">
-			<u-button type="primary" class="submit" hover-class="none" @click="rejectSubmit()">驳回</u-button>
-			<u-button type="primary" class="submit" hover-class="none" @click="passSubmit()">通过</u-button>
+		<!-- 	<u-button type="primary" class="submit" hover-class="none" @click="rejectSubmit()">驳回</u-button>
+			<u-button type="primary" class="submit" hover-class="none" @click="passSubmit()">通过</u-button> -->
 		</view>
 	</view>
 </template>
 
 <script>
+	import {
+		mapState
+	} from 'vuex';
 	export default {
 		data() {
 			return {
-				
+				id: "",
+				currentPage: 1,
+				pageSize: 10,
+				List: [],
 			}
 		},
+		onLoad(options) {
+			this.id = options.id
+		},
+		onShow(options) {
+			this.getList()
+		},
+		computed: {
+			...mapState(['hasLogin', 'userInfo']),
+		},
 		methods: {
-			rejectSubmit(){
-				uni.showModal({
-					content: "确定驳回该设置?",
-					success(res) {
-						// if (res.confirm) {
-						// 	that.$api.doRequest('post', '/warehouseInOutInfo/InOutWarehouse',
-						// 		that.detailData).then(res => {
-						// 		if (res.data.code == 200) {
-						// 		that.$api.msg(title)
-						// 		setTimeout(() => {
-						// 			uni.navigateBack()
-						// 		}, 1000)
-						// 		}else{
-						// 			that.$api.msg(res.data.message)
-						// 		}
-						// 	})
-						// }
+			getList() {
+				// this.$api.doRequest('get', '/stockPurchaseReceiptReport/getInfo', {
+				// id:this.id
+				// }).then(res => {
+				// 	if (res.data.code == 200) {
+				// 		console.log("hdshfuiehfiuo",res)
+				// 	}
+				// })
+				this.$api.doRequest('get', '/paymentManagement/selectPaymentManagement', {
+					currentPage: this.currentPage,
+					pageSize: this.pageSize,
+					// warehouseName: this.warehouseName,
+					managementType: 1
+				}).then(res => {
+					if (res.data.code == 200) {
+						this.List = res.data.data.records
 					}
 				})
 			},
-			passSubmit(){
+			//驳回
+			rejectSubmit() {
+				var that = this
+				if (this.List.length > 0) {
+					uni.showModal({
+						content: "确定驳回付款申请?",
+						showCancel: true,
+						confirmText: '确定',
+						success: function(res) {
+							if (res.confirm) {
+								that.audit(that.List[0], 0, false, '', '')
+							}
+						}
+					})
+				}
+			},
+			//通過
+			passSubmit() {
+				var that = this
 				uni.showModal({
-					content: "确定通过该设置?",
-					success(res) {
-						// if (res.confirm) {
-						// 	that.$api.doRequest('post', '/warehouseInOutInfo/InOutWarehouse',
-						// 		that.detailData).then(res => {
-						// 		if (res.data.code == 200) {
-						// 		that.$api.msg(title)
-						// 		setTimeout(() => {
-						// 			uni.navigateBack()
-						// 		}, 1000)
-						// 		}else{
-						// 			that.$api.msg(res.data.message)
-						// 		}
-						// 	})
-						// }
+					content: "确定通过付款申请?",
+					showCancel: true,
+					confirmText: '确定',
+					success: function(res) {
+						if (res.confirm) {
+							that.audit(that.List[0], 0, true)
+						}
 					}
 				})
 			},
+			audit(item, index, status, status2, reason) {
+				if (this.List.length > 0) {
+					if (status == true && item.status == "已驳回") {
+						this.$api.doRequest('get', '/paymentManagement/api/openAuditFlow', {
+							compId: "2710b21efc1e4393930c5dc800010dc4",
+							id: item.id
+						}).then(res => {
+							if (res.data.code == 200) {
+								this.audit(this.List[index + 1], index + 1, status, status2, reason)
+							}
+						})
+					} else {
+						this.$api.doRequest('get', '/workflow/api/handle', {
+							taskId: item.taskId,
+							approved: status,
+							auditMind: reason  ? '已驳回' : '34',
+							needReapply: status2  ? true : false
+						}).then(res => {
+							if (res.data.code == 200) {
+								this.audit(this.List[index + 1], index + 1, status, status2, reason)
+							}
+						})
+					}
+				} else {
+					if (status == true) {
+						that.$api.msg('通过成功')
+						this.getList()
+					} else if (status == false) {
+						that.$api.msg('驳回成功')
+						this.getList()
+					}
+				}
+			},
 		}
 	}
 </script>
@@ -82,25 +139,26 @@
 		margin: 10rpx;
 		padding: 20rpx 20rpx 140rpx 20rpx;
 	}
+
 	.content1,
 	.content2 {
 		border-radius: 20rpx;
 		background: white;
 		padding: 20rpx;
-	
+
 		.title {
 			font-size: 28rpx;
 			font-weight: 600;
 			color: #333333;
 			text-align: center;
 		}
-	
+
 		.row {
 			display: flex;
 			justify-content: space-between;
 			border-bottom: 1px solid #EEEEEE;
 			padding: 21rpx 0;
-	
+
 			.right,
 			input {
 				font-size: 28rpx;
@@ -108,9 +166,11 @@
 			}
 		}
 	}
-	.content2{
+
+	.content2 {
 		margin-top: 20rpx;
 	}
+
 	.bottom-btn {
 		width: 92%;
 		position: fixed;
@@ -118,12 +178,14 @@
 		display: flex;
 		z-index: 2;
 	}
+
 	.submit {
 		width: 40%;
 		background: #22C572;
 		border-radius: 10rpx;
 	}
-	.row1{
-		border-bottom: 0!important;
+
+	.row1 {
+		border-bottom: 0 !important;
 	}
 </style>

+ 1 - 1
pages/task/audit/freight_setting_approval.vue

@@ -56,7 +56,7 @@
 				tranProcessInfo.flag = "1"
 				tranProcessInfo.tranPriceIng = this.list.tranPriceIng
 				this.$api.doRequest('post', '/tranProcessInfo/api/setUpTranPrice', tranProcessInfo).then(res => {
-					this.$message.success('审核通过成功')
+						that.$api.msg('审核通过成功')
 				})
 			}
 		}

+ 8 - 11
pages/task/audit/freight_settlement_approval.vue

@@ -48,7 +48,6 @@
 				currentPage: 1,
 				pageSize: 10,
 				list: [],
-
 			}
 		},
 		onLoad() {
@@ -69,8 +68,9 @@
 			},
 			// 驳回
 			rejectSubmit() {
+				var that = this
 				if (this.list.length == 0) {
-					this.$message.success('没有要审核的条目!')
+						this.$api.msg('没有要审核的条目!')
 				} else {
 					uni.showModal({
 						content: "是否确定驳回?",
@@ -78,7 +78,7 @@
 						confirmText: '确定',
 						success: function(res) {
 							if (res.confirm) {
-								this.audit(this.list[0], 0, false, true, '已驳回')
+								that.audit(that.list[0], 0, false, true, '已驳回')
 							}
 						}
 					})
@@ -86,8 +86,9 @@
 			},
 			//通过
 			passSubmit() {
+				var that = this
 				if (this.list.length == 0) {
-					this.$message.success('没有要审核的条目!')
+					this.$api.msg('没有要审核的条目!')
 				} else {
 					uni.showModal({
 						content: "是否确定通过?",
@@ -95,16 +96,12 @@
 						confirmText: '确定',
 						success: function(res) {
 							if (res.confirm) {
-								this.a(0)
-								// this.audit(this.list[0], 0, true, 2)
+								that.audit(that.list[0], 0, true, 2)
 							}
 						}
 					})
 				}
 			},
-			a(ing){
-				console.log(ing)
-			},
 			//审核方法
 			audit(item, index, status, status2, reason) {
 				if (index < this.list.length) {
@@ -118,10 +115,10 @@
 					})
 				} else {
 					if (status == true) {
-						this.$message.success('通过成功')
+							that.$api.msg('通过成功')
 						this.getList()
 					} else if (status == false) {
-						this.$message.success('驳回成功')
+							that.$api.msg('驳回成功')
 						this.getList()
 					}
 				}

+ 36 - 16
pages/task/audit/purchase_settlement_approval.vue

@@ -70,30 +70,50 @@
 			},
 			//驳回
 			rejectSubmit(){
+				var that = this
 				if (this.list.length == 0) {
-					this.$message.success('没有要审核的条目!')
+						that.$api.msg('没有要审核的条目!')
 				} else {
+					// uni.showModal({
+					// 	content: "是否确定驳回?",
+					// 	success(res) {
+					// 		if(res)
+					// 		this.audit(this.list[0], 0, false, true, '已驳回')
+					// 	}
+					// })
+					
+					
 					uni.showModal({
-						content: "是否确定驳回?",
-						success(res) {
-							if(res)
-							this.audit(this.list[0], 0, false, true, '已驳回')
-						}
-					})
+						content: "是否确定驳回?",
+						showCancel: true,
+						confirmText: '确定',
+						success: function(res) {
+							if (res.confirm) {
+								that.audit(that.list[0], 0, false, true, '已驳回')
+							}}})
 				}
 			},
 			//通过
 			passSubmit(){
+				var that = this
 				if (this.list.length == 0) {
-					this.$message.success('没有要审核的条目!')
+						that.$api.msg('没有要审核的条目!')
 				} else {
+					// uni.showModal({
+					// 	content: "是否确定通过?",
+					// 	success(res) {
+					// 		if(res)
+					// 		this.audit(this.list[0], 0, true, 2)
+					// 	}
+					// })
 					uni.showModal({
-						content: "是否确定通过?",
-						success(res) {
-							if(res)
-							this.audit(this.list[0], 0, true, 2)
-						}
-					})
+						content: "是否确定通过?",
+						showCancel: true,
+						confirmText: '确定',
+						success: function(res) {
+							if (res.confirm) {
+								that.audit(that.list[0], 0, true, 2)
+							}}})
 				}
 			},
 			//审核方法
@@ -109,10 +129,10 @@
 					})
 				} else {
 					if (status == true) {
-						this.$message.success('通过成功')
+							that.$api.msg('通过成功')
 						this.getList()
 					} else if (status == false) {
-						this.$message.success('驳回成功')
+							that.$api.msg('驳回成功')
 						this.getList()
 					}
 				}

+ 114 - 13
pages/task/audit/purchase_settlement_details.vue

@@ -3,32 +3,33 @@
 		<view class="content">
 			<view class="top">
 				<view>合同编号</view>
-				<view>123456796</view>
+				<view>{{contractNo}}</view>
 			</view>
-			<view class="car-container" v-for="(item,index) in 4">
-				<view class="car-num title">辽H123465(c001)</view>
+			<view class="car-container" v-for="(item,index) in list">
+				<view class="car-num title">{{item.carNo}}({{item.tranCarNo}})</view>
 				<view class="car-type-item">
 					<view class="left">净重</view>
-					<view class="left">150.11吨</view>
+					<view class="left">{{item.netWeight}}吨</view>
 				</view>
 				<view class="car-type-item">
 					<view class="left">结重</view>
-					<view class="left">120.4吨</view>
+					<view class="left">120.4{{item.settlementWeight}}吨</view>
 				</view>
 				<view class="car-type-item">
 					<view class="left">扣款</view>
-					<view class="left">120元/吨</view>
+					<view class="left">{{item.deductionAmountchange}}元/吨</view>
 				</view>
 				<view class="car-type-item">
 					<view class="left">应付</view>
-					<view class="left">1000元</view>
+					<view class="left">{{item.amountIngPayable}}元</view>
 				</view>
 			</view>
 		</view>
 		<u-toast ref="uToast" />
 		<view class="bottom-btn">
-			<u-button type="primary" class="submit" hover-class="none" @click="rejectSubmit()">驳回</u-button>
-			<u-button type="primary" class="submit" hover-class="none" @click="passSubmit()">通过</u-button>
+			<!-- <u-button type="primary" class="submit" hover-class="none" @click="rejectSubmit()">驳回</u-button>
+			<u-button type="primary" class="submit" hover-class="none" @click="passSubmit()">通过</u-button> -->
+			 <u-button type="primary" class="submit" hover-class="none" >???</u-button>
 		</view>
 	</view>
 </template>
@@ -37,11 +38,106 @@
 	export default {
 		data() {
 			return {
-
+				id: "",
+				currentPage:1,
+				pageSize:10,
+				list:[],
+				contractNo:"",
 			}
 		},
+		onLoad(options) {
+			this.id = options.id
+			this.getList()
+		},
 		methods: {
-
+			getList(id) {
+				this.$api.doRequest('get', '/stockPurchaseReceiptReport/getInfo', {
+					id: this.id
+				}).then(res => {
+					this.contractNo = res.data.data.contractNo
+					if (res.data.code == 200) {
+						this.$api.doRequest('get', '/stockPurchaseReceiptReport/selectPurchaseOrder', {
+						compId: "2710b21efc1e4393930c5dc800010dc4",
+						  currentPage: this.currentPage,
+						  pageSize: this.pageSize,
+						  contractNo: this.contractNo,
+						}).then(res => {
+							if (res.data.code == 200) {
+								this.list = res.data.data.records
+							}
+						})
+					}
+				})
+			},
+			//驳回
+			rejectSubmit(){
+				var that = this
+				if (this.list.length == 0) {
+						that.$api.msg('没有要审核的条目!')
+				} else {
+					// uni.showModal({
+					// 	content: "是否确定驳回?",
+					// 	success(res) {
+					// 		if(res)
+					// 		this.audit(this.list[0], 0, false, true, '已驳回')
+					// 	}
+					// })
+					
+					
+					uni.showModal({
+						content: "是否确定驳回?",
+						showCancel: true,
+						confirmText: '确定',
+						success: function(res) {
+							if (res.confirm) {
+								that.audit(that.list[0], 0, false, true, '已驳回')
+							}}})
+				}
+			},
+			//通过
+			passSubmit(){
+				var that = this
+				if (this.list.length == 0) {
+						that.$api.msg('没有要审核的条目!')
+				} else {
+					// uni.showModal({
+					// 	content: "是否确定通过?",
+					// 	success(res) {
+					// 		if(res)
+					// 		this.audit(this.list[0], 0, true, 2)
+					// 	}
+					// })
+					uni.showModal({
+						content: "是否确定通过?",
+						showCancel: true,
+						confirmText: '确定',
+						success: function(res) {
+							if (res.confirm) {
+								that.audit(that.list[0], 0, true, 2)
+							}}})
+				}
+			},
+			//审核方法
+			audit(item, index, status, status2, reason) {
+				if (index < this.list.length) {
+					this.$api.doRequest('post', '/workflow/api/handle', {
+						taskId: item.taskId,
+						approved: status,
+						auditMind: reason != undefined ? '已驳回' : '34',
+						needReapply: status2 != undefined ? true : false,
+					}).then(res => {
+						this.audit(this.list[index + 1], index + 1, status)
+					})
+				} else {
+					if (status == true) {
+							that.$api.msg('通过成功')
+						this.getList()
+					} else if (status == false) {
+							that.$api.msg('驳回成功')
+						this.getList()
+					}
+				}
+			},
 		}
 	}
 </script>
@@ -53,23 +149,27 @@
 		border-radius: 20rpx;
 		background: white;
 	}
+
 	.content {
-		.top{
+		.top {
 			display: flex;
 			justify-content: space-between;
 		}
+
 		.title {
 			font-size: 28rpx;
 			font-weight: 600;
 			color: #333333;
 			text-align: left;
 		}
-		.car-type-item{
+
+		.car-type-item {
 			display: inline-flex;
 			// justify-content: center;
 			width: 50%;
 		}
 	}
+
 	.bottom-btn {
 		width: 92%;
 		position: fixed;
@@ -77,6 +177,7 @@
 		display: flex;
 		z-index: 2;
 	}
+
 	.submit {
 		width: 40%;
 		background: #22C572;

+ 2 - 2
pages/task/audit/warehouse_approval.vue

@@ -113,7 +113,7 @@
 				uni.showModal({
 					content: "是否确定通过审核?",
 					showCancel: true,
-					confirmText: '提交',
+					confirmText: '确定',
 					success: function(res) {
 						if (res.confirm) {
 							that.$api.doRequest('post', '/purchasePrice/purchasePriceEdit', {
@@ -140,7 +140,7 @@
 				uni.showModal({
 					content: "是否确定驳回?",
 					showCancel: true,
-					confirmText: '提交',
+					confirmText: '确定',
 					success: function(res) {
 						if (res.confirm) {
 							that.$api.doRequest('post', '/workflow/api/handle', {