浏览代码

feat:商品详情

jinchaoyu 1 年之前
父节点
当前提交
be6b401fa4

+ 98 - 60
components/productConSwiperGroupbuying/index.vue

@@ -1,81 +1,119 @@
 <template>
 	<view class='product-bg'>
-		<u-swiper name="image"  @click="openImg" :list="imgUrls" indicator-pos="topLeft " mode="number"></u-swiper>
+
+		<u-swiper @click="openImg" :list="swiperTabList" @change="e => currentNum = e.current" :autoplay="false"
+			indicatorStyle="	position: absolute;top: 10px !important;left: 10px !important;">
+			<view slot="indicator" class="indicator-num">
+				<text class="indicator-num__text">{{ currentNum + 1 }}/{{ swiperTabList.length }}</text>
+			</view>
+		</u-swiper>
 	</view>
 </template>
 
 <script>
-	export default {
-		props: {
-			imgUrls: {
-				type: Array,
-				default: function() {
-					return [];
-				}
-			},
-			videoline: {
-				type: String,
-				value: ""
+export default {
+	props: {
+		imgUrls: {
+			type: Array,
+			default: function () {
+				return [];
 			}
 		},
-		data() {
-			return {
-				indicatorDots: true,
-				circular: true,
-				autoplay: true,
-				interval: 3000,
-				duration: 500,
-				currents: "1",
-				controls: true,
-				isPlay:true,
-				videoContext:''
-			};
+		videoline: {
+			type: String,
+			value: ""
+		}
+	},
+	data () {
+		return {
+			swiperTabList: ['https://yj-bucket-67ff.obs.cn-southwest-2.myhuaweicloud.com/upload/20230515/948f6d74dd7ccbcb3fc4c0d1e1282f9e.jpg', 'https://yj-bucket-67ff.obs.cn-southwest-2.myhuaweicloud.com/upload/20230522/6cf788d4130dd00c7a5ace07f302e99a.jpg'],
+			indicatorDots: true,
+			currentNum: 0,
+			circular: true,
+			autoplay: true,
+			interval: 3000,
+			duration: 500,
+			currents: "1",
+			controls: true,
+			isPlay: true,
+			videoContext: ''
+		};
+	},
+	mounted () {
+		console.log(this.imgUrls, 'imgUrls..........');
+		if (this.videoline) {
+			this.imgUrls.shift()
+		}
+		// #ifndef APP-PLUS
+		this.videoContext = uni.createVideoContext('myVideo', this);
+		// #endif
+	},
+	methods: {
+		openImg (index) {
+			uni.previewImage({
+				current: index,
+				urls: this.imgUrls,
+				indicator: 'number',
+				loop: true
+			});
 		},
-		mounted() {
-			console.log(this.imgUrls,'imgUrls..........');
-			if(this.videoline){
-				this.imgUrls.shift()
-			}
+		videoPause (e) {
+			// #ifdef APP-PLUS
+			this.isPlay = true
+			this.autoplay = true
+			// #endif
+		},
+		bindPause: function () {
+
 			// #ifndef APP-PLUS
+			this.videoContext.play();
+			this.$set(this, 'controls', false)
+			this.autoplay = false
+			// #endif
+			// #ifdef APP-PLUS
+			this.isPlay = false
 			this.videoContext = uni.createVideoContext('myVideo', this);
+			this.videoContext.play();
 			// #endif
 		},
-		methods: {
-			openImg (index){
-				uni.previewImage({
-					current: index,
-					urls: this.imgUrls,
-					indicator: 'number',
-					loop: true
-				});
-			},
-			videoPause(e){
-				// #ifdef APP-PLUS
-				this.isPlay= true
-				this.autoplay = true
-				// #endif
-			},
-			bindPause: function() {
-				
-				// #ifndef APP-PLUS
-				this.videoContext.play();
-				this.$set(this, 'controls', false)
-				this.autoplay = false
-				// #endif
-				// #ifdef APP-PLUS
-				this.isPlay= false
-				this.videoContext = uni.createVideoContext('myVideo', this);
-				this.videoContext.play();
-				// #endif
-			},
-			change: function(e) {
-				this.$set(this, 'currents', e.detail.current + 1);
-			}
+		change: function (e) {
+			this.$set(this, 'currents', e.detail.current + 1);
 		}
 	}
+}
 </script>
 
 <style scoped lang="scss">
+.indicator {
+	@include flex(row);
+	justify-content: center;
+
+	&__dot {
+		height: 6px;
+		width: 6px;
+		border-radius: 100px;
+		background-color: rgba(255, 255, 255, 0.35);
+		margin: 0 5px;
+		transition: background-color 0.3s;
 
+		&--active {
+			background-color: #ffffff;
+		}
+	}
+}
 
+
+.indicator-num {
+	padding: 2px 0;
+	background-color: rgba(0, 0, 0, 0.35);
+	border-radius: 100px;
+	width: 35px;
+	@include flex;
+	justify-content: center;
+
+	&__text {
+		color: #FFFFFF;
+		font-size: 12px;
+	}
+}
 </style>

+ 284 - 0
pages/groupbuying_details/detail/index.vue

@@ -0,0 +1,284 @@
+<template>
+	<view class="detail" style="    padding: 30rpx;">
+
+		<scroll-view scroll-y="true" scroll-with-animation='true' style="height: calc(100% - 100rpx)">
+
+			<view class="detail-img">
+				<image
+					src="https://lanhu-dds-backend.oss-cn-beijing.aliyuncs.com/merge_image/imgs/38e693de009644aa9de2dc6d6f7e747a_mergeImage.png"
+					mode="scaleToFill" />
+			</view>
+			<view class="detail-content">
+				<view style="display:flex; 	margin-bottom: 20rpx;">
+					<text class="red"> ¥48.00</text>
+					<text class="line-thr">¥52.00</text>
+				</view>
+				<view class="detail-content-t">
+					宫中秘策(GOONGBE)进口儿童韩国进口儿童防晒霜80g
+				</view>
+				<view class='time '>
+					<image src="http://www.gzzzyd.com/groupon/home_slices/编辑@2x.png" mode="scaleToFill" />
+					发布于:
+					<text class="imp_info">
+						1天20小时36分钟前
+					</text>
+				</view>
+			</view>
+
+			<view class="detail-info">
+				<view class="title">
+					商品信息
+				</view>
+			</view>
+		</scroll-view>
+
+		<view class="footer acea-row row-between-wrapper">
+				<!-- <button open-type="contact" hover-class='none' class='item'>
+						<view class='iconfont icon-kefu'></view>
+						<view>客服</view>
+					</button> -->
+
+				<navigator hover-class="none" class="item skeleton-rect" open-type="switchTab" url="/pages/index/index">
+					<view class="iconfont icon-shouye6"></view>
+					<view class="p_center">{{ $t(`首页`) }}</view>
+				</navigator>
+
+					<view style="    margin-right: 30rpx;">
+						<view class="bnt acea-row">
+							<view class="buy-box" @submit="goBuy">
+								<button class="share-btn ">
+									分享有礼
+								</button>
+								<button class="now-btn ">
+									立即购买
+								</button>
+							</view>
+						</view>
+					</view>
+
+			</view>
+
+	</view>
+</template>
+
+<script>
+import {
+	userEdit,
+} from '@/api/user.js';
+
+import {
+	toLogin
+} from '@/libs/login.js';
+import {
+	mapGetters
+} from "vuex";
+import dayjs from "@/plugin/dayjs/dayjs.min.js";
+// #ifdef MP
+import authorize from '@/components/Authorize';
+// #endif
+import colors from '@/mixins/color.js';
+
+export default {
+	components: {
+		// #ifdef APP-PLUS
+		appUpdate,
+		// #endif
+		// #ifdef MP
+		authorize
+		// #endif
+	},
+	mixins: [colors],
+	data () {
+		return {
+		};
+	},
+	computed: mapGetters(['isLogin']),
+	watch: {
+		isLogin: {
+			handler: function (newV, oldV) {
+				if (newV) {
+					this.getUserInfo();
+				}
+			},
+			deep: true
+		}
+	},
+	onLoad () {
+
+		if (this.isLogin) {
+			this.getUserInfo();
+			// #ifdef APP-PLUS
+			this.formatSize()
+			// 获取版本号
+			plus.runtime.getProperty(plus.runtime.appid, (inf) => {
+				console.log(inf.version)
+				this.version = inf.version;
+			});
+			// #endif 
+			this.setLang();
+		} else {
+			toLogin();
+		}
+	},
+	methods: {
+
+		formSubmit: function (e) {
+			let that = this,
+				value = e.detail.value,
+				userInfo = that.switchUserInfo[that.userIndex];
+			if (!value.nickname) return that.$util.Tips({
+				title: that.$t(`请输入姓名`)
+			});
+			value.avatar = this.userInfo.avatar;
+			userEdit(value).then(res => {
+				return that.$util.Tips({
+					title: res.msg,
+					icon: 'success'
+				}, {
+					tab: 3,
+					url: 1
+				});
+			}).catch(msg => {
+				return that.$util.Tips({
+					title: msg || that.$t(`保存失败`)
+				}, {
+					tab: 3,
+					url: 1
+				});
+			});
+		}
+	}
+}
+</script>
+
+<style scoped lang="scss">
+.time {
+	height: 44rpx;
+	font-size: 24rpx;
+	font-weight: 400;
+	color: #999999;
+	line-height: 44rpx;
+
+	image {
+		width: 40rpx;
+		height: 40rpx;
+		margin: 0 10rpx;
+		vertical-align: middle;
+	}
+
+	.imp_info {
+		height: 44rpx;
+		font-size: 24rpx;
+		font-weight: 400;
+		color: #333333;
+		line-height: 44rpx;
+	}
+}
+
+.detail {
+	height: 80vh;
+}
+
+.detail-img {
+	image {
+		width: 702rpx;
+		height: 702rpx;
+	}
+
+	margin-bottom: 20rpx;
+}
+
+.detail-content-t {
+	flex: 1;
+	font-size: 20rpx;
+	font-weight: 400;
+	color: #333333;
+	line-height: 28rpx;
+	margin-bottom: 20rpx;
+}
+
+.detail-content {
+	.red {
+		display: block;
+		font-size: 28rpx;
+		font-weight: 500;
+		color: #B22338 !important;
+		margin-right: 10rpx;
+	}
+
+	.line-thr {
+		display: block;
+		font-size: 28rpx;
+		font-weight: 400;
+		color: #999999;
+		text-decoration: line-through;
+	}
+}
+
+.detail-info {
+	.title {
+		margin: 30rpx 0;
+		height: 44rpx;
+		font-size: 32rpx;
+		font-weight: 500;
+		color: #111111;
+		line-height: 44rpx;
+	}
+}
+
+
+.footer {
+	padding: 0 20rpx 0 10rpx;
+	position: fixed;
+	bottom: 0;
+	width: 100%;
+	box-sizing: border-box;
+	background-color: #fff;
+	z-index: 277;
+	border-top: 1rpx solid #f0f0f0;
+	height: 100rpx;
+	height: calc(100rpx+ constant(safe-area-inset-bottom)); ///兼容 IOS<11.2/
+	height: calc(100rpx + env(safe-area-inset-bottom)); ///兼容 IOS>11.2/
+}
+ .footer .item .iconfont {
+	text-align: center;
+	font-size: 40rpx;
+}
+ .footer .item .iconfont.icon-shoucang1 {
+	color: var(--view-theme);
+}
+ .footer .item .iconfont.icon-gouwuche1 {
+	font-size: 40rpx;
+	position: relative;
+}
+
+.buy-box{
+	display: flex;
+	width: 100%;
+}
+.share-btn{
+	width: 280rpx;
+height: 84rpx;
+background: #F1F8E5;
+border-radius: 54rpx 0rpx 0rpx 54rpx;
+
+font-size: 28rpx;
+font-weight: 400;
+color: #75BE00;
+line-height: 84rpx;
+
+
+}
+.now-btn{
+	width: 280rpx;
+height: 84rpx;
+background: #B42A3E;
+border-radius: 0rpx 54rpx 54rpx 0rpx;
+font-size: 28rpx;
+font-weight: 400;
+color: #fff;
+line-height: 84rpx;
+
+
+}
+</style>

+ 167 - 184
pages/groupbuying_details/index.vue

@@ -17,7 +17,6 @@
 						<!-- #ifdef APP-PLUS || MP -->
 						<view class="" :style="'width:100%;' + 'height:' + sysHeight"></view>
 						<!-- #endif -->
-						{{ storeInfo }}
 						<productConSwiperGroupbuying class="skeleton-rect" :imgUrls="storeInfo.imgList"
 							:videoline="storeInfo.video_link" @videoPause="videoPause"></productConSwiperGroupbuying>
 
@@ -25,7 +24,8 @@
 							<view class="home">
 								<view class="count">共24个</view>
 								<scroll-view scroll-x class="navscroll"> <!-- 设置滚动条方向为横向 -->
-									<view style="width: 108rpx;height: 108rpx; margin-right: 20rpx;" class="item" v-for="item in 24">
+									<view style="width: 108rpx;height: 108rpx; margin-right: 20rpx; padding: 0;" class="item"
+										v-for="item in 24">
 										<!-- 通过for循环生成view -->
 										<image style="width: 108rpx;height: 108rpx;"
 											src="https://lanhu-dds-backend.oss-cn-beijing.aliyuncs.com/merge_image/imgs/38e693de009644aa9de2dc6d6f7e747a_mergeImage.png"
@@ -45,18 +45,21 @@
 										storeInfo.vip_price > 0 &&
 										storeInfo.is_vip == 1 &&
 										svip_price_open == 1
-										">{{ $t(`¥`) }}{{ storeInfo.vip_price }}</text>
+									">{{ $t(`¥`) }}{{ storeInfo.vip_price }}</text>
 									<image v-if="storeInfo.vip_price &&
 										storeInfo.vip_price > 0 &&
 										storeInfo.is_vip == 1 &&
 										svip_price_open == 1
-										" src="../../static/images/svip.gif"></image>
+									" src="../../static/images/svip.gif"></image>
 								</view>
 								<!-- <view class="iconfont icon-fenxiang skeleton-rect" @click="listenerActionSheet"></view> -->
 							</view>
 							<view class="introduce skeleton-rect" v-text="storeInfo.goodsName"></view>
 							<view class='info-area'>
 								<view class='time '>
+									<image src="http://www.gzzzyd.com/groupon/home_slices/编辑@2x.png" mode="scaleToFill" />
+
+
 									发布于:
 									<text class="imp_info">
 										1天20小时36分钟前
@@ -64,6 +67,7 @@
 								</view>
 								<view class='view-count '>
 									726人浏览过
+									<image src="http://www.gzzzyd.com/groupon/home_slices/浏览@2x.png" mode="scaleToFill" />
 								</view>
 							</view>
 							<view class="countdown flex-row">
@@ -78,8 +82,7 @@
 									<text class="yellow">正在参团中</text>
 								</view>
 								<view class="countdown-r">
-									<image class="icon_5" referrerpolicy="no-referrer"
-										src="http://wine.gzzzyd.com/test/static/img/bg.a82f9752.jpg" />
+									<image src="http://www.gzzzyd.com/groupon/home_slices/倒计时@2x.png" mode="scaleToFill" />
 									<text class="yellow">截止倒计时</text>
 									<text class="red2">02时25分19秒</text>
 								</view>
@@ -159,7 +162,7 @@
 								</view>
 
 								<view class="all-products-body">
-									<view class="all-products-item">
+									<view class="all-products-item" @click="addGoodPopupShow = true">
 										<image
 											src="https://lanhu-dds-backend.oss-cn-beijing.aliyuncs.com/merge_image/imgs/38e693de009644aa9de2dc6d6f7e747a_mergeImage.png"
 											mode="scaleToFill" />
@@ -169,9 +172,51 @@
 												宫中秘策(GOONGBE)进口儿童韩国进口儿童防晒霜80g
 											</view>
 											<view class="all-products-item-content-b">
+												<view style="display:flex;">
+													<text class="red"> ¥48.00</text>
+													<text class="line-thr">¥52.00</text>
+												</view>
+
 												<view>
-													<text> ¥48.00</text>
-													<text>¥52.00</text>
+													<u-number-box v-model="value" @change="valChange"></u-number-box>
+												</view>
+											</view>
+										</view>
+									</view>
+									<view class="all-products-item" @click="addGoodPopupShow = true">
+										<image
+											src="https://lanhu-dds-backend.oss-cn-beijing.aliyuncs.com/merge_image/imgs/38e693de009644aa9de2dc6d6f7e747a_mergeImage.png"
+											mode="scaleToFill" />
+
+										<view class="all-products-item-content">
+											<view class="all-products-item-content-t">
+												宫中秘策(GOONGBE)进口儿童韩国进口儿童防晒霜80g
+											</view>
+											<view class="all-products-item-content-b">
+												<view style="display:flex;">
+													<text class="red"> ¥48.00</text>
+													<text class="line-thr">¥52.00</text>
+												</view>
+
+												<view>
+													<u-number-box v-model="value" @change="valChange"></u-number-box>
+												</view>
+											</view>
+										</view>
+									</view>
+									<view class="all-products-item" @click="addGoodPopupShow = true">
+										<image
+											src="https://lanhu-dds-backend.oss-cn-beijing.aliyuncs.com/merge_image/imgs/38e693de009644aa9de2dc6d6f7e747a_mergeImage.png"
+											mode="scaleToFill" />
+
+										<view class="all-products-item-content">
+											<view class="all-products-item-content-t">
+												宫中秘策(GOONGBE)进口儿童韩国进口儿童防晒霜80g
+											</view>
+											<view class="all-products-item-content-b">
+												<view style="display:flex;">
+													<text class="red"> ¥48.00</text>
+													<text class="line-thr">¥52.00</text>
 												</view>
 
 												<view>
@@ -223,97 +268,30 @@
 					</view>
 				</scroll-view>
 			</view>
-			<!-- <view class="uni-p-b-98"></view> -->
 			<view class="footer acea-row row-between-wrapper">
-				<!-- <button open-type="contact" hover-class='none' class='item'>
-						<view class='iconfont icon-kefu'></view>
-						<view>客服</view>
-					</button> -->
-
 				<navigator hover-class="none" class="item skeleton-rect" open-type="switchTab" url="/pages/index/index">
 					<view class="iconfont icon-shouye6"></view>
 					<view class="p_center">{{ $t(`首页`) }}</view>
 				</navigator>
-				<!-- <view @click="setCollect" class="item skeleton-rect">
-					<view class="iconfont icon-shoucang1" v-if="storeInfo.userCollect"></view>
-					<view class="iconfont icon-shoucang" v-else></view>
-					<view class="p_center">{{ $t(`收藏`) }}</view>
-				</view> -->
-
-				<view v-if="a" class="presale">
-					<view class="acea-row">
-						<form class=" bnts bg-color-hui"><button class=" bnts bg-color-hui" form-type="submit">{{
-							$t(`暂无产品`)
-						}}</button></form>
-					</view>
-				</view>
-				<view v-else>
-					<view v-if="storeInfo.isSale">
-						<view class="bnt acea-row" :class="!storeInfo.cart_button ? 'virbnt' : ''" v-if="!availableCheck">
-							<form v-if="storeInfo.cart_button" @submit="joinCart" class="joinCart bnts"
-								:class="!storeInfo.cart_button ? 'virbnt' : ''">
-								<button class="joinCart bnts" form-type="submit">
-									{{ $t(`加入购物车`) }}
-								</button>
-							</form>
-							<form class="buy bnts bg-color-hui">
-								<button class="buy bnts bg-color-hui" form-type="submit" :class="!storeInfo.cart_button ? 'virbnt' : ''">
-									{{ $t(`已售罄`) }}
-								</button>
-							</form>
-						</view>
-						<view class="bnt acea-row" :class="!storeInfo.cart_button ? 'virbnt' : ''" v-else>
-							<form v-if="storeInfo.cart_button" @submit="joinCart" class="joinCart bnts"
-								:class="!storeInfo.cart_button ? 'virbnt' : ''">
-								<button class="joinCart bnts" form-type="submit">
-									{{ $t(`加入购物车`) }}
-								</button>
-							</form>
-							<view class="buy bnts bg-color-hui" @submit="goBuy">
-								<button class="buy bnts ">
-									分享有礼
-								</button>
-								<button class="buy bnts " :class="!storeInfo.cart_button ? 'virbnt' : ''">
-									立即购买
-								</button>
-							</view>
-						</view>
-					</view>
-					<view class="presale" v-else>
-						<view class="acea-row" v-if="presale_pay_status === 1 || presale_pay_status === 3">
-							<form class="bnts bg-color-hui"><button class="bnts bg-color-hui" form-type="submit">{{
-								presale_pay_status === 1 ? $t(`未开始售卖`) : $t(`已结束`)
-							}}</button>
-							</form>
-						</view>
-						<view class="acea-row"
-							v-else-if="attr.productSelect.quota <= 0 || attr.productSelect.quota < attr.productSelect.totalSales">
-							<form class=" bnts bg-color-hui"><button class=" bnts bg-color-hui" form-type="submit">{{
-								$t(`已售罄`)
-							}}</button></form>
-						</view>
-						<view class="bnts acea-row" v-else-if="presale_pay_status === 2">
-							<form @submit="goBuy" class="bnts"><button class="bnts" form-type="submit">{{ $t(`立即购买`)
-							}}</button>
-							</form>
+
+				<view style="    margin-right: 30rpx;">
+					<view class="bnt acea-row">
+						<view class="buy-box" @submit="goBuy">
+							<button class="share-btn ">
+								分享有礼
+							</button>
+							<button class="now-btn ">
+								立即购买
+							</button>
 						</view>
 					</view>
 				</view>
 
-				<!-- 	<view v-else>
-						<view class="virbnt acea-row" :class="storeInfo.is_virtual?'virbnt':''" v-if="attr.productSelect.stock <= 0">
-							<form class="buy bnts bg-color-hui"><button class="virbuy virbnts bg-color-hui"
-									form-type="submit">已售罄</button></form>
-						</view>
-						<view class="virbnt acea-row" v-else>
-							<form @submit="goBuy" class="buy bnts"><button class="virbuy virbnts" form-type="submit">立即购买</button>
-							</form>
-						</view>
-					</view> -->
 			</view>
-			<shareRedPackets :sharePacket="sharePacket" @listenerActionSheet="listenerActionSheet" @closeChange="closeChange"
-				:showAnimate="showAnimate" @boxStatus="boxStatus">
-			</shareRedPackets>
+
+
+
+
 			<!-- 组件 -->
 			<productWindow v-if="attr.cartAttr" :attr="attr" :isShow="1" :iSplus="1" @myevent="onMyEvent"
 				@ChangeAttr="ChangeAttr" @ChangeCartNum="ChangeCartNum" @attrVal="attrVal" @iptCartNum="iptCartNum"
@@ -384,6 +362,17 @@
 			</view>
 
 		</view>
+
+
+
+		<u-popup :show="addGoodPopupShow" @close="addGoodPopupShow = false" @open="	">
+			<view>
+				<detail v-if="addGoodPopupShow"></detail>
+			</view>
+		</u-popup>
+
+
+
 	</view>
 </template>
 
@@ -417,6 +406,9 @@ import {
 	mapGetters
 } from "vuex";
 
+
+
+import detail from './detail/index.vue'
 import cusPreviewImg from "@/components/cusPreviewImg/index.vue";
 import productConSwiperGroupbuying from "@/components/productConSwiperGroupbuying";
 import couponListWindow from "@/components/couponListWindow";
@@ -451,14 +443,14 @@ export default {
 		couponListWindow,
 		productWindow,
 		userEvaluation,
-		shareRedPackets,
 		kefuIcon,
 		cusPreviewImg,
 		// #ifdef MP
 		authorize,
 		// #endif
 		parser,
-		homeList
+		homeList,
+		detail
 	},
 	directives: {
 		trigger: {
@@ -473,11 +465,12 @@ export default {
 		return {
 			albumWidth: 0,
 			availableCheck: false,
+			addGoodPopupShow: false,
 			attrAddrValue: '请选择收获地址',
 			imgHost: HTTP_REQUEST_URL,
 			sysHeight: sysHeight,
 			a: false,
-			showSkeleton: true, //骨架屏显示隐藏
+			showSkeleton: false, //骨架屏显示隐藏
 			isNodes: 0, //控制什么时候开始抓取元素节点,只要数值改变就重新抓取
 			Active: false,
 			presale_pay_status: 1,
@@ -644,7 +637,6 @@ export default {
 				}
 				this.sharePacket.isCanShare = false
 				this.sharePacket.isFristUrl = true
-				this.listenerActionSheet()
 			}
 			let that = this;
 			var pages = getCurrentPages();
@@ -692,43 +684,25 @@ export default {
 			//记录推广人uid
 			if (options.spid) app.globalData.spid = options.spid;
 			// #endif
-			that.getGoodsDetails();
+			// that.getGoodsDetails();
 			// that.getCouponList(0);
-			//#ifdef H5
-			that.isLogin && silenceBindingSpread();
-			//#endif
+
 		}
 	},
 	onReady: function () {
 		this.isNodes++;
-		// #ifdef H5
-		this.codeVal = window.location.origin + '/pages/goods_details/index?id=' + this.id +
-			'&spid=' + this.$store.state.app.uid
-		// #endif	
-		// #ifdef APP-PLUS
-		this.codeVal = HTTP_REQUEST_URL + '/pages/goods_details/index?id=' + this.id +
-			'&spid=' + this.$store.state.app.uid
-		// #endif	
-		this.$nextTick(function () {
-			// #ifdef MP
-			const menuButton = uni.getMenuButtonBoundingClientRect();
-			const query = uni.createSelectorQuery().in(this);
-			query
-				.select("#home")
-				.boundingClientRect((data) => {
-					this.homeTop = menuButton.top * 2 + menuButton.height - data.height || 0;
-				})
-				.exec();
-			// #endif
-			// #ifdef H5
-			const clipboard = new ClipboardJS(".copy-data");
-			clipboard.on("success", () => {
-				this.$util.Tips({
-					title: this.$t(`复制成功`),
-				});
-			});
-			// #endif
-		});
+		// this.$nextTick(function () {
+		// 	// #ifdef MP
+		// 	const menuButton = uni.getMenuButtonBoundingClientRect();
+		// 	const query = uni.createSelectorQuery().in(this);
+		// 	query
+		// 		.select("#home")
+		// 		.boundingClientRect((data) => {
+		// 			this.homeTop = menuButton.top * 2 + menuButton.height - data.height || 0;
+		// 		})
+		// 		.exec();
+		// 	// #endif
+		// });
 	},
 	/**
 	 * 用户点击右上角分享
@@ -1461,62 +1435,7 @@ export default {
 		 */
 		listenerActionSheet () {
 			this.currentPage = false
-			if (this.isLogin === false) {
-				toLogin();
-			} else {
-				// 校验是否可以分享(先购买产品)
-				if (!this.sharePacket.isCanShare) {
-					postLinkedUrl().then(res => {
-						if (res.msg == '暂无承载数据') {
-							if (this.sharePacket.isFristUrl) {
-								if (this.promotionNo) {
-									this.$Cache.set('INVITE_CODE', this.promotionNo);
-								} else {
-									// this.$Cache.set('INVITE_CODE', '');
-								}
-								this.sharePacket.isFristUrl = false
-							} else {
-								this.$util.Tips({
-									title: this.$t(`请先购买共富1580商品`),
-								});
-							}
-						} else {
-							uni.showShareMenu();
-							this.sharePacket.isCanShare = true
-							//判断是否为自己的要求码进入
-							if (this.promotionNo !== res.data.promotionNo) {
-								if (this.promotionNo) {
-									this.$Cache.set('INVITE_CODE', this.promotionNo);
-								}
-							}
-							this.promotionShare = res.data.promotionNo
-						}
 
-						// this.downloadFilePromotionCode();
-						// this.posters = true;
-					})
-				}
-				// if (this.posterImage) {
-				// 	this.posters = true;
-				// 	return
-				// }
-				// // #ifdef H5
-				// if (this.$wechat.isWeixin() === true) {
-				// 	this.weixinStatus = true;
-				// }
-				// // #endif
-				// // #ifndef APP-PLUS
-				// this.downloadFilePromotionCode();
-				// // #endif
-				// // #ifdef APP-PLUS
-				// if (this.PromotionCode.indexOf("http") == 0) {
-				// 	// this.downloadFilePromotionCode();
-
-				// }
-				// #endif
-				// this.goPoster()
-				// this.posters = true;
-			}
 		},
 		// 分享关闭
 		listenerActionClose: function () {
@@ -2397,6 +2316,8 @@ action-sheet-item {
 		width: 100%;
 		height: 100%;
 		position: relative;
+		left: 0;
+		margin-top: 10rpx;
 
 		.count {
 			text-align: center;
@@ -2427,6 +2348,14 @@ action-sheet-item {
 	color: #333333;
 	line-height: 44rpx;
 
+	image {
+		width: 40rpx;
+		height: 40rpx;
+		margin: 0 10rpx;
+		vertical-align: middle;
+
+	}
+
 	.time {
 		height: 44rpx;
 		font-size: 24rpx;
@@ -2545,7 +2474,11 @@ action-sheet-item {
 			display: flex;
 			margin-bottom: 20rpx;
 
+
 			image {
+				border-radius: 50%;
+				background: black;
+				margin-right: 20rpx;
 				width: 64rpx;
 				height: 64rpx;
 				border: 2rpx solid #FFFFFF;
@@ -2614,8 +2547,9 @@ action-sheet-item {
 			margin-bottom: 20rpx;
 
 			image {
-				width: 64rpx;
-				height: 64rpx;
+				width: 128rpx;
+				height: 128rpx;
+				margin-right: 20rpx;
 				border: 2rpx solid #FFFFFF;
 			}
 
@@ -2637,13 +2571,62 @@ action-sheet-item {
 					flex: 1;
 					font-size: 28rpx;
 					font-weight: 500;
-					line-height: 44rpx;
+					line-height: 80rpx;
 					display: flex;
 					justify-content: space-between;
+
+					.red {
+						display: block;
+						font-size: 28rpx;
+						font-weight: 500;
+						color: #B22338 !important;
+						margin-right: 10rpx;
+					}
+
+					.line-thr {
+						display: block;
+						font-size: 28rpx;
+						font-weight: 400;
+						color: #999999;
+						text-decoration: line-through;
+					}
 				}
 			}
 		}
 	}
 }
+
+
+.buy-box {
+	display: flex;
+	width: 100%;
+}
+
+.share-btn {
+	width: 280rpx;
+	height: 84rpx;
+	background: #F1F8E5;
+	border-radius: 54rpx 0rpx 0rpx 54rpx;
+
+	font-size: 28rpx;
+	font-weight: 400;
+	color: #75BE00;
+	line-height: 84rpx;
+
+
+}
+
+.now-btn {
+	width: 280rpx;
+	height: 84rpx;
+	background: #B42A3E;
+	border-radius: 0rpx 54rpx 54rpx 0rpx;
+	font-size: 28rpx;
+	font-weight: 400;
+	color: #fff;
+	line-height: 84rpx;
+
+
+}
 </style>
 

+ 64 - 3
pages/index/diy/index_mall.vue

@@ -18,7 +18,26 @@
 		</view>
 		<!-- 轮播 -->
 		<view class="swiper-group">
-			<u-swiper :list="swiperList" indicator indicatorMode="line" circular></u-swiper>
+			<u-swiper
+                :list="swiperTabList"
+                @change="e => current = e.current"
+                :autoplay="false"
+        >
+            <view
+                    slot="indicator"
+                    class="indicator"
+            >
+                <view
+                        class="indicator__dot"
+                        v-for="(item, index) in swiperTabList"
+                        :key="index"
+                        :class="[index === current && 'indicator__dot--active']"
+                >
+                </view>
+            </view>
+        </u-swiper>
+
+
 		</view>
 
 		<view class="header-group">
@@ -144,7 +163,7 @@ export default {
 					console.log("dizhixinxi -> ", res)
 					that.positionInfo.longitude = res.longitude;
 					that.positionInfo.latitude = res.latitude;
-					that.loAcquire(that.positionInfo.longitude, that.positionInfo.latitude)
+					// that.loAcquire(that.positionInfo.longitude, that.positionInfo.latitude)
 				}
 			});
 		},
@@ -699,4 +718,46 @@ page {
 	width: 12px;
 	height: 12px;
 	margin: 4px 0 4px 0;
-}</style>
+}
+
+
+
+
+
+
+
+
+
+
+.indicator {
+        @include flex(row);
+        justify-content: center;
+
+        &__dot {
+             height: 6px;
+             width: 6px;
+             border-radius: 100px;
+             background-color: rgba(255, 255, 255, 0.35);
+             margin: 0 5px;
+             transition: background-color 0.3s;
+    
+            &--active {
+                 background-color: #ffffff;
+             }
+        }
+    }
+
+    .indicator-num {
+        padding: 2px 0;
+        background-color: rgba(0, 0, 0, 0.35);
+        border-radius: 100px;
+        width: 35px;
+        @include flex;
+        justify-content: center;
+
+        &__text {
+             color: #FFFFFF;
+             font-size: 12px;
+         }
+    }
+</style>