فهرست منبع

已退回数量,装车吨位必填

wangzhuo 1 سال پیش
والد
کامیت
745e2bb55d
2فایلهای تغییر یافته به همراه36 افزوده شده و 6 حذف شده
  1. 23 5
      pages/listview.vue
  2. 13 1
      pages/particulars/index.vue

+ 23 - 5
pages/listview.vue

@@ -17,7 +17,7 @@
 		<!-- tab -->
 		<view style="background-color: #3c9cff;">
 			<u-tabs :list="tabs" lineColor="#fff" lineWidth="60" @change="change" :activeStyle="{
-					width: '150rpx',
+					width: '140rpx',
 					height: '60rpx',
 					color: '#fff',
 					backgroundColor: '#3c9cff',
@@ -25,7 +25,7 @@
 					lineHeight: '60rpx',
 					textAlign: 'center'
 					}" :inactiveStyle="{
-					width: '150rpx',
+					width: '140rpx',
 					height: '60rpx',
 					color: '#fff',
 					backgroundColor: '#3c9cff',
@@ -134,6 +134,7 @@
 		orderBillsPlansList
 	} from "@/api/home"
 	import storage from '@/utils/storage'
+import tab from "../plugins/tab"
 	export default {
 		data() {
 			return {
@@ -184,7 +185,10 @@
 				}, {
 				    name: '已通过'
 				}, {
-				    name: '已退回'
+				    name: '已退回',
+					badge: {
+						value: null
+					}
 				}]
 				this.condition.flowType = '未提交'
 			}
@@ -199,7 +203,14 @@
 			this.condition.head += 9;
 			this.condition.tail += 9;
 			orderBillsPlansList(this.condition).then(res => {
-				var next_data = res.data;
+				var next_data = res.data.orderBillsPlansList;
+				if(res.data.numberOfReturns != null) {
+					this.tabs.forEach(tab => {
+						if(tab.name === '已退回') {
+							tab.badge.value = res.data.numberOfReturns;
+						}
+					})
+				}
 				this.orderBillsPlansList = this.orderBillsPlansList.concat(next_data);
 			})
 		},
@@ -214,7 +225,14 @@
 				this.condition.head = 1;
 				this.condition.tail = 9;
 				orderBillsPlansList(this.condition).then(res => {
-					this.orderBillsPlansList = res.data;
+					this.orderBillsPlansList = res.data.orderBillsPlansList;
+					if(res.data.numberOfReturns != null) {
+						this.tabs.forEach(tab => {
+							if(tab.name === '已退回') {
+								tab.badge.value = res.data.numberOfReturns;
+							}
+						})
+					}
 					this.loadingPageLoading = false
 				})
 			},

+ 13 - 1
pages/particulars/index.vue

@@ -462,9 +462,21 @@
 			},
 			// 提交里程点击事件
 			disabledClick() {
+				
+				if(this.formData.loadQty == null || this.formData.loadQty == 0) {
+						this.$refs.uToast.show({
+							type: 'warning',
+							icon: false,
+							message: "请输入装车吨位!",
+							iconUrl: 'https://cdn.uviewui.com/uview/demo/toast/warning.png'
+						})
+				} else {
+					this.submitShow = true
+				}
+				
 				// if (this.status317 == 2 && this.dataVerify() == 'ok') {
 				// if (this.dataVerify() == 'ok') {
-					this.submitShow = true
+					// this.submitShow = true
 				// } else {
 					// this.$refs.uToast.show({
 					// 	type: 'warning',