guo 2 vuotta sitten
vanhempi
commit
74757ef04a

+ 5 - 4
pages.json

@@ -33,7 +33,8 @@
 		},{
 			"path": "pages/mobile/modelThree",
 			"style": {
-				"navigationBarTitleText": "车型件"
+				"navigationBarTitleText": "车型件",
+				"enablePullDownRefresh": true
 			}
 		}
 	    ,{
@@ -41,7 +42,7 @@
             "style" :                                                                                    
             {
                 "navigationBarTitleText": "OEM零件详情",
-                "enablePullDownRefresh": false
+                "enablePullDownRefresh": true
             }
             
         }
@@ -59,7 +60,7 @@
             "style" :                                                                                    
             {
                 "navigationBarTitleText": "适用车型",
-                "enablePullDownRefresh": false
+                "enablePullDownRefresh": true
             }
             
         }
@@ -68,7 +69,7 @@
             "style" :                                                                                    
             {
                 "navigationBarTitleText": "选择子组",
-                "enablePullDownRefresh": false
+                "enablePullDownRefresh": true
             }
             
         }

+ 18 - 3
pages/mobile/CarModelList.vue

@@ -70,7 +70,10 @@
 				epc_id:'',
 				partnum:'',
 				itemData:{},
-				itemList:[]
+				itemList:[],
+				page:1,
+				total_page:1
+				
 			}
 		},
 		onLoad(opt) {
@@ -86,12 +89,16 @@
 				});
 				this.$http('advancedEpc/findApplicableModelsPc', {
 					epc_id:this.epc_id,
-					partnum:this.partnum
+					partnum:this.partnum,
+					page:this.page
 				}, 'GET').then(res => {
 					uni.hideLoading();
 					
 					this.itemData = res.data.result;
-					this.itemList = res.data.result.list;
+					var list = res.data.result.list;
+					
+					this.total_page = res.data.result.total_page;
+					this.itemList = this.itemList.concat(list)
 			
 				});
 			},
@@ -101,6 +108,14 @@
 					url: 'SonGroup?epc_id=' + this.epc_id + '&token=' + item.token + '&param=' + item.param+ '&access_time=' + this.itemData.access_time
 				})
 			},
+		},
+		onReachBottom() {
+			console.log('page--total_page',this.page,this.total_page);
+			if (this.page <= this.total_page) {
+				this.page++;
+				
+				this.getItemData()
+			}
 		}
 	}
 </script>

+ 40 - 5
pages/mobile/OemDetail.vue

@@ -212,8 +212,9 @@
 				tongyongList: [],
 				epcList: [],
 				epc_Count:'',
-				xiaoshouList:[]
-				
+				xiaoshouList:[],
+				page:1,
+				total_page:1
 			}
 		},
 		onLoad(opt) {
@@ -267,17 +268,22 @@
 				});
 				this.$http('advancedEpc/findApplicableModelsPc', {
 					epc_id:this.epc_id,
-					partnum:this.partsnum
+					partnum:this.partsnum,
+					page:this.page,
 				}, 'GET').then(res => {
 					uni.hideLoading();
 					
-					this.epcList = res.data.result.list;
+					
 					this.epc_Count = res.data.result.total_count;
+					
+					this.total_page = res.data.result.total_page;
+					var list = res.data.result.list;
+					this.epcList = this.epcList.concat(list)
 				});
 			},
 			topClick(index) {
 				this.tabIndex = index
-				
+				this.page = 1;
 				if (this.tabIndex == 0) {
 					// 配件信息
 					this.getItemData();
@@ -299,6 +305,35 @@
 				// 	// this.getItemData();
 				// }
 			},
+		},
+		onReachBottom() {
+			
+			// if (this.tabIndex == 0) {
+			// 	// 配件信息
+			// 	this.getItemData();
+			// } 
+			// // else if (this.tabIndex == 1) {
+			// // 	// 维修工时
+			// // 	// this.getItemData();
+			// // }
+			// else if (this.tabIndex == 1) {
+			// 	// 通用件
+			// 	// this.getTongData();
+			// }
+			// else
+			 if (this.tabIndex == 2) {
+				// EPC车型
+				if (this.page <= this.total_page) {
+					this.page++;
+					
+					this.getCarModelData()()
+				}
+			}
+			// else if (this.tabIndex == 4) {
+			// 	// 4S销售车型
+			// 	// this.getItemData();
+			// }
+			
 		}
 	}
 </script>

+ 2 - 1
pages/mobile/OemSearch.vue

@@ -95,7 +95,8 @@
 				});
 				this.$http('advancedEpc/findPartsPc', {
 					epc_id:this.epc_id,
-					keyword:this.searchValue
+					keyword:this.searchValue,
+					cur_page:'2',
 				}, 'GET').then(res => {
 					uni.hideLoading();
 			

+ 14 - 2
pages/mobile/SonGroup.vue

@@ -24,7 +24,9 @@
 				param:'',
 				access_time:'',
 				itemData:{},
-				itemList: []
+				itemList: [],
+				page:1,
+				total_page:1
 			}
 		},
 		onLoad(opt) {
@@ -45,12 +47,15 @@
 					token:this.token,
 					param:this.param,
 					access_time:this.access_time,
+					page:this.page
 				}, 'GET').then(res => {
 					uni.hideLoading();
 					
 					this.itemData = res.data.result;
-					this.itemList = res.data.result.list;
 					
+					this.total_page = res.data.result.total_page;
+					var list = res.data.result.list;
+					this.itemList = this.itemList.concat(list)
 			
 				});
 			},
@@ -61,6 +66,13 @@
 				
 				})
 			}
+		},
+		onReachBottom() {
+			if (this.page <= this.total_page) {
+				this.page++;
+				
+				this.getItemData()()
+			}
 		}
 	}
 </script>

+ 19 - 4
pages/mobile/modelThree.vue

@@ -57,7 +57,9 @@
 				son_epc_id: '',
 				son_token: '',
 				son_param: '',
-				son_access_time: '',
+				son_access_time: '',
+				page:1,
+				total_page:1
 			}
 		},
 		onLoad(opt) {
@@ -168,12 +170,18 @@
 					epc_id: this.epc_id,
 					token: this.token,
 					param: this.param,
-					access_time: this.access_time,
+					access_time: this.access_time,
+					page:this.page,
 				}, 'GET').then(res => {
 					uni.hideLoading();
-					
-					this.itemList = res.data.result.list.rows;
+					
+					
 					this.imgUrl = res.data.result.list.image_info[0].pic_url;
+					
+					this.total_page = res.data.result.total_page;
+					
+					var list = res.data.result.list.rows;
+					this.itemList = this.itemList.concat(list)
 					console.log('itemList++',this.itemList);
 				});
 			},
@@ -202,6 +210,13 @@
 					}
 				});
 			}
+		},
+		onReachBottom() {
+			if (this.page <= this.total_page) {
+				this.page++;
+				
+				this.getPeijianData()
+			}
 		}
 	}
 </script>