浏览代码

Merge branch 'master' of http://git.zthymaoyi.com/gdc/yiliangyiyun-app

# Conflicts:
#	config/index.js
ccj 3 年之前
父节点
当前提交
12fe4c1630

+ 6 - 3
pages/task/my_task.vue

@@ -71,10 +71,12 @@
 			...mapState(['hasLogin', 'userInfo'])
 		},
 		onShow() {
+			this.warehouseInOutInfo.currentPage=1
+			this.data.currentPage=1
 			this.taskInfo=[]
 			this.getIndexBuyData()
 			this.pcUserInfo =  uni.getStorageSync("pcUserInfo")
-			this.warehouseInOutInfo.phone = this.userInfo.phone
+			// this.warehouseInOutInfo.phone = this.userInfo.phone
 		},
 		onReachBottom() { //上拉触底函数
 			if (!this.isLoadMore) { //此处判断,上锁,防止重复请求
@@ -226,8 +228,9 @@
 						}else{
 							that.isSole=false
 						}
-						if(res.data.data.records.length==0&&this.data.currentPage==1
-						||res.data.data.records.length==0&&this.warehouseInOutInfo.currentPage==1){
+						if(res.data.data.records.length==0&&this.data.currentPage==1&&this.statusFlag==3
+						||res.data.data.records.length==0&&this.warehouseInOutInfo.currentPage==1&&this.statusFlag==1){
+							console.log()
 							this.taskInfo=[]
 						}
 						uni.hideLoading()

+ 1 - 7
pages/task/procurement_close_details.vue

@@ -101,12 +101,6 @@
 			
 			// this.userInfo =  uni.getStorageSync("userInfo")
 		},
-		onReachBottom() { //上拉触底函数
-			if (!this.isLoadMore) { //此处判断,上锁,防止重复请求
-				this.warehouseInOutInfo.currentPage += 1
-				this.Data()
-			}
-		},
 		methods: {
 			getData(){
 				var data=[]
@@ -139,7 +133,7 @@
 														uni.navigateBack()
 													})
 												}else{
-													that.$api.msg(res1.data.message);
+													that.$api.msg('系统异常,请联系管理员');
 												}
 											})
 										}

+ 15 - 15
pages/task/procurement_details.vue

@@ -99,20 +99,16 @@
 			
 			// this.userInfo =  uni.getStorageSync("userInfo")
 		},
