zyx 1 year ago
parent
commit
dc5bff3223
6 changed files with 71 additions and 433 deletions
  1. 26 14
      pages/index/index.vue
  2. 0 3
      pages/public/login.vue
  3. 42 414
      pages/share/share.vue
  4. 3 2
      pages/user/jiance.vue
  5. BIN
      static/icon/lj.png
  6. BIN
      static/img/sp.png

+ 26 - 14
pages/index/index.vue

@@ -69,17 +69,19 @@
 			<!-- 列表 -->
 			<view class="splist flex" v-for="item in 3">
 				<view class="tp">
-					<image class="list-iamg" src="../../static/error/errorImage.jpg" mode=""></image>
+					<image class="list-iamg" src="../../static/img/sp.png" mode=""></image>
 				</view>
 				<view class="right" >
-					<view class="list-title">风平乐樱桃姜黄复合肽压片 糖果套盒...</view>
+					<view class="list-title clamp2">风平乐樱桃姜黄复合肽压片 糖果套盒...糖果套盒...糖果套盒...</view>
 					<view class="ysjg flex-start">
 						<view class="yj">¥139</view>
 						<view class="dz">直降40元</view>
 					</view>
 					<view class="bto flex">
 						<view class="xj">¥99</view>
-						<button class="ljgm text-center">立即购买</button>
+						<view class="ljgm">
+							<text class="butt">立即购买</text>
+						</view>
 					</view>
 				</view>
 			</view>
@@ -90,17 +92,19 @@
 			</view>
 			<view class="splist flex" v-for="item in 3">
 				<view class="tp">
-					<image class="list-iamg" src="../../static/error/errorImage.jpg" mode=""></image>
+					<image class="list-iamg" src="../../static/img/sp.png" mode=""></image>
 				</view>
 				<view class="right" >
-					<view class="list-title">风平乐樱桃姜黄复合肽压片 糖果套盒...</view>
+					<view class="list-title clamp2">风平乐樱桃姜黄复合肽压片 糖果套盒...风平乐樱桃姜黄复风平乐樱桃姜黄复风平乐樱桃姜黄复风平乐樱桃姜黄复</view>
 					<view class="ysjg flex-start">
 						<view class="yj">¥139</view>
 						<view class="dz">直降40元</view>
 					</view>
 					<view class="bto flex">
 						<view class="xj">¥99</view>
-						<button class="ljgm text-center">立即购买</button>
+						<view class="ljgm">
+							<text class="butt">立即购买</text>
+						</view>
 					</view>
 				</view>
 			</view>
@@ -340,7 +344,7 @@
 	
 	.splist {
 		width: 690rpx;
-		height: 276rpx;
+		height: 270rpx;
 		background: #FFFFFF;
 		box-shadow: 0rpx 0rpx 20rpx 0rpx rgba(50,50,52,0.06);
 		border-radius: 10rpx;
@@ -360,9 +364,10 @@
 				font-weight: bold;
 				color: #333333;
 				padding-left: 22rpx;
-				margin-top: 10rpx;
+				margin-top: 30rpx;
 			}
 			.ysjg {
+				// margin-top: 30rpx;
 				padding-top: 50rpx;
 				padding-left: 22rpx;
 				.yj {
@@ -380,20 +385,27 @@
 				}
 			}
 			.bto {
-				padding-top: 20rpx;
 				padding-left: 20rpx;
 				.xj {
+					padding-top: 15rpx;
 					font-size: 36rpx;
 					color: #FF6F0F;
 				}
 				.ljgm {
-					display: inline-block;
+					margin-right: 25rpx;
+					width: 137rpx;
+					height: 52rpx;
+					border-radius: 26rpx;
 					background-color: #01A6A8;
 					color: #fff;
-					border-radius: 50rpx;
-					font-size: $font-base + 2rpx;
-					text-align: center;
-					margin-left: 160rpx;
+					font-size: 28rpx;
+					.butt {
+						padding: 6rpx 10rpx;
+						text-align: center;
+						display: flex;
+						justify-content: center;
+						align-items: center;
+					}
 				}
 			}
 		}

