fanfan 8 months ago
commit ca258f8684
  1. 99
      pages/activity/newGoods.vue
  2. 9
      pages/goods/detail.vue
  3. 51
      pages/index/index.vue

@ -14,25 +14,26 @@
<view class="item">
<view class="goodsInfo">
<view class="goodsDetail">
<view class="infoRight">
<image :src="item.goods_image" mode="widthFix" class="infoImg"></image>
</view>
<view class="infoLeft">
<view class="gName">
{{item.goods_name}}
</view>
<view class="gd">
<!-- <view class="gd">
{{item.selling_point}}
</view> -->
<view class="price">
<view class="lowPrice">
{{item.goods_price_min?Number(item.goods_price_min):''}}
</view>
<view class="buyNow">
立即购买
</view>
</view>
</view>
<view class="infoRight">
<image :src="item.goods_image" mode="widthFix" class="infoImg"></image>
</view>
</view>
<view class="price">
<view class="lowPrice">
{{item.goods_price_min?Number(item.goods_price_min):''}}
</view>
<view class="buyNow">
立即购买
</view>
</view>
</view>
</view>
@ -294,16 +295,16 @@
justify-content: space-between;
width: 100%;
position: relative;
align-items: flex-start;
.infoLeft {
flex: 1;
margin-top: 20rpx;
.gName {
margin-bottom: 15rpx;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
-webkit-line-clamp: 1;
-webkit-line-clamp: 2;
max-width: 300rpx;
height: 56rpx;
height: 112rpx;
font-size: 40rpx;
font-weight: 600;
color: #3F3F3F;
@ -311,62 +312,54 @@
margin-top: 32rpx;
}
.gd {
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
-webkit-line-clamp: 2;
max-width: 350rpx;
height: 88rpx;
font-size: 32rpx;
font-family: PingFang SC, PingFang SC;
font-weight: 400;
color: #9F9F9F;
line-height: 44rpx;
}
.gp {
height: 44rpx;
font-size: 32rpx;
font-family: PingFang SC, PingFang SC;
font-weight: 400;
color: #DE041C;
line-height: 38rpx;
}
// .gd {
// overflow: hidden;
// -webkit-line-clamp: 2;
// height: 88rpx;
// font-size: 32rpx;
// font-weight: 400;
// color: #9F9F9F;
// line-height: 44rpx;
// }
// .gp {
// height: 44rpx;
// font-size: 32rpx;
// font-family: PingFang SC, PingFang SC;
// font-weight: 400;
// color: #DE041C;
// line-height: 38rpx;
// }
}
.infoRight {
width: 290rpx;
height: 290rpx;
width: 220rpx;
height: 220rpx;
border-radius: 0rpx 0rpx 0rpx 0rpx;
opacity: 1;
margin-left: 14rpx;
margin-right: 14rpx;
display: flex;
justify-content: flex-start;
align-items: center;
margin-top: 40rpx;
.infoImg {
width: 290rpx;
height: 290rpx;
width: 200rpx;
height: 200rpx;
}
position: absolute;
top: -68rpx;
right: 20rpx;
}
}
.price {
display: flex;
justify-content: flex-end;
justify-content: space-between;
margin-top: 50rpx;
margin-right: 30rpx;
.lowPrice {
height: 50rpx;
font-size: 36rpx;
font-family: PingFang SC, PingFang SC;
font-weight: 600;
color: #DE041C;
line-height: 50rpx;
margin-right: 20rpx;
}
.buyNow {

@ -383,7 +383,7 @@
</view>
<view class="shareWechat" v-if="shareType=='share'">
<view class="shareGoods">
<image :src="goods.goods_image" mode="" class="shareImg"></image>
<image :src="goods.goods_image" mode="heightFix" class="shareImg"></image>
</view>
<view class="shareInfo">
<view class="shareGoodsInfo">
@ -1035,8 +1035,13 @@
toHaibao(index) {
this.shareCancel();
if (index == 2) {
let str = `${this.goods.goods_name}\n
前台价${this.goods.goods_price_max}\n
推广价${this.goods.goods_price_min}\n
SKU${this.goods.goods_no}
`
uni.setClipboardData({
data: this.goods.goods_name, // value
data: str, // value
success: function() {
//
uni.showToast({

@ -1118,6 +1118,25 @@
this.isTop = true
}
},
/**
* 分享当前页面
*/
onShareAppMessage() {
return {
}
},
/**
* 分享到朋友圈
* 本接口为 Beta 版本暂只在 Android 平台支持详见分享到朋友圈 (Beta)
* https://developers.weixin.qq.com/miniprogram/dev/framework/open-ability/share-timeline.html
*/
onShareTimeline() {
return {
}
}
}
</script>
<style lang="scss" scoped>
@ -1194,7 +1213,7 @@
position: absolute;
z-index: 9;
text-align: center;
font-size: 28rpx;
font-size: 29rpx;
font-family: PingFang SC, PingFang SC;
font-weight: 400;
color: #FFFFFF;
@ -1226,7 +1245,7 @@
align-items: center;
justify-content: center;
background-color: #F3202A;
font-size: 24rpx;
font-size: 25rpx;
color: #fff;
top: -10rpx;
right: -10rpx;
@ -1248,7 +1267,7 @@
margin-right: 30rpx;
position: relative;
display: inline-block;
font-size: 28rpx;
font-size: 29rpx;
font-weight: 400;
padding: 0 20rpx;
color: #282828;
@ -1315,7 +1334,7 @@
align-items: center;
justify-content: center;
margin-top: 30rpx;
font-size: 22rpx;
font-size: 23rpx;
font-weight: 400;
color: #7D7D7D;
}
@ -1340,7 +1359,7 @@
}
text {
font-size: 24rpx;
font-size: 28rpx;
font-weight: 400;
color: #5A5A5A;
margin-top: 10rpx;
@ -1391,7 +1410,7 @@
text:nth-child(2) {
font-family: PingFang SC, PingFang SC;
font-weight: 400;
font-size: 24rpx;
font-size: 25rpx;
color: #FFFFFF;
text-align: left;
font-style: normal;
@ -1423,7 +1442,7 @@
}
text {
font-size: 24rpx;
font-size: 25rpx;
font-family: PingFang SC, PingFang SC;
font-weight: 400;
color: #FFFFFF;
@ -1491,7 +1510,7 @@
background: linear-gradient(180deg, #FF1C75 0%, #FF470D 100%);
border-radius: 28px 28px 28px 28px;
opacity: 1;
font-size: 24rpx;
font-size: 25rpx;
font-family: PingFang SC, PingFang SC;
font-weight: 400;
color: #FFFFFF;
@ -1547,7 +1566,7 @@
position: absolute;
// width:100%;
text-align: center;
font-size: 24rpx;
font-size: 25rpx;
font-family: PingFang SC, PingFang SC;
font-weight: 500;
color: #8C4D00;
@ -1600,19 +1619,19 @@
height: 34rpx;
line-height: 34rpx;
width: 90%;
font-size: 20rpx;
font-size: 24rpx;
font-weight: 400;
color: #FFFFFF;
text-align: center;
text {
font-size: 16rpx;
font-size: 24rpx;
}
}
}
.name {
font-size: 20rpx;
font-size: 21rpx;
font-weight: 400;
line-height: 50rpx;
color: #505050;
@ -1620,7 +1639,7 @@
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
margin-top: 10rpx;
margin-top: 10rpx;font-size: 24rpx;
}
}
@ -1638,7 +1657,7 @@
position: relative;
.more {
font-size: 20rpx;
font-size: 21rpx;
font-weight: 400;
color: #8C4D00;
position: absolute;
@ -1673,7 +1692,7 @@
width: 40rpx;
height: 40rpx;
background-color: #FF4D4D;
font-size: 24rpx;
font-size: 25rpx;
color: #FFFFFF;
border-radius: 6rpx;
}
@ -1826,7 +1845,7 @@
height: 34rpx;
line-height: 34rpx;
width: 90%;
font-size: 20rpx;
font-size: 24rpx;
font-weight: 400;
color: #FFFFFF;
text-align: center;

Loading…
Cancel
Save