wangchao před 3 roky
rodič
revize
10ba45b8af

+ 11 - 7
pages/erpbusiness/customer.vue

@@ -220,13 +220,17 @@
 						this.recentCustomers.push(item)
 						uni.setStorageSync('recentCustomers', this.recentCustomers)
 					}else{
-						let _copyList = this.$u.deepClone(this.recentCustomers);
+						let _isDel = false
 						for (let i = 0; i < this.recentCustomers.length; i++) {
-							if (this.recentCustomers[i].customerPhone != item.customerPhone) {
-								_copyList.push(item)
-								uni.setStorageSync('recentCustomers', _copyList)
+							if (this.recentCustomers[i].customerPhone == item.customerPhone) {
+										_isDel = true
 							}
 						}
+						if(!_isDel){
+							let _data = uni.getStorageSync('recentCustomers')
+							_data.push(item)
+							uni.setStorageSync('recentCustomers', _data)
+						}
 					}
 					// uni.hideLoading()
 					uni.navigateBack()
@@ -345,20 +349,20 @@
 				// 	}
 				// }
 			},
-			emptysearch() {
+			emptysearch() {debugger
 				this.show = false
 				this.searchKeyWord = ''
 				this.gridList = []
 				this.currentPage = 1
 				this.getList()
 			},
-			doSearch() {
+			doSearch() {debugger
 				this.show = true
 				this.gridList = []
 				this.currentPage = 1
 				this.getList()
 			},
-			getList() {
+			getList() {debugger
 				var that = this
 				var url = ''
 				var data = {}

+ 1 - 1
pages/erpbusiness/index.vue

@@ -16,7 +16,7 @@
 			<!-- 获取当前用户负责的仓库,如果无仓库隐藏收购信息 -->
 			<view class="content2">
 				<view>收购信息</view>
-				<view @click="navTo('/pages/erpbusiness/acquisitionInformation?status='+status+'&id='+sgId)">{{status}}></view>
+				<view v-if="isShowAcquisitionInfo&&sgId" @click="navTo('/pages/erpbusiness/acquisitionInformation?status='+status+'&id='+sgId)">{{status}}></view>
 			</view>
 		</view>
 		<!-- <view class="wrap">

+ 3 - 3
pages/erpbusiness/quality_testing.vue

@@ -210,6 +210,9 @@
 			this.managementType = options.managementType
 		},
 		onShow() {
+			uni.showLoading({
+				title: "正在加载"
+			})
 			this.pageSize = 10
 			this.currentPage = 1
 			var that = this
@@ -292,9 +295,6 @@
 			},
 			getList(flag) {
 				var that = this
-				uni.showLoading({
-					title: "正在加载"
-				})
 				this.$api.doRequest('get', 'qualityInspectionManagement/selectQualityInspection', {
 						pageSize: this.pageSize,
 						currentPage: this.currentPage,