+ 0 - 3
pages/public/login.vue

@@ -2,9 +2,6 @@
 	<view class="container">
 		<view class="container_text">
 			<image class="banner-img" src="/static/img/login-img.png" mode="scaleToFill"></image>
-			<view class="title-img">
-				<!-- <image class="title-image" src="../../static/img/login-title.png" mode=""></image> -->
-			</view>
 		</view>
 		<view class="login_text">
 			<view class="login_input flex">

+ 42 - 414
pages/share/share.vue

@@ -1,95 +1,28 @@
 <template>
 	<view class="content">
-		<view class="vheigh"></view>
-		<!-- <view class="top-bg">
-			<view class="top" @click="clickSearch()">
-				<view class="top-icon">
-					<image src="../../static/icon/icon.png" mode=""></image>
-				</view>
-				<view class="top-main">输入关键词搜索</view>
-			</view>
-		</view> -->
-		<!-- <view class="navbar">
-			<view class="nav-item" :class="{ current: tabCurrentIndex === 0 }" @click="tabClick('0')">笔记素材</view>
-			<view class="nav-item" :class="{ current: tabCurrentIndex === 1 }" @click="tabClick('1')">买家反馈</view>
-		</view> -->
-		<swiper :current="tabCurrentIndex" :style="{ height: height }" class="swiper-box" duration="300"
-			@change="changeTab">
-			<swiper-item class="tab-content">
-				<scroll-view scroll-y="true" class="list-scroll-content">
-					<view class="main" v-for="(item, index) in bjsclist" :key="index"
-						@click="navTo('/pages/zc/wzDetail?id=' + item.id)">
-						<view class="main-userInfo">
-							<view class="avatar">
-								<image src="../../static/icon/fire.png" mode=""></image>
-							</view>
-							<view class="main-user-info">
-								<view class="main-userName">{{ item.author }}</view>
-								<view class="main-user-time">2022-12-20 20:52</view>
-							</view>
-						</view>
-						<view class="main-info">{{ item.synopsis }}</view>
-						<!-- <sunuiGrand :content="item.synopsis" clamp="4" expandText="全文" shinkText="收起" bg="#ffffff"></sunuiGrand> -->
-						<!-- <view class="imagebox">
-							<view class="image-item" v-for="(itm, inx) in item.share_images"><image :src="itm" mode=""></image></view>
-						</view> -->
-						<view class="main-bottom flex">
-							<view class="main-bottom-item" @click.stop="navTo('/pages/zc/wzshare?id=' + item.id)">
-								<view class="main-bottom-icon">
-									<image src="../../static/icon/pyq.png" mode=""></image>
-								</view>
-								<view class="main-bottom-font">朋友圈</view>
-							</view>
-							<button class="main-bottom-item" open-type="share" @click.stop="seave(item)">
-								<view class="main-bottom-icon1">
-									<image src="../../static/icon/wxhy.png" mode=""></image>
-								</view>
-								<view class="main-bottom-font">微信好友</view>
-							</button>
-							<view class="main-bottom-item" @click.stop="wzdz(item)">
-								<view class="main-bottom-icon" v-if="item.user_good == 1">
-									<image src="../../static/icon/zanguo.png" mode=""></image>
-								</view>
-								<view class="main-bottom-icon" v-else>
-									<image src="../../static/icon/zan.png" mode=""></image>
-								</view>
-								<view class="main-bottom-font">{{ item.goods_count }}</view>
-							</view>
-						</view>
+		<view class="list-scroll-content">
+			<view class="main">
+				<view class="main-userInfo">
+					<view class="avatar">
+						<image src="../../static/icon/fire.png" mode=""></image>
 					</view>
