xuhaolan 3 년 전
부모
커밋
2cf2cc523d

+ 8 - 0
api/index.js

@@ -16,6 +16,14 @@ export function groom1(data) {
 		data
 	});
 }
+// vip专区
+export function getVip(data) {
+	return request({
+		url: '/api/products',
+		method: 'get',
+		data
+	});
+}
 // 新品首发
 export function groom3(data) {
 	return request({

+ 17 - 0
api/user.js

@@ -181,3 +181,20 @@ export function share(data) {
 		data
 	})
 }
+//上传图片
+export function upload(data) {
+	return request({
+		url: '/api/upload/image',
+		method: 'post',
+		data
+	})
+}
+
+//用户修改信息
+export function edit(data) {
+	return request({
+		url: '/api/user/edit',
+		method: 'post',
+		data
+	});
+}

+ 10 - 0
api/wallet.js

@@ -9,6 +9,16 @@ export function spreadCommission(data,state) {
 	});
 }
 
+// 获取总收入支出
+export function getSpreadsum(data) {
+	return request({
+		url: '/api/spreadsum',
+		method: 'get',
+		data
+	});
+}
+
+
 // 获取账户余额
 export function userBalance(data) {
 	return request({

+ 257 - 198
components/seckill/seckill.vue

@@ -1,13 +1,16 @@
 <template>
 	<view class="seckill-section m-t" v-if="show">
 		<view class="s-header">
-			<view class="f-left-icon"></view>
+			<view class="f-left-icon">
+				<image src="../../static/index/huo.png" mode=""></image>
+			</view>
 			<view class="tit-box"><text class="tit">限时秒杀</text></view>
 			<view class="tip-box">
-				<text class="tip" v-if="status == 1">{{ showTime }}点场结束</text>
+				<text class="tip" v-if="status == 1">{{ showTime }}点场结束</text>
 				<text class="tip" v-if="status == 2">距离下场开始</text>
 				<text class="tip" v-if="status == 0">当天活动已结束</text>
-				<uni-countdown v-if="status == 1 || status == 2" :show-day="false" :hour="stopTimeH" :minute="stopTimeM" :second="stopTimeS"></uni-countdown>
+				<uni-countdown v-if="status == 1 || status == 2" :show-day="false" :hour="stopTimeH" :minute="stopTimeM"
+					:second="stopTimeS"></uni-countdown>
 			</view>
 			<view class="textNav iconfont iconenter" @click="navTo('/pages/product/seckill')">更多</view>
 		</view>
@@ -16,231 +19,287 @@
 				<view v-for="(item, index) in list" :key="index" class="floor-item">
 					<image class="list-image" :src="item.image" mode="aspectFill"></image>
 					<text class="title clamp">{{ item.title }}</text>
-					<text class="price">¥{{ item.price }}</text>
+					<view class="price-box">
+						<text class="price">¥{{ item.price }}</text>
+						<text class="price1">¥{{ item.ot_price }}</text>
+					</view>
 				</view>
 				<view v-if="list.length == 0" class="floor-item ">
 					<image class="list-image" mode="aspectFill"></image>
 					<text class="title clamp"></text>
 					<text class="price"></text>
 				</view>
-				<view v-if="list.length == 0" class="noGoodsBg"><view>敬请期待</view></view>
+				<view v-if="list.length == 0" class="noGoodsBg">
+					<view>敬请期待</view>
+				</view>
 			</view>
 		</scroll-view>
 	</view>
 </template>
 
 <script>
-import uniCountdown from '@/components/uni-countdown/uni-countdown.vue';
-import { getSeckillList, getSeckillClass } from '@/api/product.js';
-import { timeComputed } from '@/utils/rocessor.js';
-export default {
-	components: {
-		uniCountdown
-	},
-	data() {
-		return {
-			list: [],
-			page: 1,
-			limit: 10,
-			showTime: '', //显示的时间
-			showTImeId: '', //显示时间id用于查询数据
-			stopTimeH: 0,
-			stopTimeM: 0,
-			stopTimeS: 0,
-			// 判断是否所有活动已经结束
-			stop: false, //活动是否已经结束
-			show: false, //是否显示活动
-			status: 0 //获取状态值1为有活动开始中 2为活动未开始 0为活动已经结束
-		};
-	},
-	created: function(e) {
-		// 载入分类
-		this.getClass();
-	},
-	methods: {
-		navTo(url) {
-			uni.navigateTo({
-				url
-			});
+	import uniCountdown from '@/components/uni-countdown/uni-countdown.vue';
+	import {
+		getSeckillList,
+		getSeckillClass
+	} from '@/api/product.js';
+	import {
+		timeComputed
+	} from '@/utils/rocessor.js';
+	export default {
+		components: {
+			uniCountdown
 		},
-		getList() {
-			getSeckillList(
-				{
-					page: this.page,
-					limit: this.limit
-				},
-				this.showTImeId
-			)
-				.then(e => {
-					this.list = e.data;
-				})
-				.catch(e => {
-					console.log(e);
-				});
+		data() {
+			return {
+				list: [],
+				page: 1,
+				limit: 10,
+				showTime: '', //显示的时间
+				showTImeId: '', //显示时间id用于查询数据
+				stopTimeH: 0,
+				stopTimeM: 0,
+				stopTimeS: 0,
+				// 判断是否所有活动已经结束
+				stop: false, //活动是否已经结束
+				show: false, //是否显示活动
+				status: 0 //获取状态值1为有活动开始中 2为活动未开始 0为活动已经结束
+			};
 		},
-		getClass() {
-			let obj = this;
-			getSeckillClass({})
-				.then(({ data }) => {
-					let arr = data.seckillTime;
-					// 用于判断是否有数据
-					let showDate = false;
-					for (var i = 0; i < arr.length; i++) {
-						let ar = arr[i];
-						if (ar.status === 1 || ar.status === 2) {
-							obj.status = ar.status;
-							// 保存要显示的场次时间
-							obj.showTime = ar.time;
-							// 保存要显示活动商品的id
-							obj.showTImeId = ar.id;
-							// 保存当前状态值
-							// 计算倒计时时间
-							if (ar.status === 1) {
-								obj.timeComputed(ar.stop * 1000);
-							} else {
-								// 获取需要开始
-								let arTime = ar.time.split(':');
-								let h = arTime[0];
-								let m = arTime[1];
-								let time = new Date();
-								// 设置时间
-								time.setHours(h, m, 0);
-								obj.timeComputed(time.getTime());
+		created: function(e) {
+			// 载入分类
+			this.getClass();
+		},
+		methods: {
+			navTo(url) {
+				uni.navigateTo({
+					url
+				});
+			},
+			getList() {
+				getSeckillList({
+							page: this.page,
+							limit: this.limit
+						},
+						this.showTImeId
+					)
+					.then(e => {
+						this.list = e.data;
+						console.log(this.list,'ss');
+					})
+					.catch(e => {
+						console.log(e);
+					});
+			},
+			getClass() {
+				let obj = this;
+				getSeckillClass({})
+					.then(({
+						data
+					}) => {
+						let arr = data.seckillTime;
+						// 用于判断是否有数据
+						let showDate = false;
+						for (var i = 0; i < arr.length; i++) {
+							let ar = arr[i];
+							if (ar.status === 1 || ar.status === 2) {
+								obj.status = ar.status;
+								// 保存要显示的场次时间
+								obj.showTime = ar.time;
+								// 保存要显示活动商品的id
+								obj.showTImeId = ar.id;
+								// 保存当前状态值
+								// 计算倒计时时间
+								if (ar.status === 1) {
+									obj.timeComputed(ar.stop * 1000);
+								} else {
+									// 获取需要开始
+									let arTime = ar.time.split(':');
+									let h = arTime[0];
+									let m = arTime[1];
+									let time = new Date();
+									// 设置时间
+									time.setHours(h, m, 0);
+									obj.timeComputed(time.getTime());
+								}
+								// 获取商品列表
+								obj.getList();
+								// 保存当前有活动在举行
+								showDate = true;
+								// 任务查询结束跳出循环
+								break;
 							}
-							// 获取商品列表
+						}
+						// 判断是否有活动
+						if (arr.length > 0) {
+							obj.show = true;
+						}
+						// 判断今天活动是否已经全部结束
+						if (!showDate) {
+							// 保存活动结束最后一个小时的活动商品
+							obj.showTImeId = arr[arr.length - 1].id;
+							// 活动已经结束
+							obj.status = 0;
+							// 获取结束时的商品
 							obj.getList();
-							// 保存当前有活动在举行
-							showDate = true;
-							// 任务查询结束跳出循环
-							break;
+							console.log(obj.status);
 						}
-					}
-					// 判断是否有活动
-					if (arr.length > 0) {
-						obj.show = true;
-					}
-					// 判断今天活动是否已经全部结束
-					if (!showDate) {
-						// 保存活动结束最后一个小时的活动商品
-						obj.showTImeId = arr[arr.length - 1].id;
-						// 活动已经结束
-						obj.status = 0;
-						// 获取结束时的商品
-						obj.getList();
-						console.log(obj.status);
-					}
-					// 如果所有场次均已经结束
-				})
-				.catch(e => {
-					uni.showModal({
-						title: JSON.stringify(e)
+						// 如果所有场次均已经结束
+					})
+					.catch(e => {
+						uni.showModal({
+							title: JSON.stringify(e)
+						});
 					});
-				});
-		},
-		// 计算倒计时时间
-		timeComputed(da) {
-			let obj = this;
-			let stopTime = timeComputed(da)
-			obj.stopTimeH =stopTime.hours;
-			obj.stopTimeM = stopTime.minutes;
-			obj.stopTimeS =stopTime.seconds;
+			},
+			// 计算倒计时时间
+			timeComputed(da) {
+				let obj = this;
+				let stopTime = timeComputed(da)
+				obj.stopTimeH = stopTime.hours;
+				obj.stopTimeM = stopTime.minutes;
+				obj.stopTimeS = stopTime.seconds;
+			}
 		}
-	}
-};
+	};
 </script>
 
 <style lang="scss">
-/* 秒杀专区 */
-.seckill-section {
-	padding: 4rpx 30rpx 24rpx;
-	.s-header {
-		display: flex;
-		align-items: center;
-		height: 92rpx;
-		line-height: 1;
-		.tit-box {
-			flex-shrink: 0;
-		}
-		.tit {
-			@extend %font-title;
-		}
-		.f-left-icon {
-			@extend %f-left-icon;
-		}
-		.textNav {
-			line-height: 1;
-			padding: 15rpx 0;
-			flex-shrink: 0;
-			flex-grow: 1;
-			min-width: 100rpx;
-		}
-		.tip-box {
-			flex-grow: 1;
+	/* 秒杀专区 */
+	.seckill-section {
+		padding: 4rpx 30rpx 24rpx;
+
+		.s-header {
 			display: flex;
-			justify-content: flex-start;
 			align-items: center;
+			height: 92rpx;
+			line-height: 1;
+
+			.tit-box {
+				flex-shrink: 0;
+			}
+
+			.tit {
+				@extend %font-title;
+			}
+
+			.f-left-icon {
+				// @extend %f-left-icon;
+				margin-right: 5rpx;
+				width: 37rpx;
+				height: 36rpx;
+
+				image {
+					width: 100%;
+					height: 100%;
+				}
+			}
+
+			.textNav {
+				line-height: 1;
+				padding: 15rpx 0;
+				flex-shrink: 0;
+				flex-grow: 1;
+				min-width: 100rpx;
+			}
+
+			.tip-box {
+				flex-grow: 1;
+				display: flex;
+				justify-content: flex-start;
+				align-items: center;
+			}
+
+			.tip {
+				font-size: $font-sm;
+				color: #FF4C4C;
+				font-weight: bold;
+				padding-left: 10rpx;
+				padding-right: 10rpx;
+			}
+
+			.timer {
+				display: inline-block;
+				width: 40rpx;
+				height: 36rpx;
+				text-align: center;
+				line-height: 36rpx;
+				margin-right: 14rpx;
+				font-size: $font-sm + 2rpx;
+				color: #fff;
+				border-radius: 2px;
+				background: rgba(0, 0, 0, 0.8);
+			}
+
+			.iconenter {
+				font-size: $font-sm;
+				color: $font-color-light;
+				flex: 1;
+				text-align: right;
+			}
 		}
-		.tip {
-			font-size: $font-sm;
-			color: $font-color-light;
-			padding-left: 10rpx;
-			padding-right: 10rpx;
-		}
-		.timer {
-			display: inline-block;
-			width: 40rpx;
-			height: 36rpx;
-			text-align: center;
-			line-height: 36rpx;
-			margin-right: 14rpx;
-			font-size: $font-sm + 2rpx;
-			color: #fff;
-			border-radius: 2px;
-			background: rgba(0, 0, 0, 0.8);
-		}
-		.iconenter {
-			font-size: $font-sm;
-			color: $font-color-light;
-			flex: 1;
-			text-align: right;
+
+		.floor-list {
+			white-space: nowrap;
+			background-color: white;
+			padding: 20rpx;
+			border-radius: 5rpx;
+			box-shadow: $box-shadow;
 		}
-	}
-	.floor-list {
-		white-space: nowrap;
-		background-color: white;
-		padding: 20rpx;
-		border-radius: 5rpx;
-		box-shadow: $box-shadow;
-	}
-	.scoll-wrapper {
-		display: flex;
-		align-items: flex-start;
-		.noGoodsBg {
+
+		.scoll-wrapper {
+			
 			display: flex;
+			justify-content: left;
 			align-items: center;
-			justify-content: center;
-			height: 100%;
-			position: absolute;
-			top: 0;
-			left: 0;
-			width: 100%;
-			color: $font-color-light;
-		}
-		.floor-item {
-			width: 150rpx;
-			margin-right: 20rpx;
-			font-size: $font-sm + 2rpx;
-			color: $font-color-dark;
-			line-height: 1.8;
-			.list-image {
-				width: 150rpx;
-				height: 150rpx;
-				border-radius: 6rpx;
+
+			.noGoodsBg {
+				display: flex;
+				align-items: center;
+				justify-content: center;
+				height: 100%;
+				position: absolute;
+				top: 0;
+				left: 0;
+				width: 100%;
+				color: $font-color-light;
 			}
-			.price {
-				color: $color-red;
+
+			.floor-item {
+				
+				display: flex;
+				justify-content: center;
+				flex-direction: column;
+				width: 200rpx;
+				height: 300rpx;
+				margin: 0 10rpx;
+				background: #FFFFFF;
+				border: 3rpx solid #F0E6CF;
+				border-radius: 10rpx;
+
+				.list-image {
+					margin: 10rpx auto;
+					width: 180rpx;
+					height: 180rpx;
+					border-radius: 6rpx;
+				}
+				.clamp{
+					margin-left: 10rpx;
+				}
+				.price-box{
+					display: flex;
+				}
+				.price {
+					color: $color-red;
+				}
+				.price1{
+					font-size: 22rpx;
+					font-weight: 500;
+					text-decoration: line-through;
+					color: #969696;
+					line-height: 26px;
+				}
 			}
 		}
 	}
-}
 </style>

+ 4 - 2
components/uni-countdown/uni-countdown.vue

@@ -24,7 +24,7 @@
 			},
 			backgroundColor: {
 				type: String,
-				default: '#FFFFFF'
+				default: 'black'
 			},
 			borderColor: {
 				type: String,
@@ -32,7 +32,7 @@
 			},
 			color: {
 				type: String,
-				default: '#000000'
+				default: '#fff'
 			},
 			splitorColor: {
 				type: String,
@@ -177,5 +177,7 @@
 		text-align: center;
 		font-size: $uni-font-size-sm;
 		border-radius: 8rpx;
+		background-color: #333333; 
+		color: #fff;
 	}
 </style>

+ 2 - 2
manifest.json

@@ -64,7 +64,7 @@
         }
     },
     "h5" : {
-        "title" : "响亮商城",
+        "title" : "皓月瓷肌",
         "domain" : "",
         "router" : {
             "base" : "/index/",
@@ -74,7 +74,7 @@
             "proxy" : {
                 "/api" : {
                     // "target" : "http://lnpt.frp.liuniu946.com/api",
-                    "target" : "https://xl.liuniu946.com/api",
+                    "target" : "https://hy.liuniu946.com/api",
                     // "changeOrigin": true,
                     "pathRewrite" : {
                         "/api" : "" // rewrite path

+ 31 - 4
pages.json

@@ -5,7 +5,7 @@
 	"pages": [{
 			"path": "pages/index/index",
 			"style": {
-				"navigationBarTitleText": "响亮商城",
+				"navigationBarTitleText": "皓月瓷肌",
 				"app-plus": {
 					"titleNView": false
 				}
@@ -359,7 +359,7 @@
 		{
 			"path": "pages/user/scoreAccumulate",
 			"style": {
-				"navigationBarTitleText": "响亮积分明细"
+				"navigationBarTitleText": "积分明细"
 			}
 		},
 		{
@@ -502,7 +502,34 @@
 				"navigationBarTitleText": "邀请好友"
 			}
 		}
-	],
+	    ,{
+            "path" : "pages/index/vipShop",
+            "style" :                                                                                    
+            {
+                "navigationBarTitleText": "",
+                "enablePullDownRefresh": false
+            }
+            
+        }
+        ,{
+            "path" : "pages/product/miaosha",
+            "style" :                                                                                    
+            {
+                "navigationBarTitleText": "",
+                "enablePullDownRefresh": false
+            }
+            
+        }
+        ,{
+            "path" : "pages/money/success",
+            "style" :                                                                                    
+            {
+                "navigationBarTitleText": "",
+                "enablePullDownRefresh": false
+            }
+            
+        }
+    ],
 	"subPackages": [{
 		"root": "pages/activity",
 		"name": "activity",
@@ -536,7 +563,7 @@
 	}],
 	"globalStyle": {
 		"navigationBarTextStyle": "black",
-		"navigationBarTitleText": "响亮商城",
+		"navigationBarTitleText": "皓月瓷肌",
 		"navigationBarBackgroundColor": "#FFFFFF",
 		"backgroundColor": "#f8f8f8",
 		//#ifdef H5

+ 3 - 2
pages/cart/cart.vue

@@ -75,7 +75,7 @@
 					</text> -->
 				</view>
-				<button type="primary" class="no-border confirm-btn" @click="createOrder">结算</button>
+				<button type="primary" class="no-border confirm-btn" @click="createOrder">结算</button>
 			</view>
 		</view>
 		<!-- <u-tabbar activeColor="#EE0979" v-model="current" :list="tabbar" :mid-button="true"></u-tabbar> -->
@@ -515,7 +515,8 @@ export default {
 		height: 76rpx;
 		line-height: 76rpx;
 		font-size: $font-base + 2rpx;
-		background: $base-color;
+		background:#303030 ;
+		color:#F8DABA ;
 	}
 }
 /* 复选框选中状态 */

+ 109 - 55
pages/index/index.vue

@@ -28,11 +28,11 @@
 					<image class="nitem-image" src="../../static/sy/sy12.png" mode=""></image>
 					<view class="nitem-font">全部分类</view>
 				</view>
-				<view class="navbar-item" @click="navTo('')">
+				<view class="navbar-item" @click="navTo('/pages/index/vipShop')">
 					<image class="nitem-image" src="../../static/sy/sy14.png" mode=""></image>
 					<view class="nitem-font">超值拼团</view>
 				</view>
-				<view class="navbar-item" @click="navTo('/pages/index/sign')">
+				<view class="navbar-item" @click="navTo('')">
 					<image class="nitem-image" src="../../static/sy/sy15.png" mode=""></image>
 					<view class="nitem-font">公司介绍</view>
 				</view>
@@ -42,70 +42,74 @@
 				</view>
 			</view>
 		</view>
-		<view class="jx-box">
-			<view class="jx-box-title">
-				<image src="../../static/sy/sy03.png" mode=""></image>
-			</view>
-			<view class="jx-box-img">
-				<image src="../../static/sy/sy09.png" mode=""></image>
-			</view>
-		</view>
-		<view class="jx-box-content">
-			<view class="content-left">
-				<image src="../../static/sy/sy15.png" mode=""></image>
+		<seckill></seckill>
+		<view class=" jx">
+			<view class="jx-box">
+				<view class="jx-box-title">
+					<image src="../../static/sy/sy03.png" mode=""></image>
+				</view>
+				<view class="jx-box-img">
+					<image src="../../static/sy/sy09.png" mode=""></image>
+				</view>
 			</view>
-			<view class="content-right">
-				<view class="shop-name">
-					测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据
+			<view class="jx-box-content" v-for="item in vipList" @click="navToDetailPage(item)">
+				<view class="content-left">
+					<image :src=item.image mode=""></image>
 				</view>
-				<view class="shop-content">
-					<view class="shop-content-left">
-						<view class="price-box">
-							<view class="yuan-price">
-								${{99}}
+				<view class="content-right">
+					<view class="shop-name">
+						{{item.store_name}}
+					</view>
+					<view class="shop-content">
+						<view class="shop-content-left">
+							<view class="price-box">
+								<view class="yuan-price">
+									¥{{item.ot_price}}
+								</view>
+								<image src="../../static/sy/sy06.png" mode=""></image>
+								<view class="j-price">
+									直降{{item.ot_price*1-item.price*1}}元
+								</view>
 							</view>
-							<image src="../../static/sy/sy06.png" mode=""></image>
-							<view class="j-price">
-								直降{{40}}元
+							<view class="price-x">
+								¥{{item.price}}
 							</view>
 						</view>
-						<view class="price-x">
-							${{199}}
+						<view class="shop-content-right">
+							立即购买
 						</view>
 					</view>
-					<view class="shop-content-right">
-						立即购买
-					</view>
 				</view>
 			</view>
-
+			<view class="cai" @click="navTo('/pages/index/vipShop')">
+				查看更多<span style ="margin-left: 5rpx;">></span>
+			</view>
 		</view>
-
-		<view class="product-box" v-if="bastList.length != 0">
+		<view class="product-box">
 			<view class="product-title">
 				<view class="bb">
-
 				</view>
 				<view class="pt-title">猜你喜欢</view>
 				<view class="bb">
-
 				</view>
 			</view>
 			<view class="hotgoods">
-				<view class="hotgoods-item" v-for="item in bastList" :key="item.id" @click="navToDetailPage(item)">
+				<view class="hotgoods-item" v-for="item in firstList" :key="item.id" @click="navToDetailPage(item)">
 					<view class="image-wrapper">
 
 						<image class="image" :src="item.image" mode="scaleToFill"></image>
 					</view>
-					<view class="title clamp2">{{ item.store_name }}</view>
-					<view class="titlee">{{ item.store_name }}</view>
+					<view class="hotgoods-box">
+						<view class="title clamp2">{{ item.store_name }}</view>
+						<view class="titlee">{{ item.store_name }}</view>
+					</view>
 					<view class="hot-price">
 						<!-- <view class="hotPrice-box">会员价</view> -->
 						<view class="price">
 							<text class="font-size-sm">¥</text>
 							{{ item.price * 1 }}
 						</view>
-						<view class="yuanPrice">{{ item.ot_price }}</view>
+						<view class="yuanPrice">¥{{ item.price }}</view>
 					</view>
 				</view>
 			</view>
@@ -121,7 +125,8 @@
 	} from '../../api/user.js';
 	import seckill from '../../components/seckill/seckill.vue';
 	import {
-		loadIndexs
+		loadIndexs,
+		getVip
 	} from '@/api/index.js';
 	import {
 		getUserInfo,
@@ -170,7 +175,9 @@
 				bastList: [], //会员礼包
 				shoplist: [], //商店列表
 				page: 1,
-				limit: 5
+				limit: 5,
+				vipList: [], //vip商品
+				firstList: [],
 			};
 		},
 		computed: {
@@ -193,6 +200,17 @@
 			//#endif
 		},
 		onShow: function() {
+			getVip({
+				page: 1,
+				limit: 3,
+				is_vip: 3
+			}).then(res => {
+				this.vipList = res.data
+				res.data.forEach(e => {
+					e.isVip = e.store_type ? "3" : "0"
+				})
+				console.log(res.data, 'vip商品');
+			})
 			// 判断是否强制登录
 			if (!this.hasLogin) {
 				// 登录拦截
@@ -249,8 +267,8 @@
 				path += 'spread=' + this.userInfo.uid;
 				let data = {
 					link: this.baseURL + '/index/' + path,
-					title: this.userInfo.nickname + '邀请您进入响亮商城',
-					desc: '欢迎加入响亮商城',
+					title: this.userInfo.nickname + '邀请您进入皓月瓷肌',
+					desc: '欢迎加入皓月瓷肌',
 					imgUrl: 'https://xl.liuniu946.com/index/static/img/logo.jpg'
 				};
 				console.log(data, '分享数据');
@@ -341,7 +359,7 @@
 						limit: that.limit
 					})
 					.then(function(res) {
-						that.$set(that, 'bargainlist', res.data.slice(0, 2));
+						// that.$set(that, 'bargainlist', res.data.slice(0, 2));
 					})
 					.catch(res => {
 						console.log(res, 'getBargainList');
@@ -436,9 +454,14 @@
 						data
 					}) => {
 						let goods = data.info;
+						console.log(goods, '商品信息');
 						this.carouselList = data.banner;
 						this.swiperLength = this.carouselList.length;
 						this.bastList = data.giftInfo; //会员礼包
+						data.info.firstList.forEach(e => {
+							e.isVip = e.store_type ? "3" : "0"
+						})
+						this.firstList = data.info.firstList //首页商品
 						uni.stopPullDownRefresh();
 					})
 					.catch(e => {
@@ -455,7 +478,7 @@
 			navToDetailPage(item) {
 				let id = item.id;
 				uni.navigateTo({
-					url: '/pages/product/product?id=' + id + '&isVip=1'
+					url: '/pages/product/product?id=' + id + '&isVip=' + item.isVip
 				});
 			},
 
@@ -477,6 +500,10 @@
 </script>
 
 <style lang="scss">
+	page {
+		background: #EEEFEE;
+	}
+
 	.carousel-section {
 		position: relative;
 		padding-top: 10px;
@@ -542,6 +569,7 @@
 					flex-grow: 1;
 					padding: 5rpx 30rpx;
 					background: #EEEEEE;
+
 					.iconsearch {
 						font-size: 50rpx;
 						color: #CBCBCB;
@@ -551,6 +579,7 @@
 						margin-left: 19rpx;
 						flex-grow: 1;
 						color: #CBCBCB;
+
 						input {
 							font-size: 28rpx;
 
@@ -625,6 +654,11 @@
 
 	}
 
+	.jx {
+		background: #fff;
+		width: 750rpx;
+	}
+
 	.jx-box {
 		background: #fff;
 		display: flex;
@@ -654,51 +688,66 @@
 		}
 	}
 
+	.cai {
+		display: flex;
+		justify-content: center;
+		align-items: center;
+		padding-bottom: 20rpx;
+		font-size: 28rpx;
+		font-weight: 500;
+		color: #999999;
+	}
+
 	.jx-box-content {
 		display: flex;
+
 		.content-left {
 			margin: 20rpx 15rpx;
 			width: 236rpx;
 			height: 236rpx;
 			background: #E2E2E2;
 			border-radius: 10rpx;
+
 			image {
 				width: 100%;
-				height:100%;
+				height: 100%;
 			}
 		}
 
+
 		.content-right {
 			display: flex;
 			flex-direction: column;
 			justify-content: space-around;
-			
+
 			.shop-name {
 				width: 382rpx;
 				font-size: 32rpx;
 				font-weight: bold;
 				color: #333333;
-				
+
 				overflow: hidden;
 				text-overflow: ellipsis;
-				display:-webkit-box;
-				-webkit-box-orient:vertical;
-				-webkit-line-clamp:2;
+				display: -webkit-box;
+				-webkit-box-orient: vertical;
+				-webkit-line-clamp: 2;
 			}
 
 			.shop-content {
+				width: 455rpx;
 				display: flex;
 				justify-content: space-between;
-				
+
 				.shop-content-left {
 					display: flex;
 					flex-direction: column;
-					
-					
-					
+
+
+
 					.price-box {
 						display: flex;
 						align-items: center;
+
 						.yuan-price {
 							font-size: 26rpx;
 							font-weight: 500;
@@ -707,6 +756,7 @@
 						}
 
 						image {
+							margin: 0 10rpx;
 							width: 16rpx;
 							height: 18rpx;
 						}
@@ -726,7 +776,7 @@
 				}
 
 				.shop-content-right {
-					margin-top:20rpx ;
+					margin-top: 20rpx;
 					align-items: center;
 					text-align: center;
 					width: 137rpx;
@@ -830,6 +880,10 @@
 					color: #333333;
 				}
 
+				.hotgoods-box {
+					height: 100rpx;
+				}
+
 				.titlee {
 					margin-left: 15rpx;
 					font-size: 26rpx;

+ 194 - 0
pages/index/vipShop.vue

@@ -0,0 +1,194 @@
+<template>
+	<view>
+		<view class="jx-box-content" v-for="item in vipList" @click="navToDetailPage(item)">
+			<view class="content-left">
+				<image :src=item.image mode=""></image>
+			</view>
+			<view class="content-right">
+				<view class="shop-name">
+					{{item.store_name}}
+				</view>
+				<view class="shop-content">
+					<view class="shop-content-left">
+						<view class="price-box">
+							<view class="yuan-price">
+								¥{{item.ot_price}}
+							</view>
+							<image src="../../static/sy/sy06.png" mode=""></image>
+							<view class="j-price">
+								直降{{item.ot_price*1-item.price*1}}元
+							</view>
+						</view>
+						<view class="price-x">
+							¥{{item.price}}
+						</view>
+					</view>
+					<view class="shop-content-right" >
+						立即购买
+					</view>
+				</view>
+			</view>
+		</view>
+		<uni-load-more :status="loadingType"></uni-load-more>
+	</view>
+</template>
+
+<script>
+	import uniLoadMore from '@/uview-ui/components/u-loadmore/u-loadmore.vue';
+	import {getVip} from '@/api/index.js';
+	export default {
+		components:{
+			uniLoadMore
+		},
+		data() {
+			return {
+				vipList:[],//商品列表
+				page:1,
+				limit:10,
+				loadingType:'more'
+			};
+		},
+		onLoad() {
+		    this.getVipList()
+		},
+		onReachBottom() {
+		    this.getVipList()
+		},
+		methods:{
+			navToDetailPage(item) {
+				let id = item.id;
+				uni.navigateTo({
+					url: '/pages/product/product?id=' + id +'&isVip='+item.isVip
+				});
+			},
+			getVipList(){
+				let obj = this
+				if(obj.loadingType === 'loading' || obj.loadingType === 'noMore'){
+					return //如果正在加载中,防止重复加载
+				}
+				obj.loadingType = 'loading'
+				getVip(
+				{   page:obj.page,
+					limit:obj.limit,
+					is_vip:3
+				}).then(res=>{
+					
+					 res.data.forEach(e=>{
+						e.isVip = e.store_type? "3" : "0"
+					 })
+					console.log(res.data,'vip商品');
+					 if(res.data.length>0){
+						obj.vipList = obj.vipList.concat(res.data)
+						console.log(obj.vipList,'vip');
+						obj.page++
+					 }
+					if(obj.limit == res.data.length){
+						console.log("haiyou");
+						obj.loadingType = 'more'
+					}else{
+						console.log("wule");
+						obj.loadingType = 'noMore'
+					}
+					console.log(obj.loadingType,"12345789");
+					uni.hideLoading()
+					this.$set(obj.vipList,'loaded',true)
+				})
+				
+				
+			}
+		}
+	}
+</script>
+
+<style lang="scss">
+	.jx-box-content {
+		display: flex;
+		.content-left {
+			margin: 20rpx 15rpx;
+			width: 236rpx;
+			height: 236rpx;
+			background: #E2E2E2;
+			border-radius: 10rpx;
+			image {
+				width: 100%;
+				height:100%;
+			}
+		}
+	
+
+		.content-right {
+			display: flex;
+			flex-direction: column;
+			justify-content: space-around;
+			
+			.shop-name {
+				width: 382rpx;
+				font-size: 32rpx;
+				font-weight: bold;
+				color: #333333;
+				
+				overflow: hidden;
+				text-overflow: ellipsis;
+				display:-webkit-box;
+				-webkit-box-orient:vertical;
+				-webkit-line-clamp:2;
+			}
+
+			.shop-content {
+				width: 455rpx;
+				display: flex;
+				justify-content: space-between;
+				
+				.shop-content-left {
+					display: flex;
+					flex-direction: column;
+					
+					
+					
+					.price-box {
+						display: flex;
+						align-items: center;
+						.yuan-price {
+							font-size: 26rpx;
+							font-weight: 500;
+							text-decoration: line-through;
+							color: #999999;
+						}
+
+						image {
+							margin: 0 10rpx;
+							width: 16rpx;
+							height: 18rpx;
+						}
+
+						.j-price {
+							font-size: 24rpx;
+							font-weight: bold;
+							color: #B59467;
+						}
+					}
+
+					.price-x {
+						font-size: 36rpx;
+						font-weight: bold;
+						color: #FF4C4C;
+					}
+				}
+
+				.shop-content-right {
+					margin-top:20rpx ;
+					align-items: center;
+					text-align: center;
+					width: 137rpx;
+					height: 52rpx;
+					font-size: 26rpx;
+					font-weight: 500;
+					color: #F8DABA;
+					background: #303030;
+					border-radius: 26rpx;
+					line-height: 52rpx;
+				}
+			}
+		}
+	}
+</style>

+ 8 - 8
pages/money/pay.vue

@@ -11,13 +11,13 @@
 					<text class="tit">微信支付</text>
 					<text>推荐使用微信支付</text>
 				</view>
-				<label class="radio"><radio value="" color="#5dbc7c" :checked="payType == 1"></radio></label>
+				<label class="radio"><radio value="" color="#FF4C4C" :checked="payType == 1"></radio></label>
 			</view>
 			<!-- #ifdef APP-PLUS -->
 			<view class="type-item b-b" @click="changePayType(2)">
 				<text class="icon iconfont iconzhifubao"></text>
 				<view class="con"><text class="tit">支付宝支付</text></view>
-				<label class="radio"><radio value="" color="#5dbc7c" :checked="payType == 2"></radio></label>
+				<label class="radio"><radio value="" color="#FF4C4C" :checked="payType == 2"></radio></label>
 			</view>
 			<!-- #endif -->
 			<view class="type-item" @click="changePayType(3)">
@@ -28,22 +28,22 @@
 				</view>
 				<label class="radio"><radio value="" color="#5dbc7c" :checked="payType == 3"></radio></label>
 			</view>
-			<view class="type-item" @click="changePayType(5)">
+			<!-- <view class="type-item" @click="changePayType(5)">
 				<image class="cash-icon" src="../../static/icon/mygx.png" mode=""></image>
 				<view class="con">
 					<text class="tit">现金支付</text>
 					<text>可用现金 {{ userInfo.cash }}</text>
 				</view>
 				<label class="radio"><radio value="" color="#5dbc7c" :checked="payType == 5"></radio></label>
-			</view>
-			<view class="type-item" @click="changePayType(4)" v-if="isP == 1">
+			</view> -->
+			<!-- <view class="type-item" @click="changePayType(4)" v-if="isP == 1">
 				<text class="icon iconfont iconyue"></text>
 				<view class="con">
 					<text class="tit">拼团积分</text>
 					<text>可用余额 {{ userInfo.pink_integral }}</text>
 				</view>
 				<label class="radio"><radio value="" color="#5dbc7c" :checked="payType == 4"></radio></label>
-			</view>
+			</view> -->
 		</view>
 		<text class="mix-btn" :class="{ clickbg: payLoding }" @click="!payLoding ? confirm() : ''">确认支付</text>
 	</view>
@@ -452,8 +452,8 @@ export default {
 	height: 80upx;
 	margin: 80upx auto 30upx;
 	font-size: $font-lg;
-	color: #fff;
-	background-color: $base-color;
+	color: #F8DABA;
+	background-color: #303030;
 	border-radius: 10upx;
 	/* box-shadow: 1px 2px 5px rgba(219, 63, 96, 0.4); */
 }

+ 71 - 67
pages/money/paySuccess.vue

@@ -1,6 +1,6 @@
 <template>
 	<view class="content">
-		<image class="success-icon" src="../../static/img/paySuccess.png" mode=""></image>
+		<image class="success-icon" src="../../static/img/paySuccess1.png" mode=""></image>
 		<text class="tit">订单支付成功</text>
 		<view class="btn-group">
 			<navigator url="/pages/order/order?state=1" open-type="redirect" class="mix-btn">查看订单</navigator>
@@ -10,75 +10,79 @@
 </template>
 
 <script>
-export default {
-	data() {
-		return {
-			type: 2 //1为兑换支付成功2为预购成功
-		};
-	},
-	onLoad(opt) {
-		// 保存订单号
-	// 	if ('type' in opt) {
-	// 		this.type = opt.type;
-	// 	}
-	// 	if (this.type == 1) {
-	// 		uni.setNavigationBarTitle({
-	// 			title: '兑换成功'
-	// 		});
-	// 	}
-	// 	if (this.type == 2) {
-	// 		uni.setNavigationBarTitle({
-	// 			title: '预约成功'
-	// 		});
-	// 	}
-	},
-	methods: {}
-};
+	export default {
+		data() {
+			return {
+				type: 2 //1为兑换支付成功2为预购成功
+			};
+		},
+		onLoad(opt) {
+			// 保存订单号
+			// 	if ('type' in opt) {
+			// 		this.type = opt.type;
+			// 	}
+			// 	if (this.type == 1) {
+			// 		uni.setNavigationBarTitle({
+			// 			title: '兑换成功'
+			// 		});
+			// 	}
+			// 	if (this.type == 2) {
+			// 		uni.setNavigationBarTitle({
+			// 			title: '预约成功'
+			// 		});
+			// 	}
+		},
+		methods: {}
+	};
 </script>
 
 <style lang="scss">
-.content {
-	display: flex;
-	flex-direction: column;
-	justify-content: center;
-	align-items: center;
-}
-.success-icon {
-	margin-top: 100rpx;
-	width: 302rpx;
-	height: 320rpx;
-}
-.tit {
-	margin-top: 40rpx;
-	font-size: 32rpx;
-	font-family: PingFang SC;
-	font-weight: bold;
-	color: #333333;
-}
-.btn-group {
-	padding-top: 130rpx;
-	display: flex;
-	justify-content: flex-start;
-}
-.mix-btn {
-	margin-top: 30upx;
-	display: flex;
-	align-items: center;
-	justify-content: center;
-	width: 301rpx;
-	height: 78rpx;
-	background: #EF0E74;
-	border-radius: 10rpx;
-	font-size: $font-lg;
-	font-size: 30rpx;
-	font-family: PingFang SC;
-	font-weight: 500;
-	color: #ffffff;
+	.content {
+		display: flex;
+		flex-direction: column;
+		justify-content: center;
+		align-items: center;
+	}
+
+	.success-icon {
+		margin-top: 100rpx;
+		width: 302rpx;
+		height: 320rpx;
+	}
+
+	.tit {
+		margin-top: 40rpx;
+		font-size: 32rpx;
+		font-family: PingFang SC;
+		font-weight: bold;
+		color: #333333;
+	}
+
+	.btn-group {
+		padding-top: 130rpx;
+		display: flex;
+		justify-content: flex-start;
+	}
+
+	.mix-btn {
+
+		margin-top: 30upx;
+		display: flex;
+		align-items: center;
+		justify-content: center;
+		width: 301rpx;
+		height: 78rpx;
+		background: #303030;
+		border-radius: 10rpx;
+		font-size: 30rpx;
+		font-weight: 500;
+		color: #fff;
+	
 	&.hollow {
-		margin-left: 36rpx;
-		background: #fff;
-		color: #EF0E74;
-		border: 1px solid #EF0E74;
+			margin-left: 36rpx;
+			background: #fff;
+			color: #303030;
+			border: 2px solid #303030;
+		}
 	}
-}
 </style>

+ 10 - 9
pages/money/recharge.vue

@@ -40,7 +40,7 @@
 				<view class="icon iconfont iconweixin"></view>
 				<view class="tit">微信充值</view>
 			</view>
-			<view class="right"><radio value="weixin" color=" #EB001C" :checked="type == 'weixin'" /></view>
+			<view class="right"><radio value="weixin" color="#262A35" :checked="type == 'weixin'" /></view>
 		</view>
 		<button class="add-btn up" :class="{ 'active-bg': payLoding }" @click="!payLoding ? confirm() : ''">立即充值</button>
 	</view>
@@ -229,7 +229,7 @@ page {
 		font-size: 30rpx;
 		font-family: PingFang SC;
 		font-weight: bold;
-		color: #ff6f0f;
+		color: #FF4C4C;
 	}
 }
 
@@ -277,8 +277,8 @@ page {
 			}
 		}
 		.seletPrice {
-			background: linear-gradient(143.2747deg, #ff6a00, #ee0979);
-			color: #ffffff;
+			background: #303030;
+			color: #F8DABA;
 		}
 	}
 }
@@ -381,20 +381,21 @@ page {
 		
 	}
 	&.up {
-		color: #F21F5D;
+		color: #F8DABA;
 	}
+	background: #303030;
 	margin-top: 100rpx;
 	display: flex;
 	align-items: center;
 	justify-content: center;
 	width: 604rpx;
 	height: 90rpx;
-	border: 2rpx solid #F21F5D;
+	border: 2rpx solid #303030;
 	border-radius: 10rpx;
 	font-size: 36rpx;
 	font-family: PingFang SC;
 	font-weight: 500;
-	color: #F21F5D;
+	color: #F8DABA;
 	line-height: 90rpx;
 	text-align: center;
 }
@@ -479,7 +480,7 @@ page {
 }
 
 .active-bg {
-	background: linear-gradient(143.2747deg, #ff6a00, #ee0979) !important;
-	color: #FFFFFF !important;
+	background: #303030 !important;
+	color: #F8DABA !important;
 }
 </style>

+ 86 - 0
pages/money/success.vue

@@ -0,0 +1,86 @@
+<template>
+	<view class="content">
+		<image class="success-icon" src="../../static/img/success.png" mode=""></image>
+		<text class="tit">提交成功</text>
+		<view class="btn-group">
+			<!-- <navigator url="/pages/order/order?state=1" open-type="redirect" class="mix-btn">查看订单</navigator> -->
+			<navigator url="/pages/index/index" open-type="switchTab" class="mix-btn hollow">返回首页</navigator>
+		</view>
+	</view>
+</template>
+
+<script>
+	export default {
+		data() {
+			return {
+				type: 2 //1为兑换支付成功2为预购成功
+			};
+		},
+		onLoad(opt) {
+			// 保存订单号
+			// 	if ('type' in opt) {
+			// 		this.type = opt.type;
+			// 	}
+			// 	if (this.type == 1) {
+			// 		uni.setNavigationBarTitle({
+			// 			title: '兑换成功'
+			// 		});
+			// 	}
+			// 	if (this.type == 2) {
+			// 		uni.setNavigationBarTitle({
+			// 			title: '预约成功'
+			// 		});
+			// 	}
+		},
+		methods: {}
+	};
+</script>
+
+<style lang="scss">
+	.content {
+		display: flex;
+		flex-direction: column;
+		justify-content: center;
+		align-items: center;
+	}
+
+	.success-icon {
+		margin-top: 200rpx;
+		margin-left: -55rpx;
+		width: 400rpx;
+		height: 320rpx;
+	}
+
+	.tit {
+	font-size: 40rpx;
+	font-weight: 500;
+	color: #333333;
+	line-height: 40rpx;
+	}
+
+	.btn-group {
+		padding-top: 130rpx;
+		display: flex;
+		justify-content: flex-start;
+	}
+
+	.mix-btn {
+
+		display: flex;
+		align-items: center;
+		justify-content: center;
+		width: 301rpx;
+		height: 78rpx;
+		background: #303030;
+		border-radius: 10rpx;
+		font-size: 30rpx;
+		font-weight: 500;
+		color: #fff;
+	
+	&.hollow {
+			background: #fff;
+			color: #303030;
+			border: 2px solid #303030;
+		}
+	}
+</style>

+ 24 - 18
pages/money/wallet.vue

@@ -4,31 +4,31 @@
 			<view class="status_bar"><!-- 这里是状态栏 --></view>
 			<view class="body-title">
 				<view class="goback-box" @click="toBack"><image class="goback" src="../../static/icon/fanhui.png" mode=""></image></view>
-				<view class="header">我的易货券</view>
+				<view class="header">我的钱包</view>
 			</view>
-			<view class="content-bg"><image src="../../static/img/myyue.png" mode=""></image></view>
+			<view class="content-bg"></view>
 			<view class="money-box">
 				<view class="money">{{money | getMoneyStyle}}</view>
-				<view>我的易货券</view>
+				<view>余额</view>
 			</view>
 			<view class="moneybtn-box">
 				<view class="money-btn" @click="navto('/pages/money/withdmoenys?type=yue')">
-					易货券转账
+					<!-- 易货券转账 -->
 				</view>
 				<view class="money-btn" @click="navto('/pages/money/recharge')">
-					易货券充值
+					钱包充值>
 				</view>
 			</view>
 		</view>
 		<view class="info-box flex">
 			<view class="info-item">
 				<view class="info-font">累计收入</view>
-				<view class="info-num">{{recharge}}</view>
+				<view class="info-num">{{shouzhi.income || '0.00'}}</view>
 			</view>
 			<view class="shu"></view>
 			<view class="info-item">
 				<view class="info-font">累计支出</view>
-				<view class="info-num">{{orderStatusSum}}</view>
+				<view class="info-num">{{shouzhi.expen|| '0.00'}}</view>
 			</view>
 		</view>
 		<view class="navbar">
@@ -65,7 +65,7 @@
 </template>
 
 <script>
-import { spreadCommission, userBalance } from '@/api/wallet.js';
+import { spreadCommission, userBalance,getSpreadsum } from '@/api/wallet.js';
 import { getMoneyStyle } from '@/utils/rocessor.js';
 import uniLoadMore from '@/components/uni-load-more/uni-load-more.vue';
 import empty from '@/components/empty';
@@ -125,11 +125,16 @@ export default {
 					limit: 10 //每次信息条数
 				}
 			],
-			money: ''
+			money: '',
+			shouzhi:[],
 		};
 	},
 	onLoad(options) {},
 	onShow() {
+		getSpreadsum().then(res=>{
+			this.shouzhi = res.data
+			console.log(res,'在拍卖行');
+		})
 		this.loadData();
 		// 获取用户余额
 		userBalance({}).then(({ data }) => {
@@ -172,16 +177,16 @@ export default {
 					console.log(data,'1');
 					console.log(JSON.stringify(data),'2')
 					
-					obj.recharge = data.income;
-					obj.orderStatusSum = data.expend;
-					if (data.list.length > 0) {
-						navItem.orderList = navItem.orderList.concat(data.list[0].list);
-						console.log(navItem.orderList);
+					obj.recharge = data.income;//累计收入
+					obj.orderStatusSum = data.expend;//支出
+					if (data.length > 0) {
+						navItem.orderList = navItem.orderList.concat(data[0].list);
+						console.log(navItem.orderList,'徐浩岚');
 						navItem.page++;
 					}else {
 						navItem.loadingType = 'noMore';
 					}
-					if (navItem.limit == data.list[0].list.length) {
+					if (navItem.limit == data[0].list.length) {
 						//判断是否还有数据, 有改为 more, 没有改为noMore
 						navItem.loadingType = 'more';
 						return;
@@ -223,6 +228,7 @@ page {
 	position: relative;
 	height: 480rpx;
 	.content-bg {
+		background: #303030;
 		position: absolute;
 		top: 0;
 		left: 0;
@@ -328,12 +334,12 @@ page {
 	justify-content: space-between;
 	position: relative;
 	z-index: 2;
-	color: #ffffff;
+	color: #F8DABA;
 	padding:20rpx 50rpx ;
 	font-size: 30rpx;
 	font-family: PingFang SC;
 	font-weight: bold;
-	color: #FFFFFF;
+	color: #F8DABA;
 }
 
 .navbar {
@@ -364,7 +370,7 @@ page {
 				transform: translateX(-50%);
 				width: 44px;
 				height: 0;
-				border-bottom: 2px solid #fe5b38;
+				border-bottom: 2px solid #F8DABA;
 			}
 		}
 	}

+ 1 - 1
pages/money/withdrawal.vue

@@ -18,7 +18,7 @@
 		</view>
 		<button class="add-btn up" @click="confirm">提交申请</button>
 		<view class="tip" v-if="withdrawal != 0">
-			实际到账{{ realmoney }}现金,{{ gy }}响亮积分
+			实际到账{{ realmoney }}现金
 		</view>
 	</view>
 </template>

+ 7 - 7
pages/order/createOrder.vue

@@ -1,8 +1,8 @@
 <template>
 	<view>
-		<view class="navbar">
+		<!-- <view class="navbar">
 			<view v-for="(item, index) in navList" :key="index" class="nav-item" :class="{ current: tabCurrentIndex === index }" @click="tabClick(index)">{{ item.text }}</view>
-		</view>
+		</view> -->
 
 		<!-- 地址 -->
 		<navigator v-if="tabCurrentIndex == 0" url="/pages/set/address?source=1" class="address-section">
@@ -78,14 +78,14 @@
 				<text class="cell-tit clamp">优惠券</text>
 				<text class="cell-tip active" v-if="couponListshow && !couponChecked.coupon_price">选择优惠券</text>
 				<text class="cell-tip red" v-if="couponChecked.coupon_price">-¥{{ couponChecked.coupon_price }}</text>
-				<text class="cell-tip disabled" v-if="!couponListshow && !couponChecked.coupon_price">没有优惠券</text>
+				<text class="cell-tip disabled" v-if="!couponListshow && !couponChecked.coupon_price">暂时没有优惠券</text>
 				<text class="cell-more wanjia wanjia-gengduo-d"></text>
 			</view>
-			<view class="yt-list-cell b-b" v-if="moneyAll.storeFreePostage > 0">
+			<!-- <view class="yt-list-cell b-b" v-if="moneyAll.storeFreePostage > 0">
 				<view class="cell-icon hb">减</view>
 				<text class="cell-tit clamp">商家促销</text>
 				<text class="cell-tip disabled">满{{ moneyAll.storeFreePostage }}包邮</text>
-			</view>
+			</view> -->
 		</view>
 		<!-- 金额明细 -->
 		<view class="yt-list">
@@ -358,9 +358,9 @@ export default {
 				obj.shopList = data.cartInfo; //商品列表
 				obj.moneyAll = data.priceGroup; //金额数据
 				obj.orderKey = data.orderKey; //订单key
-				(obj.system_store = data.system_store), //到店自提列表
+				// (obj.system_store = data.system_store), //到店自提列表
 					obj.shopAddress = data.system_store //选中的地址
-					obj.shopAddress.address = obj.shopAddress.address.join(',')
+					// obj.shopAddress.address = obj.shopAddress.address.join(',')
 				// 计算金额
 				this.payMoneyNub();
 				// 加载优惠券

+ 44 - 9
pages/product/common/productBottom.vue

@@ -1,13 +1,17 @@
 <template>
 	<view class="page-bottom">
-		<navigator url="/pages/index/index" open-type="switchTab" class="p-b-btn">
-			<text class="iconfont iconhome"></text>
-			<text>首页</text>
-		</navigator>
-		<view class="action-btn-group">
-			<button type="primary" class=" action-btn no-border add-cart-btn" @click="buy(2)">加入购物车</button>
+		<view class="p-b-btn" v-if="!product_id" :class="{ active: goodsObjact.userCollect }" @click="toFavorite(goodsObjact)">
+			<text class="iconfont " :class="{ iconlike: !goodsObjact.userCollect, iconlikefill: goodsObjact.userCollect }"></text>
+			<text>收藏</text>
+		</view>
+		<view class="action-btn-group" v-if="!product_id" >
+			<button v-if="isVip!=3" type="primary" class=" action-btn no-border add-cart-btn" @click="buy(2)">加入购物车</button>
 			<button type="primary" class=" action-btn no-border buy-now-btn" @click="buy(1)">立即购买</button>
 		</view>
+		<view class="action-btn-group" v-else>
+			
+			<button type="primary" class="botton" @click="buy(1)">立即购买</button>
+		</view>
 	</view>
 </template>
 
@@ -15,6 +19,9 @@
 import { collectAdd, collectDel } from '@/api/product.js';
 export default {
 	props: {
+		isVip:{
+			
+		},
 		many: {
 			default: 9
 		},
@@ -25,10 +32,23 @@ export default {
 		},
 		goodsid:{
 			default: ''
+		},
+		product_id:{
+			
 		}
 	},
 	data() {
-		return {};
+		return {
+			
+		};
+	},
+	onLoad(){
+		// seckillGoods({}, this.goodsid).then(function({ data }) {
+		// 	obj.list = data;
+		// 	console.log(obj.list,'list');
+		// 	obj.product_id = data.productValue["默认"].product_id
+		// 	console.log(obj.product_id,'徐浩岚');
+		// });
 	},
 	methods: {
 		buy(type) {
@@ -37,6 +57,7 @@ export default {
 		//收藏
 		toFavorite(item) {
 			let obj = this;
+			console.log(obj.goodsObjact,'信息');
 			item.userCollect = !item.userCollect;
 			if (!item.userCollect) {
 				collectDel({ id: obj.goodsid, category: 'product' }).then(function(e) {
@@ -91,7 +112,7 @@ export default {
 		}
 		&.active,
 		&.active .iconfont {
-			color: $uni-color-primary;
+			color: #FF4C4C;
 		}
 		.iconlikefill {
 			font-size: 46rpx;
@@ -103,7 +124,7 @@ export default {
 	}
 	.action-btn-group {
 		display: flex;
-		height: 96rpx;
+		height: 85rpx;
 		overflow: hidden;
 		margin-left: 20rpx;
 		position: relative;
@@ -127,13 +148,27 @@ export default {
 			border-radius: 0;
 			background: transparent;
 			&.buy-now-btn {
+				width: 600rpx;
 				background-color: #FF4C4C;
 			}
 			&.add-cart-btn {
+				width: 600rpx;
 				background-color: #FFB238;
 			}
 		}
 	}
+	.botton{
+		width: 691rpx;
+		height: 85rpx;
+		background: linear-gradient(90deg, #FE6F61 0%, #FF4343 100%);
+		border-radius: 43rpx;
+		
+		line-height: 85rpx;
+		margin:  0 auto;
+		font-size: 36rpx;
+		font-weight: 500;
+		color: #FFFFFF;
+	}
 }
 .p-b-btn {
 	display: flex;

+ 45 - 12
pages/product/common/productContent.vue

@@ -1,14 +1,22 @@
 <template>
 	<view class="introduce-section">
+		
+		<text class="title clamp2">{{ goodsObjact.store_name }}</text>
+		<text class="info" v-if="goodsObjact.store_info">{{ goodsObjact.store_info }}</text>
+		<view class="m-price" v-if="goodsObjact.ot_price > goodsObjact.price"><image src="../../../static/img/list02.png" mode=""></image>市场参考价¥{{ goodsObjact.ot_price }}</view>
 		<view class="price-box">
+			<view class="price-img">
+				<image src="../../../static/img/list03.png" mode=""></image>
+			</view>
 			<text class="price-tip">¥</text>
 			<view class="price">
 				{{ goodsObjact.price }}
-				<text class="m-price" v-if="goodsObjact.ot_price > goodsObjact.price">¥{{ goodsObjact.ot_price }}</text>
+				
+			</view>
+			<view class="price-img-right">
+				<image src="../../../static/img/list01.png" mode=""></image>
 			</view>
 		</view>
-		<text class="title clamp2">{{ goodsObjact.store_name }}</text>
-		<text class="info" v-if="goodsObjact.store_info">{{ goodsObjact.store_info }}</text>
 	</view>
 </template>
 
@@ -48,7 +56,7 @@ export default {
 	background: #fff;
 	padding: 26rpx 26rpx 30rpx 20rpx;
 	.title {
-		margin-top: 26rpx;
+		// margin-top: 26rpx;
 		font-size: 36rpx;
 		font-family: PingFang SC;
 		font-weight: 800;
@@ -95,9 +103,28 @@ export default {
 	.price-box {
 		display: flex;
 		align-items: baseline;
-		height: 64rpx;
-		font-size: 26rpx;
-		color: #FF4C4C;
+		
+		font-size: 40rpx;
+		color: #303030;
+		.price-img{
+			margin-right: 10rpx;
+			width: 24rpx;
+			height: 24rpx;
+			image{
+				width: 100%;
+				height: 100%;
+			}
+		}
+		.price-img-right{
+			margin-left: 10rpx;
+			width: 96rpx;
+			height: 24rpx;
+			image{
+				width: 100%;
+				height: 100%;
+			}
+			
+		}
 	}
 	.price {
 		font-size: 50rpx;
@@ -108,11 +135,17 @@ export default {
 		}
 	}
 	.m-price {
-		margin: 0 12rpx;
-		color: $font-color-light;
-		text-decoration: line-through;
-		margin-left: 25rpx;
-		font-size: 24rpx;
+		image{
+			
+			width: 20rpx;
+			height: 20rpx;
+			margin-right: 10rpx;
+		}
+		
+		font-size: 26rpx;
+		font-weight: 500;
+		color: #FF4C4C;
+		line-height: 37rpx;
 	}
 }
 </style>

+ 4 - 4
pages/product/list.vue

@@ -22,13 +22,13 @@
 			<view v-for="(item, index) in goodsList" :key="index" class="goods-item" @click="navToDetailPage(item)">
 				<view class="image-wrapper">
 					<image :src="item.image" mode="aspectFill"></image>
-					<view class="fanli" v-if="item.give_integral != 0">
+					<!-- <view class="fanli" v-if="item.give_integral != 0">
 						<view class="fanli-bg"><image src="../../static/img/index-fanl.png" mode=""></image></view>
 						<view class="fanli-font flex">
 							<view class="font-left">获得响亮积分</view>
 							<view class="font-right">{{ item.give_integral * 1 }}</view>
 						</view>
-					</view>
+					</view> -->
 				</view>
 				<text class="title clamp">{{ item.store_name }}</text>
 				<view class="price-box">
@@ -72,8 +72,8 @@
 
 <script>
 import uniLoadMore from '@/components/uni-load-more/uni-load-more.vue';
-import { getProducts } from '@/api/product.js';
-import { getCategoryList } from '@/api/product.js';
+import { getProducts,getCategoryList } from '@/api/product.js';
+
 export default {
 	components: {
 		uniLoadMore

+ 817 - 0
pages/product/miaosha.vue

@@ -0,0 +1,817 @@
+<template>
+	<view class="container">
+		<!-- 轮播图 -->
+		<top-swiper :imgList="imgList"></top-swiper>
+		<!-- 标题 -->
+		<product-content :goodsObjact="goodsObjact"></product-content>
+		<view class="c-list">
+			<view class="c-row b-b" @click="toggleSpec">
+				<text class="tit">购买数量</text>
+				<view class="con">
+					<text class="selected-text">{{ goodsNumber }}</text>
+				</view>
+				<text class="iconfont iconenter"></text>
+			</view>
+			<!-- <view class="c-row b-b">
+				<text>每购买一个送{{goodsObjact.give_integral}}响亮积分</text>
+			</view> -->
+		</view>
+		<!-- 拼货时间及优惠 -->
+		<!-- <discounts @clickCoupon="Getcoupon" :Info="goodsObjact.store_info" :showCoupon="true"></discounts> -->
+		<!-- 猜你喜欢 -->
+		<!-- <guess-like @Addcar='Addcar' @clickNavTo='navToDetailPage' :goodList = 'good_list||[]'></guess-like> -->
+		<!-- 评价 -->
+		<estimate @navTo="navTo('/pages/product/reply?id=' + goodsid)" v-if="reply" :reply="reply" :list="list"></estimate>
+		<!-- 规格信息 -->
+		<fresh-detail :goodsObjact="goodsObjact"></fresh-detail>
+		<!-- 图文详情 -->
+		<content-text :description="description"></content-text>
+		<!-- 底部高度撑开 -->
+		<view class="contentBottomHeight"></view>
+		<!-- 底部操作菜单 -->
+		<product-bottom :product_id='product_id' @buy="buy" :goodsObjact="goodsObjact" :isVip='isVip' :goodsid="goodsid" @specOPne="specOPne"></product-bottom>
+		<!-- 规格-模态层弹窗 -->
+		<view class="popup spec" :class="specClass" @touchmove.stop.prevent="stopPrevent" @click="toggleSpec">
+			<!-- 遮罩层 -->
+			<view class="mask"></view>
+			<view class="layer attr-content" @click.stop="stopPrevent">
+				<view class="a-t">
+					<image :src="actionImage"></image>
+					<view class="right">
+						<view class="good-name clamp">{{ goodsObjact.store_name }}</view>
+						<text class="price">¥{{ actionPrice }}</text>
+						<!-- <text class="stock">库存:{{ goodsObjact.stock }}件</text> -->
+						<!-- <view class="selected" v-if="goodsType == 0">
+							已选:
+							<text class="selected-text" v-for="(sItem, sIndex) in specSelected" :key="sIndex">{{ sItem }}</text>
+						</view> -->
+					</view>
+				</view>
+				<view v-for="(item, index) in specList" :key="index" class="attr-list">
+					<text>{{ item.attr_name }}</text>
+					<view class="item-list">
+						<text
+							v-for="(childItem, childIndex) in item.attr_value"
+							:key="childIndex"
+							class="tit"
+							:class="{ selected: childItem.check }"
+							@click="selectSpec(childItem, item, index)"
+						>
+							{{ childItem.attr }}
+						</text>
+					</view>
+				</view>
+				<view class="flex">
+					<view>购买数量</view>
+					<view class="item-list">
+						<uni-number-box class="step" :isMin="true" :value="goodsNumber" :min="1" :max="goodsNumberMax" @eventChange="numberChange"></uni-number-box>
+					</view>
+				</view>
+				<button class="btn" @click.stop="buy">确定</button>
+			</view>
+		</view>
+	</view>
+</template>
+
+<script>
+import uniNumberBox from '@/components/uni-number-box.vue';
+import { goodsDetail, cartAdd,seckillGoods } from '@/api/product.js';
+import { mapState } from 'vuex';
+import store from '@/store/index.js';
+import { orderData, userinfo } from '@/api/user.js';
+import { saveUrl } from '@/utils/loginUtils.js';
+// #ifdef H5
+import { weixindata, shareLoad } from '@/utils/wxAuthorized';
+// #endif
+// 头部轮播图
+import topSwiper from './common/topSwiper.vue';
+// 标题
+import productContent from './common/productContent.vue';
+// 到货时间及优惠
+import discounts from './common/discounts.vue';
+// 规格信息
+import freshDetail from './common/freshDetail.vue';
+// 图文详情
+import contentText from './common/contentText.vue';
+// 底部按钮
+import productBottom from './common/productBottom.vue';
+// 猜你喜欢
+import guessLike from './common/guessLike.vue';
+// 评价
+import estimate from './common/estimate.vue';
+export default {
+	components: {
+		uniNumberBox,
+		guessLike,
+		topSwiper,
+		productContent,
+		discounts,
+		freshDetail,
+		contentText,
+		productBottom,
+		estimate
+	},
+	data() {
+		return {
+			product_id:0,//秒杀id
+			goodsStore: 0, //选中库存
+			specList: [],
+			buys_show: true,
+			buys_shows: false,
+			specSelected: [], //选中的分类
+			specClass: 'none', //显示隐藏弹窗
+			many: 1, //1是单规格  2是多规格
+			reply: '', //评论
+			list: '', //商品详情的数据
+			type: 1, //默认支付方式add为
+			goodsType: 0,
+			goodsNumber: 1, //购买数量
+			goodsid: '', //商品id
+			description: '', //商品描述
+			goodsObjact: {
+				percent: 1
+			}, //保存商品数据
+			//图片循环
+			imgList: [],
+			// 对比对象
+			actionPrice: 0, //默认选中商品价格
+			actionImage: '', //默认选中图片
+			good_list: '', //猜你喜欢列表
+			goodsNumberMax: 0, //最大可购买数量
+			// 倒计时数据保存
+			seckillObj: {
+				stopTime: 0, //结束时间
+				stop: false, //是否结束
+				stopTimeH: 0, //小时
+				stopTimeM: 0, //分钟
+				stopTimeS: 0, //秒钟
+				stopTimeD: 0, //天
+				upTime: 0 //更新组件内部组件用
+			},
+			// 拼团数据保存
+			pink: {
+				id: '', //拼团编号
+				uid: '', //用户编号
+				people: '', //拼团人数
+				price: '', //拼团价格
+				stop_time: '', //拼团结束时间
+				nickname: '', //团长昵称
+				avatar: '', //团长头像
+				count: '', //拼团剩余人数
+				h: '', //时
+				i: '', //分
+				s: '' //秒
+			},
+			userInfo: '',
+			isVip: '0'
+		};
+	},
+	filters: {
+		parseIntTo(percent) {
+			percent = +percent * 100;
+			if (percent % 1 === 0) {
+				return percent;
+			} else {
+				percent = percent.toFixed(1);
+				return percent;
+			}
+		}
+	},
+	async onLoad(options) {
+		console.log(this.options)
+		let obj = this;
+		userinfo({})
+			.then(({ data }) => {
+				obj.userInfo = data;
+				console.log(data,"123456")
+			})
+		//保存商品id
+		this.goodsid = options.id;
+		this.goodsType = options.type;
+		// 判断有无人邀请
+		if (options.spread) {
+			// 存储邀请人
+			uni.setStorageSync('spread', options.spread);
+		}
+		if (options.isVip) {
+			obj.isVip = options.isVip;
+			console.log(options,'isVip')
+		}
+		console.log(obj.isVip, 'vip');
+		saveUrl();
+		this.seckillGoods();
+		// 注册邀请信息
+		// #ifdef H5
+		let bool = uni.getStorageSync('weichatBrowser') || '';
+		if (bool) {
+			weixindata();
+		}
+		// #endif
+	},
+	computed: {
+		...mapState(['weichatObj', 'baseURL', 'urlFile'])
+	},
+	// 分享
+	// onShareAppMessage(options) {
+	// 	// 设置菜单中的转发按钮触发转发事件时的转发内容
+	// 	let pages = getCurrentPages(); //获取加载的页面
+	// 	let currentPage = pages[pages.length - 1]; //获取当前页面的对象
+	// 	let url = currentPage.route; //当前页面url
+	// 	let item = currentPage.options; //如果要获取url中所带的参数可以查看options
+	// 	let shareObj = {
+	// 		title: this.goodsObjact.store_name,
+	// 		desc: obj.goodsObjact.store_info,
+	// 		path: url + '?id=' + item.id + '&spread=' + this.userInfo.uid, // 默认是当前页面,必须是以‘/’开头的完整路径
+	// 		imageUrl: this.goodsObjact.image,
+	// 		success: function(res) {
+	// 			// 转发成功之后的回调
+	// 			if (res.errMsg == 'shareAppMessage:ok') {
+	// 			}
+	// 		},
+	// 		fail: function() {
+	// 			// 转发失败之后的回调
+	// 			if (res.errMsg == 'shareAppMessage:fail cancel') {
+	// 				// 用户取消转发
+	// 			} else if (res.errMsg == 'shareAppMessage:fail') {
+	// 				// 转发失败,其中 detail message 为详细失败信息
+	// 			}
+	// 		}
+	// 	};
+
+	// 	return shareObj;
+	// },
+	methods: {
+		//收藏
+		toFavorite(item) {
+			let obj = this;
+			item.userCollect = !item.userCollect;
+			if (!item.userCollect) {
+				collectDel({ id: obj.goodsid, category: 'product' }).then(function(e) {
+					uni.showToast({
+						title: '成功取消收藏',
+						type: 'top',
+						duration: 1500
+					});
+				});
+			} else {
+				collectAdd({ id: obj.goodsid, category: 'product' }).then(function(e) {
+					uni.showToast({
+						title: '成功加入收藏',
+						type: 'top',
+						duration: 1500
+					});
+				});
+			}
+		},
+		//选择规格
+		selectSpec(item, arr, ind) {
+			arr.attr_value.forEach(function(e) {
+				e.check = false;
+			});
+			item.check = true;
+			let obj = this;
+			obj.specSelected[ind] = item.attr;
+			let str = obj.specSelected.join(',');
+			// 获取当前选中的对象
+			if (obj.productValue[str]) {
+				obj.buys_show = true;
+				obj.buys_shows = false;
+				obj.actionPrice = obj.productValue[str].price;
+				obj.goodsNumberMax = obj.productValue[str].stock;
+				obj.actionImage = obj.productValue[str].image;
+				obj.uniqueId = obj.productValue[str].unique;
+				obj.goodsStore = obj.productValue[str].stock;
+			} else {
+				(obj.buys_show = false), (obj.buys_shows = true);
+			}
+			if (obj.goodsStore == 0) {
+				obj.buys_show = false;
+				obj.buys_shows = true;
+			}
+			obj.specSelected[ind] = item.attr;
+		},
+		// 打開彈窗
+		specOPne(type = 1) {
+			let obj = this;
+			obj.specClass = 'show';
+			obj.type = type;
+		},
+		//规格弹窗开关
+		toggleSpec(str) {
+			if (this.specClass === 'show') {
+				this.specClass = 'hide';
+				setTimeout(() => {
+					this.specClass = 'none';
+				}, 250);
+			} else if (this.specClass === 'none') {
+				this.specClass = 'show';
+			}
+			// 保存当前购买类型
+			this.type = str;
+		},
+		//领取优惠券
+		Getcoupon() {
+			uni.navigateTo({
+				url: '/pages/coupon/getcoupon'
+			});
+		},
+		// 购买数量变化
+		numberChange(e) {
+			this.goodsNumber = e.number;
+		},
+		// #ifdef H5
+		// 加载微信html5页面分享方法
+		shareDate() {
+			let obj = this;
+			// 保存分享人id链接
+			let url = window.location.href + '&spread=' + this.userInfo.uid;
+			// 判断是否微信浏览器
+			let bool = uni.getStorageSync('weichatBrowser') || '';
+			if (bool) {
+				// 过滤微信强制添加的链接地址
+				url = url.replace(/[\?,&]from=singlemessage/g, '');
+				let data = {
+					link: url, // 分享链接
+					imgUrl: obj.goodsObjact.image, // 分享图标
+					desc: obj.goodsObjact.store_info,
+					title: obj.goodsObjact.store_name,
+					success: function(e) {
+						console.log(e);
+					}
+				};
+				console.log(data, '分享');
+				shareLoad(data);
+			}
+		},
+		// #endif
+		//详情页
+		navToDetailPage(item) {
+			let id = item.id;
+			uni.navigateTo({
+				url: '/pages/product/product?id=' + id
+			});
+		},
+		// 跳转页面
+		navTo(url) {
+			uni.navigateTo({
+				url: '/pages/product/reply?id=' + this.goodsid
+			});
+		},
+		//加入购物车
+		Addcar(item) {
+			let obj = this;
+			cartAdd({
+				cartNum: '1', //商品数量
+				uniqueId: '', //商品标签
+				new: 0, //商品是否新增加到购物车1为不加入0为加入
+				mer_id: '',
+				productId: item.id //商品编号
+			})
+				.then(function(e) {
+					uni.showToast({
+						title: '成功加入购物车',
+						type: 'top',
+						duration: 500,
+						icon: 'none'
+					});
+
+					obj.seckillGoods();
+				})
+				.catch(e => {
+					console.log(e);
+				});
+		},
+		seckillGoods() {
+			let obj = this;
+			// 获取普通商品信息
+			seckillGoods({}, this.goodsid).then(function({ data }) {
+				obj.list = data;
+				console.log(obj.list,'list');
+				obj.product_id = data.productValue["默认"].product_id
+				console.log(obj.product_id,'obj.product_id');
+				obj.good_list = data.good_list; //保存猜你喜欢列表
+				obj.reply = data.reply; //保存评论列表
+				let goods = data.storeInfo;
+				obj.goodsObjact = goods;
+				console.log(data.storeInfo,'基本商品');
+				if (obj.goodsObjact.description != null) {
+					obj.description = obj.goodsObjact.description.replace(/\<img/gi, '<img class="rich-img"');
+				} //小程序商品详情图超出屏幕问题
+				obj.imgList = goods.images; //保存轮播图
+				obj.specList = data.productAttr; //保存分类列表
+				if (Array.isArray(data.productValue) != true) {
+					obj.many = 2;
+					obj.specList = data.productAttr; //保存产品属性
+					obj.productValue = data.productValue; //保存属性值
+					obj.specSelected = []; //初始化默认选择对象
+					for (let i = 0; i < obj.specList.length; i++) {
+						// 设置默认数据
+						let attrValue = obj.specList[i].attr_value[0];
+						attrValue.check = true;
+						obj.specSelected.push(attrValue.attr);
+					}
+					let str = obj.specSelected.join(',');
+					console.log(str, 'str');
+					// 设置默认值
+					obj.actionPrice = obj.productValue[str].price;
+					obj.goodsNumberMax = obj.productValue[str].stock;
+					obj.actionImage = obj.productValue[str].image;
+					obj.uniqueId = obj.productValue[str].unique;
+					obj.goodsStore = obj.productValue[str].quota;
+				} else {
+					obj.many = 1;
+					obj.productValue = data.productValue; //保存分类查询数据
+					obj.actionPrice = goods.price; //保存默认选中商品价格
+					obj.actionImage = goods.image_base; //保存默认选中商品图片
+					obj.goodsNumberMax = goods.stock; //保存默认选中最大可购买商品数量
+				}
+				obj.shopId = data.mer_id; //保存商店id
+				// #ifdef H5
+				obj.shareDate();
+				// #endif
+			});
+		},
+		// #ifdef H5
+		// 加载微信html5页面分享方法
+		shareDate() {
+			let obj = this;
+			// 保存分享人id链接
+			let url = window.location.href + '&spread=' + this.userInfo.uid;
+			// 判断是否微信浏览器
+			let bool = uni.getStorageSync('weichatBrowser') || '';
+			if (bool) {
+				// 过滤微信强制添加的链接地址
+				url = url.replace(/[\?,&]from=singlemessage/g, '');
+				let data = {
+					link: url, // 分享链接
+					imgUrl: obj.goodsObjact.image, // 分享图标
+					desc: obj.goodsObjact.store_info,
+					title: obj.goodsObjact.store_name,
+					success: function(e) {
+						console.log(e);
+					}
+				};
+				shareLoad(data);
+			}
+		},
+		// #endif
+		// 立即购买
+		buy() {
+			let obj = this;
+			console.log(obj.userInfo,'userInfo');
+			// if (obj.userInfo.lock_spread_user == null) {
+			// 	if (obj.userInfo.unlock_spread_user == null) {
+			// 		uni.showModal({
+			// 			title: '提示',
+			// 			content: '您未绑定或锁定邀请人,无法购买会员礼包,是否前往绑定关系',
+			// 			success: function(res) {
+			// 				if (res.confirm) {
+			// 					console.log('用户点击确定');
+			// 					uni.navigateTo({
+			// 						url: '/pages/set/user'
+			// 					});
+			// 				} else if (res.cancel) {
+			// 					console.log('用户点击取消');
+			// 				}
+			// 			}
+			// 		});
+			// 		return;
+			// 	} else {
+			// 		uni.showModal({
+			// 			title: '提示',
+			// 			content: '已锁定邀请人:' + obj.userInfo.unlock_spread_user.phone + '购买商品后将绑定关系',
+			// 			success: function(res) {
+			// 				if (res.confirm) {
+			// 					obj.buy1();
+			// 				} else if (res.cancel) {
+			// 					console.log('用户点击取消');
+			// 				}
+			// 			}
+			// 		});
+			// 		return;
+			// 	}
+			// }
+			// 创建传值对象
+			let data = {
+				cartNum: obj.goodsNumber, //商品数量
+				new: 1,
+				secKillId: obj.product_id,
+				productId: obj.goodsid, //商品编号
+				uniqueId: obj.uniqueId
+			};
+			console.log(data,'商品详情');
+
+			if (obj.type == 2) {
+				data.new = 0;
+			}
+			cartAdd(data)
+				.then(function(e) {
+					let da = e.data;
+					if (obj.type == 1) {
+						// 跳转到支付页
+						uni.navigateTo({
+							url: '/pages/order/createOrder?id=' + da.cartId
+						});
+					}
+					if (obj.type == 2) {
+						uni.showToast({
+							title: '成功加入购物车',
+							type: 'top',
+							duration: 2000,
+							icon: 'none'
+						});
+						obj.seckillGoods();
+					}
+					obj.toggleSpec();
+				})
+				.catch(e => {
+					console.log(e);
+				});
+		},
+		buy1() {
+			let obj = this;
+			let data = {
+				cartNum: obj.goodsNumber, //商品数量
+				new: 1,
+				secKillId: obj.product_id,
+				productId: obj.goodsid, //商品编号
+				uniqueId: obj.uniqueId
+			};
+
+			if (obj.type == 2) {
+				data.new = 0;
+			}
+			cartAdd(data)
+				.then(function(e) {
+					let da = e.data;
+					if (obj.type == 1) {
+						// 跳转到支付页
+						uni.navigateTo({
+							url: '/pages/order/createOrder?id=' + da.cartId
+						});
+					}
+					if (obj.type == 2) {
+						uni.showToast({
+							title: '成功加入购物车',
+							type: 'top',
+							duration: 2000,
+							icon: 'none'
+						});
+						obj.seckillGoods();
+					}
+					obj.toggleSpec();
+				})
+				.catch(e => {
+					console.log(e);
+				});
+		},
+		// 阻止触发上级事件
+		stopPrevent() {}
+	}
+};
+</script>
+
+<style lang="scss">
+/*  弹出层 */
+.popup {
+	position: fixed;
+	left: 0;
+	top: 0;
+	right: 0;
+	bottom: 0;
+	z-index: 99;
+
+	&.show {
+		display: block;
+		.mask {
+			animation: showPopup 0.2s linear both;
+		}
+		.layer {
+			animation: showLayer 0.2s linear both;
+		}
+	}
+	&.hide {
+		.mask {
+			animation: hidePopup 0.2s linear both;
+		}
+		.layer {
+			animation: hideLayer 0.2s linear both;
+		}
+	}
+	&.none {
+		display: none;
+	}
+	.mask {
+		position: fixed;
+		top: 0;
+		width: 100%;
+		height: 100%;
+		z-index: 1;
+		background-color: rgba(0, 0, 0, 0.4);
+	}
+	.layer {
+		position: fixed;
+		z-index: 99;
+		bottom: 0;
+		width: 100%;
+		min-height: 30vh;
+		border-radius: 10rpx 10rpx 0 0;
+		background-color: #fff;
+		.btn {
+			height: 66rpx;
+			line-height: 66rpx;
+			border-radius: 100rpx;
+			// background: $uni-color-primary;
+			background: #FF4C4C;
+			font-size: $font-base + 2rpx;
+			color: #fff;
+			margin: 30rpx auto 20rpx;
+		}
+	}
+	@keyframes showPopup {
+		0% {
+			opacity: 0;
+		}
+		100% {
+			opacity: 1;
+		}
+	}
+	@keyframes hidePopup {
+		0% {
+			opacity: 1;
+		}
+		100% {
+			opacity: 0;
+		}
+	}
+	@keyframes showLayer {
+		0% {
+			transform: translateY(120%);
+		}
+		100% {
+			transform: translateY(0%);
+		}
+	}
+	@keyframes hideLayer {
+		0% {
+			transform: translateY(0);
+		}
+		100% {
+			transform: translateY(120%);
+		}
+	}
+}
+/* 规格选择弹窗 */
+.attr-content {
+	padding: 10rpx 30rpx;
+	.a-t {
+		display: flex;
+		image {
+			width: 170rpx;
+			height: 170rpx;
+			flex-shrink: 0;
+			border-radius: 8rpx;
+		}
+		.right {
+			display: flex;
+			flex-direction: column;
+			padding-left: 24rpx;
+			font-size: $font-sm + 2rpx;
+			color: $font-color-base;
+			line-height: 42rpx;
+			.good-name {
+				padding-top: 20rpx;
+				max-width: 320rpx;
+				font-size: 30rpx;
+				font-family: PingFang SC;
+				font-weight: bold;
+				color: #1d2023;
+				line-height: 42rpx;
+				margin-bottom: 15rpx;
+			}
+			.price {
+				font-size: 60rpx;
+				font-family: PingFang SC;
+				font-weight: bold;
+				color: #ff6f0f;
+				// font-size: $font-lg;
+				// color: $uni-color-primary;
+				// margin-bottom: 10rpx;
+			}
+			.selected-text {
+				margin-right: 10rpx;
+			}
+		}
+	}
+	.attr-list {
+		display: flex;
+		flex-direction: column;
+		font-size: $font-base + 2rpx;
+		color: $font-color-base;
+		padding-top: 30rpx;
+		padding-left: 10rpx;
+	}
+	.item-list {
+		padding: 20rpx 0 0;
+		display: flex;
+		flex-wrap: wrap;
+		.tit {
+			display: flex;
+			align-items: center;
+			justify-content: center;
+			background: #eee;
+			// margin-left: 10rpx;
+			margin-right: 20rpx;
+			margin-bottom: 20rpx;
+			border-radius: 100rpx;
+			min-width: 60rpx;
+			height: 60rpx;
+			padding: 0 20rpx;
+			font-size: $font-base;
+			color: $font-color-dark;
+		}
+		.selected {
+			background: #FCEFF1;
+			border: 1px solid #EF041F;
+			color: #EF041F;
+		}
+	}
+}
+
+//默认商品底部高度
+.goodsBottom {
+	height: 160rpx;
+}
+page {
+	background: #f0f0f0;
+}
+//秒杀、拼团底部高度
+.contentBottomHeight {
+	height: 110rpx;
+}
+//默认商品底部高度
+.goodsBottom {
+	height: 160rpx;
+}
+/deep/ .iconenter {
+	font-size: $font-base + 2rpx;
+	color: #888;
+}
+/deep/ .con_image {
+	width: 130rpx;
+	height: 130rpx;
+	display: inline-block;
+	padding: 15rpx;
+	image {
+		width: 100%;
+		height: 100%;
+	}
+}
+/* 商品详情中限制图片大小 */
+/deep/ .rich-img {
+	width: 100% !important;
+	height: auto;
+}
+.c-list {
+	margin-top: 20rpx;
+	font-size: $font-sm + 2rpx;
+	color: $font-color-base;
+	background: #fff;
+	.c-row {
+		display: flex;
+		align-items: center;
+		padding: 20rpx 30rpx;
+		position: relative;
+	}
+	.tit {
+		width: 140rpx;
+	}
+	.con {
+		flex: 1;
+		color: $font-color-dark;
+		.selected-text {
+			margin-right: 10rpx;
+		}
+	}
+	.bz-list {
+		height: 40rpx;
+		font-size: $font-sm + 2rpx;
+		color: $font-color-dark;
+		text {
+			display: inline-block;
+			margin-right: 30rpx;
+		}
+	}
+	.con-list {
+		flex: 1;
+		display: flex;
+		flex-direction: column;
+		color: $font-color-dark;
+		line-height: 40rpx;
+	}
+	.red {
+		color: $uni-color-primary;
+	}
+}
+
+</style>

+ 61 - 36
pages/product/product.vue

@@ -12,9 +12,9 @@
 				</view>
 				<text class="iconfont iconenter"></text>
 			</view>
-			<view class="c-row b-b">
+			<!-- <view class="c-row b-b">
 				<text>每购买一个送{{goodsObjact.give_integral}}响亮积分</text>
-			</view>
+			</view> -->
 		</view>
 		<!-- 拼货时间及优惠 -->
 		<!-- <discounts @clickCoupon="Getcoupon" :Info="goodsObjact.store_info" :showCoupon="true"></discounts> -->
@@ -29,7 +29,7 @@
 		<!-- 底部高度撑开 -->
 		<view class="contentBottomHeight"></view>
 		<!-- 底部操作菜单 -->
-		<product-bottom @buy="buy" :goodsObjact="goodsObjact" :goodsid="goodsid" @specOPne="specOPne"></product-bottom>
+		<product-bottom @buy="buy" :goodsObjact="goodsObjact" :isVip='isVip' :goodsid="goodsid" @specOPne="specOPne"></product-bottom>
 		<!-- 规格-模态层弹窗 -->
 		<view class="popup spec" :class="specClass" @touchmove.stop.prevent="stopPrevent" @click="toggleSpec">
 			<!-- 遮罩层 -->
@@ -75,7 +75,7 @@
 
 <script>
 import uniNumberBox from '@/components/uni-number-box.vue';
-import { goodsDetail, cartAdd } from '@/api/product.js';
+import { goodsDetail, cartAdd,seckillGoods } from '@/api/product.js';
 import { mapState } from 'vuex';
 import store from '@/store/index.js';
 import { orderData, userinfo } from '@/api/user.js';
@@ -177,6 +177,7 @@ export default {
 		}
 	},
 	async onLoad(options) {
+		console.log(this.options)
 		let obj = this;
 		userinfo({})
 			.then(({ data }) => {
@@ -193,6 +194,7 @@ export default {
 		}
 		if (options.isVip) {
 			obj.isVip = options.isVip;
+			console.log(options,'isVip')
 		}
 		console.log(obj.isVip, 'vip');
 		saveUrl();
@@ -238,6 +240,28 @@ export default {
 	// 	return shareObj;
 	// },
 	methods: {
+		//收藏
+		toFavorite(item) {
+			let obj = this;
+			item.userCollect = !item.userCollect;
+			if (!item.userCollect) {
+				collectDel({ id: obj.goodsid, category: 'product' }).then(function(e) {
+					uni.showToast({
+						title: '成功取消收藏',
+						type: 'top',
+						duration: 1500
+					});
+				});
+			} else {
+				collectAdd({ id: obj.goodsid, category: 'product' }).then(function(e) {
+					uni.showToast({
+						title: '成功加入收藏',
+						type: 'top',
+						duration: 1500
+					});
+				});
+			}
+		},
 		//选择规格
 		selectSpec(item, arr, ind) {
 			arr.attr_value.forEach(function(e) {
@@ -365,6 +389,7 @@ export default {
 				obj.reply = data.reply; //保存评论列表
 				let goods = data.storeInfo;
 				obj.goodsObjact = goods;
+				console.log(data.storeInfo,'基本商品');
 				if (obj.goodsObjact.description != null) {
 					obj.description = obj.goodsObjact.description.replace(/\<img/gi, '<img class="rich-img"');
 				} //小程序商品详情图超出屏幕问题
@@ -430,38 +455,38 @@ export default {
 		buy() {
 			let obj = this;
 			console.log(obj.userInfo);
-			if (obj.userInfo.lock_spread_user == null) {
-				if (obj.userInfo.unlock_spread_user == null) {
-					uni.showModal({
-						title: '提示',
-						content: '您未绑定或锁定邀请人,无法购买会员礼包,是否前往绑定关系',
-						success: function(res) {
-							if (res.confirm) {
-								console.log('用户点击确定');
-								uni.navigateTo({
-									url: '/pages/set/user'
-								});
-							} else if (res.cancel) {
-								console.log('用户点击取消');
-							}
-						}
-					});
-					return;
-				} else {
-					uni.showModal({
-						title: '提示',
-						content: '已锁定邀请人:' + obj.userInfo.unlock_spread_user.phone + '购买商品后将绑定关系',
-						success: function(res) {
-							if (res.confirm) {
-								obj.buy1();
-							} else if (res.cancel) {
-								console.log('用户点击取消');
-							}
-						}
-					});
-					return;
-				}
-			}
+			// if (obj.userInfo.lock_spread_user == null) {
+			// 	if (obj.userInfo.unlock_spread_user == null) {
+			// 		uni.showModal({
+			// 			title: '提示',
+			// 			content: '您未绑定或锁定邀请人,无法购买会员礼包,是否前往绑定关系',
+			// 			success: function(res) {
+			// 				if (res.confirm) {
+			// 					console.log('用户点击确定');
+			// 					uni.navigateTo({
+			// 						url: '/pages/set/user'
+			// 					});
+			// 				} else if (res.cancel) {
+			// 					console.log('用户点击取消');
+			// 				}
+			// 			}
+			// 		});
+			// 		return;
+			// 	} else {
+			// 		uni.showModal({
+			// 			title: '提示',
+			// 			content: '已锁定邀请人:' + obj.userInfo.unlock_spread_user.phone + '购买商品后将绑定关系',
+			// 			success: function(res) {
+			// 				if (res.confirm) {
+			// 					obj.buy1();
+			// 				} else if (res.cancel) {
+			// 					console.log('用户点击取消');
+			// 				}
+			// 			}
+			// 		});
+			// 		return;
+			// 	}
+			// }
 			// 创建传值对象
 			let data = {
 				cartNum: obj.goodsNumber, //商品数量

+ 4 - 2
pages/product/seckill.vue

@@ -132,9 +132,10 @@ export default {
 		navProduct(ls, ind) {
 			if (ls.status == 1) {
 				let data = ls.dataList[ind];
+				console.log(data,'data');
 
 				uni.navigateTo({
-					url: '/pages/product/product?id=' + data.id + '&type=1'
+					url: '/pages/product/miaosha?id=' + data.id + '&type=1'
 				});
 			}
 		},
@@ -142,7 +143,7 @@ export default {
 		getList(ind, source) {
 			// 获取数据对象
 			let date = this.indexList[ind];
-			console.log(date, source);
+			console.log(date, source,'23232323');
 			if (source === 'tabChange' && date.loaded === true) {              
 				//tab切换只有第一次需要加载数据
 				return;
@@ -165,6 +166,7 @@ export default {
 				date.id
 			)
 				.then(e => {
+					console.log(e,'煮熟');
 					date.dataList.push(...e.data);
 					// 查询翻页增加
 					date.page++;

+ 1 - 1
pages/public/login.vue

@@ -201,7 +201,7 @@ export default {
 						obj.login();
 						// 保存返回用户数据
 						obj.setUserInfo(e.data);
-						let ur = uni.getStorageSync('present')|| '/pages/index/index';
+						let ur =  '/pages/index/index';
 						//成功跳转首页
 						uni.switchTab({
 							url: ur,

+ 1 - 1
pages/public/register.vue

@@ -1,7 +1,7 @@
 <template>
 	<view class="container">
 		<view class="status_bar"><!-- 这里是状态栏 --></view>
-		<view class="loginTitle">欢迎注册响亮商城</view>
+		<view class="loginTitle">欢迎注册皓月瓷肌</view>
 		<view class="loginText">请认真填写个人信息</view>
 		<view class="login-box">
 			<view class="username">账号</view>

+ 2 - 2
pages/set/address.vue

@@ -201,8 +201,8 @@ page {
 	width: 690rpx;
 	height: 80rpx;
 	font-size: $font-lg;
-	color: #fff;
-	background-color: $base-color;
+	color: #F8DABA;
+	background-color: #303030;
 	border-radius: 10rpx;
 }
 </style>

+ 3 - 3
pages/set/addressManage.vue

@@ -24,7 +24,7 @@
 				:switch-checked="addressData.default"
 				:show-switch="true"
 				:show-arrow="false"
-				switch-color="#5dbc7c"
+				switch-color="#303030"
 				@switchChange="switchChange"
 			></uni-list-item>
 		</uni-list>
@@ -207,8 +207,8 @@ page {
 	height: 80rpx;
 	margin: 60rpx auto;
 	font-size: $font-lg;
-	color: #fff;
-	background-color: $base-color;
+	color: #F8DABA;
+	background-color: #303030;
 	border-radius: 10rpx;
 	// box-shadow: 1px 2px 5px rgba(219, 63, 96, 0.4);
 }

+ 276 - 70
pages/set/userinfo.vue

@@ -1,93 +1,299 @@
 <template>
-	<view class="content">
-		<view class="row b-b">
+	<!-- 	<view class="container">
+		<uni-list>
+		    <uni-list-item title="个人资料" @click="navTo('/pages/set/userinfo')" ></uni-list-item>
+			<uni-list-item title="修改密码" @click="navTo('/pages/set/password')" ></uni-list-item>
+		    <uni-list-item title="实名认证" @click="navTo('/pages/set/phone')" ></uni-list-item>
+		    <uni-list-item title="收货地址" @click="navTo('/pages/set/address')" ></uni-list-item>
+		</uni-list>
+		<uni-list class="margin-t-20">
+		    <uni-list-item title="消息推送" :switch-checked='true' :show-switch="true" :show-arrow="false" switch-color='#5dbc7c'  @switchChange='switchChange'> 
+			</uni-list-item>
+		</uni-list>
+		
+		<uni-list class="margin-t-20">
+		    <uni-list-item title="清除缓存" ></uni-list-item>
+		    <uni-list-item title="检查更新" >
+				<template slot="right">
+					当前版本 1.0.3
+				</template>
+			</uni-list-item>
+		</uni-list>
+		<view class="list-cell log-out-btn" @click="toLogout">
+			<text class="cell-tit">退出登录</text>
+		</view>
+	</view> -->
+	<view class="container">
+		<view class="row b-b flex jg">
+			<text class="tit">头像</text>
+			<image :src="userInfo.avatar" @click="imgsub"></image>
+		</view>
+		<view class="row b-b flex">
 			<text class="tit">昵称</text>
-			<input class="input" type="text" v-model="name" placeholder="修改昵称" placeholder-class="placeholder" />
+			<input class="input" v-model="userInfo.nickname" type="text" placeholder-class="placeholder" />
+		</view>
+		<view class="row b-b flex">
+			<text class="tit">邀请码</text>
+			<input class="input" v-model="userInfo.uid" type="text" disabled="true" placeholder-class="placeholder"
+				style="color: #999;" />
+		</view>
+		<!-- v-if="agents!=''" -->
+		<!-- <view class="row b-b flex" v-if="!Array.isArray(userInfo.agent)">
+		<text class="tit">代理区域</text>
+		<view class="agents" style="color: #999;text-align: right;">
+			<view class="agent" v-for="(item,index) in userInfo.agent" :key="index">
+			{{item}}	
+			</view>
+		</view>
+	</view> -->
+		<view class="row b-b flex" v-if="userInfo.account || userInfo.phone">
+			<text class="tit">用户账号</text>
+			<input class="input" v-model="userInfo.account || userInfo.phone" type="number" disabled="true"
+				placeholder-class="placeholder" />
 		</view>
-		<button class="add-btn" @click="confirm">提交</button>
+		<view class="submit-box flex">
+			<view class="submit" @click="edit">确认修改</view>
+			<view class="submit dl" @click="toLogout">退出登录</view>
+		</view>
+
 	</view>
 </template>
 
 <script>
-import { mapState } from 'vuex';
-import { userEdit } from '@/api/set.js';
-export default {
-	data() {
-		return {
-			name: ''
-		};
-	},
+	// import uniList from "@/components/uni-list/uni-list.vue"
+	// import uniListItem from "@/components/uni-list-item/uni-list-item.vue"
+	// import { logout } from '@/api/set.js';
+	// import {  
+	//     mapMutations  
+	// } from 'vuex';
+	// export default {
+	// 	components: {
+	// 		uniList,uniListItem
+	// 	},
+	// 	data() {
+	// 		return {
+
+	// 		};
+	// 	},
+	// 	methods:{
+	// 		...mapMutations('user',['logout']),
+	// 		navTo(url){
+	// 			uni.navigateTo({
+	// 				url:url
+	// 			})
+	// 		},
+	// 		//退出登录
+	// 		toLogout(){
+	// 			let obj = this;
+	// 			uni.showModal({
+	// 			    content: '确定要退出登录么',
+	// 			    success: (e)=>{
+	// 			    	if(e.confirm){
+	// 						logout({}).then((e) => {
+	// 							uni.navigateBack();
+	// 						}).catch((e) => {
+	// 							console.log(e);
+	// 						})
+	// 			    		obj.logout();
+	// 			    	}
+	// 			    }
+	// 			});
+	// 		},
+	// 		//switch切换触发方法
+	// 		switchChange(e){
+	// 			console.log(e);
+	// 			let statusTip = e.value ? '打开': '关闭';
+	// 			this.$api.msg(`${statusTip}消息推送`);
+	// 		},
+
+	// 	}
+	// }
+	import uniList from '@/components/uni-list/uni-list.vue';
+	import uniListItem from '@/components/uni-list-item/uni-list-item.vue';
+	import {
+		mapState,
+		mapMutations
+	} from 'vuex';
+	import {
+		logout
+	} from '@/api/set.js';
 
-	computed: {
-		...mapState('user', ['userInfo'])
-	},
-	onShow(option) {
-		this.name = this.userInfo.nickname + '';
-	},
-	methods: {
-		switchChange(e) {
-			this.addressData.default = e.value;
+	import {
+		edit
+	} from '@/api/user.js';
+	import{upload} from '@/api/order.js'
+	export default {
+		components: {
+			uniList,
+			uniListItem
 		},
-		confirm() {
-			userEdit({ nickname: this.name, avatar: this.userInfo.avatar })
-				.then(e => {
-					this.$api.msg('修改成功');
-					setTimeout(()=> {
+		data() {
+			return {
+				userInfo: {},
+				pics: [],
+			};
+		},
+		onLoad() {
+			this.userInfo = uni.getStorageSync('userInfo') || '';
+			console.log(this.userInfo)
+		},
+		methods: {
+			...mapMutations('user', ['logout']),
+			//退出登录
+			toLogout() {
+				let obj = this;
+				uni.showModal({
+					content: '确定要退出登录么',
+					success: e => {
+						if (e.confirm) {
+							logout({}).then(e => {
+									obj.logout();
+									uni.switchTab({
+										url: '/pages/index/index'
+									})
+								})
+								.catch(e => {
+									console.log(e);
+								});
+						}
+					}
+				});
+			},
+			imgsub() {
+				let obj = this
+				console.log('上传头像')
+				// this.$util.uploadImageOne('upload/image', function(res) {
+				// 	console.log('------',res);
+				// 	this.pics.push(res.data.pathreplace(/http:\/\/mer.crmeb.net/,'https://hy.liuniu946.com'));
+				// 	// obj.userInfo.avatar = res.data.path.replace(/http:\/\/mer.crmeb.net/,'http://zccy.frp.liuniu946.com')
+				// 	obj.$set(this, 'pics', this.pics);
+				// 	obj.$set(this, 'extract_pic', this.pics[0])
+				// });
+				// uploads({
+				// 	filename: ''
+				// }).then(data => {
+				// 	console.log("data",data);
+				// 	this.userInfo.avatar = data[0].url;
+				// })
+				upload({
+					filename: ''
+				}).then(res => {
+					console.log(res[0].url)
+					obj.userInfo.avatar = res[0].url
+					// console.log(obj.userInfo.avatar)
+				});
+			
+			},
+			edit() {
+				const that = this;
+				uni.showLoading({
+					title: '提交中...',
+					mask: true
+				})
+				edit({
+					avatar: this.userInfo.avatar,
+					nickname: this.userInfo.nickname
+				}).then(e => {
+					uni.hideLoading()
+					that.$api.msg('修改成功');
+					setTimeout(() => {
 						uni.switchTab({
-							url:'/pages/user/user'
+							url: '/pages/user/user'
 						});
 					}, 1000);
+				}).catch(e => {
 					console.log(e);
+					that.$api.msg('修改失败');
 				})
-				.catch(e => {
-					console.log(e);
-				});
+			}
 		}
-	}
-};
+	};
 </script>
 
-<style lang="scss">
-page {
-	background: $page-color-base;
-	padding-top: 16upx;
-}
+<style lang='scss'>
+	/* page{
+		background: $page-color-base;
+	}
+	.list-cell{
+		display:flex;
+		align-items:baseline;
+		padding: 20rpx $page-row-spacing;
+		line-height:60rpx;
+		position:relative;
+		background: #fff;
+		justify-content: center;
+		&.log-out-btn{
+			margin-top: 40rpx;
+			.cell-tit{
+				color: $uni-color-primary;
+				text-align: center;
+				margin-right: 0;
+			}
+		}
+		.cell-tit{
+			flex: 1;
+			font-size: $font-base + 2rpx;
+			color: $font-color-dark;
+			margin-right:10rpx;
+		}
+		.cell-tip{
+			font-size: $font-base;
+			color: $font-color-light;
+		}
+		switch{
+			transform: translateX(16rpx) scale(.84);
+		}
+	} */
+	page {
+		background-color: #f3f3f3;
+		min-height: 100%;
 
-.row {
-	display: flex;
-	align-items: center;
-	position: relative;
-	padding: 0 30upx;
-	height: 110upx;
-	background: #fff;
+		.container {
+			height: 100%;
 
-	.tit {
-		flex-shrink: 0;
-		width: 120upx;
-		font-size: 30upx;
-		color: $font-color-dark;
+		}
 	}
-	.input {
-		flex: 1;
-		font-size: 30upx;
-		color: $font-color-dark;
+
+	.row {
+		background-color: #fff;
+		padding: 42rpx 25rpx;
+		font-size: 30rpx;
+		color: #333333;
+
+		image {
+			width: 80rpx;
+			height: 80rpx;
+			border-radius: 50%;
+		}
+
+		.input {
+			text-align: right;
+			color: #333333;
+		}
+	}
+
+	.submit-box {
+		display: flex;
+		flex-direction: column;
+		padding-top: 157rpx;
+
+		.submit {
+			margin: 40rpx auto;
+			width: 560rpx;
+			background-color: #ff4c4b;
+			color: #FFFFFF;
+			text-align: center;
+			padding: 26rpx 0rpx;
+			border-radius: 50rpx;
+		}
+
+		.dl {
+			background-color: #FFFFFF;
+			color: #ff4c4b;
+		}
 	}
-	.iconlocation {
-		font-size: 36upx;
-		color: $font-color-light;
+
+	.jg {
+		margin-bottom: 20rpx;
 	}
-}
-.add-btn {
-	display: flex;
-	align-items: center;
-	justify-content: center;
-	width: 690upx;
-	height: 80upx;
-	margin: 60upx auto;
-	font-size: $font-lg;
-	color: #fff;
-	background-color: $base-color;
-	border-radius: 10upx;
-	// box-shadow: 1px 2px 5px rgba(219, 63, 96, 0.4);
-}
 </style>

+ 25 - 20
pages/user/cash.vue

@@ -6,21 +6,21 @@
 				<view class="goback-box" @click="toBack"><image class="goback" src="../../static/icon/fanhui.png" mode=""></image></view>
 				<view class="header">我的佣金</view>
 			</view>
-			<view class="content-bg"><image src="../../static/img/cash-bg.png" mode=""></image></view>
+			<view class="content-bg"></image></view>
 			<view class="money-box">
-				<view class="money">{{ userInfo.cash }}</view>
-				<view>我的现金</view>
+				<view class="money">{{ userInfo.brokerage_price ||'0.00' }}</view>
+				<view>余额</view>
 			</view>
 			<view class="moneybtn-box">
 				<view class="money-btn" @click="navto('/pages/money/withdmoenys?type=cash')">
 					<!-- 现金转账 -->
 				</view>
-				<view class="money-btn" @click="navto('/pages/user/withdrawal')">
-					现金提现
+				<view class="money-btn" style="margin-top: 60rpx;" @click="navto('/pages/user/withdrawal')">
+					现金提现>
 				</view>
 			</view>
 		</view>
-		<view class="info-box flex">
+		<!-- <view class="info-box flex">
 			<view class="info-item">
 				<view class="info-font">累计收入</view>
 				<view class="info-num">{{recharge}}</view>
@@ -30,7 +30,7 @@
 				<view class="info-font">累计支出</view>
 				<view class="info-num">{{orderStatusSum}}</view>
 			</view>
-		</view>
+		</view> -->
 		<view class="navbar">
 			<view v-for="(item, index) in navList" :key="index" class="nav-item" :class="{ current: tabCurrentIndex === index }" @click="tabClick(index)">{{ item.text }}</view>
 		</view>
@@ -65,7 +65,7 @@
 </template>
 
 <script>
-import { cashList, userBalance } from '@/api/wallet.js';
+import { cashList, userBalance,spreadCommission} from '@/api/wallet.js';
 import { getMoneyStyle } from '@/utils/rocessor.js';
 import { mapState, mapMutations } from 'vuex';
 import uniLoadMore from '@/uview-ui/components/u-loadmore/u-loadmore.vue';
@@ -104,7 +104,7 @@ export default {
 			recharge: 0,
 			navList: [
 				{
-					state: 1,
+					state: 3,
 					text: '收入',
 					loadingType: 'more',
 					orderList: [],
@@ -112,7 +112,7 @@ export default {
 					limit: 10 //每次信息条数
 				},
 				{
-					state: 0,
+					state: 4,
 					text: '支出',
 					loadingType: 'more',
 					orderList: [],
@@ -136,7 +136,9 @@ export default {
 		},
 		// 点击返回 我的页面
 		toBack() {
-			uni.navigateBack({});
+			uni.switchTab({
+				url:'./user'
+			})
 		},
 		//获取收入支出信息
 		async loadData(source) {
@@ -155,23 +157,25 @@ export default {
 			}
 			// 修改当前对象状态为加载中
 			navItem.loadingType = 'loading';
+			console.log(navItem.loadingType,'state');
 
-			cashList(
+			spreadCommission(
 				{
 					page: navItem.page,
 					limit: navItem.limit,
-					pm: state
-				}
+					
+				},state
 			)
 				.then(({ data }) => {
+					console.log(data,'data');
 					obj.recharge = data.income;
 					obj.orderStatusSum = data.expend;
-					if (data.list.length > 0) {
-						navItem.orderList = navItem.orderList.concat(data.list);
+					if (data.length > 0) {
+						navItem.orderList = navItem.orderList.concat(data[0].list);
 						console.log(navItem.orderList);
 						navItem.page++;
 					}
-					if (navItem.limit == data.list.length) {
+					if (navItem.limit == data.length) {
 						//判断是否还有数据, 有改为 more, 没有改为noMore
 						navItem.loadingType = 'more';
 						return;
@@ -213,6 +217,7 @@ page {
 	position: relative;
 	height: 480rpx;
 	.content-bg {
+		background: #303030;
 		position: absolute;
 		top: 0;
 		left: 0;
@@ -302,12 +307,12 @@ page {
 	justify-content: space-between;
 	position: relative;
 	z-index: 2;
-	color: #ffffff;
+	color:#F8DABA ;
 	padding:20rpx 50rpx ;
 	font-size: 30rpx;
 	font-family: PingFang SC;
 	font-weight: bold;
-	color: #FFFFFF;
+	color: #F8DABA;
 }
 .money-box {
 	position: relative;
@@ -354,7 +359,7 @@ page {
 				transform: translateX(-50%);
 				width: 44px;
 				height: 0;
-				border-bottom: 2px solid #fe5b38;
+				border-bottom: 2px solid #F8DABA;
 			}
 		}
 	}

+ 3 - 3
pages/user/team.vue

@@ -175,11 +175,11 @@ page {
 		top: 0;
 		left: 0;
 		right: 0;
-		width: 450rpx;
+		width: 750rpx;
 		margin: 0 auto;
 		height: 480rpx;
-		border-bottom-left-radius: 40%;
-		border-bottom-right-radius: 40%;
+		// border-bottom-left-radius: 10%;
+		// border-bottom-right-radius: 10%;
 		background: #303030;
 		// image {
 		// 	width: 100%;

+ 33 - 12
pages/user/user.vue

@@ -14,30 +14,30 @@
 					<image :src="userInfo.avatar || '../../static/error/missing-face.png'" mode=""></image>
 					<view class="user-font">
 						<view class="name clamp">{{ userInfo.nickname }}</view>
-						<view class="phone">{{ userInfo.phone }}</view>
+						<view class="phone">{{ getPhone }}</view>
 					</view>
 				</view>
-				<view class="kpi">
-					<image style="width: 19rpx; height: 19rpx;" src="../../static/icon/add.png" mode=""></image>会员VIP
+				<view class="kpi" v-show="userInfo.level!=0">
+					<image style="width: 34rpx; height: 34rpx; margin-right: 8rpx;" src="../../static/icon/vip.png" mode=""></image>会员VIP
 				</view>
 			</view>
 			<view class="info-right">
 				<view class="item-item" @click="navTo('/pages/money/wallet')">
-					<view class="item-num">{{ userInfo.sp_final || 0}}</view>
+					<view class="item-num">{{ userInfo.now_money || 0}}</view>
 					<view class="item-font">我的钱包</view>
 				</view>
 				<view class="" style="width: 1rpx;height: 100rpx;background: #EEEEEE;">
 
 				</view>
 				<view class="item-item" @click="navTo('/pages/user/cash')">
-					<view class="item-num">{{userInfo.top_ticket || 0}}</view>
+					<view class="item-num">{{userInfo.brokerage_price || 0}}</view>
 					<view class="item-font">我的佣金</view>
 				</view>
 				<view class="" style="width: 1rpx;height: 100rpx;background: #EEEEEE;">
 
 				</view>
 				<view class="item-item" @click="navTo('/pages/user/team')">
-					<view class="item-num">{{userInfo.aid_val || 0}}</view>
+					<view class="item-num">{{all || 0}}</view>
 					<view class="item-font">我的推广</view>
 				</view>
 			</view>
@@ -75,8 +75,10 @@
 			</uni-list-item>
 			<uni-list-item title="我的收藏" @click="navTo('/pages/user/favorites')" thumb="/static/user/user11.png">
 			</uni-list-item>
+			<!-- <uni-list-item title="点击试试" @click="navTo('/pages/public/login')" thumb="/static/user/user11.png">
+			</uni-list-item> -->
 			<uni-list-item title="客服中心" @click="openKf()" thumb="/static/user/user09.png"></uni-list-item>
-			<uni-list-item title="设置" @click="navTo('/pages/set/set')" thumb="/static/user/user13.png"></uni-list-item>
+			<uni-list-item title="设置" @click="navTo('/pages/set/userinfo')" thumb="/static/user/user13.png"></uni-list-item>
 		</uni-list>
 		<uni-popup ref="popupkf" type="center">
 			<view class="popup-box">
@@ -124,9 +126,10 @@
 	} from 'vuex';
 	import uniList from '@/components/uni-list/uni-list.vue';
 	import uniListItem from '@/components/uni-list-item/uni-list-item.vue';
+	
 	import {
 		orderData,
-		getUserInfo
+		getUserInfo,myspread
 	} from '@/api/user.js';
 	import {
 		saveUrl,
@@ -142,6 +145,7 @@
 		},
 		data() {
 			return {
+				all:0,//推荐人数
 				current: 4,
 				tabbar: tabbar1,
 				qded: false, //是否已签到
@@ -207,6 +211,11 @@
 			// 判断是否已经登录
 			if (this.hasLogin) {
 				this.loadBaseData();
+				myspread({
+				}).then(({ data }) => {
+					console.log(data,'推荐人');
+						this.all = data.total;
+					})
 			}
 			this.loadBaseData();
 		},
@@ -247,12 +256,17 @@
 		// },
 		// #endif
 		computed: {
-			...mapState('user', ['userInfo', 'orderInfo', 'hasLogin'])
+			...mapState('user', ['userInfo', 'orderInfo', 'hasLogin']),
+			getPhone(){
+				let reg= /^(\d{3})\d{4}(\d{4})$/;
+			 return	this.userInfo.phone.replace(reg,'$1****$2')
+			}
 		},
 		methods: {
 			...mapMutations('user', ['setUserInfo', 'setOrderInfo']),
 			// 加载初始数据
 			loadBaseData() {
+				console.log(this.userInfo,'info');
 				getUserInfo({})
 					.then(({
 						data
@@ -285,6 +299,12 @@
 			 */
 			navTo(url) {
 				console.log(url);
+				let pages = getCurrentPages();
+				console.log(pages,'pages');
+				
+				let prevPage = pages[pages.length-2]
+				console.log(prevPage,'pages2');
+			
 				// if (!this.hasLogin) {
 				// 	// 保存地址
 				// 	saveUrl();
@@ -577,6 +597,7 @@
 			align-items: center;
 			margin: 30rpx 0;
 			padding: 0 34rpx;
+
 			.item-item {
 				padding-bottom: 20rpx;
 				width: 33%;
@@ -584,13 +605,13 @@
 				justify-content: center;
 				flex-direction: column;
 				align-items: center;
-			
+
 				.item-num {
 					font-size: 36rpx;
 					font-weight: bold;
 					color: #333333;
 				}
-			
+
 				.item-font {
 					margin-top: 18rpx;
 					font-size: 22rpx;
@@ -657,7 +678,7 @@
 		.main {
 			padding: 30rpx 0 20rpx;
 
-		
+
 
 			.oitem {
 				width: 25%;

+ 17 - 13
pages/user/withdrawal.vue

@@ -4,7 +4,7 @@
 		<view class="content-money">
 			<view class="flex " style="width: 750rpx;justify-content: space-around;margin-left: 0;">
 				<view class="buttom">
-					<view class="icon">{{ userInfo.cash | getMoneyStyle }}</view>
+					<view class="icon">{{ userInfo.brokerage_price | getMoneyStyle }}</view>
 					<text class="text">可提现现金</text>
 				</view>
 			</view>
@@ -15,11 +15,11 @@
 			<view class="row">
 				<text class="tit">¥</text>
 				<input class="input" type="number" v-model="withdrawal" :placeholder="'最低提现金额' + minPrice + '元'" placeholder-class="placeholder" />
-				<view class="buttom" @click="withdrawal = userInfo.cash">全部提现</view>
+				<view class="buttom" @click="withdrawal = userInfo.brokerage_price">全部提现</view>
 			</view>
 		</view>
 		<view class="tip" v-if="withdrawal != 0">
-			实际到账 {{ real }}元
+			实际到账 {{ real || "0"}}元
 		</view>
 		<!-- #ifndef MP-WEIXIN -->
 		<view class="list" >
@@ -33,7 +33,7 @@
 						<view class="right"><radio value="weixin" color="#5dbc7c" :checked="type == 'weixin'" /></view>
 					</view>
 				</label> -->
-				<label>
+				<!-- <label>
 					<view class="box">
 						<view class="icon iconfont iconzhifubao"></view>
 						<view class="title-box">
@@ -47,7 +47,7 @@
 						</view>
 						<view class="right"><radio value="alipay" color="#F8DABA" :checked="type == 'alipay'" /></view>
 					</view>
-				</label>
+				</label> -->
 				<label>
 					<view class="box">
 						<view class="icon iconfont"><image class="icon-img" src="/static/icon/i8.png" mode="aspectFit"></image></view>
@@ -66,14 +66,14 @@
 			</radio-group>
 		</view>
 		<!-- #endif -->
-		<view class="row b-b" v-if="type == 'alipay'">
+	<!-- 	<view class="row b-b" v-if="type == 'alipay'">
 			<text class="tit">支付宝账号</text>
 			<input class="input" type="text" v-model="alipay_code" placeholder="请输入支付宝账号" placeholder-class="placeholder" />
 		</view>
 		<view class="row b-b" v-if="type == 'alipay'">
 			<text class="tit">支付宝姓名</text>
 			<input class="input" type="text" v-model="alipay_name" placeholder="请输入支付宝姓名" placeholder-class="placeholder" />
-		</view>
+		</view> -->
 		<view class="row b-b" v-if="type == 'bank'">
 			<text class="tit">银行卡号</text>
 			<input class="input" type="text" v-model="bank_code" placeholder="请输入银行卡号" placeholder-class="placeholder" />
@@ -156,6 +156,7 @@ export default {
 		// 切换选中对象
 		tabRadio(e) {
 			this.type = e.detail.value;
+			console.log(this.type);
 		},
 		// 提交
 		confirm() {
@@ -180,7 +181,7 @@ export default {
 				data.alipay_code = this.alipay_code;
 			}
 			if (this.type == 'bank') {
-				console.log(bank);
+				// console.log(bank,'bank');
 				data.name = this.bank_people;
 				data.bankname = this.bank_name;
 				data.cardnum = this.bank_code;
@@ -195,11 +196,14 @@ export default {
 						.catch(e => {
 							console.log(e);
 						});
-					uni.showToast({
-						title: '提交成功',
-						duration: 2000,
-						position: 'top'
-					});
+						uni.navigateTo({
+							url:'../money/paySuccess'
+						})
+					// uni.showToast({
+					// 	title: '提交成功',
+					// 	duration: 2000,
+					// 	position: 'top'
+					// });
 				})
 				.catch(e => {
 					console.log();

BIN
static/icon/vip.png


BIN
static/img/list01.png


BIN
static/img/list02.png


BIN
static/img/list03.png


BIN
static/img/paySuccess1.png


BIN
static/img/success.png


BIN
static/img/weixin.png


BIN
static/img/yue.png


BIN
static/index/huo.png


+ 1 - 1
store/index.js

@@ -12,7 +12,7 @@ Vue.use(Vuex)
 const store = new Vuex.Store({
 	state: {
 		// baseURL:"http://yrh.liuniu946.com",//'http://eb.shuibo.net',//请求地址配置 
-		baseURL:'https://xl.liuniu946.com',//请求地址配置 
+		baseURL:'https://hy.liuniu946.com',//请求地址配置 
 		// baseURL:'http://lnpt.frp.liuniu946.com/',//请求地址配置 
 		urlFile:'/index',//项目部署所在文件夹
 		userInfo: {}, //登录信息