-		onReachBottom() { //上拉触底函数
-			if (!this.isLoadMore) { //此处判断,上锁,防止重复请求
-				this.warehouseInOutInfo.currentPage += 1
-				this.Data()
-			}
-		},
 		methods: {
 			getData(){
-				var data=[]
 				this.$api.doRequest('get', '/warehouseBaseInfo/selectContractNoList', 
 				{compId:this.pcUserInfo.compId,flag:3}).then(res => {
+					var data=[]
 					if(res.data.code==200){
-						for(var i=0;i<res.data.data.length;i++){
-							data.push({value:res.data.data[i].contractNo,label:res.data.data[i].contractNo})
+						if(res.data.data.length>0){
+							for(var i=0;i<res.data.data.length;i++){
+								data.push({value:res.data.data[i].contractNo,label:res.data.data[i].contractNo})
+							}
 						}
 						this.contractNoList=data
 					}
@@ -127,6 +123,10 @@
 				this.list.contractNo=item[0].value
 			},
 			audit(){
+				       if (this.list.procurementPlanType == '期货') {
+				           this.list.freezingDeposit = this.list.transactionsNumber*this.list.customerInfo.depositRatio
+				       }
+					   console.log(this.list)
 				var that=this
 				uni.showModal({
 					content: "审核通过后,将通知客户订单生效,是否确定通过审核?",
@@ -134,25 +134,25 @@
 					confirmText: '提交',
 					success: function(res) {
 						if (res.confirm) {
-							that.$api.doRequest('post', '/purchaseOrder/api/editPurchaseOrder', that.list).then(res => {
-								if (res.data.code == 200) {
+							that.$api.doRequest('post', '/purchaseOrder/api/editPurchaseOrder', that.list).then(res1 => {
+								if (res1.data.code == 200) {
 									that.$api.doRequest('post', '/workflow/api/handle', {
 										taskId:that.list.taskId,
 										approved: true,
 										auditMind: '34',
 										needReapply: false,
-										}).then(res1 => {
-										if (res1.data.code == 200) {
+										}).then(res2 => {
+										if (res2.data.code == 200) {
 											that.$api.msg('审核成功');
 											that.$nextTick(function(){
 												uni.navigateBack(-1)
 											})
 										}else{
-											that.$api.msg(res1.data.message);
+											that.$api.msg('系统异常,请联系管理员');
 										}
 									})
 								}else{
-									that.$api.msg(res.data.message);
+									that.$api.msg('系统异常,请联系管理员');
 								}
 							})
 						}

+ 1 - 7
pages/task/procurement_report_details.vue

@@ -125,12 +125,6 @@
 			
 			// this.userInfo =  uni.getStorageSync("userInfo")
 		},
-		onReachBottom() { //上拉触底函数
-			if (!this.isLoadMore) { //此处判断,上锁,防止重复请求
-				this.warehouseInOutInfo.currentPage += 1
-				this.Data()
-			}
-		},
 		methods: {
 			getData(){
 				var data=[]
@@ -172,7 +166,7 @@
 											uni.navigateBack()
 										})
 									}else{
-										that.$api.msg(res1.data.message);
+										that.$api.msg('系统异常,请联系管理员');
 									}
 								})
 							}

+ 1 - 7
pages/task/sale_close_details.vue

@@ -101,12 +101,6 @@
 			
 			// this.userInfo =  uni.getStorageSync("userInfo")
 		},
-		onReachBottom() { //上拉触底函数
-			if (!this.isLoadMore) { //此处判断,上锁,防止重复请求
-				this.warehouseInOutInfo.currentPage += 1
-				this.Data()
-			}
-		},
 		methods: {
 			getData(){
 				var data=[]
@@ -166,7 +160,7 @@
 														uni.navigateBack()
 													})
 												}else{
-													that.$api.msg(res1.data.message);
+													that.$api.msg('系统异常,请联系管理员');
 												}
 											}).catch()
 										}

+ 5 - 8
pages/task/sale_details.vue

@@ -99,12 +99,6 @@
 			
 			// this.userInfo =  uni.getStorageSync("userInfo")
 		},
-		onReachBottom() { //上拉触底函数
-			if (!this.isLoadMore) { //此处判断,上锁,防止重复请求
-				this.warehouseInOutInfo.currentPage += 1
-				this.Data()
-			}
-		},
 		methods: {
 			getData(){
 				var data=[]
@@ -127,6 +121,9 @@
 				this.list.contractNo=item[0].value
 			},
 			audit(){
+				if (this.list.salePlanType == '期货') {
+					this.list.freezingDeposit = this.list.transactionsNumber*this.list.customerInfo.depositRatio
+				}
 				var that=this
 				uni.showModal({
 					content: "审核通过后,将通知客户订单生效,是否确定通过审核?",
@@ -148,11 +145,11 @@
 												uni.navigateBack(-1)
 											})
 										}else{
-											that.$api.msg(res1.data.message);
+											that.$api.msg('系统异常,请联系管理员');
 										}
 									})
 								}else{
-											that.$api.msg(res.data.message);
+											that.$api.msg('系统异常,请联系管理员');
 										}
 							})
 						}

+ 1 - 7
pages/task/sale_report_details.vue

@@ -125,12 +125,6 @@
 			
 			// this.userInfo =  uni.getStorageSync("userInfo")
 		},
-		onReachBottom() { //上拉触底函数
-			if (!this.isLoadMore) { //此处判断,上锁,防止重复请求
-				this.warehouseInOutInfo.currentPage += 1
-				this.Data()
-			}
-		},
 		methods: {
 			getData(){
 				var data=[]
@@ -172,7 +166,7 @@
 											uni.navigateBack()
 										})
 									}else{
-										that.$api.msg(res1.data.message);
+										that.$api.msg('系统异常,请联系管理员');
 									}
 								})
 							}