-				</scroll-view>
-			</swiper-item>
-			<!-- <swiper-item class="tab-content">
-				<scroll-view scroll-y="true" class="list-scroll-content">
-					<view class="info">
-						<view class="info-item" v-for="(item, index) in mjfklist" :key="index"
-							@click="navTo('/pages/zc/plDetail?id=' + item.id)">
-							<view class="info-image">
-								<image :src="item.main_pic" mode=""></image>
-							</view>
-							<view class="info-name clamp">{{ item.title }}</view>
-							<view class="info-userinfo flex">
-								<view class="info-left">
-									<view class="info-avatar">
-										<image :src="item.avatar" mode=""></image>
-									</view>
-									<view class="info-userinfo-name">{{ item.nickname }}</view>
-								</view>
-								<view class="info-right" @click.stop="pldz(item)">
-									<view class="info-avatar" v-if="item.user_good == 0">
-										<image src="../../static/icon/zan.png" mode=""></image>
-									</view>
-									<view class="info-avatar" v-if="item.user_good == 1">
-										<image src="../../static/icon/zanguo.png" mode=""></image>
-									</view>
-									<view class="info-userinfo-name">{{ item.goods_count }}</view>
-								</view>
-							</view>
-						</view>
+					<view class="main-user-info">
+						<view class="main-userName">冲冲冲</view>
+						<view class="main-user-time">2022-12-20 20:52</view>
 					</view>
-				</scroll-view>
-			</swiper-item> -->
-		</swiper>
+					<view class="fenxiang flex">
+						<image class="img-lj" src="../../static/icon/lj.png"></image>
+						<view class="wen-lj">45612</view>
+					</view>
+				</view>
+				<view class="text">
+					<view>风平乐樱桃姜黄复合肽压片糖果套盒,轻松饱腹降 低食欲不再是梦,C天然果蔬纤维素多种果蔬纤维 满足日常膳食营养,专享价【989】</view>
+				</view>
+				<view class="share-img">
+					<image src="../../static/img/sp.png" mode=""></image>
+				</view>
+			</view>
+		</view>
 		<u-tabbar activeColor="#01A6A8" inactive-color='#666666' :list="tabbar"></u-tabbar>
 	</view>
 </template>
@@ -109,247 +42,33 @@
 		tabbar1
 	} from '@/utils/tabbar.js';  //底部导航栏
 	export default {
-		// #ifdef MP
-		onShareAppMessage: function(res) {
-			console.log(this.share);
-			if (res.from === 'button') {
-				// 来自页面内分享按钮
-				let pages = getCurrentPages();
-				// 获取当前页面
-				let page = pages[pages.length - 1];
-				let path = '/' + page.route + '?';
-				// 保存传值
-				for (let i in page.options) {
-					path += i + '=' + page.options[i] + '&';
-				}
-				// 保存邀请人
-				let data = {
-					path: path,
-					imageUrl: this.share.image_input[0],
-					title: this.share.title
-				};
-				console.log('data', data);
-				return data;
-			}
-		},
-		// #endif
 		data() {
 			return {
-				tabCurrentIndex: 0,
-				height: '',
-				bjsclist: '',
-				mjfklist: '',
-				share: '',
+				
 				tabbar: tabbar1,
 			};
 		},
 		onLoad() {},
 		onShow() {
-			this.loadData();
 		},
 		onReachBottom() {},
-		onReady(res) {
-			var _this = this;
-			uni.getSystemInfo({
-				success: resu => {
-					const query = uni.createSelectorQuery();
-					query.select('.swiper-box').boundingClientRect();
-					query.exec(function(res) {
-						_this.height = resu.windowHeight - res[0].top + 'px';
-						console.log('打印页面的剩余高度', _this.height);
-					});
-				},
-				fail: res => {}
-			});
-		},
+		
 		methods: {
-			seave(item) {
-				this.share = item;
-			},
-			clickSearch() {
-				uni.navigateTo({
-					url: '/pages/product/search'
-				});
-			},
-			changeTab(e) {
-				this.tabCurrentIndex = e.target.current;
-				this.loadData();
-			},
-			tabClick(index) {
-				this.tabCurrentIndex = index;
-				this.loadData();
-			},
-			// 文章点赞
-			wzdz(item) {
-				article_good({}, item.id).then(e => {
-					if (item.user_good == 0) {
-						item.user_good = 1;
-						item.goods_count += 1;
-					} else {
-						item.user_good = 0;
-						item.goods_count -= 1;
-					}
-				});
-			},
-			// 评论点赞
-			pldz(item) {
-				reply_good({}, item.id).then(e => {
-					if (item.user_good == 0) {
-						item.user_good = 1;
-						item.goods_count += 1;
-					} else {
-						item.user_good = 0;
-						item.goods_count -= 1;
-					}
-				});
-			},
 			navTo(url) {
 				uni.navigateTo({
 					url
 				});
 			},
-			async loadData(source) {
-				let obj = this;
-				if (this.tabCurrentIndex == 0) {
-					article({
-								page: 1,
-								limit: 1000
-							},
-							1
-						)
-						.then(({
-							data
-						}) => {
-							this.bjsclist = data;
-						})
-						.catch(e => {
-							console.log(e);
-						});
-				} else {
-					reply_list({
-								page: 1,
-								limit: 1000
-							},
-							0
-						)
-						.then(({
-							data
-						}) => {
-							this.mjfklist = data;
-						})
-						.catch(e => {
-							console.log(e);
-						});
-				}
-			}
 		}
 	};
 </script>
 
 <style lang="scss">
