Procházet zdrojové kódy

Merge branch 'develop' of http://git.chelingzhu.com/chelingzhu-web/zxyj-mini-html into develop

lilei před 4 roky
rodič
revize
97eb43ae6f

+ 2 - 1
pages/checkOut/checkOut.vue

@@ -14,7 +14,8 @@
 			label="备注"
 			label="备注"
 			input-align="right"
 			input-align="right"
 			auto-height
 			auto-height
-			placeholder="请填写备注(最多500个字符)"
+			:maxlength="10"
+			placeholder="请填写备注(最多10个字符)"
 			type="textarea"
 			type="textarea"
 		>
 		>
 		</u-field>
 		</u-field>

+ 3 - 2
pages/goods/goodsDetail.vue

@@ -17,7 +17,7 @@
 					</view>
 					</view>
 				</view>
 				</view>
 				<view class="goods-price">
 				<view class="goods-price">
-					<view>换数量<text>(库存{{goodContent.inventoryQty}}件)</text></view>
+					<view>换数量<text>(库存{{goodContent.inventoryQty}}件)</text></view>
 					<view>
 					<view>
 						<u-number-box :max="goodContent.inventoryQty" v-model="nums"></u-number-box>
 						<u-number-box :max="goodContent.inventoryQty" v-model="nums"></u-number-box>
 					</view>
 					</view>
@@ -103,7 +103,8 @@
 			},
 			},
 			// 立即下单
 			// 立即下单
 			toOrder(){
 			toOrder(){
-				this.$u.vuex("vuex_toOrderList",[{id:this.id,buyQty:this.nums,goods:this.goodContent}])
+				// console.log(this.goodContent,this.id,'pppppppp')
+				this.$u.vuex("vuex_toOrderList",[{id:this.id,buyQty:this.nums,goodsNo:this.goodContent.goodsNo,goods:this.goodContent}])
 				uni.redirectTo({
 				uni.redirectTo({
 					url:"/pages/toOrder/index"
 					url:"/pages/toOrder/index"
 				})
 				})

+ 15 - 14
pages/order/order.vue

@@ -41,7 +41,9 @@
 										<text style="margin-right: 20upx;">
 										<text style="margin-right: 20upx;">
 											支付剩余
 											支付剩余
 										</text>
 										</text>
-										<u-count-down @end="getRow" style="margin-right: 20upx;" separator ="zh" :timestamp="filterTime(item.orderTime)" :show-days="false" :show-hours="false"></u-count-down>
+										<u-count-down @end="getRow" 
+										style="margin-right: 20upx;" separator ="zh" 
+										:timestamp="item.leftTimeT" :show-days="false" :show-hours="false"></u-count-down>
 									<u-button :custom-style="btnStyle" @click="toPay(item)"  shape="circle" type="error" size="medium">去支付</u-button>
 									<u-button :custom-style="btnStyle" @click="toPay(item)"  shape="circle" type="error" size="medium">去支付</u-button>
 								</view>
 								</view>
 								<view v-if="item.orderState=='WAIT_SEND'||item.orderState=='SEND_PART'" class="text-right">
 								<view v-if="item.orderState=='WAIT_SEND'||item.orderState=='SEND_PART'" class="text-right">
@@ -223,10 +225,12 @@
 					this.pageNo += 1
 					this.pageNo += 1
 					this.getRow()
 					this.getRow()
 				} else {
 				} else {
-					uni.showToast({
-						title: '已经到底了',
-						icon: 'none'
-					});
+					if(this.list.length) {
+						uni.showToast({
+							title: '已经到底了',
+							icon: 'none'
+						});
+					}
 					this.status = "nomore"
 					this.status = "nomore"
 				}
 				}
 			},
 			},
@@ -250,6 +254,12 @@
 						} else {
 						} else {
 							this.list = res.data.list || []
 							this.list = res.data.list || []
 						}
 						}
+						let nowT = new Date().valueOf() // 现在时间戳
+						this.list.map(item=>{
+							let orderT = new Date(item.orderTime).valueOf() // 下单时间戳
+							let tt = ((1800 * 1000) - (nowT - orderT))/1000  // 距离30分钟支付 相差时间戳  
+							item.leftTimeT = tt > 0 ? tt : 0
+						})
 						this.total = res.data.count || 0
 						this.total = res.data.count || 0
 					} else {
 					} else {
 						this.list = []
 						this.list = []
@@ -277,15 +287,6 @@
 				this.searchParams = params
 				this.searchParams = params
 				this.getRow(1)
 				this.getRow(1)
 			},
 			},
-			// 支付剩余时间
-			filterTime (time) {
-				console.log(time,'tttttt')
-				let nowT = new Date().valueOf() // 现在时间戳
-				let orderT = new Date(time).valueOf() // 下单时间戳
-				let tt = (1800 * 1000) - (nowT - orderT)   // 距离30分钟支付 相差时间戳  
-				console.log(tt,'tttttt')
-				return  tt
-			},
 			
 			
 			// 跳转到设置支付密码页
 			// 跳转到设置支付密码页
 			toSetPwd () {
 			toSetPwd () {

+ 1 - 0
pages/toOrder/index.vue

@@ -130,6 +130,7 @@
 		},
 		},
 		onLoad() {
 		onLoad() {
 			this.goodsList = this.$store.state.vuex_toOrderList
 			this.goodsList = this.$store.state.vuex_toOrderList
+			// console.log(this.goodsList,'llllllllllll')
 			// 监听设置密码是否成功
 			// 监听设置密码是否成功
 			uni.$once('setPswSuccess', this.setPsw)
 			uni.$once('setPswSuccess', this.setPsw)
 		},
 		},

+ 1 - 11
pages/userCenter/ldDetailed.vue

@@ -130,19 +130,9 @@
 						this.listdata = []
 						this.listdata = []
 						this.total = 0
 						this.total = 0
 					}
 					}
-					this.status = "loadmore"
+					this.status = "nomore"
 				})
 				})
 			},
 			},
-			// scroll-view到底部加载更多
-			onreachBottom() {
-				if(this.listdata.length < this.total){
-					this.pageNo += 1
-					this.searchHandle()
-				}else{
-					uni.showToast({ title: '已经到底了', icon: 'none' })
-					this.status = "nomore"
-				}
-			}
 		}
 		}
 	}
 	}
 </script>
 </script>