-	.vheigh {
-		height: var(--status-bar-height);
-		background-color: #ffffff;
-	}
-
-	button {
-		padding: 0;
-		margin: 0;
-		border: none;
-		background-color: #ffffff;
-		line-height: 1;
-		height: auto;
-	}
-
-	button::after {
-		border: none;
-	}
-
 	page,
 	.content {
 		min-height: 100%;
 		height: auto;
 	}
-
-	.top-bg {
-		padding-top: 20rpx;
-		background: #ffffff;
-	}
-
-	.list-scroll-content {
-		background: #ffffff;
-		height: 100%;
-
-		.yan {
-			padding-bottom: 100rpx;
-		}
-	}
-
-	.top {
-		width: 689rpx;
-		height: 58rpx;
-		background: #ededed;
-		border-radius: 29rpx;
-		margin: 0 auto;
-		display: flex;
-		justify-content: center;
-		align-items: center;
-
-		.top-icon {
-			width: 32rpx;
-			height: 32rpx;
-
-			image {
-				width: 100%;
-				height: 100%;
-			}
-		}
-
-		.top-main {
-			margin-left: 20rpx;
-			font-size: 28rpx;
-			font-family: PingFang SC;
-			font-weight: 500;
-			color: #cbcbcb;
-		}
-	}
-
-	.navbar {
-		display: flex;
-		height: 88rpx;
-		padding: 0 5px;
-		background: #ffffff;
-		box-shadow: 0 1px 5px rgba(0, 0, 0, 0.06);
-		position: relative;
-		z-index: 10;
-
-		.nav-item {
-			flex: 1;
-			display: flex;
-			justify-content: center;
-			align-items: center;
-			height: 100%;
-			font-size: 15px;
-			color: #999999;
-			position: relative;
-
-			&.current {
-				color: #000;
-
-				&:after {
-					content: '';
-					position: absolute;
-					left: 50%;
-					bottom: 0;
-					transform: translateX(-50%);
-					width: 44px;
-					height: 0;
-					border-bottom: 2px solid #000000;
-				}
-			}
-		}
-	}
-
 	.main {
 		margin-top: 20rpx;
 		padding: 35rpx 20rpx 24rpx;
@@ -390,122 +109,31 @@
 					color: #666666;
 				}
 			}
-		}
-
-		.main-info {
-			margin-top: 20rpx;
-		}
-
-		.imagebox {
-			margin-top: 40rpx;
-			display: flex;
-			align-items: center;
-			flex-wrap: wrap;
-
-			.image-item {
-				margin: 10rpx;
-				width: 30%;
-				height: 230rpx;
-			}
-		}
-
-		.main-bottom {
-			margin-top: 60rpx;
-
-			.main-bottom-item {
-				padding: 30rpx 0;
-				width: 33%;
-				display: flex;
-				justify-content: center;
-				align-items: center;
-
-				.main-bottom-icon {
-					width: 36rpx;
-					height: 36rpx;
+			.fenxiang {
+				padding-left: 310rpx;
+				.img-lj {
+					width: 28rpx;
+					height: 28rpx;
 				}
-
-				.main-bottom-icon1 {
-					width: 43rpx;
-					height: 36rpx;
-				}
-
-				.main-bottom-icon2 {
-					width: 36rpx;
-					height: 36rpx;
-				}
-
-				.main-bottom-font {
-					margin-left: 17rpx;
-					font-size: 22rpx;
-					font-family: PingFang SC;
-					font-weight: 500;
-					color: #333333;
+				.wen-lj {
+					font-size: 28rpx;
+					color: #FF6F0F;
+					padding-left: 10rpx;
 				}
 			}
 		}
-	}
-
-	.info {
-		padding: 10rpx;
-		display: flex;
-		flex-wrap: wrap;
-		justify-content: space-between;
-
-		image {
-			width: 100%;
-			height: 100%;
+		.text {
+			word-wrap: break-word;
+			word-break: normal;
+			margin: 20rpx 80rpx 20rpx 55rpx;
+			font-size: 28rpx;
+			font-weight: 500;
+			color: #666666;
 		}
 
-		.info-item {
-			width: 48%;
-			padding-bottom: 20rpx;
-
-			.info-image {
-				width: 100%;
-				height: 480rpx;
-			}
-
-			.info-name {
-				margin-top: 20rpx;
-				padding: 0 10rpx;
-				font-size: 26rpx;
-				font-family: PingFang SC;
-				font-weight: bold;
-				color: #000000;
-			}
-
-			.info-userinfo {
-				margin-top: 20rpx;
-				padding: 0 10rpx;
+		
+	
 
-				.info-left {
-					display: flex;
-					align-items: center;
-
-					.info-avatar {
-						width: 32rpx;
-						height: 32rpx;
-					}
-				}
-
-				.info-userinfo-name {
-					margin-left: 10rpx;
-					font-size: 24rpx;
-					font-family: PingFang SC;
-					font-weight: bold;
-					color: #999999;
-				}
-
-				.info-right {
-					display: flex;
-					align-items: center;
-
-					.info-avatar {
-						width: 30rpx;
-						height: 30rpx;
-					}
-				}
-			}
-		}
+	
 	}
 </style>

+ 3 - 2
pages/user/jiance.vue

@@ -3,6 +3,9 @@
 		<view class="jc">
 			<view class="list">
 				<image class="xc" src="../../static/img/xc.png" mode=""></image>
+				<image class="xc" src="../../static/img/xc.png" mode=""></image>
+				<image class="xc" src="../../static/img/xc.png" mode=""></image>
+				<image class="xc" src="../../static/img/xc.png" mode=""></image>
 			</view>
 		</view>
 	</view>
@@ -24,7 +27,6 @@ export default {
 </script>
 <style lang="scss">
 	.container {
-		// height: 100%;
 		min-height: 1500rpx;
 		background-color: #fff;
 		.jc {
@@ -33,7 +35,6 @@ export default {
 			.xc {
 				width: 360rpx;
 				height: 477rpx;
-				// padding: 15rpx 23rpx;
 				padding:  20rpx 10rpx 10rpx 20rpx;
 			}
 		}

BIN
static/icon/lj.png


BIN
static/img/sp.png