Compare commits
94 Commits
zyh
...
home_hotLi
@ -1,2 +1,176 @@
|
||||
@charset "UTF-8";.font-color-red{color:#eb3729 !important}.bg-color-red{background-color:#eb3729 !important}.icon-color{color:#eb3729}.cart-color{color:#eb3729 !important;border:1px solid #eb3729 !important}.padding20{padding:20rpx}.pad20{padding:0 20rpx}.padding30{padding:30rpx}.pad30{padding:0 30rpx}.acea-row{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-wrap:wrap;-ms-flex-wrap:wrap;flex-wrap:wrap}.acea-row.row-middle{-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center}.acea-row.row-top{-webkit-box-align:start;-webkit-align-items:flex-start;-ms-flex-align:start;align-items:flex-start}.acea-row.row-bottom{-webkit-box-align:end;-webkit-align-items:flex-end;-ms-flex-align:end;align-items:flex-end}.acea-row.row-center{-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center}.acea-row.row-right{-webkit-box-pack:end;-webkit-justify-content:flex-end;-ms-flex-pack:end;justify-content:flex-end}.acea-row.row-left{-webkit-box-pack:start;-webkit-justify-content:flex-start;-ms-flex-pack:start;justify-content:flex-start}.acea-row.row-between{-webkit-box-pack:justify;-webkit-justify-content:space-between;-ms-flex-pack:justify;justify-content:space-between}.acea-row.row-around{-webkit-justify-content:space-around;-ms-flex-pack:distribute;justify-content:space-around}.acea-row.row-column-around{-webkit-box-orient:vertical;-webkit-box-direction:normal;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;-webkit-justify-content:space-around;-ms-flex-pack:distribute;justify-content:space-around}.acea-row.row-column{-webkit-box-orient:vertical;-webkit-box-direction:normal;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column}.acea-row.row-column-between{-webkit-box-orient:vertical;-webkit-box-direction:normal;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;-webkit-box-pack:justify;-webkit-justify-content:space-between;-ms-flex-pack:justify;justify-content:space-between}.acea-row.row-center-wrapper{-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center}.acea-row.row-between-wrapper{-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:justify;-webkit-justify-content:space-between;-ms-flex-pack:justify;justify-content:space-between}.slider-banner{position:relative;width:100%;overflow:hidden}.slider-banner .swiper-container{height:100%}.slider-banner image{display:block;width:100%;height:100%}.start{width:122rpx;height:30rpx;background-image:url("https://wx.yixiang.co/static/images/start.png");background-repeat:no-repeat;-webkit-background-size:122rpx auto;background-size:122rpx auto}.start.star5{background-position:0 3rpx}.start.star4{background-position:0 -30rpx}.start.star3{background-position:0 -70rpx}.start.star2{background-position:0 -105rpx}.start.star1{background-position:0 -140rpx}.start.star0{background-position:0 -175rpx}.checkbox-wrapper{position:relative}.checkbox-wrapper input{display:none}.checkbox-wrapper .icon{position:absolute;left:0;top:50%;display:inline-block;width:18px;height:18px;border:1px solid #cccccc;-webkit-border-radius:50%;border-radius:50%;-webkit-transform:translate(0, -50%);-ms-transform:translate(0, -50%);transform:translate(0, -50%)}.checkbox-wrapper input:checked+.icon{background-color:#e93323;border-color:#e93323;background-image:url("https://wx.yixiang.co/static/images/enter.png");-webkit-background-size:21rpx 15rpx;background-size:21rpx 15rpx;background-repeat:no-repeat;background-position:center center}.Loads{height:80rpx;font-size:25rpx;color:#000}.Loads .iconfont{font-size:30rpx;margin-right:10rpx;height:32rpx;line-height:32rpx}@-webkit-keyframes load{from{-webkit-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}@keyframes load{from{-webkit-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}.loadingpic{-webkit-animation:load 3s linear 1s infinite;animation:load 3s linear 1s infinite}.loading{-webkit-animation:load linear 1s infinite;animation:load linear 1s infinite} |
||||
/*# sourceMappingURL=./base.css.map */ |
||||
@charset "UTF-8"; |
||||
/** |
||||
*相关初始化 |
||||
*/ |
||||
.font-color-red { |
||||
color: #2DB5AE !important; |
||||
} |
||||
.bg-color-red { |
||||
background-color: #2DB5AE !important; |
||||
color: #ffffff !important; |
||||
} |
||||
.icon-color { |
||||
color: #2DB5AE; |
||||
} |
||||
.cart-color { |
||||
color: #2DB5AE !important; |
||||
border: 1px solid #2DB5AE !important; |
||||
} |
||||
/* padding20 */ |
||||
.padding20 { |
||||
padding: 20rpx; |
||||
} |
||||
/* pad20 */ |
||||
.pad20 { |
||||
padding: 0 20rpx; |
||||
} |
||||
/* padding30 */ |
||||
.padding30 { |
||||
padding: 30rpx; |
||||
} |
||||
/*pad30 */ |
||||
.pad30 { |
||||
padding: 0 30rpx; |
||||
} |
||||
/* layout */ |
||||
.acea-row { |
||||
display: flex; |
||||
flex-wrap: wrap; |
||||
/* 辅助类 */ |
||||
} |
||||
.acea-row.row-middle { |
||||
align-items: center; |
||||
} |
||||
.acea-row.row-top { |
||||
align-items: flex-start; |
||||
} |
||||
.acea-row.row-bottom { |
||||
align-items: flex-end; |
||||
} |
||||
.acea-row.row-center { |
||||
justify-content: center; |
||||
} |
||||
.acea-row.row-right { |
||||
justify-content: flex-end; |
||||
} |
||||
.acea-row.row-left { |
||||
justify-content: flex-start; |
||||
} |
||||
.acea-row.row-between { |
||||
justify-content: space-between; |
||||
} |
||||
.acea-row.row-around { |
||||
justify-content: space-around; |
||||
} |
||||
.acea-row.row-column-around { |
||||
flex-direction: column; |
||||
justify-content: space-around; |
||||
} |
||||
.acea-row.row-column { |
||||
flex-direction: column; |
||||
} |
||||
.acea-row.row-column-between { |
||||
flex-direction: column; |
||||
justify-content: space-between; |
||||
} |
||||
/* 上下左右垂直居中 */ |
||||
.acea-row.row-center-wrapper { |
||||
align-items: center; |
||||
justify-content: center; |
||||
} |
||||
/* 上下两边居中对齐 */ |
||||
.acea-row.row-between-wrapper { |
||||
align-items: center; |
||||
justify-content: space-between; |
||||
} |
||||
.acea-row.row-center-column { |
||||
flex-direction: column; |
||||
align-items: center; |
||||
justify-content: center; |
||||
} |
||||
/* 轮播图 */ |
||||
.slider-banner { |
||||
position: relative; |
||||
width: 100%; |
||||
/* height:750rpx; */ |
||||
overflow: hidden; |
||||
} |
||||
.slider-banner .swiper-container { |
||||
height: 100%; |
||||
} |
||||
.slider-banner image { |
||||
display: block; |
||||
width: 100%; |
||||
height: 100%; |
||||
} |
||||
.start { |
||||
width: 122rpx; |
||||
height: 30rpx; |
||||
background-image: url("https://wx.yixiang.co/static/images/start.png"); |
||||
background-repeat: no-repeat; |
||||
background-size: 122rpx auto; |
||||
} |
||||
.start.star5 { |
||||
background-position: 0 3rpx; |
||||
} |
||||
.start.star4 { |
||||
background-position: 0 -30rpx; |
||||
} |
||||
.start.star3 { |
||||
background-position: 0 -70rpx; |
||||
} |
||||
.start.star2 { |
||||
background-position: 0 -105rpx; |
||||
} |
||||
.start.star1 { |
||||
background-position: 0 -140rpx; |
||||
} |
||||
.start.star0 { |
||||
background-position: 0 -175rpx; |
||||
} |
||||
/* 单选框和多选框 */ |
||||
.Loads { |
||||
font-size: 24rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 500; |
||||
color: #3A3A3C; |
||||
height: 80rpx; |
||||
} |
||||
.Loads .iconfont { |
||||
font-size: 30rpx; |
||||
margin-right: 10rpx; |
||||
height: 32rpx; |
||||
line-height: 32rpx; |
||||
} |
||||
/*加载动画*/ |
||||
@keyframes load { |
||||
from { |
||||
transform: rotate(0deg); |
||||
} |
||||
to { |
||||
transform: rotate(360deg); |
||||
} |
||||
} |
||||
.loadingpic { |
||||
animation: load 3s linear 1s infinite; |
||||
} |
||||
.loading { |
||||
animation: load linear 1s infinite; |
||||
} |
||||
/* 多选框样式 */ |
||||
checkbox .wx-checkbox-input { |
||||
width: 40rpx; |
||||
height: 40rpx; |
||||
border-radius: 50% !important; |
||||
color: #ffffff !important; |
||||
border: 2rpx solid #2DB5AE !important; |
||||
box-sizing: border-box; |
||||
} |
||||
checkbox .wx-checkbox-input.wx-checkbox-input-checked { |
||||
border: none !important; |
||||
color: #fff; |
||||
background: linear-gradient(135deg, #39D396 0%, #1B8DCC 100%); |
||||
} |
||||
checkbox .wx-checkbox-input.wx-checkbox-input-checked::before { |
||||
font-size: 28rpx; |
||||
} |
||||
|
@ -1,2 +1,62 @@
|
||||
input{line-height:normal;-webkit-box-sizing:border-box;box-sizing:border-box}@font-face{font-family:'GuildfordProBook 5';src:url('https://wx.yixiang.co/static/iconfont/GuildfordProBook5.otf')}[v-cloak]{display:none}.iconfont{font-size:36rpx}@media (-webkit-min-device-pixel-ratio:1.5),(min-device-pixel-ratio:1.5){.border-1px::after{-webkit-transform:scaleY(.7);-ms-transform:scaleY(.7);transform:scaleY(.7)}.border-1px::before{-webkit-transform:scaleY(.7);-ms-transform:scaleY(.7);transform:scaleY(.7)}}@media (-webkit-min-device-pixel-ratio:2),(min-device-pixel-ratio:2){.border-1px::after{-webkit-transform:scaleY(.5);-ms-transform:scaleY(.5);transform:scaleY(.5)}.border-1px::before{-webkit-transform:scaleY(.5);-ms-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:3),(min-device-pixel-ratio:3){.border-1px::after{-webkit-transform:scaleY(.33);-ms-transform:scaleY(.33);transform:scaleY(.33)}.border-1px::before{-webkit-transform:scaleY(.33);-ms-transform:scaleY(.33);transform:scaleY(.33)}}.line1{overflow:hidden;-o-text-overflow:ellipsis;text-overflow:ellipsis;white-space:nowrap;width:100%}.line2{word-break:break-all;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}.mask{position:fixed;top:0;left:0;right:0;bottom:0;z-index:55;background-color:rgba(0,0,0,0.5)} |
||||
/*# sourceMappingURL=./reset.css.map */ |
||||
input { |
||||
line-height: normal; |
||||
box-sizing: border-box; |
||||
} |
||||
@font-face { |
||||
font-family: 'GuildfordProBook 5'; |
||||
src: url('https://wx.yixiang.co/static/iconfont/GuildfordProBook5.otf'); |
||||
} |
||||
[v-cloak] { |
||||
display: none; |
||||
} |
||||
.iconfont { |
||||
font-size: 36rpx; |
||||
} |
||||
/* 一像素边框 */ |
||||
@media (-webkit-min-device-pixel-ratio: 1.5), (min-device-pixel-ratio: 1.5) { |
||||
.border-1px::after { |
||||
transform: scaleY(0.7); |
||||
} |
||||
.border-1px::before { |
||||
transform: scaleY(0.7); |
||||
} |
||||
} |
||||
@media (-webkit-min-device-pixel-ratio: 2), (min-device-pixel-ratio: 2) { |
||||
.border-1px::after { |
||||
transform: scaleY(0.5); |
||||
} |
||||
.border-1px::before { |
||||
transform: scaleY(0.5); |
||||
} |
||||
} |
||||
@media (-webkit-min-device-pixel-ratio: 3), (min-device-pixel-ratio: 3) { |
||||
.border-1px::after { |
||||
transform: scaleY(0.33); |
||||
} |
||||
.border-1px::before { |
||||
transform: scaleY(0.33); |
||||
} |
||||
} |
||||
.line1 { |
||||
overflow: hidden; |
||||
text-overflow: ellipsis; |
||||
white-space: nowrap; |
||||
width: 100%; |
||||
} |
||||
.line2 { |
||||
word-break: break-all; |
||||
display: -webkit-box; |
||||
-webkit-line-clamp: 2; |
||||
-webkit-box-orient: vertical; |
||||
overflow: hidden; |
||||
} |
||||
.mask { |
||||
position: fixed; |
||||
top: 0; |
||||
left: 0; |
||||
right: 0; |
||||
bottom: 0; |
||||
z-index: 55; |
||||
background: rgba(0, 0, 0, 0.6); |
||||
backdrop-filter: blur(10rpx); |
||||
} |
||||
|
@ -0,0 +1,110 @@
|
||||
<template> |
||||
<view class="tabbar-box"> |
||||
<view :style="'background: '+bgcolor+';' + (addBottom?'height: 158rpx;':'height: 118rpx;')"></view> |
||||
<view class="tabbar acea-row row-around" :style="addBottom?'':'height: 118rpx;'"> |
||||
<view class="item" @click="changeTab(item)" v-for="(item, index) in tabList" :key="item.pagePath"> |
||||
<image class="icon" v-if="item.pagePath == pagePath" :src="item.selectedIconPath" mode="widthFix"></image> |
||||
<image class="icon" v-else :src="item.iconPath" mode="widthFix"></image> |
||||
<view class="text" :style="item.pagePath == pagePath?'color: #2DB5AE;':''">{{item.text}}</view> |
||||
<view class="line" v-if="item.pagePath == pagePath" ></view> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
</template> |
||||
|
||||
<script> |
||||
export default { |
||||
name: 'Tabbar', |
||||
props: { |
||||
pagePath: { |
||||
type: String, |
||||
default: 'pages/home/index' |
||||
}, |
||||
bgcolor: { |
||||
type: String, |
||||
default: '#FFFFFF' |
||||
} |
||||
}, |
||||
data() { |
||||
return { |
||||
addBottom: this.addBottom, |
||||
tabList: [ |
||||
{ |
||||
"pagePath": "/pages/home/index", |
||||
"iconPath": "../static/icon-home.png", |
||||
"selectedIconPath": "../static/icon-home-hot.png", |
||||
"text": "首页" |
||||
}, |
||||
{ |
||||
"pagePath": "/pages/shop/GoodsClass/index", |
||||
"iconPath": "../static/icon-class.png", |
||||
"selectedIconPath": "../static/icon-class-hot.png", |
||||
"text": "分类" |
||||
}, |
||||
{ |
||||
"pagePath": "/pages/shop/ShoppingCart/index", |
||||
"iconPath": "../static/icon-cart.png", |
||||
"selectedIconPath": "../static/icon-cart-hot.png", |
||||
"text": "购物车" |
||||
}, |
||||
{ |
||||
"pagePath": "/pages/user/User/index", |
||||
"iconPath": "../static/icon-user.png", |
||||
"selectedIconPath": "../static/icon-user-hot.png", |
||||
"text": "我的" |
||||
} |
||||
], |
||||
} |
||||
}, |
||||
methods: { |
||||
changeTab(item) { |
||||
uni.switchTab({ |
||||
url: item.pagePath |
||||
}) |
||||
} |
||||
} |
||||
} |
||||
</script> |
||||
|
||||
<style lang="less" scoped> |
||||
.tabbar-box { |
||||
width: 100%; |
||||
} |
||||
.tabbar { |
||||
position: fixed; |
||||
bottom: 0; |
||||
left: 0; |
||||
z-index: 1000; |
||||
width: 100%; |
||||
height: 158rpx; |
||||
background: #F1F1F1; |
||||
box-shadow: 0rpx -4rpx 38rpx 0rpx rgba(0,0,0,0.2); |
||||
border-radius: 28rpx 28rpx 0rpx 0rpx; |
||||
padding-top: 8rpx; |
||||
.item { |
||||
width: 66rpx; |
||||
text-align: center; |
||||
.icon { |
||||
width: 50rpx; |
||||
height: 50rpx; |
||||
image { |
||||
width: 50rpx; |
||||
height: 50rpx; |
||||
} |
||||
} |
||||
.text { |
||||
font-size: 20rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 500; |
||||
line-height: 22rpx; |
||||
color: #3A3A3C; |
||||
padding-bottom: 6rpx; |
||||
} |
||||
.line { |
||||
background-color: #2DB5AE; |
||||
height: 4rpx; |
||||
width: 66rpx; |
||||
} |
||||
} |
||||
} |
||||
</style> |
@ -1,5 +1,9 @@
|
||||
// export const VUE_APP_API_URL = 'http://192.168.10.129:48080/bxgApp'
|
||||
export const VUE_APP_API_URL = 'https://farm.lotus-wallet.com/bxgApp' |
||||
export const VUE_APP_API_URL = 'http://192.168.10.113:48080/bxgApp' |
||||
// export const VUE_APP_API_URL = 'https://farm.lotus-wallet.com/bxgApp'
|
||||
// export const VUE_APP_API_URL = 'https://app.moo-mou.com/admin-api/bxgApp'
|
||||
// export const VUE_APP_API_URL = 'https://xiaohui.shop.cyjyyjy.com/xiaohuiapp'
|
||||
export const VUE_APP_RESOURCES_URL = 'https://h5.yixiang.co/static' |
||||
export const BXG_TENANT_ID = 128 |
||||
// export const BXG_TENANT_ID = 129
|
||||
export const BXG_TENANT_ID = 138 |
||||
// export const BXG_TENANT_ID = 128
|
||||
|
@ -0,0 +1,537 @@
|
||||
<template> |
||||
<view class="product-con"> |
||||
<view class="header"> |
||||
<cu-custom :isBack="true" :isCenter="true" > |
||||
<block slot="backText"> |
||||
<view class="backImg"> |
||||
<image src="@/static/images/back-btn.png" mode=""></image> |
||||
</view> |
||||
</block> |
||||
</cu-custom> |
||||
</view> |
||||
|
||||
<!-- 商品轮播 --> |
||||
<product-con-swiper :imgUrls="imgUrls"></product-con-swiper> |
||||
|
||||
<view class="tui-pro-detail"> |
||||
<view class="activity-info-box"> |
||||
<view class="tui-right__box"> |
||||
<view class="acea-row row-middle row-center"> |
||||
<view class="iconfont icon-kanjia"></view> |
||||
<text>砍价活动</text> |
||||
</view> |
||||
<view class="count-down-box" v-if="goodsDetail.stopTime"> |
||||
<count-down :isSecond="false" :datatime="goodsDetail.stopTime" :styleAllStyle="styleAllStyle" :timeTxtStyle="timeTxtStyle"></count-down> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
|
||||
<view class="tui-pro-price"> |
||||
<text class="tui-price">¥{{goodsDetail.minPrice}}</text> |
||||
<view class="tui-original-price">¥{{goodsDetail.price}}</view> |
||||
</view> |
||||
|
||||
<view class="tui-pro-title">{{ goodsDetail.title }}</view> |
||||
<view class="tui-pro-info">{{ goodsDetail.info }}</view> |
||||
<view class="tui-sale-info"> |
||||
<view class="tips acea-row"> |
||||
<view class="tip">甄选品牌</view> |
||||
</view> |
||||
<view>库存:{{ goodsDetail.stock }}{{ goodsDetail.unitName }}</view> |
||||
</view> |
||||
</view> |
||||
|
||||
<view class="safeguard-info acea-row" v-if="tempName || goodsDetail.config"> |
||||
<view class="safeguard-item" v-if="tempName"> |
||||
<image class="img" src="@/static/images/by.png" mode=""></image> |
||||
<view class="line1">{{tempName}}</view> |
||||
</view> |
||||
<view class="safeguard-item" v-for="(item,index) in goodsDetail.config" :key="index"> |
||||
<image class="img" :src="item.configuration" mode=""></image> |
||||
<view class="line1">{{item.content}}</view> |
||||
</view> |
||||
<!-- <view class="safeguard-item"> |
||||
<image class="img" src="@/static/images/fxt.png" mode=""></image> |
||||
<view>7天无理由</view> |
||||
</view> |
||||
<view class="line"></view> |
||||
<view class="safeguard-item"> |
||||
<image class="img" src="@/static/images/bj.png" mode=""></image> |
||||
<view>30天保价</view> |
||||
</view> --> |
||||
</view> |
||||
|
||||
<!-- 用户评价 --> |
||||
<!-- <view class="userEvaluation" v-if="replyCount"> |
||||
<view class="title acea-row row-between-wrapper" @click="goEvaluateList(storeInfo.productId)"> |
||||
<view class="acea-row row-middle"><text>评价</text><text class="replyCount">{{ replyCount }}</text></view> |
||||
<view @click="goEvaluateList(id)" class="praise acea-row row-middle"> |
||||
<view>好评率{{ replyChance }}%</view> |
||||
<view class="jiantou-right"></view> |
||||
</view> |
||||
</view> |
||||
<user-evaluation :reply="reply"></user-evaluation> |
||||
</view> --> |
||||
|
||||
<view class="product-intro"> |
||||
<!-- <view class="title">商品展示</view> --> |
||||
<view class="conter"> |
||||
<mp-html id="article" :setTitle="false" :lazy-load="true" :copy-link="false" :tag-style="tagStyle" |
||||
:content="goodsDetail.description" @linktap="linktap" /> |
||||
</view> |
||||
<!-- <view class="conter" v-html="goodsDetail.description"></view> --> |
||||
</view> |
||||
|
||||
<view :style="addBottom?'height: 162rpx;':'height: 122rpx;'"></view> |
||||
<!--底部操作栏--> |
||||
<view class="tui-operation acea-row row-between" :style="addBottom?'height: 162rpx;':'height: 122rpx;'"> |
||||
<view class="tui-operation-left acea-row row-between"> |
||||
<!-- #ifdef MP-WEIXIN --> |
||||
<button class="tui-operation-item" open-type="contact" hover-class="tui-opcity" :hover-stay-time="150"> |
||||
<image src="@/static/images/service-icon.png" mode=""></image> |
||||
<view class="tui-operation-text">客服</view> |
||||
</button> |
||||
<!-- #endif --> |
||||
|
||||
<view @click="goShoppingCart" class="tui-operation-item"> |
||||
<image src="@/static/images/cart-icon.png" mode=""></image> |
||||
<view class="tui-operation-text">购物车</view> |
||||
</view> |
||||
|
||||
<!-- <view class="tui-operation-item" hover-class="tui-opcity" :hover-stay-time="150" @click="setCollect"> |
||||
<image v-if="userCollect" src="@/static/images/star-light.png" mode=""></image> |
||||
<image v-else src="@/static/images/star.png" mode=""></image> |
||||
<view class="tui-operation-text">{{userCollect?'已收藏':'收藏'}}</view> |
||||
</view> --> |
||||
</view> |
||||
|
||||
<view class="tui-operation-right acea-row"> |
||||
<view class="btn other-col" @click="openAlone">原价购买</view> |
||||
<view v-if="goodsDetail.stock>0" class="btn" @click="goDargain">发起砍价</view> |
||||
<view v-else class="btn" style="background: #a0d2d0">已售罄</view> |
||||
</view> |
||||
</view> |
||||
|
||||
<!-- 词条弹框 --> |
||||
<view class="entry-mask" v-show="showEntry" @touchmove.stop.prevent @click="closeEntry"> |
||||
<view class="entry-box"> |
||||
<scroll-view scroll-y="true" style="height: 310rpx;"> |
||||
<view class="entry"> |
||||
{{entryInfo.entryInfo}} |
||||
</view> |
||||
</scroll-view> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
</template> |
||||
|
||||
<script> |
||||
import ProductConSwiper from '@/components/ProductConSwiper'; |
||||
import CountDown from '@/components/CountDown'; |
||||
import { getBargainDetail } from '@/api/activity'; |
||||
import { getEntry } from '@/api/store' |
||||
import { handleQrCode } from '@/utils/index' |
||||
export default { |
||||
components: { |
||||
ProductConSwiper, |
||||
CountDown, |
||||
}, |
||||
data() { |
||||
return { |
||||
addBottom: this.addBottom, |
||||
goodsDetail: { |
||||
minPrice: 0, |
||||
price: 0, |
||||
stock: '', |
||||
unitName: '', |
||||
}, |
||||
bargainId: 0, |
||||
bargainUid: 0, |
||||
imgUrls: [], |
||||
tempName: '', |
||||
styleAllStyle: 'width:30rpx;height:24rpx;background:#F5F6F8;border-radius:8rpx;font-size:20rpx;color:#3A3A3C;line-height:24rpx;', |
||||
timeTxtStyle: 'font-size:20rpx;color:#F5F6F8;line-height:24rpx;padding:0rpx 4rpx;', |
||||
entryInfo: {}, |
||||
showEntry: false, |
||||
tagStyle: { |
||||
a: 'color:#0A59F7;text-decoration:underline;', |
||||
img: 'padding:0;margin:0;font-size:0;display:block;' |
||||
}, |
||||
subType:true |
||||
}; |
||||
}, |
||||
onLoad() { |
||||
let url = handleQrCode() |
||||
// bargainId 砍价商品id |
||||
// bargainUid 发起砍价人 |
||||
if (url) { |
||||
// 通过二维码进来 |
||||
this.bargainId = url.bargainId |
||||
// this.bargainUid = url.partake |
||||
} else { |
||||
// 正常途径进来 |
||||
this.bargainId = this.$yroute.query.id |
||||
// this.bargainUid = this.$yroute.query.partake |
||||
} |
||||
// if (this.bargainUid == 0 || !this.bargainUid) { |
||||
// // url未携带用户uid,填上登录用户uid,跳转 |
||||
// this.bargainUid = this.userInfo.uid |
||||
// } |
||||
this.getBargainDetail(); |
||||
}, |
||||
methods: { |
||||
|
||||
// 获取产品详情 |
||||
getBargainDetail() { |
||||
uni.showLoading({ |
||||
title: '加载中', |
||||
mask: true, |
||||
}) |
||||
getBargainDetail(this.bargainId).then(res => { |
||||
uni.hideLoading() |
||||
this.goodsDetail = res.data.bargain; |
||||
this.imgUrls.push(this.goodsDetail.image); |
||||
// console.log(this.goodsDetail); |
||||
this.goodsDetail.description = this.goodsDetail.description.replace(/\<img/gi, '<img style="max-width:100%;height:auto;"'); |
||||
this.goodsDetail.rule = this.goodsDetail.rule.replace(/\<img/gi, '<img style="max-width:100%;height:auto;"'); |
||||
this.tempName = res.data.tempName; |
||||
}).catch(res => { |
||||
uni.hideLoading() |
||||
uni.showToast({ |
||||
title: res.msg, |
||||
icon: 'none', |
||||
duration: 2000, |
||||
}) |
||||
}) |
||||
}, |
||||
goShoppingCart() { |
||||
uni.setStorageSync('pathToCart', '/pages/activity/DargainGoodsDetails/index?id='+ this.bargainId +'&partake=0'); |
||||
this.$yrouter.switchTab('/pages/shop/ShoppingCart/index'); |
||||
}, |
||||
// 单独购买 |
||||
openAlone() { |
||||
this.$yrouter.push({ |
||||
path: '/pages/shop/GoodsCon/index', |
||||
query: { |
||||
id: this.goodsDetail.productId, |
||||
}, |
||||
}) |
||||
}, |
||||
goDargain() { |
||||
let isParticipation=JSON.parse(this.$yroute.query.isParticipation) |
||||
if(this.subType && !isParticipation) { |
||||
let tmplIds = ['iUviwf1eQoQ2BGXdCQx7ki_EAj_4e4v1eLI5IeUbT_0']; |
||||
uni.requestSubscribeMessage({ |
||||
tmplIds, |
||||
success:res=> { |
||||
this.subType=false |
||||
this.$yrouter.push({ |
||||
path: "/pages/activity/DargainDetails/index", |
||||
query: { id: this.bargainId, partake: 0 } |
||||
}); |
||||
}, |
||||
fail(err) { |
||||
console.log("requestSubscribeMessage err", err) |
||||
} |
||||
|
||||
}) |
||||
}else{ |
||||
this.$yrouter.push({ |
||||
path: "/pages/activity/DargainDetails/index", |
||||
query: { id: this.bargainId, partake: 0 } |
||||
}); |
||||
} |
||||
|
||||
}, |
||||
linktap(e) { |
||||
// console.log('description', e.innerText); |
||||
if (e.innerText == this.entryInfo.entryName) { |
||||
this.showEntry = true; |
||||
return; |
||||
} |
||||
getEntry({ |
||||
name: e.innerText |
||||
}).then(res => { |
||||
this.entryInfo = res.data; |
||||
this.showEntry = true; |
||||
}) |
||||
}, |
||||
closeEntry() { |
||||
this.showEntry = false; |
||||
}, |
||||
onShareAppMessage: function() { |
||||
return { |
||||
title: this.storeInfo.title, |
||||
imageUrl: this.storeInfo.image, |
||||
path: 'pages/activity/DargainGoodsDetails/index?id=' + this.storeInfo.id + '&spread=' + uni.getStorageSync('uid') + '&pageType=good&codeType=routine', |
||||
success(res) { |
||||
uni.showToast({ |
||||
title: '分享成功', |
||||
}) |
||||
}, |
||||
fail(res) { |
||||
uni.showToast({ |
||||
title: '分享失败', |
||||
icon: 'none', |
||||
}) |
||||
}, |
||||
} |
||||
}, |
||||
//分享到朋友圈 |
||||
onShareTimeline(res) { |
||||
return { |
||||
title: this.storeInfo.title, |
||||
imageUrl: this.storeInfo.image, |
||||
path: 'pages/activity/DargainGoodsDetails/index?id=' + this.storeInfo.id + '&spread=' + uni.getStorageSync('uid') + '&pageType=good&codeType=routine', |
||||
} |
||||
}, |
||||
|
||||
} |
||||
} |
||||
</script> |
||||
|
||||
<style lang="less" scoped> |
||||
.header { |
||||
.tab-title { |
||||
font-size: 32rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 600; |
||||
color: #2DB5AE; |
||||
line-height: 42rpx; |
||||
} |
||||
.backImg { |
||||
width: 88rpx; |
||||
height: 62rpx; |
||||
padding-left: 26rpx; |
||||
image { |
||||
width: 100%; |
||||
height: 100%; |
||||
} |
||||
} |
||||
} |
||||
|
||||
.tui-pro-detail { |
||||
margin: 8rpx 32rpx 20rpx; |
||||
width: 686rpx; |
||||
// height: 230rpx; |
||||
background: #F5F6F8; |
||||
box-shadow: 0rpx 10rpx 16rpx 0rpx rgba(0, 0, 0, 0.06); |
||||
border-radius: 16rpx; |
||||
padding: 24rpx; |
||||
|
||||
position: relative; |
||||
} |
||||
|
||||
.activity-info-box { |
||||
position: absolute; |
||||
top: 0rpx; |
||||
right: 24rpx; |
||||
width: 220rpx; |
||||
height: 74rpx; |
||||
overflow: hidden; |
||||
.tui-right__box { |
||||
padding-top: 8rpx; |
||||
width: 188rpx; |
||||
height: 74rpx; |
||||
background: #2DB5AE; |
||||
border-radius: 0rpx 0rpx 16rpx 16rpx; |
||||
position: relative; |
||||
z-index: 1; |
||||
margin: 0rpx 16rpx; |
||||
font-size: 20rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 600; |
||||
color: #FFFFFF; |
||||
line-height: 26rpx; |
||||
.iconfont.icon-kanjia { |
||||
font-size: 26rpx; |
||||
font-weight: 500; |
||||
line-height: 26rpx; |
||||
margin-right: 6rpx; |
||||
} |
||||
.count-down-box { |
||||
padding-top: 6rpx; |
||||
padding-left: 10rpx; |
||||
} |
||||
} |
||||
.tui-right__box::after { |
||||
width: 32rpx; |
||||
height: 32rpx; |
||||
content: ""; |
||||
position: absolute; |
||||
top: 0; |
||||
left: -32rpx; |
||||
border-radius: 16rpx; |
||||
box-shadow: 16rpx -16rpx 0rpx #2DB5AE; |
||||
} |
||||
.tui-right__box::before { |
||||
width: 32rpx; |
||||
height: 32rpx; |
||||
content: ""; |
||||
position: absolute; |
||||
top: 0; |
||||
right: -32rpx; |
||||
border-radius: 16rpx; |
||||
box-shadow: -16rpx -16rpx 0rpx #2DB5AE; |
||||
} |
||||
} |
||||
|
||||
.tui-pro-price { |
||||
font-size: 48rpx; |
||||
font-family: Futura; |
||||
font-weight: 600; |
||||
color: #3A3A3C; |
||||
line-height: 64rpx; |
||||
display: flex; |
||||
.tui-original-price { |
||||
padding-top: 18rpx; |
||||
font-size: 30rpx; |
||||
font-family: Futura; |
||||
font-weight: 600; |
||||
color: #999999; |
||||
line-height: 40rpx; |
||||
padding-left: 16rpx; |
||||
text-decoration: line-through; |
||||
} |
||||
} |
||||
|
||||
.tui-pro-title { |
||||
font-size: 34rpx; |
||||
font-family: SourceHanSansSCVF; |
||||
font-weight: 600; |
||||
color: #3A3A3C; |
||||
line-height: 50rpx; |
||||
} |
||||
.tui-pro-info { |
||||
font-size: 20rpx; |
||||
font-family: SourceHanSansSCVF; |
||||
font-weight: 600; |
||||
color: #999999; |
||||
line-height: 28rpx; |
||||
} |
||||
|
||||
.tui-sale-info { |
||||
display: flex; |
||||
align-items: center; |
||||
justify-content: space-between; |
||||
padding-top: 16rpx; |
||||
font-size: 20rpx; |
||||
font-family: SourceHanSansSCVF; |
||||
font-weight: 500; |
||||
color: #999999; |
||||
line-height: 28rpx; |
||||
.tips { |
||||
padding-top: 4rpx; |
||||
.tip { |
||||
width: 80rpx; |
||||
height: 26rpx; |
||||
background: #2DB5AE; |
||||
border-radius: 6rpx; |
||||
margin-right: 4rpx; |
||||
font-size: 16rpx; |
||||
font-family: PingFang SC; |
||||
color: #FFFFFF; |
||||
line-height: 26rpx; |
||||
text-align: center; |
||||
margin-right: 20rpx; |
||||
} |
||||
} |
||||
} |
||||
|
||||
.safeguard-info { |
||||
width: 686rpx; |
||||
height: 120rpx; |
||||
background: #F5F6F8; |
||||
box-shadow: 0rpx 10rpx 16rpx 0rpx rgba(0, 0, 0, 0.06); |
||||
border-radius: 16rpx; |
||||
padding: 18rpx 0rpx; |
||||
margin: 0rpx 32rpx 20rpx; |
||||
.safeguard-item { |
||||
flex: 1; |
||||
// width: 226rpx; |
||||
height: 84rpx; |
||||
border-right: 2rpx solid #979797; |
||||
font-size: 20rpx; |
||||
font-family: SourceHanSansSCVF; |
||||
font-weight: 600; |
||||
color: #999999; |
||||
line-height: 28rpx; |
||||
text-align: center; |
||||
.img { |
||||
width: 46rpx; |
||||
height: 46rpx; |
||||
margin-top: 2rpx; |
||||
} |
||||
} |
||||
.safeguard-item:last-child { |
||||
border-right: 0; |
||||
} |
||||
// .line { |
||||
// width: 2rpx; |
||||
// height: 84rpx; |
||||
// background-color: #979797; |
||||
// } |
||||
} |
||||
|
||||
.tui-operation { |
||||
width: 100%; |
||||
position: fixed; |
||||
z-index: 100; |
||||
bottom: 0; |
||||
left: 0; |
||||
background: #F1F1F1; |
||||
box-shadow: 0rpx -4rpx 38rpx 0rpx rgba(0,0,0,0.2); |
||||
border-radius: 28rpx 28rpx 0rpx 0rpx; |
||||
.tui-operation-left { |
||||
padding: 12rpx 28rpx; |
||||
width: 220rpx; |
||||
// width: 330rpx; |
||||
.tui-operation-item { |
||||
width: 60rpx; |
||||
display: flex; |
||||
align-items: center; |
||||
flex-direction: column; |
||||
background: none; |
||||
padding: 0; |
||||
margin: 0; |
||||
border: 0; |
||||
|
||||
image { |
||||
width: 50rpx; |
||||
height: 50rpx; |
||||
} |
||||
&:after { |
||||
display: none; |
||||
} |
||||
.tui-operation-text { |
||||
font-size: 20rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 500; |
||||
color: #3A3A3C; |
||||
line-height: 22rpx; |
||||
} |
||||
} |
||||
} |
||||
.tui-operation-right { |
||||
padding-top: 18rpx; |
||||
padding-right: 18rpx; |
||||
.btn { |
||||
width: 186rpx; |
||||
height: 66rpx; |
||||
background: #2DB5AE; |
||||
border-radius: 16rpx; |
||||
font-size: 26rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 600; |
||||
color: #FFFFFF; |
||||
line-height: 66rpx; |
||||
text-align: center; |
||||
margin-right: 14rpx; |
||||
} |
||||
.other-col { |
||||
background: #98DAD7; |
||||
} |
||||
} |
||||
} |
||||
|
||||
</style> |
@ -0,0 +1,697 @@
|
||||
<template> |
||||
<view class="bargain on"> |
||||
<view class="header"> |
||||
<cu-custom :isBack="true" :isCenter="true" :bgColor="bgColor"> |
||||
<block slot="backText"> |
||||
<view class="backImg"> |
||||
<image src="@/static/images/back-btn.png" mode=""></image> |
||||
</view> |
||||
</block> |
||||
<block slot="content"> |
||||
<view class="tab-title">活动专区</view> |
||||
</block> |
||||
</cu-custom> |
||||
</view> |
||||
|
||||
<view class="banner-box"> |
||||
<swiper class="swiper" circular @change="swiperChange" :autoplay="true"> |
||||
<swiper-item v-for="(item, index) in banner" :key="index" class="swiper-item" @click="goBannerDetail"> |
||||
<image class="swiper-image " :src="item.pic" mode="aspectFill" lazy-load> |
||||
</image> |
||||
</swiper-item> |
||||
</swiper> |
||||
<view class="dots acea-row"> |
||||
<view :class="'dot ' + (swiperCurrent === index ? 'dot-active' : '')" v-for="(dot, index) in banner.length" :key="index"></view> |
||||
</view> |
||||
</view> |
||||
|
||||
<view class="activity-content"> |
||||
<!-- <view class="top-nav-box" :style="(activityType !== 0?'height: 104rpx;':'')+(navStyle?'position: fixed;top:'+CustomBar+'px;left: 0;':'')"> --> |
||||
<view class="top-nav-box" :style="(navStyle?'position: fixed;top:'+CustomBar+'px;left: 0;':'')"> |
||||
<view class="activity-type-box acea-row row-center"> |
||||
<view class="item" @click="setActivityType(0)"> |
||||
<view :class="'title ' + (activityType === 0? 'active' : '')">秒杀专区</view> |
||||
</view> |
||||
<view class="item" @click="setActivityType(1)"> |
||||
<view :class="'title ' + (activityType === 1 ? 'active' : '')">拼团专区</view> |
||||
</view> |
||||
<view class="item" @click="setActivityType(2)"> |
||||
<view :class="'title ' + (activityType === 2 ? 'active' : '')">砍价专区</view> |
||||
</view> |
||||
</view> |
||||
<!-- <view class="tab-box acea-row row-between" v-if="activityType === 0"> --> |
||||
<view class="tab-box acea-row row-between" > |
||||
<view :class="'tab ' + (tabType === 0 ? 'active' : '')" @click="setTabType(0)">{{activityType==0?(timeList[seckillActive].status == 2 ? '活动即将开始' : '活动抢购中'):'活动中' }}</view> |
||||
<view :class="'tab ' + (tabType === 1 ? 'active' : '')" @click="setTabType(1)">{{activityType==0?'下期预告':'已参与'}}</view> |
||||
</view> |
||||
</view> |
||||
<view class="list-box" :style="navStyle?'padding-top:186rpx':''"> |
||||
<!-- <view class="list-box" :style="navStyle?(activityType !== 0?'padding-top:104rpx':'padding-top:186rpx'):''"> --> |
||||
<view class="countdown-box acea-row row-between-wrapper" v-if="activityType === 0 && tabType === 0 && timeList[seckillActive].stop"> |
||||
<view class="acea-row row-middle"> |
||||
<view class="text">{{timeList[seckillActive].status == 2 ? timeList[seckillActive].time + '即将开始' : '本轮结束仅剩'}}</view> |
||||
<CountDown :isDay="true" :dayText="' 天 '" :hourText="' 时 '" :minuteText="' 分 '" :secondText="' 秒'" :datatime="timeList[seckillActive].stop"></CountDown> |
||||
</view> |
||||
<image src="../../../static/images/icon-tishi.png" mode="" @click="showRule"></image> |
||||
</view> |
||||
|
||||
<view class="goods-box"> |
||||
<view class="item acea-row row-between" v-for="(item,index) in goodsList" :key="index"> |
||||
<image class="goods-img" :src="item.image" mode="aspectFill"></image> |
||||
<view class="info-box"> |
||||
<view class="name line1">{{item.title}}</view> |
||||
<view class="progress-box" v-if="activityType === 0"> |
||||
<view class="acea-row row-between"> |
||||
<text>{{activityType == 0?'秒杀':activityType == 1?'拼团':'砍价'}}剩余</text> |
||||
<text>{{100 - item.percent}}%</text> |
||||
</view> |
||||
<view class="progress"> |
||||
<view class="bg-red" :style="'width:'+ (100 - item.percent) + '%'"></view> |
||||
<!-- <view class="bg-red" :style="{ width: loading ? item.percent + '%' : '' }"></view> --> |
||||
</view> |
||||
</view> |
||||
<view class="original-price" v-if="activityType !== 0"> |
||||
<view class="otPrice">{{activityType == 1?'单买价 ':'原价 '}}¥{{activityType == 1?item.productPrice:item.price}}</view> |
||||
</view> |
||||
<view class="acea-row row-between"> |
||||
<view class="acea-row"> |
||||
<view class="price"> |
||||
{{activityType == 0?'秒杀价':activityType == 1?'拼团价':'可砍至'}}<text>¥{{activityType != 2?item.price:item.minPrice}}</text> |
||||
</view> |
||||
<view class="otPrice" v-if="activityType === 0">¥{{item.otPrice}}</view> |
||||
</view> |
||||
<!-- <view class="btn" @click="goDetail(item)">{{activityType == 0?(timeList[seckillActive].status == 2?'即将开始':'立即秒杀'):'发起' + (activityType == 1?'拼团':'砍价')}}</view> --> |
||||
<view :style="[{backgroundColor:tabType==1 && activityType!==0 ? '#EC3A5B':''},{backgroundColor:item.stock==0 &&tabType==0?'#a0d2d0':''}]" class="btn" @click="goDetail(item)">{{activityType == 0?(timeList[seckillActive].status == 2?'即将开始':(item.stock==0?'已售罄':'立即秒杀')):(tabType==0?(item.stock==0?'已售罄':('发起'+(activityType == 1?'拼团':'砍价'))):'参与中')}}</view> |
||||
</view> |
||||
|
||||
</view> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
|
||||
</view> |
||||
<!-- 提示弹窗 --> |
||||
<view class="mask" @touchmove.stop.prevent :hidden="active === false && isShowRule === false" @click="close"> |
||||
<view class="bargainTip" style="padding-bottom: 0;" :class="isShowRule === true ? 'on' : ''"> |
||||
<view class="rule-content" v-html="timeList[0].rule"></view> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
</template> |
||||
|
||||
<script> |
||||
import { getBanner} from '@/api/store'; |
||||
import { getSeckillConfig, getSeckillList, getCombinationList, getBargainList,getUserCombinationList} from '@/api/activity'; |
||||
import CountDown from '@/components/CountDown'; |
||||
import cookie from '@/utils/store/cookie' |
||||
export default { |
||||
components: { |
||||
CountDown, |
||||
}, |
||||
data() { |
||||
return { |
||||
CustomBar: this.CustomBar, |
||||
bgColor: '', |
||||
banner: [], |
||||
swiperCurrent: 0, |
||||
activityType: 0, |
||||
tabType: 0, |
||||
navStyle: false, |
||||
goodsList: [], |
||||
timeList: [], |
||||
seckillList: [], |
||||
seckillTimeIndex: 0, |
||||
seckillActive: 0, |
||||
datatime: 0, |
||||
seckillForm: { |
||||
page: 1, //页码 |
||||
limit: 10, //数量 |
||||
}, |
||||
seckillLoaded: false, |
||||
groupForm: { |
||||
page: 1, //页码 |
||||
limit: 10, //数量 |
||||
}, |
||||
grouponList: [], |
||||
groupLoaded: false, |
||||
bargainForm: { |
||||
page: 1, //页码 |
||||
limit: 10, //数量 |
||||
}, |
||||
bargainList: [], |
||||
participationList:[],//用户已参与砍价 |
||||
bargainLoaded: false, |
||||
isShowRule: false, // 显示砍价规则弹框 |
||||
active: false, |
||||
}; |
||||
}, |
||||
mounted() { |
||||
this.seckillInfo(); |
||||
this.getGrouponList(); |
||||
this.getBargainList(); |
||||
}, |
||||
onLoad() { |
||||
switch (this.$yroute.query.isType){ |
||||
case '0': |
||||
this.tabType=0 |
||||
this.activityType=2 |
||||
break; |
||||
case '1': |
||||
this.tabType=1 |
||||
this.activityType=2 |
||||
break; |
||||
case '2': |
||||
this.tabType=0 |
||||
this.activityType=1 |
||||
break; |
||||
} |
||||
|
||||
getBanner(3).then( |
||||
res => { |
||||
this.$set(this,'banner',res.data.banner) |
||||
}) |
||||
}, |
||||
onPageScroll(e) { |
||||
if (e.scrollTop > 130) { |
||||
this.bgColor = '#F1F1F1'; |
||||
this.navStyle = true; |
||||
} else { |
||||
this.bgColor = '', |
||||
this.navStyle = false; |
||||
}; |
||||
}, |
||||
onReachBottom() { |
||||
switch (this.activityType) { |
||||
case 0: |
||||
this.getSeckillList(); |
||||
break; |
||||
case 1: |
||||
this.getGrouponList(); |
||||
break; |
||||
case 2: |
||||
this.getBargainList(); |
||||
break; |
||||
default: |
||||
break; |
||||
} |
||||
}, |
||||
methods: { |
||||
// 关闭弹窗 |
||||
close: function () { |
||||
this.active = false; |
||||
this.isShowRule = false; |
||||
}, |
||||
showRule() { |
||||
// console.log('asdqwer') |
||||
// this.active = true; |
||||
this.isShowRule = true; |
||||
}, |
||||
goBannerDetail(item){ |
||||
if (item.uniapp_url) { |
||||
this.$yrouter.push(item.uniapp_url) |
||||
} |
||||
}, |
||||
swiperChange(e) { |
||||
this.swiperCurrent = e.detail.current; |
||||
}, |
||||
setActivityType(i) { |
||||
if(this.activityType == i) return; |
||||
this.activityType = i; |
||||
this.goodsList=[] |
||||
// this.tabType = 0; |
||||
if(i === 0) { |
||||
this.setTime(0); |
||||
// this.goodsList = this.seckillList; |
||||
} else if(i === 1) { |
||||
this.getGrouponList() |
||||
// this.goodsList = this.grouponList; |
||||
} else { |
||||
this.getBargainList() |
||||
// this.goodsList = this.bargainList; |
||||
} |
||||
}, |
||||
setTabType(i) { |
||||
if(this.tabType == i) return; |
||||
this.goodsList=[] |
||||
this.tabType = i; |
||||
if(this.activityType == 0) { |
||||
this.setTime(i); |
||||
}else if(this.activityType == 1){ |
||||
this.getGrouponList() |
||||
}else{ |
||||
this.getBargainList() |
||||
} |
||||
|
||||
}, |
||||
goDetail(item) { |
||||
const token = cookie.get('login_status') |
||||
console.log(token,1111111111); |
||||
if(!token){ |
||||
uni.showToast({ |
||||
title: '请登录', |
||||
icon: "none", |
||||
duration: 2000 |
||||
}); |
||||
// this.$yrouter.reLaunch({ |
||||
// path: '/pages/user/User/index', |
||||
// }) |
||||
return |
||||
} |
||||
let id = item.id; |
||||
if(this.activityType === 0) { |
||||
let time = this.timeList[this.seckillActive].stop |
||||
this.$yrouter.push({ |
||||
path: '/pages/activity/SeckillDetails/index', |
||||
query: { |
||||
id, |
||||
time, |
||||
status: this.timeList[this.seckillActive].status, |
||||
}, |
||||
}) |
||||
} else if (this.activityType === 1) { |
||||
this.$yrouter.push({ |
||||
path: '/pages/activity/GroupDetails/index', |
||||
query: { id,tabType:this.tabType } |
||||
}) |
||||
} else { |
||||
let isParticipation=item.isParticipation |
||||
this.$yrouter.push({ |
||||
path: "/pages/activity/DargainGoodsDetails/index", |
||||
query: { id, partake: 0 ,isParticipation} |
||||
}); |
||||
// this.$yrouter.push({ |
||||
// path: "/pages/activity/DargainDetails/index", |
||||
// query: { id, partake: 0 } |
||||
// }); |
||||
} |
||||
}, |
||||
seckillInfo() { |
||||
uni.showLoading({ |
||||
title: "", |
||||
}); |
||||
getSeckillConfig().then(res => { |
||||
this.timeList = res.data.seckillTime; |
||||
this.timeList.forEach(res=>{ |
||||
res.rule=res.rule.replace(/\<img/gi, '<img style="max-width:100%;height:auto;"') |
||||
}) |
||||
this.seckillTimeIndex = res.data.seckillTimeIndex; |
||||
this.seckillActive = res.data.seckillTimeIndex; |
||||
this.datatime = this.timeList[this.seckillActive].stop; |
||||
this.getSeckillList(); |
||||
uni.hideLoading(); |
||||
// this.$nextTick(() => { |
||||
// this.sticky = true; |
||||
// }) |
||||
}) |
||||
}, |
||||
setTime(i) { |
||||
this.seckillList=[] |
||||
this.seckillForm.page=1 |
||||
if(i == 0 && this.tabType==0) { |
||||
this.seckillActive = this.seckillTimeIndex; |
||||
} else { |
||||
if(this.seckillTimeIndex == this.timeList.length-1) { |
||||
return |
||||
} else { |
||||
this.seckillActive = this.seckillTimeIndex+1; |
||||
} |
||||
} |
||||
this.seckillForm.page = 1; |
||||
this.seckillLoaded = false; |
||||
this.datatime = this.timeList[this.seckillActive].stop; |
||||
this.seckillList = []; |
||||
uni.showLoading({ |
||||
title: "", |
||||
}); |
||||
this.getSeckillList(); |
||||
}, |
||||
getSeckillList() { |
||||
if (this.seckillLoaded) return; |
||||
uni.showLoading({ |
||||
title: "", |
||||
}); |
||||
let time = this.timeList[this.seckillActive].id; |
||||
getSeckillList(time, this.seckillForm).then(res => { |
||||
this.seckillLoaded = res.data.length < this.seckillForm.limit; |
||||
this.seckillList.push.apply(this.seckillList, res.data); |
||||
if(this.activityType === 0) { |
||||
this.goodsList = this.seckillList; |
||||
} |
||||
this.seckillForm.page++; |
||||
uni.hideLoading(); |
||||
}) |
||||
}, |
||||
getGrouponList() { |
||||
this.groupForm.page=1 |
||||
this.grouponList=[] |
||||
this.groupLoaded=false |
||||
if (this.groupLoaded) return |
||||
uni.showLoading({ |
||||
title: "", |
||||
}); |
||||
if(this.activityType === 1 && this.tabType===0){ |
||||
getCombinationList(this.groupForm).then(res => { |
||||
this.grouponList = this.grouponList.concat(res.data.storeCombinationQueryVos) |
||||
this.groupForm.page++; |
||||
this.groupLoaded = res.data.storeCombinationQueryVos.length < this.groupForm.limit; |
||||
this.goodsList = this.grouponList; |
||||
}) |
||||
}else{ |
||||
getUserCombinationList(this.groupForm).then(res => { |
||||
this.grouponList = this.grouponList.concat(res.data.storeCombinationQueryVos) |
||||
this.groupForm.page++; |
||||
this.groupLoaded = res.data.storeCombinationQueryVos.length < this.groupForm.limit; |
||||
this.goodsList = this.grouponList; |
||||
}) |
||||
} |
||||
uni.hideLoading(); |
||||
|
||||
}, |
||||
getBargainList() { |
||||
if (this.bargainLoaded) return; |
||||
this.bargainList=[] |
||||
this.bargainForm.page=1 |
||||
uni.showLoading({ |
||||
title: "", |
||||
}); |
||||
getBargainList(this.bargainForm).then(res => { |
||||
if(this.tabType===0){ |
||||
this.bargainList.push.apply(this.bargainList, res.data.yxStoreBargainQueryVos); |
||||
}else{ |
||||
this.bargainList.push.apply(this.bargainList, res.data.isParticipation); |
||||
} |
||||
this.bargainForm.page++; |
||||
this.bargainLoaded = res.data.length < this.bargainForm.limit; |
||||
if(this.activityType === 2) { |
||||
this.goodsList = this.bargainList; |
||||
} |
||||
uni.hideLoading(); |
||||
}); |
||||
}, |
||||
} |
||||
} |
||||
</script> |
||||
|
||||
<style lang="less" scoped> |
||||
|
||||
.bargainTip { |
||||
.rule-content { |
||||
padding: 24rpx; |
||||
min-height: 300rpx; |
||||
max-height: 600rpx; |
||||
overflow-y: scroll; |
||||
font-size: 26rpx; |
||||
font-weight: 600; |
||||
color: #3A3A3C; |
||||
line-height: 38rpx; |
||||
z-index: 100; |
||||
} |
||||
} |
||||
.header { |
||||
position: fixed; |
||||
top: 0; |
||||
left: 0; |
||||
z-index: 20; |
||||
width: 750rpx; |
||||
.tab-title { |
||||
font-size: 32rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 600; |
||||
color: #2DB5AE; |
||||
line-height: 42rpx; |
||||
} |
||||
.backImg { |
||||
width: 88rpx; |
||||
height: 62rpx; |
||||
padding-left: 26rpx; |
||||
image { |
||||
width: 100%; |
||||
height: 100%; |
||||
} |
||||
} |
||||
} |
||||
|
||||
.banner-box { |
||||
position: relative; |
||||
width: 750rpx; |
||||
height: 488rpx; |
||||
.swiper { |
||||
width: 100%; |
||||
height: 100%; |
||||
.swiper-item { |
||||
.swiper-image { |
||||
width: 100%; |
||||
height: 100%; |
||||
} |
||||
} |
||||
} |
||||
.dots { |
||||
position: absolute; |
||||
bottom: 82rpx; |
||||
left: 50%; |
||||
transform: translateX(-50%); |
||||
z-index: 1; |
||||
.dot { |
||||
width: 8rpx; |
||||
height: 8rpx; |
||||
background: #FFFFFF; |
||||
border-radius: 6rpx; |
||||
margin: 0rpx 8rpx; |
||||
transition: width .5s cubic-bezier(.18,.89,.17,.88); |
||||
} |
||||
.dot-active { |
||||
width: 34rpx; |
||||
background: #3A3A3C; |
||||
transition: width .5s cubic-bezier(.18,.89,.17,.88); |
||||
} |
||||
} |
||||
} |
||||
|
||||
.activity-content { |
||||
position: relative; |
||||
top: -64rpx; |
||||
width: 750rpx; |
||||
.top-nav-box { |
||||
width: 750rpx; |
||||
background: #FFFFFF; |
||||
border-radius: 28rpx 28rpx 0rpx 0rpx; |
||||
.activity-type-box { |
||||
height: 104rpx; |
||||
padding: 34rpx 0rpx 26rpx; |
||||
.item { |
||||
width: 112rpx; |
||||
text-align: center; |
||||
position: relative; |
||||
margin: 0rpx 33rpx; |
||||
.title { |
||||
font-size: 26rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 500; |
||||
color: #3A3A3C; |
||||
line-height: 38rpx; |
||||
} |
||||
.active { |
||||
color: #2DB5AE; |
||||
font-weight: 600; |
||||
} |
||||
.title::after { |
||||
display: block; |
||||
content: ''; |
||||
width: 100%; |
||||
height: 4rpx; |
||||
background: #2DB5AE; |
||||
position: absolute; |
||||
bottom: 0; |
||||
left: 0; |
||||
opacity: 0; |
||||
transform:scaleX(0); |
||||
transition: all .2s cubic-bezier(.18,.89,.17,.88),opacity .15s ease; |
||||
} |
||||
.active::after { |
||||
opacity: 1; |
||||
transform: scaleX(1); |
||||
} |
||||
} |
||||
} |
||||
|
||||
.tab-box { |
||||
width: 100%; |
||||
bottom: 0; |
||||
height: 82rpx; |
||||
overflow: hidden; |
||||
.tab { |
||||
width: 322rpx; |
||||
height: 82rpx; |
||||
background: #D4D4D4; |
||||
border-radius: 28rpx 28rpx 0rpx 0rpx; |
||||
// float: left; |
||||
text-align: center; |
||||
position: relative; |
||||
z-index: 1; |
||||
margin: 0rpx 26rpx; |
||||
font-size: 26rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 600; |
||||
color: #999999; |
||||
line-height: 82rpx; |
||||
} |
||||
.active { |
||||
background: #F1F1F1; |
||||
color: #2DB5AE; |
||||
} |
||||
.tab::after { |
||||
width: 58rpx; |
||||
height: 58rpx; |
||||
content: ""; |
||||
position: absolute; |
||||
bottom: 0px; |
||||
left: -58rpx; |
||||
border-radius: 30rpx; |
||||
box-shadow: 30rpx 30rpx 0rpx #D4D4D4; |
||||
} |
||||
.tab::before { |
||||
width: 58rpx; |
||||
height: 58rpx; |
||||
content: ""; |
||||
position: absolute; |
||||
bottom: 0px; |
||||
right: -58rpx; |
||||
border-radius: 30rpx; |
||||
box-shadow: -30rpx 30rpx 0rpx #D4D4D4; |
||||
} |
||||
.active::after { |
||||
box-shadow: 30rpx 30rpx 0rpx #F1F1F1; |
||||
} |
||||
.active::before { |
||||
box-shadow: -30rpx 30rpx 0rpx #F1F1F1; |
||||
} |
||||
} |
||||
} |
||||
} |
||||
|
||||
.activity-content .list-box { |
||||
width: 750rpx; |
||||
height: calc(100% - 186rpx); |
||||
background: #F1F1F1; |
||||
padding: 20rpx 32rpx; |
||||
overflow-y: scroll; |
||||
.countdown-box { |
||||
width: 686rpx; |
||||
height: 66rpx; |
||||
margin-bottom: 32rpx; |
||||
border-radius: 16rpx; |
||||
border: 4rpx solid #2DB5AE; |
||||
.text { |
||||
width: 172rpx; |
||||
height: 42rpx; |
||||
border-right: 2rpx solid #2DB5AE; |
||||
font-size: 24rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 600; |
||||
color: #2DB5AE; |
||||
line-height: 42rpx; |
||||
text-align: center; |
||||
margin-right: 18rpx; |
||||
} |
||||
image { |
||||
width: 42rpx; |
||||
height: 42rpx; |
||||
margin-right: 8rpx; |
||||
} |
||||
} |
||||
} |
||||
|
||||
.list-box .goods-box { |
||||
padding-bottom: 20rpx; |
||||
.item { |
||||
width: 686rpx; |
||||
height: 178rpx; |
||||
background: #F5F6F8; |
||||
box-shadow: 0rpx 10rpx 16rpx 0rpx rgba(0, 0, 0, 0.06); |
||||
border-radius: 16rpx; |
||||
padding: 8rpx 16rpx 8rpx 8rpx; |
||||
margin-bottom: 20rpx; |
||||
.goods-img { |
||||
width: 164rpx; |
||||
height: 164rpx; |
||||
border-radius: 16rpx; |
||||
background: #F1F1F1; |
||||
} |
||||
.info-box { |
||||
width: 478rpx; |
||||
padding-top: 8rpx; |
||||
.name { |
||||
font-size: 26rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 500; |
||||
color: #3A3A3C; |
||||
line-height: 38rpx; |
||||
} |
||||
.progress-box { |
||||
padding: 2rpx 0rpx 16rpx; |
||||
width: 324rpx; |
||||
height: 56rpx; |
||||
font-size: 20rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 600; |
||||
color: #2DB5AE; |
||||
line-height: 26rpx; |
||||
.progress { |
||||
margin-top: 4rpx; |
||||
width: 324rpx; |
||||
height: 8rpx; |
||||
background: #D8D8D8; |
||||
border-radius: 4rpx; |
||||
.bg-red { |
||||
background: #2DB5AE; |
||||
border-radius: 4rpx; |
||||
height: 100%; |
||||
transition: width 0.6s ease; |
||||
} |
||||
} |
||||
} |
||||
|
||||
.original-price { |
||||
height: 60rpx; |
||||
padding-top: 20rpx; |
||||
.otPrice { |
||||
text-decoration: none; |
||||
} |
||||
} |
||||
|
||||
.price { |
||||
font-size: 30rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 600; |
||||
color: #2EB5AE; |
||||
line-height: 42rpx; |
||||
text { |
||||
padding-left: 8rpx; |
||||
color: #3A3A3C; |
||||
} |
||||
} |
||||
.otPrice { |
||||
padding-top: 14rpx; |
||||
font-size: 20rpx; |
||||
font-family: Futura; |
||||
font-weight: 600; |
||||
color: #999999; |
||||
line-height: 26rpx; |
||||
text-decoration: line-through; |
||||
} |
||||
.btn { |
||||
width: 138rpx; |
||||
height: 42rpx; |
||||
background: #2DB5AE; |
||||
border-radius: 16rpx; |
||||
font-size: 24rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 600; |
||||
color: #FFFFFF; |
||||
line-height: 42rpx; |
||||
text-align: center; |
||||
} |
||||
} |
||||
} |
||||
} |
||||
</style> |
@ -0,0 +1,166 @@
|
||||
<template> |
||||
<view> |
||||
<view class="header"> |
||||
<cu-custom :isBack="true" :isCenter="true"> |
||||
<block slot="backText"> |
||||
<view class="backImg"> |
||||
<image src="@/static/images/back-btn.png" mode=""></image> |
||||
</view> |
||||
</block> |
||||
<block slot="content"> |
||||
<view class="tab-title">专家专栏</view> |
||||
</block> |
||||
</cu-custom> |
||||
</view> |
||||
|
||||
<view class="list"> |
||||
<view class="item" v-for="(item,index) in dataList" :key="index"> |
||||
<image class="image" :src="item.image" mode="" :style="index%2?'right: 32rpx;':'left: 30rpx;'"></image> |
||||
<image v-if="index%2" class="bg" src="../../static/images/right-bg.png" mode=""></image> |
||||
<image v-else class="bg" src="../../static/images/left-bg.png" mode=""></image> |
||||
<view class="text-box" :style="index%2?'margin-left: 24rpx;':'margin-left: 296rpx;'"> |
||||
<view class="acea-row"> |
||||
<view class="name">{{item.expertName}}</view> |
||||
<view class="position">{{item.expertStatus}}</view> |
||||
</view> |
||||
<view class="line"></view> |
||||
<view class="unit">{{item.expertUnit}}</view> |
||||
<view class="info" :style="item.expertUnit?'':'height: 160rpx;'">{{item.expertInfo}}</view> |
||||
<view class="btn" :style="index%2?'':'margin-left: 192rpx;'" @click="contact">向ta留言咨询</view> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
</template> |
||||
|
||||
<script> |
||||
import { getExpert } from "@/api/public.js" |
||||
export default { |
||||
data() { |
||||
return { |
||||
dataList: [], |
||||
}; |
||||
}, |
||||
onLoad() { |
||||
this.getExpertList(); |
||||
}, |
||||
methods: { |
||||
getExpertList() { |
||||
uni.showLoading({ |
||||
title: '' |
||||
}) |
||||
getExpert().then(res => { |
||||
this.dataList = res.data; |
||||
uni.hideLoading(); |
||||
}) |
||||
}, |
||||
// 客服 |
||||
contact() { |
||||
wx.openCustomerServiceChat({ |
||||
extInfo: {url: 'https://work.weixin.qq.com/kfid/kfc3952c32f3d9b68c3'}, |
||||
corpId: 'ww8bcef4602d97a76a', |
||||
success(res) {} |
||||
}) |
||||
}, |
||||
} |
||||
} |
||||
</script> |
||||
|
||||
<style lang="less" scoped> |
||||
.header { |
||||
.tab-title { |
||||
font-size: 32rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 600; |
||||
color: #2DB5AE; |
||||
line-height: 42rpx; |
||||
} |
||||
.backImg { |
||||
width: 88rpx; |
||||
height: 62rpx; |
||||
padding-left: 26rpx; |
||||
image { |
||||
width: 100%; |
||||
height: 100%; |
||||
} |
||||
} |
||||
} |
||||
|
||||
.list { |
||||
padding: 20rpx 32rpx; |
||||
.item { |
||||
width: 100%; |
||||
height: 330rpx; |
||||
padding-top: 26rpx; |
||||
position: relative; |
||||
margin-bottom: 32rpx; |
||||
.image { |
||||
position: absolute; |
||||
top: 0; |
||||
width: 216rpx; |
||||
height: 330rpx; |
||||
} |
||||
.bg { |
||||
position: absolute; |
||||
top: 26rpx; |
||||
width: 100%; |
||||
height: 304rpx; |
||||
z-index: -1; |
||||
// box-shadow: 0rpx 10rpx 16rpx 0rpx rgba(0, 0, 0, 0.06); |
||||
} |
||||
.text-box { |
||||
padding-top: 10rpx; |
||||
width: 362rpx; |
||||
height: 304rpx; |
||||
|
||||
font-size: 20rpx; |
||||
font-family: SourceHanSansSCVF; |
||||
font-weight: 500; |
||||
color: #2DB5AE; |
||||
line-height: 28rpx; |
||||
.name { |
||||
font-size: 30rpx; |
||||
font-weight: bold; |
||||
color: #3A3A3C; |
||||
line-height: 46rpx; |
||||
padding-left: 4rpx; |
||||
} |
||||
.position { |
||||
padding-left: 10rpx; |
||||
font-weight: bold; |
||||
padding-top: 14rpx; |
||||
} |
||||
.line { |
||||
margin-top: 6rpx; |
||||
width: 362rpx; |
||||
height: 2rpx; |
||||
background-color: #979797; |
||||
} |
||||
.unit { |
||||
padding-left: 4rpx; |
||||
padding-bottom: 14rpx; |
||||
} |
||||
.info { |
||||
padding-left: 4rpx; |
||||
height: 132rpx; |
||||
overflow: hidden; |
||||
font-family: PingFang SC; |
||||
line-height: 26rpx; |
||||
margin-bottom: 4rpx; |
||||
} |
||||
.btn { |
||||
margin-left: 4rpx; |
||||
width: 170rpx; |
||||
height: 46rpx; |
||||
background: #2DB5AE; |
||||
border-radius: 16rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 600; |
||||
color: #FFFFFF; |
||||
line-height: 46rpx; |
||||
text-align: center; |
||||
} |
||||
} |
||||
} |
||||
} |
||||
</style> |
@ -1,219 +1,349 @@
|
||||
<template> |
||||
<view class="group-goods pa20 mx20 mb10" v-if="detail.length>0"> |
||||
<view class="title-box x-bc" @tap="$yrouter.push({ path: '/pages/shop/HotNewGoods/index',query:{type:2} })"> |
||||
<text class="title">热门榜单</text> |
||||
<view class="group-people x-f"> |
||||
<text class="tip">更多</text> |
||||
<text class="cuIcon-right"></text> |
||||
</view> |
||||
</view> |
||||
<view class="goods-box swiper-box x-f"> |
||||
<swiper class="carousel" circular @change="swiperChange" :autoplay="true" duration="2000"> |
||||
<swiper-item v-for="(goods, index) in goodsList" :key="index" class="carousel-item"> |
||||
<view class="goods-list-box x-f"> |
||||
<block v-for="mgoods in goods" :key="mgoods.id"> |
||||
<view class="min-goods" @tap="jump('/pages/shop/GoodsCon/index',{id:mgoods.id})"> |
||||
<view class="img-box"> |
||||
<view class="tag">hot</view> |
||||
<image class="img" :src="mgoods.image" mode="widthFix"></image> |
||||
</view> |
||||
<view class="price-box"> |
||||
<view class="y-f"> |
||||
<text class="seckill-current">¥{{ mgoods.price }}</text> |
||||
<text class="original">销量{{ mgoods.sales }}{{mgoods.unitName}}</text> |
||||
</view> |
||||
</view> |
||||
<view class="title"> |
||||
<slot name="titleText"></slot> |
||||
</view> |
||||
</view> |
||||
</block> |
||||
</view> |
||||
</swiper-item> |
||||
</swiper> |
||||
<view class="swiper-dots" v-if="goodsList.length > 1"> |
||||
<text :class="swiperCurrent === index ? 'dot-active' : 'dot'" v-for="(dot, index) in goodsList.length" |
||||
:key="index"></text> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
</template> |
||||
|
||||
<script> |
||||
import shActivityGoods from '@/components/sh-activity-goods.vue'; |
||||
|
||||
export default { |
||||
name: "HotCommodity", |
||||
components: { |
||||
shActivityGoods |
||||
}, |
||||
data() { |
||||
return { |
||||
goodsList: [], |
||||
swiperCurrent: 0 |
||||
}; |
||||
}, |
||||
props: { |
||||
detail: Array |
||||
}, |
||||
computed: {}, |
||||
created() {}, |
||||
watch: { |
||||
detail(next) { |
||||
this.goodsList = this.sortData(next, 4); |
||||
} |
||||
}, |
||||
methods: { |
||||
swiperChange(e) { |
||||
this.swiperCurrent = e.detail.current; |
||||
}, |
||||
// 数据分层 |
||||
sortData(oArr, length) { |
||||
let arr = []; |
||||
let minArr = []; |
||||
oArr.forEach(c => { |
||||
if (minArr.length === length) { |
||||
minArr = []; |
||||
} |
||||
if (minArr.length === 0) { |
||||
arr.push(minArr); |
||||
} |
||||
minArr.push(c); |
||||
}); |
||||
|
||||
return arr; |
||||
}, |
||||
jump(path, query) { |
||||
this.$yrouter.push({ |
||||
path, |
||||
query, |
||||
}); |
||||
}, |
||||
} |
||||
} |
||||
</script> |
||||
|
||||
|
||||
<style lang="scss" scoped> |
||||
.group-goods { |
||||
position: relative; |
||||
z-index: 9; |
||||
} |
||||
|
||||
.swiper-box, |
||||
.carousel { |
||||
width: 700rpx; |
||||
height: 240upx; |
||||
position: relative; |
||||
border-radius: 20rpx; |
||||
|
||||
.carousel-item { |
||||
width: 100%; |
||||
height: 100%; |
||||
// padding: 0 28upx; |
||||
overflow: hidden; |
||||
} |
||||
|
||||
.swiper-image { |
||||
width: 100%; |
||||
height: 100%; |
||||
// border-radius: 10upx; |
||||
background: #ccc; |
||||
} |
||||
} |
||||
|
||||
.swiper-dots { |
||||
display: flex; |
||||
position: absolute; |
||||
left: 50%; |
||||
transform: translateX(-50%); |
||||
bottom: 0rpx; |
||||
z-index: 66; |
||||
|
||||
.dot { |
||||
width: 45rpx; |
||||
height: 3rpx; |
||||
background: #eee; |
||||
border-radius: 50%; |
||||
margin-right: 10rpx; |
||||
} |
||||
|
||||
.dot-active { |
||||
width: 45rpx; |
||||
height: 3rpx; |
||||
background: #a8700d; |
||||
border-radius: 50%; |
||||
margin-right: 10rpx; |
||||
} |
||||
} |
||||
|
||||
// 今日必拼+限时抢购 |
||||
.group-goods { |
||||
background: #fff; |
||||
border-radius: 20rpx; |
||||
overflow: hidden; |
||||
|
||||
.title-box { |
||||
padding-bottom: 20rpx; |
||||
|
||||
.title { |
||||
font-size: 32rpx; |
||||
font-weight: bold; |
||||
} |
||||
|
||||
.group-people { |
||||
.time-box { |
||||
font-size: 26rpx; |
||||
color: #edbf62; |
||||
|
||||
.count-text-box { |
||||
width: 30rpx; |
||||
height: 34rpx; |
||||
background: #edbf62; |
||||
text-align: center; |
||||
line-height: 34rpx; |
||||
font-size: 24rpx; |
||||
border-radius: 6rpx; |
||||
color: rgba(#fff, 0.9); |
||||
margin: 0 8rpx; |
||||
} |
||||
} |
||||
|
||||
.head-box { |
||||
.head-img { |
||||
width: 40rpx; |
||||
height: 40rpx; |
||||
border-radius: 50%; |
||||
background: #ccc; |
||||
} |
||||
} |
||||
|
||||
.tip { |
||||
font-size: 28rpx; |
||||
padding-left: 30rpx; |
||||
color: #666; |
||||
} |
||||
|
||||
.cuIcon-right { |
||||
font-size: 30rpx; |
||||
line-height: 28rpx; |
||||
color: #666; |
||||
} |
||||
} |
||||
} |
||||
|
||||
.goods-box { |
||||
.goods-item { |
||||
margin-right: 22rpx; |
||||
|
||||
&:nth-child(4n) { |
||||
margin-right: 0; |
||||
} |
||||
} |
||||
} |
||||
.min-goods{ |
||||
margin-right: 22rpx; |
||||
|
||||
} |
||||
} |
||||
</style> |
||||
<template> |
||||
<view class="group-goods"> |
||||
<!-- <view class="group-goods pa20 mx20 mb10" v-if="detail.length>0"> --> |
||||
<!-- <view class="title-box x-bc" @tap="$yrouter.push({ path: '/pages/shop/HotNewGoods/index',query:{type:2} })"> |
||||
<text class="title">热门榜单</text> |
||||
<view class="group-people x-f"> |
||||
<text class="tip">更多</text> |
||||
<text class="cuIcon-right"></text> |
||||
</view> |
||||
</view> --> |
||||
<view class="classify-tab-box acea-row"> |
||||
<view :class="'classify-item ' + (classifyType == index?'on':'')" v-for="(item,index) in classifyList" :key="index" @click="changeClassify(index)"> |
||||
{{item.listName}} |
||||
</view> |
||||
</view> |
||||
<view class="goods-box"> |
||||
<!-- <view class="goods-box swiper-box x-f"> --> |
||||
<view class="top-box"> |
||||
<view class="top-item acea-row" v-for="(item,index) in topList" :key="index" @tap="jump('/pages/shop/GoodsCon/index',{id:item.id})"> |
||||
<view class="top-num-box"> |
||||
<view class="">{{index+1}}</view> |
||||
<view class="tip">{{index===0?'ST':index===1?'ND':index===2?'RD':'TH'}}</view> |
||||
</view> |
||||
<image class="img" :src="item.image" mode="aspectFill"></image> |
||||
<view class="info-box"> |
||||
<view class="title more-t">{{item.storeName}}</view> |
||||
<view class="price-box">¥{{ item.price }}<text>¥{{item.otPrice}}</text> </view> |
||||
<view class="original">{{ item.sales }}+人购买</view> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
<PromotionGood v-if="goodsList.length" :benefit="goodsList" /> |
||||
<!-- <swiper class="carousel" circular @change="swiperChange" :autoplay="true" duration="2000"> |
||||
<swiper-item v-for="(goods, index) in goodsList" :key="index" class="carousel-item"> |
||||
<view class="goods-list-box x-f"> |
||||
<block v-for="mgoods in goods" :key="mgoods.id"> |
||||
<view class="min-goods" @tap="jump('/pages/shop/GoodsCon/index',{id:mgoods.id})"> |
||||
<view class="img-box"> |
||||
<view class="tag">hot</view> |
||||
<image class="img" :src="mgoods.image" mode="widthFix"></image> |
||||
</view> |
||||
<view class="price-box"> |
||||
<view class="y-f"> |
||||
<text class="seckill-current">¥{{ mgoods.price }}</text> |
||||
<text class="original">销量{{ mgoods.sales }}{{mgoods.unitName}}</text> |
||||
</view> |
||||
</view> |
||||
<view class="title"> |
||||
<slot name="titleText"></slot> |
||||
</view> |
||||
</view> |
||||
</block> |
||||
</view> |
||||
</swiper-item> |
||||
</swiper> |
||||
<view class="swiper-dots" v-if="goodsList.length > 1"> |
||||
<text :class="swiperCurrent === index ? 'dot-active' : 'dot'" v-for="(dot, index) in goodsList.length" |
||||
:key="index"></text> |
||||
</view> --> |
||||
</view> |
||||
</view> |
||||
</template> |
||||
|
||||
<script> |
||||
// import shActivityGoods from '@/components/sh-activity-goods.vue'; |
||||
import PromotionGood from '@/components/PromotionGood' |
||||
export default { |
||||
name: "HotCommodity", |
||||
components: { |
||||
PromotionGood |
||||
// shActivityGoods |
||||
}, |
||||
data() { |
||||
return { |
||||
classifyList: [], |
||||
classifyType: 0, |
||||
topList: [], |
||||
goodsList: [], |
||||
swiperCurrent: 0 |
||||
}; |
||||
}, |
||||
props: { |
||||
detail: Array |
||||
}, |
||||
computed: {}, |
||||
created() { |
||||
console.log('oArr detail', this.detail) |
||||
}, |
||||
watch: { |
||||
detail(next) { |
||||
this.classifyList = next; |
||||
this.goodsList = this.sortData(next[this.classifyType].productInfo, 4); |
||||
} |
||||
}, |
||||
methods: { |
||||
changeClassify(i) { |
||||
if(this.classifyType == i) return; |
||||
this.classifyType = i; |
||||
this.goodsList = this.sortData(this.classifyList[this.classifyType].productInfo, 4); |
||||
}, |
||||
swiperChange(e) { |
||||
this.swiperCurrent = e.detail.current; |
||||
}, |
||||
// 数据分层 |
||||
sortData(oArr, length) { |
||||
let arr = []; |
||||
let minArr = []; |
||||
if(oArr.length > 5) { |
||||
this.topList = oArr.slice(0, 5); |
||||
arr = oArr.slice(5, oArr.length); |
||||
} else { |
||||
this.topList = oArr; |
||||
} |
||||
// console.log('oArr', oArr) |
||||
// oArr.forEach(c => { |
||||
// if (minArr.length === length) { |
||||
// minArr = []; |
||||
// } |
||||
// if (minArr.length === 0) { |
||||
// arr.push(minArr); |
||||
// } |
||||
// minArr.push(c); |
||||
// }); |
||||
|
||||
return arr; |
||||
}, |
||||
jump(path, query) { |
||||
this.$yrouter.push({ |
||||
path, |
||||
query, |
||||
}); |
||||
}, |
||||
} |
||||
} |
||||
</script> |
||||
|
||||
|
||||
<style lang="scss" scoped> |
||||
.group-goods { |
||||
// position: relative; |
||||
// z-index: 9; |
||||
font-family: PingFang SC; |
||||
} |
||||
|
||||
.classify-tab-box { |
||||
padding: 4rpx 32rpx 22rpx; |
||||
.classify-item { |
||||
width: 124rpx; |
||||
height: 40rpx; |
||||
border-radius: 16rpx; |
||||
border: 2rpx solid #2EB5AE; |
||||
font-size: 24rpx; |
||||
font-weight: 500; |
||||
color: #2DB5AE; |
||||
line-height: 36rpx; |
||||
text-align: center; |
||||
margin-right: 20rpx; |
||||
} |
||||
.on { |
||||
color: #FFFFFF; |
||||
background: #2DB5AE; |
||||
} |
||||
} |
||||
|
||||
.top-box { |
||||
padding: 0rpx 32rpx 12rpx; |
||||
.top-item { |
||||
width: 686rpx; |
||||
height: 174rpx; |
||||
background: #F5F6F8; |
||||
box-shadow: 0rpx 10rpx 16rpx 0rpx rgba(0, 0, 0, 0.06); |
||||
border-radius: 16rpx; |
||||
margin-bottom: 20rpx; |
||||
.top-num-box { |
||||
width: 146rpx; |
||||
height: 174rpx; |
||||
padding: 24rpx 0rpx 24rpx 12rpx; |
||||
font-size: 80rpx; |
||||
font-family: Futura; |
||||
font-weight: 700; |
||||
color: #2DB5AE; |
||||
line-height: 106rpx; |
||||
text-align: center; |
||||
.tip { |
||||
font-size: 32rpx; |
||||
line-height: 42rpx; |
||||
position: relative; |
||||
top: -22rpx; |
||||
} |
||||
} |
||||
.img { |
||||
width: 168rpx; |
||||
height: 162rpx; |
||||
border-radius: 8rpx; |
||||
margin: 6rpx 0rpx; |
||||
} |
||||
.info-box { |
||||
width: 370rpx; |
||||
height: 174rpx; |
||||
padding: 16rpx 18rpx 16rpx 10rpx; |
||||
.title { |
||||
height: 76rpx; |
||||
font-size: 26rpx; |
||||
font-weight: 500; |
||||
color: #3A3A3C; |
||||
line-height: 38rpx; |
||||
} |
||||
.price-box { |
||||
font-size: 30rpx; |
||||
font-family: Futura; |
||||
font-weight: 600; |
||||
color: #3A3A3C; |
||||
line-height: 40rpx; |
||||
text { |
||||
font-size: 20rpx; |
||||
font-weight: 500; |
||||
color: #999999; |
||||
line-height: 26rpx; |
||||
text-decoration: line-through; |
||||
padding-left: 10rpx; |
||||
} |
||||
} |
||||
.original { |
||||
font-size: 20rpx; |
||||
color: #999999; |
||||
line-height: 26rpx; |
||||
} |
||||
} |
||||
} |
||||
} |
||||
|
||||
// .swiper-box, |
||||
// .carousel { |
||||
// width: 700rpx; |
||||
// height: 240upx; |
||||
// position: relative; |
||||
// border-radius: 20rpx; |
||||
|
||||
// .carousel-item { |
||||
// width: 100%; |
||||
// height: 100%; |
||||
// // padding: 0 28upx; |
||||
// overflow: hidden; |
||||
// } |
||||
|
||||
// .swiper-image { |
||||
// width: 100%; |
||||
// height: 100%; |
||||
// // border-radius: 10upx; |
||||
// background: #ccc; |
||||
// } |
||||
// } |
||||
|
||||
// .swiper-dots { |
||||
// display: flex; |
||||
// position: absolute; |
||||
// left: 50%; |
||||
// transform: translateX(-50%); |
||||
// bottom: 0rpx; |
||||
// z-index: 66; |
||||
|
||||
// .dot { |
||||
// width: 45rpx; |
||||
// height: 3rpx; |
||||
// background: #eee; |
||||
// border-radius: 50%; |
||||
// margin-right: 10rpx; |
||||
// } |
||||
|
||||
// .dot-active { |
||||
// width: 45rpx; |
||||
// height: 3rpx; |
||||
// background: #a8700d; |
||||
// border-radius: 50%; |
||||
// margin-right: 10rpx; |
||||
// } |
||||
// } |
||||
|
||||
// 今日必拼+限时抢购 |
||||
.group-goods { |
||||
// background: #fff; |
||||
// border-radius: 20rpx; |
||||
// overflow: hidden; |
||||
|
||||
// .title-box { |
||||
// padding-bottom: 20rpx; |
||||
|
||||
// .title { |
||||
// font-size: 32rpx; |
||||
// font-weight: bold; |
||||
// } |
||||
|
||||
// .group-people { |
||||
// .time-box { |
||||
// font-size: 26rpx; |
||||
// color: #edbf62; |
||||
|
||||
// .count-text-box { |
||||
// width: 30rpx; |
||||
// height: 34rpx; |
||||
// background: #edbf62; |
||||
// text-align: center; |
||||
// line-height: 34rpx; |
||||
// font-size: 24rpx; |
||||
// border-radius: 6rpx; |
||||
// color: rgba(#fff, 0.9); |
||||
// margin: 0 8rpx; |
||||
// } |
||||
// } |
||||
|
||||
// .head-box { |
||||
// .head-img { |
||||
// width: 40rpx; |
||||
// height: 40rpx; |
||||
// border-radius: 50%; |
||||
// background: #ccc; |
||||
// } |
||||
// } |
||||
|
||||
// .tip { |
||||
// font-size: 28rpx; |
||||
// padding-left: 30rpx; |
||||
// color: #666; |
||||
// } |
||||
|
||||
// .cuIcon-right { |
||||
// font-size: 30rpx; |
||||
// line-height: 28rpx; |
||||
// color: #666; |
||||
// } |
||||
// } |
||||
// } |
||||
|
||||
.goods-box { |
||||
// .goods-item { |
||||
// margin-right: 22rpx; |
||||
|
||||
// &:nth-child(4n) { |
||||
// margin-right: 0; |
||||
// } |
||||
// } |
||||
} |
||||
|
||||
// .min-goods { |
||||
// margin-right: 22rpx; |
||||
|
||||
// } |
||||
} |
||||
</style> |
||||
|
@ -1,215 +1,215 @@
|
||||
<template> |
||||
<view class="group-goods pa20 mx20 mb10" v-if="detail.length>0"> |
||||
<view class="title-box x-bc" @tap="$yrouter.push({ path: '/pages/shop/HotNewGoods/index',query:{type:1} })"> |
||||
<text class="title">精品推荐</text> |
||||
<view class="group-people x-f"> |
||||
<text class="tip">更多</text> |
||||
<text class="cuIcon-right"></text> |
||||
</view> |
||||
</view> |
||||
<view class="goods-box swiper-box x-f"> |
||||
<swiper class="carousel" circular @change="swiperChange" :autoplay="true" duration="2000"> |
||||
<swiper-item v-for="(goods, index) in goodsList" :key="index" class="carousel-item"> |
||||
<view class="goods-list-box x-f"> |
||||
<block v-for="mgoods in goods" :key="mgoods.id"> |
||||
<view class="min-goods" @tap="$yrouter.push({ path: '/pages/shop/GoodsCon/index',query:{id:mgoods.id} })"> |
||||
<view class="img-box"> |
||||
<!-- <view class="tag">{{ mgoods.people}}人团</view> --> |
||||
<image class="img" :src="mgoods.image" mode="widthFix"></image> |
||||
</view> |
||||
<view class="price-box"> |
||||
<view class="y-f"> |
||||
<text class="seckill-current">¥{{ mgoods.price }}</text> |
||||
<text class="original">销量{{ mgoods.sales }}{{mgoods.unitName}}</text> |
||||
</view> |
||||
</view> |
||||
<view class="title"> |
||||
<slot name="titleText"></slot> |
||||
</view> |
||||
</view> |
||||
</block> |
||||
</view> |
||||
</swiper-item> |
||||
</swiper> |
||||
<view class="swiper-dots" v-if="goodsList.length > 1"> |
||||
<text :class="swiperCurrent === index ? 'dot-active' : 'dot'" v-for="(dot, index) in goodsList.length" |
||||
:key="index"></text> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
</template> |
||||
|
||||
<script> |
||||
import shActivityGoods from '@/components/sh-activity-goods.vue'; |
||||
|
||||
export default { |
||||
name: "ProductsRecommended", |
||||
components: { |
||||
shActivityGoods |
||||
}, |
||||
data() { |
||||
return { |
||||
goodsList: [], |
||||
swiperCurrent: 0 |
||||
}; |
||||
}, |
||||
props: { |
||||
detail: Array |
||||
}, |
||||
computed: {}, |
||||
created() {}, |
||||
watch: { |
||||
detail(next) { |
||||
this.goodsList = this.sortData(next, 4); |
||||
} |
||||
}, |
||||
methods: { |
||||
swiperChange(e) { |
||||
this.swiperCurrent = e.detail.current; |
||||
}, |
||||
// 数据分层 |
||||
sortData(oArr, length) { |
||||
let arr = []; |
||||
let minArr = []; |
||||
oArr.forEach(c => { |
||||
if (minArr.length === length) { |
||||
minArr = []; |
||||
} |
||||
if (minArr.length === 0) { |
||||
arr.push(minArr); |
||||
} |
||||
minArr.push(c); |
||||
}); |
||||
|
||||
return arr; |
||||
}, |
||||
jump(path, query) { |
||||
this.$yrouter.push({ |
||||
path, |
||||
query, |
||||
}); |
||||
}, |
||||
} |
||||
} |
||||
</script> |
||||
|
||||
|
||||
<style lang="scss" scoped> |
||||
.group-goods { |
||||
position: relative; |
||||
z-index: 9; |
||||
} |
||||
|
||||
.swiper-box, |
||||
.carousel { |
||||
width: 700rpx; |
||||
height: 240upx; |
||||
position: relative; |
||||
border-radius: 20rpx; |
||||
|
||||
.carousel-item { |
||||
width: 100%; |
||||
height: 100%; |
||||
// padding: 0 28upx; |
||||
overflow: hidden; |
||||
} |
||||
|
||||
.swiper-image { |
||||
width: 100%; |
||||
height: 100%; |
||||
// border-radius: 10upx; |
||||
background: #ccc; |
||||
} |
||||
} |
||||
|
||||
.swiper-dots { |
||||
display: flex; |
||||
position: absolute; |
||||
left: 50%; |
||||
transform: translateX(-50%); |
||||
bottom: 0rpx; |
||||
z-index: 66; |
||||
|
||||
.dot { |
||||
width: 45rpx; |
||||
height: 3rpx; |
||||
background: #eee; |
||||
border-radius: 50%; |
||||
margin-right: 10rpx; |
||||
} |
||||
|
||||
.dot-active { |
||||
width: 45rpx; |
||||
height: 3rpx; |
||||
background: #a8700d; |
||||
border-radius: 50%; |
||||
margin-right: 10rpx; |
||||
} |
||||
} |
||||
|
||||
// 今日必拼+限时抢购 |
||||
.group-goods { |
||||
background: #fff; |
||||
border-radius: 20rpx; |
||||
overflow: hidden; |
||||
|
||||
.title-box { |
||||
padding-bottom: 20rpx; |
||||
|
||||
.title { |
||||
font-size: 32rpx; |
||||
font-weight: bold; |
||||
} |
||||
|
||||
.group-people { |
||||
.time-box { |
||||
font-size: 26rpx; |
||||
color: #edbf62; |
||||
|
||||
.count-text-box { |
||||
width: 30rpx; |
||||
height: 34rpx; |
||||
background: #edbf62; |
||||
text-align: center; |
||||
line-height: 34rpx; |
||||
font-size: 24rpx; |
||||
border-radius: 6rpx; |
||||
color: rgba(#fff, 0.9); |
||||
margin: 0 8rpx; |
||||
} |
||||
} |
||||
|
||||
.head-box { |
||||
.head-img { |
||||
width: 40rpx; |
||||
height: 40rpx; |
||||
border-radius: 50%; |
||||
background: #ccc; |
||||
} |
||||
} |
||||
|
||||
.tip { |
||||
font-size: 28rpx; |
||||
padding-left: 30rpx; |
||||
color: #666; |
||||
} |
||||
|
||||
.cuIcon-right { |
||||
font-size: 30rpx; |
||||
line-height: 28rpx; |
||||
color: #666; |
||||
} |
||||
} |
||||
} |
||||
|
||||
.goods-box { |
||||
.goods-item { |
||||
margin-right: 22rpx; |
||||
|
||||
&:nth-child(4n) { |
||||
margin-right: 0; |
||||
} |
||||
} |
||||
} |
||||
} |
||||
<template> |
||||
<view class="group-goods pa20 mx20 mb10" v-if="detail.length>0"> |
||||
<view class="title-box x-bc" @tap="$yrouter.push({ path: '/pages/shop/HotNewGoods/index',query:{type:1} })"> |
||||
<text class="title">精品推荐</text> |
||||
<view class="group-people x-f"> |
||||
<text class="tip">更多</text> |
||||
<text class="cuIcon-right"></text> |
||||
</view> |
||||
</view> |
||||
<view class="goods-box swiper-box x-f"> |
||||
<swiper class="carousel" circular @change="swiperChange" :autoplay="true" duration="2000"> |
||||
<swiper-item v-for="(goods, index) in goodsList" :key="index" class="carousel-item"> |
||||
<view class="goods-list-box x-f"> |
||||
<block v-for="mgoods in goods" :key="mgoods.id"> |
||||
<view class="min-goods" @tap="$yrouter.push({ path: '/pages/shop/GoodsCon/index',query:{id:mgoods.id} })"> |
||||
<view class="img-box"> |
||||
<!-- <view class="tag">{{ mgoods.people}}人团</view> --> |
||||
<image class="img" :src="mgoods.image" mode="widthFix"></image> |
||||
</view> |
||||
<view class="price-box"> |
||||
<view class="y-f"> |
||||
<text class="seckill-current">¥{{ mgoods.price }}</text> |
||||
<text class="original">销量{{ mgoods.sales }}{{mgoods.unitName}}</text> |
||||
</view> |
||||
</view> |
||||
<view class="title"> |
||||
<slot name="titleText"></slot> |
||||
</view> |
||||
</view> |
||||
</block> |
||||
</view> |
||||
</swiper-item> |
||||
</swiper> |
||||
<view class="swiper-dots" v-if="goodsList.length > 1"> |
||||
<text :class="swiperCurrent === index ? 'dot-active' : 'dot'" v-for="(dot, index) in goodsList.length" |
||||
:key="index"></text> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
</template> |
||||
|
||||
<script> |
||||
import shActivityGoods from '@/components/sh-activity-goods.vue'; |
||||
|
||||
export default { |
||||
name: "ProductsRecommended", |
||||
components: { |
||||
shActivityGoods |
||||
}, |
||||
data() { |
||||
return { |
||||
goodsList: [], |
||||
swiperCurrent: 0 |
||||
}; |
||||
}, |
||||
props: { |
||||
detail: Array |
||||
}, |
||||
computed: {}, |
||||
created() {}, |
||||
watch: { |
||||
detail(next) { |
||||
this.goodsList = this.sortData(next, 4); |
||||
} |
||||
}, |
||||
methods: { |
||||
swiperChange(e) { |
||||
this.swiperCurrent = e.detail.current; |
||||
}, |
||||
// 数据分层 |
||||
sortData(oArr, length) { |
||||
let arr = []; |
||||
let minArr = []; |
||||
oArr.forEach(c => { |
||||
if (minArr.length === length) { |
||||
minArr = []; |
||||
} |
||||
if (minArr.length === 0) { |
||||
arr.push(minArr); |
||||
} |
||||
minArr.push(c); |
||||
}); |
||||
|
||||
return arr; |
||||
}, |
||||
jump(path, query) { |
||||
this.$yrouter.push({ |
||||
path, |
||||
query, |
||||
}); |
||||
}, |
||||
} |
||||
} |
||||
</script> |
||||
|
||||
|
||||
<style lang="scss" scoped> |
||||
.group-goods { |
||||
position: relative; |
||||
z-index: 9; |
||||
} |
||||
|
||||
.swiper-box, |
||||
.carousel { |
||||
width: 700rpx; |
||||
height: 240upx; |
||||
position: relative; |
||||
border-radius: 20rpx; |
||||
|
||||
.carousel-item { |
||||
width: 100%; |
||||
height: 100%; |
||||
// padding: 0 28upx; |
||||
overflow: hidden; |
||||
} |
||||
|
||||
.swiper-image { |
||||
width: 100%; |
||||
height: 100%; |
||||
// border-radius: 10upx; |
||||
background: #ccc; |
||||
} |
||||
} |
||||
|
||||
.swiper-dots { |
||||
display: flex; |
||||
position: absolute; |
||||
left: 50%; |
||||
transform: translateX(-50%); |
||||
bottom: 0rpx; |
||||
z-index: 66; |
||||
|
||||
.dot { |
||||
width: 45rpx; |
||||
height: 3rpx; |
||||
background: #eee; |
||||
border-radius: 50%; |
||||
margin-right: 10rpx; |
||||
} |
||||
|
||||
.dot-active { |
||||
width: 45rpx; |
||||
height: 3rpx; |
||||
background: #a8700d; |
||||
border-radius: 50%; |
||||
margin-right: 10rpx; |
||||
} |
||||
} |
||||
|
||||
// 今日必拼+限时抢购 |
||||
.group-goods { |
||||
background: #fff; |
||||
border-radius: 20rpx; |
||||
overflow: hidden; |
||||
|
||||
.title-box { |
||||
padding-bottom: 20rpx; |
||||
|
||||
.title { |
||||
font-size: 32rpx; |
||||
font-weight: bold; |
||||
} |
||||
|
||||
.group-people { |
||||
.time-box { |
||||
font-size: 26rpx; |
||||
color: #edbf62; |
||||
|
||||
.count-text-box { |
||||
width: 30rpx; |
||||
height: 34rpx; |
||||
background: #edbf62; |
||||
text-align: center; |
||||
line-height: 34rpx; |
||||
font-size: 24rpx; |
||||
border-radius: 6rpx; |
||||
color: rgba(#fff, 0.9); |
||||
margin: 0 8rpx; |
||||
} |
||||
} |
||||
|
||||
.head-box { |
||||
.head-img { |
||||
width: 40rpx; |
||||
height: 40rpx; |
||||
border-radius: 50%; |
||||
background: #ccc; |
||||
} |
||||
} |
||||
|
||||
.tip { |
||||
font-size: 28rpx; |
||||
padding-left: 30rpx; |
||||
color: #666; |
||||
} |
||||
|
||||
.cuIcon-right { |
||||
font-size: 30rpx; |
||||
line-height: 28rpx; |
||||
color: #666; |
||||
} |
||||
} |
||||
} |
||||
|
||||
.goods-box { |
||||
.goods-item { |
||||
margin-right: 22rpx; |
||||
|
||||
&:nth-child(4n) { |
||||
margin-right: 0; |
||||
} |
||||
} |
||||
} |
||||
} |
||||
</style> |
||||
|
@ -1,314 +1,577 @@
|
||||
<template> |
||||
<view class="returnList"> |
||||
<view class="data bgRed"> |
||||
<view v-if="orderDetail.salesState === 0"> |
||||
<view class="state" v-if="orderDetail.state === 0"> |
||||
已提交申请,请耐心等待卖家处理 |
||||
</view> |
||||
<view class="state" v-if="orderDetail.state === 1"> |
||||
<view class="state" v-if="orderDetail.serviceType === 0"> |
||||
已通过平台审核,正在退款 |
||||
</view> |
||||
<view class="state" v-if="orderDetail.serviceType === 1"> |
||||
已通过平台审核 ,请填写退货物流 |
||||
</view> |
||||
</view> |
||||
<view class="state" v-if="orderDetail.state === 2"> |
||||
已发货,等待商家审核 |
||||
</view> |
||||
<view class="state" v-if="orderDetail.state === 3"> |
||||
售后订单已完成 |
||||
</view> |
||||
</view> |
||||
<view v-if="orderDetail.salesState === 1"> |
||||
已撤销售后订单 |
||||
</view> |
||||
<view v-if="orderDetail.salesState === 2"> |
||||
商家已拒绝售后申请 |
||||
</view> |
||||
</view> |
||||
<!-- 退款总金额 --> |
||||
<view class="money"> |
||||
<view class="top"> |
||||
<text>退款总金额</text> |
||||
<text class="colorRed">¥{{ orderDetail.refundAmount || 0 }}</text> |
||||
</view> |
||||
<view class="express" v-if="orderDetail.serviceType === 1"> |
||||
<view class="title">商家已同意退货申请,请尽快发货。</view> |
||||
<view class="info people"> 收货人: {{ orderDetail.consignee || '' }} </view> |
||||
<view class="info address"> 收货地址: {{ orderDetail.address || '' }} </view> |
||||
<view class="info phone"> 收货电话: {{ orderDetail.phoneNumber || '' }} </view> |
||||
</view> |
||||
<!-- 退款信息 --> |
||||
<view class="tips" v-if="orderDetail.state === 0"> |
||||
<text class="title">您已成功发起退款申请,请耐心等待商家处理</text> |
||||
<view class="content"> |
||||
<view>· 卖家同意或超时未处理,系统将退款给您</view> |
||||
<view>· 如果卖家拒绝,您可以修改退款申请后再次发起,卖家会重新处理</view> |
||||
</view> |
||||
</view> |
||||
<!-- 撤销 --> |
||||
<!-- <view class="tips" v-if="orderDetail.serviceType === 1 && orderDetail.state >= 2"> |
||||
<text class="title">您已撤销售后申请</text> |
||||
<view class="content"> |
||||
<view>· </view> |
||||
<view>· </view> |
||||
</view> |
||||
</view> --> |
||||
<!-- 商家拒接 --> |
||||
<!-- <view class="tips" v-if="orderDetail.serviceType === 2 && orderDetail.state >= 2"> |
||||
<text class="title">卖家已拒绝</text> |
||||
<view class="content"> |
||||
<view>· </view> |
||||
<view>· </view> |
||||
</view> |
||||
</view> --> |
||||
<view class="bottom"> |
||||
<view class="btns redBtn" v-if="orderDetail.salesState === 0 && orderDetail.serviceType === 1 && orderDetail.state === 1" @click="toExpress">填写物流</view> |
||||
<view class="btns def" v-if="orderDetail.salesState === 0" @click="cancelReq">撤销申请</view> |
||||
<!-- <view class="btns redBtn" @click="editReq">修改申请</view>--> |
||||
</view> |
||||
</view> |
||||
<!-- 退款信息 --> |
||||
<view class="rebackInfo"> |
||||
<view class="top"> |
||||
退款信息 |
||||
</view> |
||||
<view class="rebackItem" v-for="item in orderDetail.cartInfo" :key="item.id"> |
||||
<image class="img" :src="item.productInfo.image" mode=""></image> |
||||
<view class="info"> |
||||
<view class="productName"> |
||||
{{ item.productInfo.storeName }} |
||||
</view> |
||||
<view class="sku"> |
||||
{{ item.productInfo.attrInfo.sku }} |
||||
</view> |
||||
</view> |
||||
</view> |
||||
<view class="bottom"> |
||||
<view class="reason"> |
||||
<view class="left"> |
||||
退款原因: |
||||
</view> |
||||
<view class="right"> |
||||
{{ orderDetail.reasons || '' }} |
||||
</view> |
||||
</view> |
||||
<view class="reason"> |
||||
<view class="left"> |
||||
退款金额: |
||||
</view> |
||||
<view class="right"> ¥{{ orderDetail.refundAmount || 0 }} </view> |
||||
</view> |
||||
<view class="reason"> |
||||
<view class="left"> |
||||
退款编号: |
||||
</view> |
||||
<view class="right"> |
||||
{{ orderDetail.id || '' }} |
||||
</view> |
||||
</view> |
||||
<view class="reason"> |
||||
<view class="left"> |
||||
申请时间: |
||||
</view> |
||||
<view class="right"> |
||||
{{ orderDetail.createTime || '' }} |
||||
</view> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
</template> |
||||
|
||||
<script> |
||||
import { getAfterSealsDetail, rebackAfterSeals } from '@/api/aftersales.js' |
||||
export default { |
||||
data() { |
||||
return { |
||||
orderId: '', |
||||
id: '', |
||||
orderInfo: {}, |
||||
orderDetail: {}, |
||||
} |
||||
}, |
||||
mounted() { |
||||
this.orderId = this.$yroute.query.key |
||||
this.id = this.$yroute.query.id |
||||
this.getReturnDetail() |
||||
}, |
||||
methods: { |
||||
/** state售后状态 0已提交等待平台审核 1平台已审核 等待用户发货/退款 2 用户已发货 3已完成 */ |
||||
async getReturnDetail() { |
||||
getAfterSealsDetail(this.orderId, this.id) |
||||
.then(res => { |
||||
this.orderDetail = res.data |
||||
}) |
||||
.catch(err => { |
||||
uni.showToast({ |
||||
title: '订单异常', |
||||
icon: 'none', |
||||
duration: 2000, |
||||
}) |
||||
}) |
||||
}, |
||||
toExpress() { |
||||
this.$yrouter.push({ |
||||
path: '/pages/order/submitExpress/index', |
||||
query: { |
||||
orderCode: this.orderId, |
||||
}, |
||||
}) |
||||
}, |
||||
// 撤销申请 |
||||
async cancelReq() { |
||||
rebackAfterSeals(this.orderId, this.id) |
||||
.then(res => { |
||||
uni.showToast({ |
||||
title: '已撤销', |
||||
icon: 'none', |
||||
duration: 2000, |
||||
}) |
||||
setTimeout(() => { |
||||
this.$yrouter.back() |
||||
}, 1500) |
||||
}) |
||||
.catch(err => { |
||||
uni.showToast({ |
||||
title: '撤销失败', |
||||
icon: 'none', |
||||
duration: 2000, |
||||
}) |
||||
}) |
||||
}, |
||||
// 修改申请 |
||||
editReq() {}, |
||||
}, |
||||
} |
||||
</script> |
||||
|
||||
<style scoped lang="scss"> |
||||
$red: #eb3729; |
||||
.returnList { |
||||
.colorRed { |
||||
color: $red; |
||||
} |
||||
.bgRed { |
||||
background-color: $red; |
||||
} |
||||
.data { |
||||
width: 100%; |
||||
height: 150rpx; |
||||
line-height: 150rpx; |
||||
padding-left: 30rpx; |
||||
color: #fff; |
||||
} |
||||
.money { |
||||
background-color: #fff; |
||||
.top { |
||||
padding: 20rpx 30rpx; |
||||
font-size: 30rpx; |
||||
display: flex; |
||||
justify-content: space-between; |
||||
border-bottom: 2rpx solid #f3f4f5; |
||||
} |
||||
.express { |
||||
padding: 20rpx 30rpx; |
||||
font-size: 26rpx; |
||||
.title { |
||||
color: #333333; |
||||
} |
||||
.info { |
||||
color: #999999; |
||||
} |
||||
} |
||||
.tips { |
||||
height: 160rpx; |
||||
padding: 20rpx 30rpx; |
||||
color: #999999; |
||||
border-bottom: 2rpx solid #f3f4f5; |
||||
font-size: 26rpx; |
||||
.title { |
||||
overflow: hidden; |
||||
white-space: nowrap; |
||||
text-overflow: ellipsis; |
||||
} |
||||
.content { |
||||
font-size: 20rpx; |
||||
} |
||||
} |
||||
.bottom { |
||||
padding: 20rpx 30rpx; |
||||
display: flex; |
||||
justify-content: flex-end; |
||||
.btns { |
||||
width: 160rpx; |
||||
height: 58rpx; |
||||
margin: 0 10rpx; |
||||
font-size: 24rpx; |
||||
text-align: center; |
||||
line-height: 58rpx; |
||||
border-radius: 180rpx; |
||||
} |
||||
.def { |
||||
color: #dddddd; |
||||
border: 2rpx solid #dddddd; |
||||
} |
||||
.redBtn { |
||||
color: #fff; |
||||
background-color: $red; |
||||
} |
||||
} |
||||
} |
||||
.rebackInfo { |
||||
padding: 0 30rpx; |
||||
background-color: #fff; |
||||
.top { |
||||
height: 80rpx; |
||||
margin: 20rpx 0; |
||||
line-height: 80rpx; |
||||
font-size: 30rpx; |
||||
font-weight: bold; |
||||
color: #333333; |
||||
border-bottom: 2rpx solid #f3f4f5; |
||||
} |
||||
.rebackItem { |
||||
padding: 20rpx 0; |
||||
font-size: 28rpx; |
||||
display: flex; |
||||
border-bottom: 2rpx solid #f3f4f5; |
||||
.img { |
||||
width: 120rpx; |
||||
height: 120rpx; |
||||
} |
||||
.info { |
||||
margin-left: 16rpx; |
||||
flex: 1; |
||||
.productName { |
||||
width: 100%; |
||||
height: 80rpx; |
||||
overflow: hidden; |
||||
text-overflow: ellipsis; |
||||
color: #333333; |
||||
} |
||||
.sku { |
||||
font-size: 24rpx; |
||||
color: #cccccc; |
||||
} |
||||
} |
||||
} |
||||
.bottom { |
||||
padding: 20rpx 0; |
||||
.reason { |
||||
font-size: 28rpx; |
||||
color: #333333; |
||||
display: flex; |
||||
justify-content: space-between; |
||||
.right { |
||||
color: #aaaaaa; |
||||
} |
||||
} |
||||
} |
||||
} |
||||
} |
||||
</style> |
||||
<template> |
||||
<view class="returnList"> |
||||
<view class="header"> |
||||
<cu-custom :isBack="true" :isCenter="true"> |
||||
<block slot="backText"> |
||||
<view class="backImg"> |
||||
<image src="@/static/images/back-btn.png" mode=""></image> |
||||
</view> |
||||
</block> |
||||
<block slot="content"> |
||||
<view class="tab-title">售后详情</view> |
||||
</block> |
||||
</cu-custom> |
||||
</view> |
||||
|
||||
<view class="content-box"> |
||||
<view class="top-info"> |
||||
<view>服务单号:{{orderDetail.orderCode}}</view> |
||||
<view>申请时间:{{orderDetail.createTime}}</view> |
||||
</view> |
||||
<view class="current-progress-title acea-row row-between-wrapper"> |
||||
<view class="progress-title">当前进度</view> |
||||
<!-- <view class="">|</view> --> |
||||
<view v-if="orderDetail.salesState === 0"> |
||||
<view class="progress-text" v-if="orderDetail.state === 0">已提交申请,请耐心等待卖家处理</view> |
||||
<view v-if="orderDetail.state === 1"> |
||||
<view class="progress-text" v-if="orderDetail.serviceType === 0">已通过平台审核,正在退款</view> |
||||
<!-- <view class="progress-text" v-if="orderDetail.serviceType === 1">已通过平台审核 ,请填写退货物流</view> --> |
||||
</view> |
||||
<view class="progress-text" v-if="orderDetail.state === 2">等待商家审核</view> |
||||
<!-- <view class="progress-text" v-if="orderDetail.state === 2">已发货,等待商家审核</view> --> |
||||
<view class="progress-text" v-if="orderDetail.state === 3">售后订单已完成</view> |
||||
</view> |
||||
<view class="progress-text" v-if="orderDetail.salesState === 1">已撤销售后订单</view> |
||||
<view class="progress-text" v-if="orderDetail.salesState === 2">商家已拒绝售后申请</view> |
||||
</view> |
||||
|
||||
<view class="current-progress acea-row row-between"> |
||||
<!-- <view class="current-progress acea-row"> --> |
||||
<view class="item" v-for="(item,index) in returnStateLs" :key="index"> |
||||
<view class="tips-box"> |
||||
<view class="acea-row row-column row-middle" v-if="orderDetail.salesState === 0 && (orderDetail.state == item.state)"> |
||||
<view class="box">{{item.tip}}</view> |
||||
<view class="jiantou"></view> |
||||
</view> |
||||
<view class="acea-row row-column row-middle" v-else-if="orderDetail.salesState === 1 && (index == 0)"> |
||||
<view class="box">已撤销</view> |
||||
<view class="jiantou"></view> |
||||
</view> |
||||
<view class="acea-row row-column row-middle" v-else-if="orderDetail.salesState === 2 && (index == 1)"> |
||||
<view class="box">已拒绝</view> |
||||
<view class="jiantou"></view> |
||||
</view> |
||||
</view> |
||||
<view class="state-box" :style="item.stateText == '处理完成'?'margin-right: 0rpx;':''"> |
||||
<view class="state">{{item.stateText}}</view> |
||||
</view> |
||||
</view> |
||||
<view class="line"></view> |
||||
</view> |
||||
|
||||
<view class="info-item"> |
||||
<view class="title">问题描述</view> |
||||
<view class="info">{{orderDetail.explains}}</view> |
||||
</view> |
||||
<view class="info-item" v-if="orderDetail.explainImg"> |
||||
<view class="title">图片凭证</view> |
||||
<view class="acea-row"> |
||||
<image :src="item" mode="" v-for="(item, index) in orderDetail.explainImg" :key="index"></image> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
|
||||
<!-- <view class="data bgRed"> |
||||
<view v-if="orderDetail.salesState === 0"> |
||||
<view class="state" v-if="orderDetail.state === 0"> |
||||
已提交申请,请耐心等待卖家处理 |
||||
</view> |
||||
<view class="state" v-if="orderDetail.state === 1"> |
||||
<view class="state" v-if="orderDetail.serviceType === 0"> |
||||
已通过平台审核,正在退款 |
||||
</view> |
||||
<view class="state" v-if="orderDetail.serviceType === 1"> |
||||
已通过平台审核 ,请填写退货物流 |
||||
</view> |
||||
</view> |
||||
<view class="state" v-if="orderDetail.state === 2"> |
||||
已发货,等待商家审核 |
||||
</view> |
||||
<view class="state" v-if="orderDetail.state === 3"> |
||||
售后订单已完成 |
||||
</view> |
||||
</view> |
||||
<view v-if="orderDetail.salesState === 1"> |
||||
已撤销售后订单 |
||||
</view> |
||||
<view v-if="orderDetail.salesState === 2"> |
||||
商家已拒绝售后申请 |
||||
</view> |
||||
</view> --> |
||||
|
||||
<!-- 退款总金额 --> |
||||
<!-- <view class="money"> --> |
||||
<!-- <view class="top"> |
||||
<text>退款总金额</text> |
||||
<text class="colorRed">¥{{ orderDetail.refundAmount || 0 }}</text> |
||||
</view> |
||||
<view class="express" v-if="orderDetail.serviceType === 1"> |
||||
<view class="title">商家已同意退货申请,请尽快发货。</view> |
||||
<view class="info people"> 收货人: {{ orderDetail.consignee || '' }} </view> |
||||
<view class="info address"> 收货地址: {{ orderDetail.address || '' }} </view> |
||||
<view class="info phone"> 收货电话: {{ orderDetail.phoneNumber || '' }} </view> |
||||
</view> --> |
||||
|
||||
<!-- 退款信息 --> |
||||
<!-- <view class="tips" v-if="orderDetail.state === 0"> |
||||
<text class="title">您已成功发起退款申请,请耐心等待商家处理</text> |
||||
<view class="content"> |
||||
<view>· 卖家同意或超时未处理,系统将退款给您</view> |
||||
<view>· 如果卖家拒绝,您可以修改退款申请后再次发起,卖家会重新处理</view> |
||||
</view> |
||||
</view> --> |
||||
|
||||
<!-- 撤销 --> |
||||
<!-- <view class="tips" v-if="orderDetail.serviceType === 1 && orderDetail.state >= 2"> |
||||
<text class="title">您已撤销售后申请</text> |
||||
<view class="content"> |
||||
<view>· </view> |
||||
<view>· </view> |
||||
</view> |
||||
</view> --> |
||||
<!-- 商家拒接 --> |
||||
<!-- <view class="tips" v-if="orderDetail.serviceType === 2 && orderDetail.state >= 2"> |
||||
<text class="title">卖家已拒绝</text> |
||||
<view class="content"> |
||||
<view>· </view> |
||||
<view>· </view> |
||||
</view> |
||||
</view> --> |
||||
<!-- <view class="bottom"> |
||||
<view class="btns redBtn" v-if="orderDetail.salesState === 0 && orderDetail.serviceType === 1 && orderDetail.state === 1" @click="toExpress">填写物流</view> |
||||
<view class="btns def" v-if="orderDetail.salesState === 0" @click="cancelReq">撤销申请</view> |
||||
|
||||
<view class="btns redBtn" @click="editReq">修改申请</view> |
||||
|
||||
</view> --> |
||||
<!-- </view> --> |
||||
|
||||
<!-- 退款信息 --> |
||||
<!-- <view class="rebackInfo"> |
||||
<view class="top"> |
||||
退款信息 |
||||
</view> |
||||
<view class="rebackItem" v-for="item in orderDetail.cartInfo" :key="item.id"> |
||||
<image class="img" :src="item.productInfo.image" mode=""></image> |
||||
<view class="info"> |
||||
<view class="productName"> |
||||
{{ item.productInfo.storeName }} |
||||
</view> |
||||
<view class="sku"> |
||||
{{ item.productInfo.attrInfo.sku }} |
||||
</view> |
||||
</view> |
||||
</view> |
||||
<view class="bottom"> |
||||
<view class="reason"> |
||||
<view class="left"> |
||||
退款原因: |
||||
</view> |
||||
<view class="right"> |
||||
{{ orderDetail.reasons || '' }} |
||||
</view> |
||||
</view> |
||||
<view class="reason"> |
||||
<view class="left"> |
||||
退款金额: |
||||
</view> |
||||
<view class="right"> ¥{{ orderDetail.refundAmount || 0 }} </view> |
||||
</view> |
||||
<view class="reason"> |
||||
<view class="left"> |
||||
退款编号: |
||||
</view> |
||||
<view class="right"> |
||||
{{ orderDetail.id || '' }} |
||||
</view> |
||||
</view> |
||||
<view class="reason"> |
||||
<view class="left"> |
||||
申请时间: |
||||
</view> |
||||
<view class="right"> |
||||
{{ orderDetail.createTime || '' }} |
||||
</view> |
||||
</view> |
||||
</view> |
||||
</view> --> |
||||
</view> |
||||
</template> |
||||
|
||||
<script> |
||||
import { getAfterSealsDetail, rebackAfterSeals } from '@/api/aftersales.js' |
||||
export default { |
||||
data() { |
||||
return { |
||||
orderId: '', |
||||
id: '', |
||||
orderInfo: {}, |
||||
orderDetail: {}, |
||||
returnStateLs: [ |
||||
{ |
||||
stateText: '提交申请', |
||||
tip: '已申请', |
||||
state: 0 |
||||
}, |
||||
{ |
||||
stateText: '申请审核', |
||||
tip: '已审核', |
||||
state: 1 |
||||
}, |
||||
// { |
||||
// stateText: '售后收货', |
||||
// tip: '待收货', |
||||
// state: 2, |
||||
// serviceType: 1 |
||||
// }, |
||||
// { |
||||
// stateText: '进行退款', |
||||
// tip: '已退款', |
||||
// state: 1, |
||||
// serviceType: 0 |
||||
// }, |
||||
{ |
||||
stateText: '进行退款', |
||||
tip: '已退款', |
||||
state: 2, |
||||
}, |
||||
{ |
||||
stateText: '处理完成', |
||||
tip: '已完成', |
||||
state: 3 |
||||
}, |
||||
] |
||||
} |
||||
}, |
||||
mounted() { |
||||
this.orderId = this.$yroute.query.key |
||||
this.id = this.$yroute.query.id |
||||
this.getReturnDetail() |
||||
}, |
||||
methods: { |
||||
/** state售后状态 0已提交等待平台审核 1平台已审核 等待用户发货/退款 2 用户已发货 3已完成 */ |
||||
async getReturnDetail() { |
||||
getAfterSealsDetail(this.orderId, this.id) |
||||
.then(res => { |
||||
this.orderDetail = res.data; |
||||
this.orderDetail.explainImg = res.data.explainImg.split(',') |
||||
}) |
||||
.catch(err => { |
||||
uni.showToast({ |
||||
title: '订单异常', |
||||
icon: 'none', |
||||
duration: 2000, |
||||
}) |
||||
}) |
||||
}, |
||||
toExpress() { |
||||
this.$yrouter.push({ |
||||
path: '/pages/order/submitExpress/index', |
||||
query: { |
||||
orderCode: this.orderId, |
||||
}, |
||||
}) |
||||
}, |
||||
// 撤销申请 |
||||
async cancelReq() { |
||||
rebackAfterSeals(this.orderId, this.id) |
||||
.then(res => { |
||||
uni.showToast({ |
||||
title: '已撤销', |
||||
icon: 'none', |
||||
duration: 2000, |
||||
}) |
||||
setTimeout(() => { |
||||
this.$yrouter.back() |
||||
}, 1500) |
||||
}) |
||||
.catch(err => { |
||||
uni.showToast({ |
||||
title: '撤销失败', |
||||
icon: 'none', |
||||
duration: 2000, |
||||
}) |
||||
}) |
||||
}, |
||||
// 修改申请 |
||||
editReq() {}, |
||||
}, |
||||
} |
||||
</script> |
||||
|
||||
<style scoped lang="less"> |
||||
.header { |
||||
.tab-title { |
||||
font-size: 32rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 600; |
||||
color: #2DB5AE; |
||||
line-height: 42rpx; |
||||
} |
||||
.backImg { |
||||
width: 88rpx; |
||||
height: 62rpx; |
||||
padding-left: 26rpx; |
||||
image { |
||||
width: 100%; |
||||
height: 100%; |
||||
} |
||||
} |
||||
} |
||||
|
||||
.content-box { |
||||
margin: 20rpx 32rpx; |
||||
padding: 20rpx 20rpx; |
||||
// width: 343px; |
||||
// height: 427px; |
||||
background: #F5F6F8; |
||||
box-shadow: 0rpx 10rpx 16rpx 0rpx rgba(0, 0, 0, 0.06); |
||||
border-radius: 16rpx; |
||||
.top-info { |
||||
padding-bottom: 30rpx; |
||||
font-size: 24rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 500; |
||||
color: #3A3A3C; |
||||
line-height: 32rpx; |
||||
view:first-child { |
||||
padding-bottom: 6rpx; |
||||
} |
||||
} |
||||
.current-progress-title { |
||||
width: 646rpx; |
||||
height: 56rpx; |
||||
padding: 0rpx 16rpx; |
||||
border-radius: 16rpx; |
||||
border: 2rpx solid #2DB5AE; |
||||
font-size: 24rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 600; |
||||
color: #2DB5AE; |
||||
line-height: 32rpx; |
||||
.progress-title { |
||||
padding-right: 14rpx; |
||||
border-right: 2rpx solid #2DB5AE; |
||||
} |
||||
.progress-text { |
||||
width: 484rpx; |
||||
font-weight: 500; |
||||
} |
||||
} |
||||
} |
||||
|
||||
.current-progress { |
||||
padding-top: 20rpx; |
||||
position: relative; |
||||
.item { |
||||
position: relative; |
||||
z-index: 1; |
||||
.tips-box { |
||||
width: 80rpx; |
||||
height: 48rpx; |
||||
margin-left: 6rpx; |
||||
margin-bottom: 8rpx; |
||||
.box { |
||||
width: 80rpx; |
||||
height: 36rpx; |
||||
background-color: #2DB5AE; |
||||
border-radius: 16rpx; |
||||
font-size: 18rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 600; |
||||
color: #FFFFFF; |
||||
line-height: 36rpx; |
||||
text-align: center; |
||||
} |
||||
.jiantou { |
||||
width: 0; |
||||
height: 0; |
||||
border-top: 12rpx solid #2DB5AE; |
||||
border-left: 6rpx solid transparent; |
||||
border-bottom: 0rpx solid transparent; |
||||
border-right: 6rpx solid transparent; |
||||
} |
||||
} |
||||
.state-box { |
||||
width: 92rpx; |
||||
height: 92rpx; |
||||
background: linear-gradient(rgba(27, 141, 204, 1), rgba(45, 183, 173, 1), rgba(57, 211, 150, 1)); |
||||
border-radius: 50%; |
||||
padding: 4rpx; |
||||
// margin-right: 42rpx; |
||||
.state { |
||||
width: 100%; |
||||
height: 100%; |
||||
background: linear-gradient(135deg, #39D396 0%, #2DB7AD 43%, #1B8DCC 100%); |
||||
border-radius: 50%; |
||||
font-size: 18rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 600; |
||||
color: #FFFFFF; |
||||
line-height: 84rpx; |
||||
text-align: center; |
||||
} |
||||
} |
||||
} |
||||
.line { |
||||
position: absolute; |
||||
top: 120rpx; |
||||
left: 86rpx; |
||||
z-index: 0; |
||||
width: 474rpx; |
||||
height: 6rpx; |
||||
background: linear-gradient(135deg, #39D396 0%, #2DB7AD 43%, #1B8DCC 100%); |
||||
} |
||||
} |
||||
|
||||
.content-box .info-item { |
||||
font-family: PingFang SC; |
||||
font-weight: 500; |
||||
.title { |
||||
font-size: 30rpx; |
||||
font-weight: 600; |
||||
color: #3A3A3C; |
||||
line-height: 42rpx; |
||||
padding: 24rpx 0rpx 10rpx; |
||||
} |
||||
.info { |
||||
font-size: 24rpx; |
||||
color: #999999; |
||||
line-height: 32rpx; |
||||
} |
||||
image { |
||||
width: 204rpx; |
||||
height: 204rpx; |
||||
border-radius: 16rpx; |
||||
// background: #dddddd; |
||||
margin-right: 17rpx; |
||||
} |
||||
image:last-child { |
||||
margin-right: 0rpx; |
||||
} |
||||
} |
||||
|
||||
@red: #2DB5AE; |
||||
.returnList { |
||||
.colorRed { |
||||
color: @red; |
||||
} |
||||
.bgRed { |
||||
background-color: @red; |
||||
} |
||||
.data { |
||||
width: 100%; |
||||
height: 150rpx; |
||||
line-height: 150rpx; |
||||
padding-left: 30rpx; |
||||
color: #fff; |
||||
} |
||||
.money { |
||||
background-color: #fff; |
||||
.top { |
||||
padding: 20rpx 30rpx; |
||||
font-size: 30rpx; |
||||
display: flex; |
||||
justify-content: space-between; |
||||
border-bottom: 2rpx solid #f3f4f5; |
||||
} |
||||
.express { |
||||
padding: 20rpx 30rpx; |
||||
font-size: 26rpx; |
||||
.title { |
||||
color: #333333; |
||||
} |
||||
.info { |
||||
color: #999999; |
||||
} |
||||
} |
||||
.tips { |
||||
height: 160rpx; |
||||
padding: 20rpx 30rpx; |
||||
color: #999999; |
||||
border-bottom: 2rpx solid #f3f4f5; |
||||
font-size: 26rpx; |
||||
.title { |
||||
overflow: hidden; |
||||
white-space: nowrap; |
||||
text-overflow: ellipsis; |
||||
} |
||||
.content { |
||||
font-size: 20rpx; |
||||
} |
||||
} |
||||
.bottom { |
||||
padding: 20rpx 30rpx; |
||||
display: flex; |
||||
justify-content: flex-end; |
||||
.btns { |
||||
width: 160rpx; |
||||
height: 58rpx; |
||||
margin: 0 10rpx; |
||||
font-size: 24rpx; |
||||
text-align: center; |
||||
line-height: 58rpx; |
||||
border-radius: 180rpx; |
||||
} |
||||
.def { |
||||
color: #dddddd; |
||||
border: 2rpx solid #dddddd; |
||||
} |
||||
.redBtn { |
||||
color: #fff; |
||||
background-color: @red; |
||||
} |
||||
} |
||||
} |
||||
.rebackInfo { |
||||
padding: 0 30rpx; |
||||
background-color: #fff; |
||||
.top { |
||||
height: 80rpx; |
||||
margin: 20rpx 0; |
||||
line-height: 80rpx; |
||||
font-size: 30rpx; |
||||
font-weight: bold; |
||||
color: #333333; |
||||
border-bottom: 2rpx solid #f3f4f5; |
||||
} |
||||
.rebackItem { |
||||
padding: 20rpx 0; |
||||
font-size: 28rpx; |
||||
display: flex; |
||||
border-bottom: 2rpx solid #f3f4f5; |
||||
.img { |
||||
width: 120rpx; |
||||
height: 120rpx; |
||||
} |
||||
.info { |
||||
margin-left: 16rpx; |
||||
flex: 1; |
||||
.productName { |
||||
width: 100%; |
||||
height: 80rpx; |
||||
overflow: hidden; |
||||
text-overflow: ellipsis; |
||||
color: #333333; |
||||
} |
||||
.sku { |
||||
font-size: 24rpx; |
||||
color: #cccccc; |
||||
} |
||||
} |
||||
} |
||||
.bottom { |
||||
padding: 20rpx 0; |
||||
.reason { |
||||
font-size: 28rpx; |
||||
color: #333333; |
||||
display: flex; |
||||
justify-content: space-between; |
||||
.right { |
||||
color: #aaaaaa; |
||||
} |
||||
} |
||||
} |
||||
} |
||||
} |
||||
</style> |
||||
|
@ -1,184 +1,254 @@
|
||||
<!-- 售后列表内容 --> |
||||
<template> |
||||
<view class="productItem"> |
||||
<view class="title"> |
||||
<view class="shopName"> |
||||
订单号:{{ item.orderCode }} |
||||
</view> |
||||
</view> |
||||
<view class="content" v-for="(i, index) in item.cartInfo"> |
||||
<image class="img" |
||||
:src="i.productInfo.image" |
||||
mode="" |
||||
@click.stop="goGoodsCon(i)" |
||||
></image> |
||||
<view class="info"> |
||||
<view class="infoTitle"> |
||||
{{ i.productInfo.storeName }} |
||||
</view> |
||||
<view class="infoSku"> |
||||
<view class="sku"> |
||||
{{ i.productInfo.attrInfo.sku || '' }} |
||||
</view> |
||||
<view class="num"> |
||||
x {{ 1 }} |
||||
</view> |
||||
</view> |
||||
<view class="infoMoney"> |
||||
退款:<view class="red"> |
||||
¥{{ i.productInfo.price }} |
||||
</view> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
<view class="money"> |
||||
<view class="status"> |
||||
<view v-if="item.salesState === 0"> |
||||
<view v-if="item.state === 0">商家处理中</view> |
||||
<view v-if="item.state === 1">售后中</view> |
||||
<view v-if="item.state === 2">等待商家收货</view> |
||||
<view v-if="item.state === 3">已完成</view> |
||||
</view> |
||||
<view v-if="item.salesState === 1"> |
||||
已撤销 |
||||
</view> |
||||
<view v-if="item.salesState === 2"> |
||||
商家拒绝 |
||||
</view> |
||||
</view> |
||||
<view class="refundMoney"> |
||||
退款:<view class="red"> |
||||
¥{{ item.refundAmount }} |
||||
</view> |
||||
</view> |
||||
</view> |
||||
<view class="btns"> |
||||
<view class="button def" |
||||
@click="toDetail" |
||||
v-if="item.state === 2" |
||||
>删除记录</view> |
||||
<view class="button redBtn" @click="toDetail(item)">查看详情</view> |
||||
</view> |
||||
</view> |
||||
</template> |
||||
|
||||
<script> |
||||
import { |
||||
deleteAfterSeals |
||||
} from '@/api/aftersales.js' |
||||
export default { |
||||
props: { |
||||
item: { |
||||
type: Object, |
||||
default: () => ({}) |
||||
} |
||||
}, |
||||
methods:{ |
||||
// 跳转商品 |
||||
goGoodsCon(item) { |
||||
this.$yrouter.push({ |
||||
path: "/pages/shop/GoodsCon/index", |
||||
query: { id: item.productInfo.id } |
||||
}); |
||||
}, |
||||
// 跳转售后详情 |
||||
toDetail (item) { |
||||
console.log(item) |
||||
this.$yrouter.push({ |
||||
path: "/pages/order/OrderReturnDetail/index", |
||||
query: { |
||||
key: item.orderCode, |
||||
id: item.id |
||||
} |
||||
}); |
||||
} |
||||
} |
||||
} |
||||
</script> |
||||
|
||||
<style lang="scss" scoped> |
||||
.productItem{ |
||||
margin: 10rpx 0; |
||||
background-color: #FFF; |
||||
.title{ |
||||
height: 80rpx; |
||||
padding: 0 30rpx; |
||||
color: #333; |
||||
font-size: 28rpx; |
||||
display: flex; |
||||
justify-content: space-between; |
||||
align-items: center; |
||||
} |
||||
.content{ |
||||
padding: 20rpx 30rpx; |
||||
border: 2rpx solid #F3F4F5; |
||||
display: flex; |
||||
.img{ |
||||
width: 180rpx; |
||||
height: 180rpx; |
||||
} |
||||
.info{ |
||||
flex: 1; |
||||
margin-left: 16rpx; |
||||
display: flex; |
||||
flex-direction: column; |
||||
justify-content: space-around; |
||||
.infoTitle{ |
||||
width: 100%; |
||||
height: 80rpx; |
||||
font-size: 28rpx; |
||||
color: #333333; |
||||
overflow: hidden; |
||||
text-overflow: ellipsis; |
||||
} |
||||
.infoSku{ |
||||
font-size: 24rpx; |
||||
color: #999999; |
||||
display: flex; |
||||
justify-content: space-between; |
||||
} |
||||
.infoMoney{ |
||||
font-size: 24rpx; |
||||
} |
||||
} |
||||
} |
||||
.money{ |
||||
height: 80rpx; |
||||
padding: 0 30rpx; |
||||
font-size: 28rpx; |
||||
font-family: PingFang SC; |
||||
color: #333333; |
||||
border: 2rpx solid #F3F4F5; |
||||
display: flex; |
||||
justify-content: space-between; |
||||
align-items: center; |
||||
} |
||||
.btns{ |
||||
padding: 20rpx 30rpx; |
||||
display: flex; |
||||
justify-content: flex-end; |
||||
.button{ |
||||
width: 160rpx; |
||||
height: 58rpx; |
||||
margin: 0 10rpx; |
||||
border-radius: 180rpx; |
||||
font-size: 24rpx; |
||||
line-height: 54rpx; |
||||
text-align: center; |
||||
} |
||||
.def{ |
||||
color: #DDD; |
||||
border: 2rpx solid #DDDDDD; |
||||
} |
||||
.redBtn{ |
||||
color: #FFF; |
||||
background-color: #EB3729; |
||||
border: 2rpx solid #EB3729; |
||||
} |
||||
} |
||||
.red{ |
||||
display: inline-block; |
||||
color: #EB3729; |
||||
} |
||||
} |
||||
</style> |
||||
<!-- 售后列表内容 --> |
||||
<template> |
||||
<view class="productItem"> |
||||
<view class="title acea-row row-between-wrapper"> |
||||
<view class="shopName">订单编号:{{ item.orderCode }}</view> |
||||
<view class="">申请时间:{{item.createTime}}</view> |
||||
</view> |
||||
<view class="content acea-row" v-for="(i, index) in item.cartInfo" :key="i.id"> |
||||
<image class="img" |
||||
:src="i.productInfo.image" |
||||
mode="aspectFill" |
||||
@click.stop="goGoodsCon(i)" |
||||
></image> |
||||
<view class="info"> |
||||
<view class="infoTitle line1"> |
||||
{{ i.productInfo.storeName }} |
||||
</view> |
||||
<view class="acea-row"> |
||||
<view class="sku">{{ i.productInfo.attrInfo.sku || '' }}</view> |
||||
</view> |
||||
<view class="money-num acea-row row-between"> |
||||
<view>¥{{ i.productInfo.price }}</view> |
||||
<view class="num">x{{ i.cartNum }}</view> |
||||
</view> |
||||
<!-- <view class="infoSku"> |
||||
<view class="sku"> |
||||
{{ i.productInfo.attrInfo.sku || '' }} |
||||
</view> |
||||
<view class="num"> |
||||
x {{ 1 }} |
||||
</view> |
||||
</view> --> |
||||
<!-- <view class="infoMoney"> |
||||
退款:<view class="red"> |
||||
¥{{ i.productInfo.price }} |
||||
</view> |
||||
</view> --> |
||||
</view> |
||||
</view> |
||||
<view class="money acea-row row-between-wrapper"> |
||||
<view class="status"> |
||||
<view v-if="item.salesState === 0"> |
||||
<view v-if="item.state === 0">商家处理中</view> |
||||
<view v-if="item.state === 1">售后中</view> |
||||
<view v-if="item.state === 2">等待商家收货</view> |
||||
<view v-if="item.state === 3">已完成</view> |
||||
</view> |
||||
<view v-if="item.salesState === 1"> |
||||
已撤销 |
||||
</view> |
||||
<view v-if="item.salesState === 2"> |
||||
商家拒绝 |
||||
</view> |
||||
</view> |
||||
<view class="btns"> |
||||
<view class="button redBtn" @click="toDetail(item)">查看详情</view> |
||||
</view> |
||||
|
||||
<!-- <view class="refundMoney"> |
||||
退款:<view class="red"> |
||||
¥{{ item.refundAmount }} |
||||
</view> |
||||
</view> --> |
||||
</view> |
||||
<!-- <view class="btns"> |
||||
<view class="button def" |
||||
@click="toDetail" |
||||
v-if="item.state === 2" |
||||
>删除记录</view> |
||||
<view class="button redBtn" @click="toDetail(item)">查看详情</view> |
||||
</view> --> |
||||
</view> |
||||
</template> |
||||
|
||||
<script> |
||||
import { |
||||
deleteAfterSeals |
||||
} from '@/api/aftersales.js' |
||||
export default { |
||||
props: { |
||||
item: { |
||||
type: Object, |
||||
default: () => ({}) |
||||
} |
||||
}, |
||||
methods:{ |
||||
// 跳转商品 |
||||
goGoodsCon(item) { |
||||
this.$yrouter.push({ |
||||
path: "/pages/shop/GoodsCon/index", |
||||
query: { id: item.productInfo.id } |
||||
}); |
||||
}, |
||||
// 跳转售后详情 |
||||
toDetail (item) { |
||||
console.log(item) |
||||
this.$yrouter.push({ |
||||
path: "/pages/order/OrderReturnDetail/index", |
||||
query: { |
||||
key: item.orderCode, |
||||
id: item.id |
||||
} |
||||
}); |
||||
} |
||||
} |
||||
} |
||||
</script> |
||||
|
||||
<style lang="scss" scoped> |
||||
.productItem{ |
||||
margin: 20rpx 32rpx; |
||||
padding: 20rpx; |
||||
// width: 343px; |
||||
// height: 291px; |
||||
background: #F5F6F8; |
||||
box-shadow: 0rpx 10rpx 16rpx 0rpx rgba(0, 0, 0, 0.06); |
||||
border-radius: 16rpx; |
||||
|
||||
// background-color: #FFF; |
||||
.title{ |
||||
font-size: 20rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 600; |
||||
color: #3A3A3C; |
||||
line-height: 26rpx; |
||||
padding-bottom: 34rpx; |
||||
|
||||
// height: 80rpx; |
||||
// padding: 0 30rpx; |
||||
// color: #333; |
||||
// font-size: 28rpx; |
||||
// display: flex; |
||||
// justify-content: space-between; |
||||
// align-items: center; |
||||
} |
||||
.content{ |
||||
padding-bottom: 20rpx; |
||||
// padding: 20rpx 30rpx; |
||||
// border: 2rpx solid #F3F4F5; |
||||
// display: flex; |
||||
.img { |
||||
width: 164rpx; |
||||
height: 164rpx; |
||||
border-radius: 12rpx; |
||||
} |
||||
.info { |
||||
// flex: 1; |
||||
width: 462rpx; |
||||
margin-left: 20rpx; |
||||
display: flex; |
||||
flex-direction: column; |
||||
justify-content: space-around; |
||||
.infoTitle{ |
||||
width: 100%; |
||||
height: 42rpx; |
||||
font-size: 26rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 500; |
||||
color: #3A3A3C; |
||||
line-height: 38rpx; |
||||
margin-bottom: 18rpx; |
||||
// overflow: hidden; |
||||
// text-overflow: ellipsis; |
||||
} |
||||
.sku { |
||||
padding: 0rpx 16rpx; |
||||
height: 46rpx; |
||||
background: #E3E3E3; |
||||
border-radius: 8rpx; |
||||
font-size: 20rpx; |
||||
color: #999999; |
||||
line-height: 46rpx; |
||||
} |
||||
.money-num { |
||||
font-size: 30rpx; |
||||
font-family: Futura; |
||||
font-weight: 600; |
||||
color: #3A3A3C; |
||||
line-height: 40rpx; |
||||
padding-top: 18rpx; |
||||
.num { |
||||
font-size: 24rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 500; |
||||
color: #999999; |
||||
line-height: 32rpx; |
||||
} |
||||
} |
||||
// .infoSku{ |
||||
// font-size: 24rpx; |
||||
// color: #999999; |
||||
// display: flex; |
||||
// justify-content: space-between; |
||||
// } |
||||
// .infoMoney{ |
||||
// font-size: 24rpx; |
||||
// } |
||||
} |
||||
} |
||||
.money{ |
||||
font-size: 24rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 500; |
||||
color: #3A3A3C; |
||||
line-height: 32rpx; |
||||
|
||||
// height: 80rpx; |
||||
// padding: 0 30rpx; |
||||
// font-size: 28rpx; |
||||
// font-family: PingFang SC; |
||||
// color: #333333; |
||||
// border: 2rpx solid #F3F4F5; |
||||
// display: flex; |
||||
// justify-content: space-between; |
||||
// align-items: center; |
||||
} |
||||
.btns{ |
||||
// padding: 20rpx 30rpx; |
||||
// display: flex; |
||||
// justify-content: flex-end; |
||||
.button{ |
||||
width: 166rpx; |
||||
height: 52rpx; |
||||
border-radius: 16rpx; |
||||
font-size: 24rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 500; |
||||
color: #2DB5AE; |
||||
line-height: 48rpx; |
||||
|
||||
// width: 160rpx; |
||||
// height: 58rpx; |
||||
// margin: 0 10rpx; |
||||
// border-radius: 180rpx; |
||||
// font-size: 24rpx; |
||||
// line-height: 54rpx; |
||||
text-align: center; |
||||
} |
||||
.def{ |
||||
color: #DDD; |
||||
border: 2rpx solid #DDDDDD; |
||||
} |
||||
.redBtn{ |
||||
// color: #FFF; |
||||
// background-color: #2DB5AE; |
||||
border: 2rpx solid #2DB5AE; |
||||
} |
||||
} |
||||
.red{ |
||||
display: inline-block; |
||||
color: #2DB5AE; |
||||
} |
||||
} |
||||
</style> |
||||
|
@ -0,0 +1,522 @@
|
||||
<template> |
||||
<view> |
||||
<view class="header"> |
||||
<cu-custom :isBack="true" :isCenter="true" :hasShadow="true"> |
||||
<block slot="backText"> |
||||
<view class="backImg"> |
||||
<image src="@/static/images/back-btn.png" mode=""></image> |
||||
</view> |
||||
</block> |
||||
<block slot="content"> |
||||
<view class="tab-title">甄选测评</view> |
||||
</block> |
||||
</cu-custom> |
||||
</view> |
||||
|
||||
<view class="synopsis-box acea-row" v-if="info.synopsis"> |
||||
<view class="left-circle"></view> |
||||
<view class="info"> |
||||
<!-- <text>甄选评测介绍</text> -->{{' ' + info.synopsis}} |
||||
</view> |
||||
<image src="../../../../static/images/evaluation-icon.png" mode=""></image> |
||||
</view> |
||||
|
||||
<view class="video-box" v-if="info.videoInput"> |
||||
<video |
||||
id="myVideo" |
||||
:src="info.videoInput" |
||||
@error="videoErrorCallback" |
||||
:show-center-play-btn="true" |
||||
:show-play-btn="true" |
||||
:show-mute-btn="true" |
||||
controls |
||||
></video> |
||||
<!-- picture-in-picture-mode="{{['push', 'pop']}}" |
||||
bindenterpictureinpicture='bindVideoEnterPictureInPicture' |
||||
bindleavepictureinpicture='bindVideoLeavePictureInPicture' --> |
||||
</view> |
||||
|
||||
<view class="productInfo-box acea-row row-between" v-if="info.productInfo"> |
||||
<image :src="info.productInfo.image" mode="aspectFill"></image> |
||||
<view class="right-text"> |
||||
<view class="name line1">{{info.productInfo.storeName}}</view> |
||||
<view class="info line1">{{info.productInfo.storeInfo}}</view> |
||||
<view class="acea-row row-between"> |
||||
<view class="price-box"> |
||||
<view class="price">¥{{info.productInfo.price}}</view> |
||||
<view class="otPrice">¥{{info.productInfo.otPrice}}</view> |
||||
</view> |
||||
<view class="btn" @click="goGoodsDetail">查看详情</view> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
|
||||
<!-- <view class="wrapper"> |
||||
<view class="item" v-if="info.summary"> |
||||
<view class="title-box acea-row row-middle"> |
||||
<view class="num">1</view> |
||||
<view class="">眼界甄选评测员总结</view> |
||||
</view> |
||||
<view class="info-text">{{info.summary}}</view> |
||||
</view> |
||||
<view class="item" v-if="info.feelSynopsis || info.feelImage"> |
||||
<view class="title-box acea-row row-middle"> |
||||
<view class="num">{{info.summary?'2':'1'}}</view> |
||||
<view class="">实用体验感受</view> |
||||
</view> |
||||
<view class="info-text" v-if="info.feelSynopsis">{{info.feelSynopsis}}</view> |
||||
<view class="images-box" v-if="info.feelImage"> |
||||
<swiper @change="feelCurrentChange"> |
||||
<swiper-item v-for="(item, index) in info.feelImageArr" :key="index"> |
||||
<image :src="item" mode="aspectFill"></image> |
||||
</swiper-item> |
||||
</swiper> |
||||
<view class="dot-box acea-row row-center"> |
||||
<view :class="'dot ' + (feelCurrent == index?'on':'')" v-for="(item,index) in info.feelImageArr" :key="index"></view> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
<view class="item" v-if="info.accessibilitySynopsis || info.accessibilityImage"> |
||||
<view class="title-box acea-row"> |
||||
<view class="num">{{info.summary?(info.feelSynopsis || info.feelImage?'3':'2'):(info.feelSynopsis || info.feelImage?'2':'1')}}</view> |
||||
<view class="">易用性体验</view> |
||||
</view> |
||||
<view class="info-text" v-if="info.accessibilitySynopsis">{{info.accessibilitySynopsis}}</view> |
||||
<view class="images-box" v-if="info.accessibilityImage"> |
||||
<swiper @change="accessibilityCurrentChange"> |
||||
<swiper-item v-for="(item, index) in info.accessibilityImageArr" :key="index"> |
||||
<image :src="item" mode="aspectFill"></image> |
||||
</swiper-item> |
||||
</swiper> |
||||
<view class="dot-box acea-row row-center"> |
||||
<view :class="'dot ' + (accessibilityCurrent == index?'on':'')" v-for="(item,index) in info.accessibilityImageArr" :key="index"></view> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
</view> --> |
||||
|
||||
<view class="wrapper-box"> |
||||
<view class="item" v-for="(item,index) in editableTabs" :key="index"> |
||||
<view class="title-box acea-row row-middle"> |
||||
<view class="num">{{index+1}}</view> |
||||
<view class="title">{{item.content}}</view> |
||||
</view> |
||||
<mp-html id="article" :setTitle="false" :lazy-load="true" :copy-link="false" :tag-style="tagStyle" |
||||
:content="item.configuration"/> |
||||
</view> |
||||
</view> |
||||
|
||||
<view :style="addBottom?'height: 162rpx;':'height: 122rpx;'"></view> |
||||
<view class="footer acea-row row-between" :style="addBottom?'height: 162rpx;':'height: 122rpx;'"> |
||||
<view class="acea-row btn-box row-around"> |
||||
<button class="item contacButton" open-type="share" hover-class="none"> |
||||
<image src="../../../../static/images/share-icon.png" mode=""></image> |
||||
<view class="">分享</view> |
||||
</button> |
||||
<button class="item contacButton" hover-class="none" @click.stop="getCollection"> |
||||
<image :src="`../../../../static/images/${isCollect?'star-light':'star'}.png`" mode=""></image> |
||||
<view class="">{{isCollect? '已收藏':'收藏'}}</view> |
||||
</button> |
||||
<!-- <view class="item" @click="share"> |
||||
<image src="../../../../static/images/share-icon.png" mode=""></image> |
||||
<view class="">分享</view> |
||||
</view> --> |
||||
</view> |
||||
<view class="btn" @click="goGoodsDetail">立即购买</view> |
||||
</view> |
||||
</view> |
||||
</template> |
||||
<script> |
||||
import { getEvaluationDetail,getUserCollection,delUserCollection} from '@/api/store' |
||||
export default { |
||||
data() { |
||||
return { |
||||
isCollect:true, |
||||
productInfo:{}, |
||||
addBottom: this.addBottom, |
||||
id: 0, |
||||
info: {}, |
||||
feelCurrent: 0, |
||||
accessibilityCurrent: 0, |
||||
editableTabs:[], |
||||
tagStyle: { |
||||
// p: 'text-indent:2em;font-family: PingFang SC;font-size:28rpx;', |
||||
img: 'padding:0;margin:20rpx 0;font-size:0;display:block;border-radius: 16rpx;' |
||||
} |
||||
}; |
||||
}, |
||||
onLoad() { |
||||
this.id = this._route.query.id |
||||
this.getInfo(this.id); |
||||
}, |
||||
onShareAppMessage() { |
||||
return { |
||||
title: '甄选测评', |
||||
path: '/pages/shop/Evaluations/EvaluationDetail/index?id='+this.id |
||||
} |
||||
}, |
||||
//分享到朋友圈 |
||||
onShareTimeline(res) { |
||||
return { |
||||
title: '甄选测评', |
||||
path: '/pages/shop/Evaluations/EvaluationDetail/index?id=' + this.id + '&spread=' + uni.getStorageSync('uid') + '&pageType=good&codeType=routine', |
||||
} |
||||
}, |
||||
methods: { |
||||
getCollection: function() { |
||||
let param={} |
||||
param.id=this.id |
||||
param.category= "collect" |
||||
if (this.isCollect) { |
||||
delUserCollection(param).then(res=>{ |
||||
this.isCollect=!this.isCollect |
||||
}) |
||||
}else{ |
||||
getUserCollection(param).then(res=>{ |
||||
this.isCollect=!this.isCollect |
||||
}) |
||||
} |
||||
}, |
||||
getInfo(id) { |
||||
uni.showLoading({ |
||||
title: '' |
||||
}) |
||||
getEvaluationDetail(id).then(res => { |
||||
this.info = res.data; |
||||
this.isCollect=this.info.isCollect; |
||||
this.$set(this,'editableTabs',res.data.editableTabs) |
||||
uni.hideLoading(); |
||||
}) |
||||
}, |
||||
videoErrorCallback(e) { |
||||
console.log('视频错误信息:') |
||||
console.log(e.detail.errMsg) |
||||
}, |
||||
goGoodsDetail() { |
||||
this.$yrouter.push({ |
||||
path: '/pages/shop/GoodsCon/index', |
||||
query: { |
||||
id: this.info.productInfo.id, |
||||
}, |
||||
}) |
||||
}, |
||||
feelCurrentChange(e) { |
||||
this.feelCurrent = e.detail.current; |
||||
}, |
||||
accessibilityCurrentChange(e) { |
||||
this.accessibilityCurrent = e.detail.current; |
||||
}, |
||||
} |
||||
} |
||||
</script> |
||||
|
||||
<style lang="less" scoped> |
||||
.header { |
||||
.tab-title { |
||||
font-size: 32rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 600; |
||||
color: #2DB5AE; |
||||
line-height: 42rpx; |
||||
} |
||||
.backImg { |
||||
width: 88rpx; |
||||
height: 62rpx; |
||||
padding-left: 26rpx; |
||||
image { |
||||
width: 100%; |
||||
height: 100%; |
||||
} |
||||
} |
||||
} |
||||
|
||||
.synopsis-box { |
||||
margin: 20rpx 32rpx 0rpx 90rpx; |
||||
padding: 20rpx 0rpx 20rpx 50rpx; |
||||
width: 628rpx; |
||||
min-height: 146rpx; |
||||
background: #F5F6F8; |
||||
box-shadow: 0rpx 10rpx 16rpx 0rpx rgba(0, 0, 0, 0.06); |
||||
border-radius: 16rpx; |
||||
position: relative; |
||||
.left-circle { |
||||
height: 98rpx; |
||||
width: 98rpx; |
||||
background: #F1F1F1; |
||||
border-radius: 50%; |
||||
position: absolute; |
||||
top: 22rpx; |
||||
left: -50rpx; |
||||
// box-shadow: 0rpx 10rpx 8rpx 0rpx rgba(0,0,0,0.15); |
||||
} |
||||
image { |
||||
width: 120rpx; |
||||
height: 120rpx; |
||||
position: absolute; |
||||
top: 24rpx; |
||||
left: -66rpx; |
||||
} |
||||
.info { |
||||
height: 100%; |
||||
overflow: hidden; |
||||
font-size: 20rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 500; |
||||
color: #2DB5AE; |
||||
line-height: 26rpx; |
||||
padding: 0rpx 8rpx; |
||||
// text { |
||||
// font-weight: 600; |
||||
// // padding-right: 6rpx; |
||||
// } |
||||
} |
||||
} |
||||
|
||||
.video-box { |
||||
margin: 20rpx 32rpx 0rpx; |
||||
width: 686rpx; |
||||
height: 384rpx; |
||||
box-shadow: 0rpx 10rpx 16rpx 0rpx rgba(0, 0, 0, 0.06); |
||||
border-radius: 16rpx; |
||||
#myVideo { |
||||
width: 686rpx; |
||||
height: 384rpx; |
||||
border-radius: 16rpx; |
||||
} |
||||
} |
||||
|
||||
.productInfo-box { |
||||
margin: 20rpx 32rpx 0rpx; |
||||
width: 686rpx; |
||||
height: 178rpx; |
||||
background: #F5F6F8; |
||||
box-shadow: 0rpx 10rpx 16rpx 0rpx rgba(0, 0, 0, 0.06); |
||||
border-radius: 16rpx; |
||||
padding: 8rpx; |
||||
image { |
||||
width: 164rpx; |
||||
height: 164rpx; |
||||
border-radius: 16rpx; |
||||
} |
||||
.right-text { |
||||
width: 478rpx; |
||||
margin-right: 8rpx; |
||||
padding-top: 8rpx; |
||||
font-size: 20rpx; |
||||
font-family: SourceHanSansSCVF; |
||||
font-weight: 600; |
||||
color: #999999; |
||||
line-height: 28rpx; |
||||
.name { |
||||
font-size: 26rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 500; |
||||
color: #3A3A3C; |
||||
line-height: 38rpx; |
||||
} |
||||
.info { |
||||
padding-bottom: 14rpx; |
||||
} |
||||
.price-box { |
||||
font-family: Futura; |
||||
.price { |
||||
color: #3A3A3C; |
||||
line-height: 36rpx; |
||||
font-size: 30rpx; |
||||
} |
||||
.otPrice { |
||||
text-decoration: line-through; |
||||
} |
||||
} |
||||
.btn { |
||||
margin-top: 18rpx; |
||||
width: 138rpx; |
||||
height: 42rpx; |
||||
background: #2DB5AE; |
||||
border-radius: 16rpx; |
||||
font-size: 24rpx; |
||||
font-family: PingFang SC; |
||||
color: #FFFFFF; |
||||
line-height: 42rpx; |
||||
text-align: center; |
||||
} |
||||
} |
||||
} |
||||
|
||||
// .wrapper { |
||||
// margin: 20rpx 32rpx; |
||||
// padding: 16rpx 24rpx; |
||||
// width: 686rpx; |
||||
// background: #F5F6F8; |
||||
// box-shadow: 0rpx 10rpx 16rpx 0rpx rgba(0,0,0,0.15); |
||||
// border-radius: 16rpx; |
||||
// .item { |
||||
// padding-bottom: 22rpx; |
||||
// .title-box { |
||||
// font-size: 30rpx; |
||||
// font-family: SourceHanSansSCVF; |
||||
// font-weight: 600; |
||||
// color: #3A3A3C; |
||||
// line-height: 23px; |
||||
// .num { |
||||
// width: 34rpx; |
||||
// height: 34rpx; |
||||
// border-radius: 50%; |
||||
// background: #2DB5AE; |
||||
// font-size: 20rpx; |
||||
// font-family: PingFang SC; |
||||
// font-weight: 600; |
||||
// color: #FFFFFF; |
||||
// line-height: 34rpx; |
||||
// text-align: center; |
||||
// margin-right: 8rpx; |
||||
// } |
||||
// } |
||||
// .info-text { |
||||
// margin-bottom: 24rpx; |
||||
// font-size: 24rpx; |
||||
// font-family: PingFang SC; |
||||
// font-weight: 500; |
||||
// color: #3A3A3C; |
||||
// line-height: 32rpx; |
||||
// text-indent: 42rpx; |
||||
// } |
||||
// .images-box { |
||||
// padding-bottom: 24rpx; |
||||
// position: relative; |
||||
// swiper { |
||||
// width: 638rpx; |
||||
// height: 360rpx; |
||||
// border-radius: 16rpx; |
||||
// overflow: hidden; |
||||
// swiper-item { |
||||
// border-radius: 16rpx; |
||||
// image { |
||||
// width: 638rpx; |
||||
// height: 360rpx; |
||||
// border-radius: 16rpx; |
||||
// } |
||||
// } |
||||
// } |
||||
// .dot-box { |
||||
// position: absolute; |
||||
// bottom: 40rpx; |
||||
// left: 50%; |
||||
// transform: translateX(-50%); |
||||
// .dot { |
||||
// width: 8rpx; |
||||
// height: 8rpx; |
||||
// background: #FFFFFF; |
||||
// border-radius: 6rpx; |
||||
// margin: 0rpx 8rpx; |
||||
// transition: width .5s cubic-bezier(.18,.89,.17,.88); |
||||
// } |
||||
// .on { |
||||
// width: 36rpx; |
||||
// background: #2DB5AE; |
||||
// transition: width .5s cubic-bezier(.18,.89,.17,.88); |
||||
// } |
||||
// } |
||||
// } |
||||
// } |
||||
// } |
||||
|
||||
.wrapper-box { |
||||
margin: 20rpx 32rpx; |
||||
padding: 16rpx 24rpx; |
||||
width: 686rpx; |
||||
background: #F5F6F8; |
||||
box-shadow: 0rpx 10rpx 16rpx 0rpx rgba(0, 0, 0, 0.06); |
||||
border-radius: 16rpx; |
||||
.item { |
||||
padding-bottom: 22rpx; |
||||
.title-box { |
||||
// padding: 0 30rpx; |
||||
font-size: 30rpx; |
||||
font-family: SourceHanSansSCVF; |
||||
font-weight: 600; |
||||
color: #3A3A3C; |
||||
line-height: 23px; |
||||
margin-bottom: 10rpx; |
||||
.num { |
||||
width: 34rpx; |
||||
height: 34rpx; |
||||
border-radius: 50%; |
||||
background: #2DB5AE; |
||||
font-size: 20rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 600; |
||||
color: #FFFFFF; |
||||
line-height: 34rpx; |
||||
text-align: center; |
||||
margin-right: 8rpx; |
||||
} |
||||
.title{ |
||||
font-size: 32rpx; |
||||
font-weight: 600; |
||||
} |
||||
} |
||||
.info-text { |
||||
margin-bottom: 24rpx; |
||||
font-size: 24rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 500; |
||||
color: #3A3A3C; |
||||
line-height: 32rpx; |
||||
text-indent: 42rpx; |
||||
} |
||||
|
||||
} |
||||
} |
||||
|
||||
|
||||
|
||||
.footer { |
||||
position: fixed; |
||||
bottom: 0; |
||||
left: 0; |
||||
width: 750rpx; |
||||
background: #F1F1F1; |
||||
box-shadow: 0rpx -4rpx 38rpx 0rpx rgba(0,0,0,0.2); |
||||
border-radius: 28rpx 28rpx 0rpx 0rpx; |
||||
padding: 12rpx 32rpx 0rpx; |
||||
.btn-box{ |
||||
width: 35%; |
||||
} |
||||
.contacButton { |
||||
height: 80rpx; |
||||
padding: 0; |
||||
background-color: #F1F1F1; |
||||
width: 100rpx; |
||||
} |
||||
.contacButton::after { |
||||
border: 0; |
||||
} |
||||
.item { |
||||
text-align: center; |
||||
font-size: 20rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 500; |
||||
color: #3A3A3C; |
||||
line-height: 22rpx; |
||||
image { |
||||
width: 50rpx; |
||||
height: 50rpx; |
||||
} |
||||
} |
||||
.btn { |
||||
margin-top: 6rpx; |
||||
width: 386rpx; |
||||
height: 66rpx; |
||||
background: #2DB5AE; |
||||
border-radius: 16rpx; |
||||
font-size: 26rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 600; |
||||
color: #FFFFFF; |
||||
line-height: 66rpx; |
||||
text-align: center; |
||||
} |
||||
} |
||||
|
||||
</style> |
@ -0,0 +1,117 @@
|
||||
<template> |
||||
<view> |
||||
<view class="header"> |
||||
<cu-custom :isBack="true" :isCenter="true"> |
||||
<block slot="backText"> |
||||
<view class="backImg"> |
||||
<image src="@/static/images/back-btn.png" mode=""></image> |
||||
</view> |
||||
</block> |
||||
<block slot="content"> |
||||
<image class="tab-title" src="../../../static/images/yanjie-logo.png" mode=""></image> |
||||
</block> |
||||
</cu-custom> |
||||
</view> |
||||
|
||||
<view class="title-box"> |
||||
<view class="en-title">SELECTION EVALUATION</view> |
||||
<view class="title">甄选评测</view> |
||||
</view> |
||||
|
||||
<view class="list-box"> |
||||
<view class="item" v-for="(item,index) in evaluations" :key="index" @click="goDetail(item)"> |
||||
<image :src="item.homeImage" mode="aspectFill"></image> |
||||
</view> |
||||
</view> |
||||
|
||||
</view> |
||||
</template> |
||||
|
||||
<script> |
||||
import { getEvaluation } from '@/api/store' |
||||
export default { |
||||
data() { |
||||
return { |
||||
evaluations: [], |
||||
}; |
||||
}, |
||||
onLoad() { |
||||
this.getData(); |
||||
}, |
||||
methods: { |
||||
getData() { |
||||
uni.showLoading({ |
||||
title: "加载中", |
||||
}); |
||||
getEvaluation().then(res => { |
||||
this.evaluations = res.data; |
||||
uni.hideLoading(); |
||||
}) |
||||
}, |
||||
goDetail(item) { |
||||
uni.navigateTo({ |
||||
url: '/pages/shop/Evaluations/EvaluationDetail/index?id=' + item.id |
||||
}) |
||||
// this.$yrouter.push({ |
||||
// path: '/pages/shop/Evaluations/EvaluationDetail/index', |
||||
// query: { |
||||
// id: item.id |
||||
// }, |
||||
// }) |
||||
} |
||||
} |
||||
} |
||||
</script> |
||||
|
||||
<style lang="less" scoped> |
||||
.header { |
||||
.tab-title { |
||||
width: 184rpx; |
||||
height: 46rpx; |
||||
} |
||||
.backImg { |
||||
width: 88rpx; |
||||
height: 62rpx; |
||||
padding-left: 26rpx; |
||||
image { |
||||
width: 100%; |
||||
height: 100%; |
||||
} |
||||
} |
||||
} |
||||
|
||||
.title-box { |
||||
padding: 22rpx 32rpx 24rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 600; |
||||
.en-title { |
||||
font-size: 20rpx; |
||||
font-family: Futura; |
||||
color: #999999; |
||||
line-height: 22rpx; |
||||
} |
||||
.title { |
||||
font-size: 50rpx; |
||||
color: #3A3A3C; |
||||
line-height: 68rpx; |
||||
} |
||||
} |
||||
|
||||
.list-box { |
||||
padding: 0rpx 32rpx 20rpx; |
||||
.item { |
||||
width: 686rpx; |
||||
height: 230rpx; |
||||
background: #F5F6F8; |
||||
box-shadow: 0rpx 10rpx 16rpx 0rpx rgba(0, 0, 0, 0.06); |
||||
border-radius: 16rpx; |
||||
margin-bottom: 20rpx; |
||||
image { |
||||
width: 100%; |
||||
height: 100%; |
||||
border-radius: 16rpx; |
||||
} |
||||
} |
||||
} |
||||
|
||||
</style> |
@ -1,101 +1,495 @@
|
||||
<template> |
||||
<view ref="container"> |
||||
<view class="collectionGoods" v-if="collectProductList.length > 0"> |
||||
<view class="item acea-row row-between-wrapper" v-for="(item, collectProductListIndex) in collectProductList" :key="collectProductListIndex" @click="goGoodsCon(item)"> |
||||
<view class="pictrue"> |
||||
<image :src="item.image" /> |
||||
</view> |
||||
<view class="text acea-row row-column-between"> |
||||
<view class="infor line1">{{ item.storeName }}</view> |
||||
<view class="acea-row row-between-wrapper"> |
||||
<view class="money font-color-red" v-if="isIntegral == 1">{{ item.costPrice }}积分</view> |
||||
<view class="money font-color-red" v-else>¥{{ item.price }}</view> |
||||
<view class="delete" @tap.stop="delCollection(collectProductListIndex)">删除</view> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
<Loading :loaded="loadend" :loading="loading"></Loading> |
||||
<view class="noCommodity" style="background-color:#fff;" v-if="collectProductList.length < 1 && page > 1"> |
||||
<view ref="container"> |
||||
<view class="header"> |
||||
<cu-custom :isBack="true" :isCenter="true"> |
||||
<block slot="backText"> |
||||
<view class="backImg"> |
||||
<image src="@/static/images/back-btn.png" mode=""></image> |
||||
</view> |
||||
</block> |
||||
<block slot="content"> |
||||
<view class="tab-title">我的收藏</view> |
||||
</block> |
||||
</cu-custom> |
||||
</view> |
||||
|
||||
<view class="content" :style="'min-height:calc(100vh - '+CustomBar+'px);'"> |
||||
<view class="nav-box" :style="'top:'+CustomBar+'px;'"> |
||||
<view class="nav acea-row row-around"> |
||||
<view class="item" @click="changeType(0)"> |
||||
<view :class="'title ' + (navType == 0? 'active' : '')">甄选商品</view> |
||||
</view> |
||||
<view class="item" @click="changeType(1)"> |
||||
<view :class="'title ' + (navType === 1 ? 'active' : '')">甄选评测</view> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
|
||||
<view class="collectionGoods" v-if="collectProductList.length > 0"> |
||||
<view class="item" v-for="(item, collectProductListIndex) in collectProductList" |
||||
:key="collectProductListIndex" :data-index="collectProductListIndex" @touchstart="drawStart" |
||||
@touchmove="drawMove" @touchend="drawEnd" :style="'right:' + item.right + 'rpx'"> |
||||
<view v-if="navType==0" class="info-box acea-row row-between-wrapper" @click="goGoodsCon(item)"> |
||||
<view class="pictrue"> |
||||
<image :src="item.image" /> |
||||
</view> |
||||
<view class="text"> |
||||
<view class="infor line1">{{ item.storeName }}</view> |
||||
<view class="acea-row sku-box"> |
||||
<view class="sku" v-if="item.productInfo.attrInfo"> |
||||
{{ item.productInfo.attrInfo.sku }}</view> |
||||
</view> |
||||
<view class="money" v-if="isIntegral == 1">{{ item.costPrice }}积分</view> |
||||
<view class="money" v-else>¥{{ item.price }}</view> |
||||
</view> |
||||
</view> |
||||
<!-- 评测 --> |
||||
<view v-else class="review-box acea-row row-between" @click="goEvaluation(item)"> |
||||
<image class="img" :src="item.homeImage" mode="aspectFill"></image> |
||||
<!-- <view class="more">MORE</view> --> |
||||
</view> |
||||
<view class="delete" @tap.stop="delCollection(collectProductListIndex)" |
||||
:style="item.right?'right: -122rpx;':''" :class="{'del-height':navType==1}">删除</view> |
||||
</view> |
||||
<Loading :loaded="loadend" :loading="loading"></Loading> |
||||
</view> |
||||
|
||||
<!--暂无收藏--> |
||||
<view v-else class="noCommodity" style="padding-top:208rpx;"> |
||||
<view class="noPictrue"> |
||||
<image src="@/static/images/no-more.png" class="image" /> |
||||
</view> |
||||
<view class="text-big"> |
||||
什么都没有,大概被外星人带走了 |
||||
</view> |
||||
<!-- <view class="text-small"> |
||||
快去领取福利优惠券吧 |
||||
</view> --> |
||||
</view> |
||||
|
||||
</view> |
||||
|
||||
|
||||
<!-- <view class="noCommodity" style="background-color:#fff;" v-if="collectProductList.length < 1 && page > 1"> |
||||
<view class="noPictrue"> |
||||
<image :src="`${$VUE_APP_RESOURCES_URL}/images/noCollection.png`" class="image" /> |
||||
</view> |
||||
<Recommend></Recommend> |
||||
</view> |
||||
</view> |
||||
</view> --> |
||||
</view> |
||||
</template> |
||||
<script> |
||||
import Recommend from '@/components/Recommend' |
||||
import { getCollectUser, getCollectDel } from '@/api/user' |
||||
import Loading from '@/components/Loading' |
||||
export default { |
||||
name: 'GoodsCollection', |
||||
components: { |
||||
Recommend, |
||||
Loading, |
||||
}, |
||||
props: {}, |
||||
data: function() { |
||||
return { |
||||
page: 1, |
||||
limit: 20, |
||||
type: 'collect', |
||||
collectProductList: [], |
||||
loadTitle: '', |
||||
loading: false, |
||||
loadend: false, |
||||
} |
||||
}, |
||||
mounted: function() { |
||||
this.get_user_collect_product() |
||||
}, |
||||
onReachBottom() { |
||||
!this.loading && this.get_user_collect_product() |
||||
}, |
||||
methods: { |
||||
goGoodsCon(item) { |
||||
if (item.isIntegral == 1) { |
||||
this.$yrouter.push({ |
||||
path: '/pages/shop/GoodsCon/index', |
||||
query: { id: item.pid }, |
||||
}) |
||||
} else { |
||||
this.$yrouter.push({ |
||||
path: '/pages/shop/GoodsCon/index', |
||||
query: { id: item.pid }, |
||||
}) |
||||
} |
||||
}, |
||||
get_user_collect_product: function() { |
||||
let that = this |
||||
if (that.loading) return //阻止下次请求(false可以进行请求); |
||||
if (that.loadend) return //阻止结束当前请求(false可以进行请求); |
||||
that.loading = true |
||||
getCollectUser(that.page, that.limit, that.type).then(res => { |
||||
that.loading = false |
||||
//apply();js将一个数组插入另一个数组; |
||||
that.collectProductList.push.apply(that.collectProductList, res.data) |
||||
that.loadend = res.data.length < that.limit //判断所有数据是否加载完成; |
||||
that.page = that.page + 1 |
||||
}) |
||||
}, |
||||
//删除收藏; |
||||
delCollection: function(index) { |
||||
let that = this, |
||||
id = that.collectProductList[index].pid, |
||||
category = that.collectProductList[index].category |
||||
getCollectDel(id, category).then(function() { |
||||
uni.showToast({ |
||||
title: '删除成功', |
||||
icon: 'success', |
||||
duration: 2000, |
||||
complete: () => { |
||||
that.collectProductList.splice(index, 1) |
||||
that.$set(that, 'collectProductList', that.collectProductList) |
||||
}, |
||||
}) |
||||
}) |
||||
}, |
||||
}, |
||||
} |
||||
import Recommend from '@/components/Recommend' |
||||
import { |
||||
getCollectUser, |
||||
getCollectDel, |
||||
getCollectEvaluation |
||||
} from '@/api/user' |
||||
import { |
||||
delUserCollection |
||||
} from '@/api/store.js' |
||||
import Loading from '@/components/Loading' |
||||
export default { |
||||
name: 'GoodsCollection', |
||||
components: { |
||||
Recommend, |
||||
Loading, |
||||
}, |
||||
props: {}, |
||||
data: function() { |
||||
return { |
||||
CustomBar: this.CustomBar, |
||||
navType: 0, |
||||
page: 1, |
||||
limit: 20, |
||||
type: 'collect', |
||||
collectProductList: [], |
||||
loadTitle: '', |
||||
loading: false, |
||||
loadend: false, |
||||
delBtnWidth: 154, |
||||
startX: 0 |
||||
} |
||||
}, |
||||
mounted: function() { |
||||
this.get_user_collect_product(this.navType) |
||||
}, |
||||
onReachBottom() { |
||||
!this.loading && this.get_user_collect_product(this.navType) |
||||
}, |
||||
methods: { |
||||
changeType(i) { |
||||
if (this.navType == i) return; |
||||
this.navType = i; |
||||
this.collectProductList = [] |
||||
this.page = 1 |
||||
this.limit = 20 |
||||
this.get_user_collect_product(this.navType) |
||||
}, |
||||
|
||||
drawStart(e) { |
||||
var touch = e.touches[0]; |
||||
// let index = e.currentTarget.dataset.index; |
||||
for (var index in this.collectProductList) { |
||||
this.collectProductList[index].right = 0; |
||||
} |
||||
this.startX = touch.clientX; |
||||
// console.log(this.startX, "drawStart", index) |
||||
}, |
||||
drawMove(e) { |
||||
let touch = e.touches[0]; |
||||
// console.log(touch, "drawMove") |
||||
let index = e.currentTarget.dataset.index; |
||||
let item = this.collectProductList[index]; |
||||
let disX = this.startX - touch.clientX; |
||||
|
||||
// console.log(index, "drawMove") |
||||
if (disX >= 20) { |
||||
if (disX > this.delBtnWidth) { |
||||
disX = this.delBtnWidth; |
||||
} |
||||
this.collectProductList[index].right = disX; |
||||
} else { |
||||
this.collectProductList[index].right = 0; |
||||
} |
||||
}, |
||||
drawEnd(e) { |
||||
let index = e.currentTarget.dataset.index; |
||||
let item = this.collectProductList[index]; |
||||
console.log(item.right, "drawEnd", index); |
||||
if (item.right >= 80) { |
||||
this.collectProductList[index].right = this.delBtnWidth; |
||||
} else { |
||||
this.collectProductList[index].right = 0; |
||||
} |
||||
console.log(this.collectProductList, "drawEnd", index); |
||||
}, |
||||
goGoodsCon(item) { |
||||
if (item.isIntegral == 1) { |
||||
this.$yrouter.push({ |
||||
path: '/pages/shop/GoodsCon/index', |
||||
query: { |
||||
id: item.pid |
||||
}, |
||||
}) |
||||
} else { |
||||
this.$yrouter.push({ |
||||
path: '/pages/shop/GoodsCon/index', |
||||
query: { |
||||
id: item.pid |
||||
}, |
||||
}) |
||||
} |
||||
}, |
||||
|
||||
goEvaluation(item) { |
||||
this.$yrouter.push({ |
||||
// 跳转评测详情 |
||||
path: '/pages/shop/Evaluations/EvaluationDetail/index', |
||||
query: { |
||||
id: item.evaluationId |
||||
}, |
||||
}) |
||||
}, |
||||
get_user_collect_product: function(navType) { |
||||
|
||||
let that = this |
||||
|
||||
if (that.loading) return //阻止下次请求(false可以进行请求); |
||||
// if (that.loadend) return //阻止结束当前请求(false可以进行请求); |
||||
that.loading = true |
||||
if (navType === 1) { |
||||
// 获取评测收藏 collectEvaluation/user |
||||
getCollectEvaluation(that.page, that.limit, that.type).then(res => { |
||||
that.loading = false |
||||
//apply();js将一个数组插入另一个数组; |
||||
var arr = []; |
||||
for (var i in res.data) { |
||||
res.data[i].right = 0; |
||||
arr.push(res.data[i]) |
||||
}; |
||||
that.collectProductList.push.apply(that.collectProductList, arr) |
||||
// this.collectProductList.forEach(val => { |
||||
// val.right = 0; |
||||
// }) |
||||
that.loadend = res.data.length < that.limit //判断所有数据是否加载完成; |
||||
that.page = that.page + 1 |
||||
}) |
||||
} else { |
||||
getCollectUser(that.page, that.limit, that.type).then(res => { |
||||
that.loading = false |
||||
//apply();js将一个数组插入另一个数组; |
||||
var arr = []; |
||||
for (var i in res.data) { |
||||
res.data[i].right = 0; |
||||
arr.push(res.data[i]) |
||||
}; |
||||
that.collectProductList.push.apply(that.collectProductList, arr) |
||||
// this.collectProductList.forEach(val => { |
||||
// val.right = 0; |
||||
// }) |
||||
that.loadend = res.data.length < that.limit //判断所有数据是否加载完成; |
||||
that.page = that.page + 1 |
||||
}) |
||||
|
||||
} |
||||
|
||||
}, |
||||
//删除收藏; |
||||
delCollection: function(index) { |
||||
let that = this |
||||
|
||||
if (that.navType === 0) { |
||||
let id = that.collectProductList[index].pid, |
||||
category = that.collectProductList[index].category |
||||
getCollectDel(id, category).then(function() { |
||||
uni.showToast({ |
||||
title: '删除成功', |
||||
icon: 'success', |
||||
duration: 2000, |
||||
complete: () => { |
||||
that.collectProductList.splice(index, 1) |
||||
that.$set(that, 'collectProductList', that.collectProductList) |
||||
}, |
||||
}) |
||||
}) |
||||
} else { |
||||
// 取消评测收藏 |
||||
let param={} |
||||
param.id=that.collectProductList[index].evaluationId, |
||||
param.category= "collect" |
||||
delUserCollection(param).then(function() { |
||||
uni.showToast({ |
||||
title: '删除成功', |
||||
icon: 'success', |
||||
duration: 2000, |
||||
complete: () => { |
||||
that.collectProductList.splice(index, 1) |
||||
that.$set(that, 'collectProductList', that.collectProductList) |
||||
}, |
||||
}) |
||||
}) |
||||
} |
||||
|
||||
}, |
||||
|
||||
}, |
||||
} |
||||
</script> |
||||
<style lang="less" scoped> |
||||
.review-box { |
||||
border-radius: 16rpx; |
||||
background: #F5F6F8; |
||||
box-shadow: 0rpx 10rpx 16rpx 0rpx rgba(0, 0, 0, 0.06); |
||||
position: relative; |
||||
.img { |
||||
width: 687rpx; |
||||
height: 240rpx; |
||||
border-radius: 16rpx; |
||||
} |
||||
|
||||
.more { |
||||
font-size: 24rpx; |
||||
position: absolute; |
||||
left: 30rpx; |
||||
bottom: 30rpx; |
||||
} |
||||
|
||||
.more::before { |
||||
position: absolute; |
||||
border-bottom: 1rpx solid black; |
||||
bottom: -8rpx; |
||||
left: -4rpx; |
||||
content: ''; |
||||
width: 100rpx; |
||||
background-color: black; |
||||
height: 1rpx; |
||||
} |
||||
|
||||
.more::after { |
||||
margin-left: 10rpx; |
||||
content: ''; |
||||
display: inline-block; |
||||
width: 0; |
||||
height: 0; |
||||
border-top: 10rpx solid transparent; |
||||
border-left: 10rpx solid black; |
||||
border-bottom: 10rpx solid transparent; |
||||
border-right: 10rpx solid transparent; |
||||
} |
||||
} |
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
.header { |
||||
.tab-title { |
||||
font-size: 32rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 600; |
||||
color: #2DB5AE; |
||||
line-height: 42rpx; |
||||
} |
||||
|
||||
.backImg { |
||||
width: 88rpx; |
||||
height: 62rpx; |
||||
padding-left: 26rpx; |
||||
|
||||
image { |
||||
width: 100%; |
||||
height: 100%; |
||||
} |
||||
} |
||||
} |
||||
|
||||
// .content-box { |
||||
// padding-top: 4rpx; |
||||
// width: 100vw; |
||||
// position: relative; |
||||
|
||||
.content { |
||||
width: 100%; |
||||
height: 100%; |
||||
overflow-y: scroll; |
||||
background: #FFFFFF; |
||||
border-radius: 28rpx 28rpx 0rpx 0rpx; |
||||
|
||||
.nav-box { |
||||
width: 100vw; |
||||
padding-top: 4rpx; |
||||
position: fixed; |
||||
left: 0; |
||||
z-index: 5; |
||||
background: #F1F1F1; |
||||
} |
||||
.nav { |
||||
width: 100vw; |
||||
background: #FFFFFF; |
||||
height: 92rpx; |
||||
padding: 34rpx 32rpx 16rpx; |
||||
border-radius: 28rpx 28rpx 0rpx 0rpx; |
||||
|
||||
.item { |
||||
width: 112rpx; |
||||
text-align: center; |
||||
position: relative; |
||||
|
||||
.title { |
||||
font-size: 26rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 500; |
||||
color: #3A3A3C; |
||||
line-height: 38rpx; |
||||
} |
||||
|
||||
.active { |
||||
color: #2DB5AE; |
||||
font-weight: 600; |
||||
} |
||||
|
||||
.title::after { |
||||
display: block; |
||||
content: ''; |
||||
width: 100%; |
||||
height: 4rpx; |
||||
background: #2DB5AE; |
||||
position: absolute; |
||||
bottom: 0; |
||||
left: 0; |
||||
opacity: 0; |
||||
transform: scaleX(0); |
||||
transition: all .2s cubic-bezier(.18, .89, .17, .88), opacity .15s ease; |
||||
} |
||||
|
||||
.active::after { |
||||
opacity: 1; |
||||
transform: scaleX(1); |
||||
} |
||||
} |
||||
} |
||||
} |
||||
// } |
||||
|
||||
.info-box { |
||||
width: 686rpx; |
||||
height: 202rpx; |
||||
background: #F5F6F8; |
||||
box-shadow: 0rpx 10rpx 16rpx 0rpx rgba(0, 0, 0, 0.06); |
||||
border-radius: 16rpx; |
||||
padding: 20rpx; |
||||
|
||||
.sku-box { |
||||
margin: 18rpx 0rpx; |
||||
height: 46rpx; |
||||
} |
||||
|
||||
.sku { |
||||
padding: 0rpx 16rpx; |
||||
height: 46rpx; |
||||
background: #E3E3E3; |
||||
border-radius: 8rpx; |
||||
font-size: 20rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 500; |
||||
color: #999999; |
||||
line-height: 46rpx; |
||||
} |
||||
} |
||||
|
||||
.collectionGoods { |
||||
padding-top: 114rpx; |
||||
} |
||||
.collectionGoods .item .delete { |
||||
position: absolute; |
||||
top: 0; |
||||
right: -186rpx; |
||||
width: 154rpx; |
||||
height: 202rpx; |
||||
background: #EC3A5B; |
||||
box-shadow: 0rpx 10rpx 16rpx 0rpx rgba(0, 0, 0, 0.06); |
||||
border-radius: 16rpx; |
||||
font-size: 26rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 600; |
||||
color: #FFFFFF; |
||||
line-height: 202rpx; |
||||
text-align: center; |
||||
text-shadow: 0rpx 10rpx 16rpx rgba(0, 0, 0, 0.15); |
||||
} |
||||
|
||||
.del-height { |
||||
height: 240rpx !important; |
||||
line-height: 240rpx !important; |
||||
} |
||||
|
||||
.noCommodity{ |
||||
.noPictrue{ |
||||
width: 428rpx; |
||||
height: 526rpx; |
||||
} |
||||
.text-big{ |
||||
padding: 0 30rpx; |
||||
text-align: center; |
||||
font-family: PingFangSC-Medium, PingFang SC; |
||||
font-style: 36rpx; |
||||
font-weight: 600; |
||||
color: #3A3A3C; |
||||
line-height: 50rpx; |
||||
} |
||||
.text-small{ |
||||
padding: 0 80rpx; |
||||
font-family: PingFangSC-Medium, PingFang SC; |
||||
text-align: center; |
||||
font-style: 28rpx; |
||||
font-weight: 400; |
||||
color: #3A3A3C; |
||||
line-height: 40rpx; |
||||
} |
||||
} |
||||
</style> |
||||
|
@ -0,0 +1,267 @@
|
||||
<template> |
||||
<view class="page"> |
||||
<view class="header"> |
||||
<cu-custom :isBack="true" :isCenter="true"> |
||||
<block slot="backText"> |
||||
<view class="backImg"> |
||||
<image src="@/static/images/back-btn.png" mode=""></image> |
||||
</view> |
||||
</block> |
||||
<block slot="content"> |
||||
<view class="tab-title">全部品牌</view> |
||||
</block> |
||||
</cu-custom> |
||||
</view> |
||||
<!-- 搜索 --> |
||||
<view v-if="brandList" class="search acea-row row-middle" @click="goGoodSearch" :style="[{top:CustomBar + 'px'}]"> |
||||
<image class="search-img" src="@/static/images/search.png" mode=""></image> |
||||
<text>搜索</text> |
||||
</view> |
||||
<view class="concent-box acea-row"> |
||||
<view class="scoll-left"> |
||||
<scroll-view class="scroll-box" scroll-y="true" :scroll-into-view="scollId" scroll-with-animation="true" |
||||
show-scrollbar="false" @scroll="scrollLoad($event)"> |
||||
<view :id="'item-'+key" class="navLeftName" v-for="(val,key) in brandList" :key="val"> |
||||
<view class="moulding-box acea-row row-middle row-between"> |
||||
<view class="moulding-left"></view> |
||||
<view class="nav-title">{{key}}</view> |
||||
<view class="moulding-right"></view> |
||||
</view> |
||||
<view class="item-box acea-row row-top"> |
||||
<view class="brand-item acea-row row-middle row-center-column row-center" |
||||
v-for="(item,index) in val" :key="index" @click="goDetail(item)"> |
||||
<image class="brand-img" :src="item.pic" mode="aspectFill"></image> |
||||
<view class="brand-text line2">{{item.brandName}}</view> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
</scroll-view> |
||||
</view> |
||||
<view class="scoll-right"> |
||||
<view scroll-y="true" class="acea-row row-center-column"> |
||||
<view class="navRightName" :class="{'active':isLight==b}" v-for="(b,i) in navRight" |
||||
@click="brandListId(b,i)" :key="i">{{b}}</view> |
||||
</view> |
||||
</view> |
||||
|
||||
</view> |
||||
</view> |
||||
</template> |
||||
|
||||
<script> |
||||
import { |
||||
getBrandByName |
||||
} from '@/api/store'; |
||||
export default { |
||||
data() { |
||||
return { |
||||
CustomBar: this.CustomBar, |
||||
brandList: {}, |
||||
navRight: 'ABCDEFGHIJKLMNOPQRSTUVWXYZ#', |
||||
scollId: '', |
||||
isLight: -1, |
||||
rectInfoList:[] |
||||
} |
||||
}, |
||||
onLoad() { |
||||
this.getBrandList(); |
||||
this.getRectInfo() |
||||
}, |
||||
methods: { |
||||
getRectInfo(){ |
||||
var top=0 |
||||
var bottom=0 |
||||
var temp=0 |
||||
for(let key in this.brandList){ |
||||
let view=uni.createSelectorQuery().select('#item-'+key); |
||||
view.boundingClientRect(data=>{ |
||||
top=temp; |
||||
bottom=top+data.height; |
||||
temp=bottom; |
||||
this.rectInfoList.push({ |
||||
'top':parseInt(top), |
||||
'bottom':parseInt(bottom), |
||||
key |
||||
}) |
||||
}).exec(); |
||||
} |
||||
}, |
||||
scrollLoad(e){ |
||||
if(this.rectInfoList.length==0){ |
||||
this.getRectInfo() |
||||
} |
||||
let scrollTop=e.target.scrollTop; |
||||
for(let i=0;i<this.rectInfoList.length;i++){ |
||||
if(i<=this.rectInfoList.length-2){ |
||||
let top=this.rectInfoList[i].top; |
||||
let bottom=this.rectInfoList[i+1].bottom; |
||||
if(scrollTop>=top && scrollTop<bottom){ |
||||
this.isLight=this.rectInfoList[i].key |
||||
} |
||||
} |
||||
} |
||||
}, |
||||
goGoodSearch() { |
||||
this.$yrouter.push({ |
||||
path: '/pages/shop/GoodSearch/index', |
||||
}) |
||||
}, |
||||
brandListId(b, i) { |
||||
if (this.isLight === i) return |
||||
this.scollId = 'item-' + b |
||||
this.isLight = b |
||||
}, |
||||
|
||||
getBrandList() { |
||||
uni.showLoading({ |
||||
title: '加载中...' |
||||
}) |
||||
getBrandByName().then(res => { |
||||
this.brandList = res.data; |
||||
uni.hideLoading(); |
||||
}) |
||||
}, |
||||
goDetail(item) { |
||||
this.$yrouter.push({ |
||||
path: '/pages/shop/brands/brandDetail/index', |
||||
query: { |
||||
id: item.id, |
||||
}, |
||||
}) |
||||
}, |
||||
} |
||||
} |
||||
</script> |
||||
|
||||
<style lang="less" scoped> |
||||
.header { |
||||
.tab-title { |
||||
font-size: 32rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 500; |
||||
color: #2DB5AE; |
||||
line-height: 42rpx; |
||||
} |
||||
|
||||
.backImg { |
||||
width: 88rpx; |
||||
height: 62rpx; |
||||
padding-left: 26rpx; |
||||
|
||||
image { |
||||
width: 100%; |
||||
height: 100%; |
||||
} |
||||
} |
||||
} |
||||
|
||||
.search { |
||||
position: fixed; |
||||
z-index: 20; |
||||
height: 62rpx; |
||||
width: 690rpx; |
||||
margin: 0 0 0 30rpx; |
||||
border: 1rpx solid #999; |
||||
border-radius: 16rpx; |
||||
background-color: #E3E3E3; |
||||
color: #999; |
||||
|
||||
.search-img { |
||||
width: 40rpx; |
||||
height: 40rpx; |
||||
vertical-align: middle; |
||||
margin: 0 20rpx; |
||||
} |
||||
|
||||
text { |
||||
font-size: 28rpx; |
||||
} |
||||
} |
||||
|
||||
.concent-box { |
||||
margin-top: 62rpx; |
||||
padding: 30rpx; |
||||
.scoll-left { |
||||
width: 100%; |
||||
.scroll-box { |
||||
height: 1450rpx; |
||||
} |
||||
.item-box{ |
||||
flex: 1; |
||||
.brand-item { |
||||
font-family: PingFang SC; |
||||
width: 210rpx; |
||||
margin-right: 30rpx; |
||||
.brand-img { |
||||
width: 180rpx; |
||||
height: 180rpx; |
||||
background: #F5F6F8; |
||||
box-shadow: 0rpx 10rpx 16rpx 0rpx rgba(0, 0, 0, 0.06); |
||||
border-radius: 16rpx; |
||||
} |
||||
.brand-text { |
||||
margin: 10rpx 0 20rpx 0; |
||||
text-align: center; |
||||
width: 170rpx; |
||||
flex-wrap: wrap; |
||||
font-size: 26rpx; |
||||
font-family: PingFang SC; |
||||
color: #3A3A3A; |
||||
line-height: 38rpx; |
||||
} |
||||
} |
||||
.brand-item:nth-child(3n+3){ |
||||
margin-right: 0; |
||||
} |
||||
} |
||||
|
||||
|
||||
.moulding-box { |
||||
width: 100%; |
||||
margin-bottom: 40rpx; |
||||
|
||||
.moulding-left { |
||||
margin-left: 15rpx; |
||||
width: 180rpx; |
||||
border-bottom: 1rpx solid #999; |
||||
} |
||||
|
||||
.moulding-right { |
||||
margin-right: 15rpx; |
||||
width: 180rpx; |
||||
border-bottom: 1rpx solid #999; |
||||
} |
||||
|
||||
.nav-title { |
||||
font-weight: 800; |
||||
font-size: 34rpx; |
||||
font-family: PingFang SC; |
||||
} |
||||
} |
||||
|
||||
} |
||||
|
||||
.scoll-right { |
||||
width: 30rpx; |
||||
position: fixed; |
||||
top: 250rpx; |
||||
right: 5rpx; |
||||
|
||||
.scroll-box { |
||||
height: 800rpx; |
||||
} |
||||
|
||||
.navRightName { |
||||
color: #afaeb3; |
||||
font-size: 24rpx; |
||||
margin-bottom: 5rpx; |
||||
font-family: PingFang SC; |
||||
} |
||||
|
||||
.active { |
||||
color: #2DB5AE; |
||||
} |
||||
} |
||||
|
||||
} |
||||
</style> |
@ -0,0 +1,340 @@
|
||||
<template> |
||||
<view> |
||||
<view class="header"> |
||||
<cu-custom :isBack="true" bgColor="''"> |
||||
<block slot="backText"> |
||||
<view class="backImg"> |
||||
<image src="@/static/images/back-btn.png" mode=""></image> |
||||
</view> |
||||
</block> |
||||
</cu-custom> |
||||
</view> |
||||
<view class="bg"> |
||||
<image :src="brandInfo.backgroundImage" mode="aspectFill"></image> |
||||
</view> |
||||
<view :style="[{height:CustomBar + 'px'}]"></view> |
||||
|
||||
<view class="brand-info-box"> |
||||
<view class="brand-img"> |
||||
<image :src="brandInfo.pic" mode=""></image> |
||||
</view> |
||||
<view class="info-box"> |
||||
<view class="name-info"> |
||||
<view class="acea-row row-between-wrapper"> |
||||
<view class="name">{{brandInfo.brandName}}</view> |
||||
<view class="brand-tips acea-row"> |
||||
<view class="tip">甄选品牌</view> |
||||
</view> |
||||
</view> |
||||
<view class="tips">{{''}}</view> |
||||
<!-- <view class="tips">{{''||'1314款商品 | 5w+人已购'}}</view> --> |
||||
</view> |
||||
<view class="info">{{brandInfo.brandDescription}}</view> |
||||
<!-- <view class="info line2">{{brandInfo.brandDescription}}</view> --> |
||||
</view> |
||||
</view> |
||||
|
||||
<view class="wrapper" :style="'min-height:calc(100vh - '+ topHeight +'px)'"> |
||||
<view class="nav acea-row row-around"> |
||||
<view class="item" @click="set_where(0)"> |
||||
<view :class="'title ' + (stock === 0 && price === 0? 'active' : '')">综合</view> |
||||
</view> |
||||
<view class="item" @click="set_where(2)"> |
||||
<view :class="'title ' + (stock === 2 ? 'active' : '')">销量</view> |
||||
</view> |
||||
<view class="item" @click="set_where(1)"> |
||||
<view :class="'title acea-row row-middle ' + (stock === 0 && price ? 'active' : '')"> |
||||
<view class="">价格</view> |
||||
<view :class="'jiantou ' + (price?price === 1?'up':'down':'')"></view> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
<PromotionGood :benefit="productList" /> |
||||
<Loading :loaded="loaded" :loading="loading"></Loading> |
||||
</view> |
||||
|
||||
</view> |
||||
</template> |
||||
|
||||
<script> |
||||
import { getBrandDetail, getProducts } from '@/api/store'; |
||||
import PromotionGood from '@/components/PromotionGood'; |
||||
import Loading from '@/components/Loading'; |
||||
export default { |
||||
components: { |
||||
PromotionGood, |
||||
Loading |
||||
}, |
||||
data() { |
||||
return { |
||||
CustomBar: this.CustomBar, |
||||
topHeight: 0, |
||||
id: 0, |
||||
brandInfo: {}, |
||||
where: { |
||||
page: 1, |
||||
limit: 10, |
||||
bid: 0, |
||||
priceOrder: '', |
||||
salesOrder: '', |
||||
}, |
||||
stock: 0, |
||||
price: 0, |
||||
productList: [], |
||||
loaded: false, |
||||
loading: false, |
||||
}; |
||||
}, |
||||
onLoad() { |
||||
this.topHeight = this.CustomBar + 132; |
||||
this.id = this._route.query.id; |
||||
this.where.bid = this.id; |
||||
this.getBrandInfo(this.id); |
||||
this.getProductList(); |
||||
}, |
||||
methods: { |
||||
getBrandInfo(id) { |
||||
uni.showLoading({ |
||||
title: '加载中...', |
||||
mask: true |
||||
}) |
||||
getBrandDetail(id).then(res => { |
||||
this.brandInfo = res.data; |
||||
uni.hideLoading(); |
||||
}).catch(err => { |
||||
uni.hideLoading(); |
||||
}) |
||||
}, |
||||
//点击事件处理 |
||||
set_where(index) { |
||||
switch (index) { |
||||
case 0: |
||||
// if(this.stock !== 0 || this.price !== 0) { |
||||
this.price = 0; |
||||
this.stock = 0; |
||||
// } |
||||
break |
||||
case 1: |
||||
if (this.price === 0) this.price = 1; |
||||
else if (this.price === 1) this.price = 2; |
||||
else if (this.price === 2) this.price = 1; |
||||
this.stock = 0; |
||||
break |
||||
case 2: |
||||
if (this.stock === 0) this.stock = 2; |
||||
this.price = 0; |
||||
break |
||||
default: |
||||
break |
||||
} |
||||
this.productList = []; |
||||
this.where.page = 1; |
||||
this.loaded = false |
||||
this.getProductList(); |
||||
}, |
||||
//设置where条件 |
||||
setWhere() { |
||||
if (this.price === 0) { |
||||
this.where.priceOrder = '' |
||||
} else if (this.price === 1) { |
||||
this.where.priceOrder = 'asc' |
||||
} else if (this.price === 2) { |
||||
this.where.priceOrder = 'desc' |
||||
} |
||||
if (this.stock === 0) { |
||||
this.where.salesOrder = '' |
||||
} else if (this.stock === 1) { |
||||
this.where.salesOrder = 'asc' |
||||
} else if (this.stock === 2) { |
||||
this.where.salesOrder = 'desc' |
||||
} |
||||
// this.where.news = this.nows ? '1' : '0' |
||||
}, |
||||
getProductList() { |
||||
if (this.loaded) return |
||||
this.loading = true; |
||||
this.setWhere(); |
||||
getProducts(this.where).then(res => { |
||||
this.productList.push.apply(this.productList, res.data); |
||||
this.loaded = res.data.length < this.where.limit; //判断所有数据是否加载完成; |
||||
console.log('this.loaded', this.loaded) |
||||
this.loading = false; |
||||
this.where.page = this.where.page + 1; |
||||
}).catch(err => { |
||||
// uni.hideLoading(); |
||||
}) |
||||
} |
||||
} |
||||
} |
||||
</script> |
||||
|
||||
<style lang="less" scoped> |
||||
.header { |
||||
position: fixed; |
||||
top:0; |
||||
left:0; |
||||
right:0; |
||||
z-index: 99; |
||||
width: 750rpx; |
||||
.backImg { |
||||
width: 88rpx; |
||||
height: 62rpx; |
||||
padding-left: 26rpx; |
||||
image { |
||||
width: 100%; |
||||
height: 100%; |
||||
} |
||||
} |
||||
} |
||||
|
||||
.bg { |
||||
width: 100vw; |
||||
height: 508rpx; |
||||
position: absolute; |
||||
top: 0; |
||||
left: 0; |
||||
z-index: -1; |
||||
// background: linear-gradient(135deg, rgba(57, 211, 150, 1), rgba(27, 141, 204, 1)); |
||||
image { |
||||
width: 100%; |
||||
height: 100%; |
||||
} |
||||
} |
||||
|
||||
.brand-info-box { |
||||
padding: 62rpx 32rpx 32rpx; |
||||
position: relative; |
||||
.brand-img { |
||||
position: absolute; |
||||
top: 14rpx; |
||||
left: 64rpx; |
||||
width: 138rpx; |
||||
height: 138rpx; |
||||
border-radius: 16rpx; |
||||
padding: 4rpx; |
||||
background: linear-gradient(135deg, rgba(57, 211, 150, 1), rgba(27, 141, 204, 1)); |
||||
image { |
||||
width: 100%; |
||||
height: 100%; |
||||
background: #F5F6F8; |
||||
border-radius: 14rpx; |
||||
} |
||||
} |
||||
.info-box { |
||||
width: 686rpx; |
||||
// height: 158rpx; |
||||
background: #F5F6F8; |
||||
box-shadow: 0rpx 10rpx 16rpx 0rpx rgba(0, 0, 0, 0.06); |
||||
border-radius: 16rpx; |
||||
padding: 14rpx 32rpx; |
||||
.name-info { |
||||
padding-left: 152rpx; |
||||
font-size: 34rpx; |
||||
font-family: SourceHanSansSCVF; |
||||
font-weight: bold; |
||||
color: #3A3A3C; |
||||
line-height: 50rpx; |
||||
.brand-tips { |
||||
.tip { |
||||
width: 76rpx; |
||||
height: 26rpx; |
||||
background: #2DB5AE; |
||||
border-radius: 6rpx; |
||||
margin-right: 4rpx; |
||||
font-size: 16rpx; |
||||
font-family: PingFang SC; |
||||
color: #FFFFFF; |
||||
line-height: 26rpx; |
||||
text-align: center; |
||||
} |
||||
} |
||||
.tips { |
||||
height: 28rpx; |
||||
padding-top: 6rpx; |
||||
font-size: 16rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 600; |
||||
color: #2DB5AE; |
||||
line-height: 22rpx; |
||||
} |
||||
} |
||||
.info { |
||||
min-height: 58rpx; |
||||
max-height: 124rpx; |
||||
// padding-top: 6rpx; |
||||
padding-top: 14rpx; |
||||
font-size: 16rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 500; |
||||
color: #2DB5AE; |
||||
line-height: 22rpx; |
||||
word-break: break-all; |
||||
display: -webkit-box; |
||||
-webkit-line-clamp: 5; |
||||
-webkit-box-orient: vertical; |
||||
overflow: hidden; |
||||
} |
||||
} |
||||
} |
||||
|
||||
.wrapper { |
||||
width: 750rpx; |
||||
background: #FFFFFF; |
||||
border-radius: 28rpx; |
||||
.nav { |
||||
width: 100vw; |
||||
height: 104rpx; |
||||
padding: 32rpx 32rpx 26rpx; |
||||
.item { |
||||
min-width: 66rpx; |
||||
text-align: center; |
||||
position: relative; |
||||
.title { |
||||
font-size: 26rpx; |
||||
font-family: SourceHanSansSCVF; |
||||
font-weight: 400; |
||||
color: #999999; |
||||
line-height: 38rpx; |
||||
.jiantou { |
||||
width: 0rpx; |
||||
height: 0rpx; |
||||
border-top: 0rpx solid transparent; |
||||
border-left: 6rpx solid transparent; |
||||
border-bottom: 10rpx solid transparent; |
||||
border-right: 6rpx solid transparent; |
||||
margin-left: 4rpx; |
||||
} |
||||
.up { |
||||
border-top: 0rpx solid transparent; |
||||
border-bottom: 10rpx solid #999999; |
||||
} |
||||
.down { |
||||
border-top: 10rpx solid #999999; |
||||
border-bottom: 0rpx solid transparent; |
||||
} |
||||
} |
||||
.active { |
||||
color: #3A3A3C; |
||||
font-weight: 500; |
||||
} |
||||
.title::after { |
||||
display: block; |
||||
content: ''; |
||||
width: 100%; |
||||
height: 4rpx; |
||||
background: #2DB5AE; |
||||
position: absolute; |
||||
bottom: 0; |
||||
left: 0; |
||||
opacity: 0; |
||||
transform:scaleX(0); |
||||
transition: all .2s cubic-bezier(.18,.89,.17,.88),opacity .15s ease; |
||||
} |
||||
.active::after { |
||||
opacity: 1; |
||||
transform: scaleX(1); |
||||
} |
||||
} |
||||
} |
||||
} |
||||
</style> |
@ -0,0 +1,428 @@
|
||||
<template> |
||||
<view> |
||||
<view class="header"> |
||||
<cu-custom :isBack="true" :isCenter="true"> |
||||
<block slot="backText"> |
||||
<view class="backImg"> |
||||
<image src="@/static/images/back-btn.png" mode=""></image> |
||||
</view> |
||||
</block> |
||||
<block slot="content"> |
||||
<view class="tab-title">品牌馆</view> |
||||
</block> |
||||
</cu-custom> |
||||
</view> |
||||
|
||||
<view class="banner-box"> |
||||
<swiper class="swiper-wrapper" @change="handleChange(item)" :autoplay="true"> |
||||
<block v-for="(item, imgUrlsIndex) in imgUrls" :key="imgUrlsIndex"> |
||||
<swiper-item @click="goBannerDetail(item)"> |
||||
<!-- <view class="image">{{item}}</view> --> |
||||
<!-- <image class="image" :src="item" class="slide-image" mode="aspectFill"/> --> |
||||
<image class="image slide-image" :src="item.pic" mode="aspectFill"></image> |
||||
</swiper-item> |
||||
</block> |
||||
</swiper> |
||||
<view class="dots-box acea-row row-center"> |
||||
<view class="dot" v-for="(item,index) in imgUrls" :key="index"> |
||||
<view :class="(currents > index?'active2 ':'active ') + (currents == index?'on':(currents-1 == index?'on2':''))"></view> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
|
||||
<view class="notice-box acea-row row-middle" v-if="noticeInfo.info"> |
||||
<view class="title"> |
||||
<image src="../../../static/images/yanjie-logo.png" mode=""></image> |
||||
</view> |
||||
<view class="min-title acea-row row-between-wrapper"> |
||||
<view class="">{{noticeInfo.title}}</view> |
||||
<image src="../../../static/images/laba.png" mode="aspectFill"></image> |
||||
</view> |
||||
<view class="uni-notice-bar-box"> |
||||
<uni-notice-bar color="#2DB5AE" backgroundColor="#F1F1F1" scrollable="true" single="true" :speed="50" :text="noticeInfo.info"></uni-notice-bar> |
||||
</view> |
||||
</view> |
||||
|
||||
<view class="brands-box"> |
||||
<view class="title-box"> |
||||
<view class="en-title">BRAND SELECTIONS</view> |
||||
<view class="acea-row row-between-wrapper"> |
||||
<view class="title">甄选品牌</view> |
||||
<view class="more-box acea-row row-middle" @click.stop="goBrandAll"> |
||||
<text>全部品牌</text> |
||||
<view class="jiantou-right"></view> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
<scroll-view scroll-x="true" class="scroll-box"> |
||||
<view class="scroll"> |
||||
<view v-for="(item,index) in brandList" :key="index"> |
||||
<image class="brand-img" :src="item.pic" mode="aspectFill" @click="goDetail(item)"></image> |
||||
</view> |
||||
</view> |
||||
</scroll-view> |
||||
</view> |
||||
|
||||
<view class="brands-box"> |
||||
<view class="title-box"> |
||||
<view class="en-title">NEW ARRIVALS</view> |
||||
<view class="title">新品推荐</view> |
||||
</view> |
||||
|
||||
<view class="newList"> |
||||
<view class="item acea-row row-between" v-for="(item,index) in newList" :key="index" @click="goGoodsCon(item)"> |
||||
<image class="img" :src="item.image" mode="aspectFill"></image> |
||||
<view class="info-box"> |
||||
<view class="name line1">{{item.storeName}}</view> |
||||
<view class="tip line2">{{item.storeInfo}}</view> |
||||
<view class="acea-row row-between-wrapper"> |
||||
<view class="acea-row row-middle"> |
||||
<image class="brand-img" :src="item.pic"></image> |
||||
<view class="brand-title one-t">{{item.brandName}}</view> |
||||
</view> |
||||
<view class="acea-row row-between-wrapper"> |
||||
<text>查看详情</text> |
||||
<view class="jiantou-right"></view> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
<Loading :loaded="loaded" :loading="loading"></Loading> |
||||
</view> |
||||
|
||||
|
||||
</view> |
||||
</template> |
||||
|
||||
<script> |
||||
import UniNoticeBar from '@/components/uni-notice-bar/uni-notice-bar' |
||||
import { getBrands, getProducts ,getBanner, getBrandNoticeInfo} from '@/api/store'; |
||||
import Loading from '@/components/Loading'; |
||||
export default { |
||||
components: { |
||||
UniNoticeBar, |
||||
Loading |
||||
}, |
||||
data() { |
||||
return { |
||||
currents: 0, |
||||
imgUrls: [], |
||||
noticeInfo: { |
||||
title: '', |
||||
info: '' |
||||
}, |
||||
brandList: [], |
||||
where: { |
||||
page: 1, |
||||
limit: 10, |
||||
news: '1', |
||||
priceOrder: '', |
||||
salesOrder: '', |
||||
isIntegral: 0 |
||||
}, |
||||
newList: [], |
||||
loaded: false, |
||||
loading: false, |
||||
}; |
||||
}, |
||||
onLoad() { |
||||
this.getBrandList(); |
||||
this.getNewProducts(); |
||||
getBanner(1).then(res => { |
||||
this.$set(this,'imgUrls',res.data.banner) |
||||
}) |
||||
getBrandNoticeInfo().then(res => { |
||||
this.noticeInfo.title = res.data.title; |
||||
this.noticeInfo.info = res.data.info; |
||||
}) |
||||
}, |
||||
onReachBottom() { |
||||
!this.loading && this.getNewProducts(); |
||||
}, |
||||
methods: { |
||||
goBrandAll(){ |
||||
this.$yrouter.push({ |
||||
path: '/pages/shop/brands/brandAll/index', |
||||
}) |
||||
}, |
||||
handleChange(e) { |
||||
this.currents = e.mp.detail.current; |
||||
}, |
||||
goBannerDetail(item){ |
||||
if (item.uniapp_url) { |
||||
this.$yrouter.push(item.uniapp_url) |
||||
} |
||||
}, |
||||
goDetail(item) { |
||||
this.$yrouter.push({ |
||||
path: '/pages/shop/brands/brandDetail/index', |
||||
query: { |
||||
id: item.id, |
||||
}, |
||||
}) |
||||
}, |
||||
goGoodsCon(item) { |
||||
this.$yrouter.push({ |
||||
path: '/pages/shop/GoodsCon/index', |
||||
query: { |
||||
id: item.id, |
||||
}, |
||||
}) |
||||
}, |
||||
getBrandList() { |
||||
uni.showLoading({ |
||||
title: '加载中...' |
||||
}) |
||||
getBrands().then(res => { |
||||
this.brandList = res.data; |
||||
uni.hideLoading(); |
||||
}) |
||||
}, |
||||
getNewProducts() { |
||||
if (this.loaded) return |
||||
this.loading = true; |
||||
getProducts(this.where).then(res => { |
||||
// uni.hideLoading(); |
||||
this.newList.push.apply(this.newList, res.data); |
||||
this.loaded = res.data.length < this.where.limit; //判断所有数据是否加载完成; |
||||
this.loading = false; |
||||
this.where.page = this.where.page + 1; |
||||
}) |
||||
} |
||||
} |
||||
} |
||||
</script> |
||||
|
||||
<style lang="less" scoped> |
||||
.jiantou-right { |
||||
width: 0; |
||||
height: 0; |
||||
border-top: 6rpx solid transparent; |
||||
border-left: 10rpx solid #2DB5AE; |
||||
border-bottom: 6rpx solid transparent; |
||||
border-right: 0rpx solid transparent; |
||||
margin-left: 8rpx; |
||||
} |
||||
|
||||
.header { |
||||
.tab-title { |
||||
font-size: 32rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 600; |
||||
color: #2DB5AE; |
||||
line-height: 42rpx; |
||||
} |
||||
.backImg { |
||||
width: 88rpx; |
||||
height: 62rpx; |
||||
padding-left: 26rpx; |
||||
image { |
||||
width: 100%; |
||||
height: 100%; |
||||
} |
||||
} |
||||
} |
||||
|
||||
.banner-box { |
||||
padding: 20rpx 32rpx; |
||||
.swiper-wrapper { |
||||
width: 686rpx; |
||||
height: 398rpx; |
||||
border-radius: 16rpx; |
||||
.image { |
||||
width: 686rpx; |
||||
height: 398rpx; |
||||
border-radius: 16rpx; |
||||
} |
||||
} |
||||
.dots-box { |
||||
padding-top: 26rpx; |
||||
.dot { |
||||
width: 92rpx; |
||||
height: 4rpx; |
||||
background: #CCEDEB; |
||||
margin: 0rpx 6rpx; |
||||
position: relative; |
||||
.active { |
||||
width: 0rpx; |
||||
height: 4rpx; |
||||
background: #2DB5AE; |
||||
position: absolute; |
||||
top: 0; |
||||
left: 0; |
||||
transition: all .6s cubic-bezier(.18,.89,.17,.88); |
||||
-webkit-transition: all .6s cubic-bezier(.18,.89,.17,.88); |
||||
-moz-transition: all .6s cubic-bezier(.18,.89,.17,.88); |
||||
-o-transition: all .6s cubic-bezier(.18,.89,.17,.88); |
||||
} |
||||
.active2 { |
||||
width: 0rpx; |
||||
height: 4rpx; |
||||
background: #2DB5AE; |
||||
position: absolute; |
||||
top: 0; |
||||
left: 92rpx; |
||||
transition: all .6s cubic-bezier(.18,.89,.17,.88); |
||||
-webkit-transition: all .6s cubic-bezier(.18,.89,.17,.88); |
||||
-moz-transition: all .6s cubic-bezier(.18,.89,.17,.88); |
||||
-o-transition: all .6s cubic-bezier(.18,.89,.17,.88); |
||||
} |
||||
.active.on { |
||||
width: 92rpx; |
||||
transition: all .6s cubic-bezier(.18,.89,.17,.88); |
||||
-webkit-transition: all .6s cubic-bezier(.18,.89,.17,.88); |
||||
-moz-transition: all .6s cubic-bezier(.18,.89,.17,.88); |
||||
-o-transition: all .6s cubic-bezier(.18,.89,.17,.88); |
||||
} |
||||
.active.on2 { |
||||
width: 92rpx; |
||||
left: 0; |
||||
transition: all .6s cubic-bezier(.18,.89,.17,.88); |
||||
-webkit-transition: all .6s cubic-bezier(.18,.89,.17,.88); |
||||
-moz-transition: all .6s cubic-bezier(.18,.89,.17,.88); |
||||
-o-transition: all .6s cubic-bezier(.18,.89,.17,.88); |
||||
} |
||||
} |
||||
} |
||||
} |
||||
|
||||
.notice-box { |
||||
margin: 0rpx 32rpx 48rpx; |
||||
width: 686rpx; |
||||
height: 62rpx; |
||||
border-radius: 16rpx; |
||||
border: 4rpx solid #2DB5AE; |
||||
.title { |
||||
padding-left: 16rpx; |
||||
padding-right: 10rpx; |
||||
height: 38rpx; |
||||
border-right: 2rpx solid #2DB5AE; |
||||
image { |
||||
width: 124rpx; |
||||
height: 30rpx; |
||||
} |
||||
} |
||||
.min-title { |
||||
width: 138rpx; |
||||
padding-left: 12rpx; |
||||
font-size: 24rpx; |
||||
font-family: SourceHanSansSCVF; |
||||
font-weight: 600; |
||||
color: #2DB5AE; |
||||
line-height: 32rpx; |
||||
image { |
||||
width: 26rpx; |
||||
height: 26rpx; |
||||
} |
||||
} |
||||
.uni-notice-bar-box { |
||||
width: 388rpx; |
||||
font-size: 24rpx; |
||||
font-family: SourceHanSansSCVF; |
||||
font-weight: 500; |
||||
color: #2DB5AE; |
||||
line-height: 32rpx; |
||||
} |
||||
} |
||||
|
||||
.brands-box { |
||||
padding-bottom: 32rpx; |
||||
.title-box { |
||||
padding: 0rpx 32rpx 24rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 500; |
||||
.en-title { |
||||
font-size: 20rpx; |
||||
font-family: Futura; |
||||
font-weight: 600; |
||||
color: #999999; |
||||
line-height: 22rpx; |
||||
} |
||||
.title { |
||||
font-size: 50rpx; |
||||
font-weight: 600; |
||||
color: #3A3A3C; |
||||
line-height: 68rpx; |
||||
} |
||||
.more-box { |
||||
font-size: 20rpx; |
||||
color: #2DB5AE; |
||||
line-height: 26rpx; |
||||
} |
||||
} |
||||
} |
||||
|
||||
.brands-box .scroll-box { |
||||
width: 100%; |
||||
overflow:hidden; |
||||
white-space:nowrap; |
||||
.scroll { |
||||
display: flex; |
||||
flex-wrap: nowrap; |
||||
padding-left: 32rpx; |
||||
padding-bottom: 16rpx; |
||||
.brand-img { |
||||
width: 126rpx; |
||||
height: 126rpx; |
||||
background: #F5F6F8; |
||||
box-shadow: 0rpx 10rpx 16rpx 0rpx rgba(0, 0, 0, 0.06); |
||||
border-radius: 16rpx; |
||||
margin-right: 8rpx; |
||||
} |
||||
view:last-child .brand-img { |
||||
margin-right: 16rpx; |
||||
} |
||||
} |
||||
} |
||||
|
||||
.newList { |
||||
padding: 0rpx 32rpx; |
||||
.item { |
||||
width: 100%; |
||||
height: 174rpx; |
||||
background: #F5F6F8; |
||||
box-shadow: 0rpx 10rpx 16rpx 0rpx rgba(0, 0, 0, 0.06); |
||||
border-radius: 16rpx; |
||||
margin-bottom: 20rpx; |
||||
padding: 6rpx 24rpx 6rpx 6rpx; |
||||
.img { |
||||
width: 162rpx; |
||||
height: 162rpx; |
||||
border-radius: 16rpx; |
||||
} |
||||
.info-box { |
||||
width: 472rpx; |
||||
padding: 6rpx 0rpx; |
||||
font-size: 20rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 500; |
||||
color: #2DB5AE; |
||||
line-height: 26rpx; |
||||
.name { |
||||
font-size: 26rpx; |
||||
font-weight: 600; |
||||
color: #3A3A3C; |
||||
line-height: 38rpx; |
||||
} |
||||
.tip { |
||||
height: 58rpx; |
||||
padding-top: 6rpx; |
||||
margin-bottom: 18rpx; |
||||
color: #999999; |
||||
} |
||||
.brand-img { |
||||
width: 34rpx; |
||||
height: 34rpx; |
||||
border-radius: 50%; |
||||
} |
||||
.brand-title { |
||||
width: 240rpx; |
||||
padding-left: 10rpx; |
||||
color: #999999; |
||||
} |
||||
} |
||||
} |
||||
} |
||||
|
||||
</style> |
@ -0,0 +1,92 @@
|
||||
<template> |
||||
<view> |
||||
<view class="header"> |
||||
<cu-custom :isBack="true" :isCenter="true"> |
||||
<block slot="backText"> |
||||
<view class="backImg"> |
||||
<image src="@/static/images/back-btn.png" mode="" ></image> |
||||
</view> |
||||
</block> |
||||
<block slot="content"> |
||||
<view class="tab-title">关于我们</view> |
||||
</block> |
||||
</cu-custom> |
||||
</view> |
||||
<view class="conter"> |
||||
<!-- <image class="img" src="../../../static/images/guanyu.jpg" mode="widthFix"></image> --> |
||||
<mp-html id="article" :setTitle="false" :lazy-load="true" :copy-link="false" :tag-style="tagStyle" |
||||
:content="aboutUsDetail"/> |
||||
</view> |
||||
</view> |
||||
</template> |
||||
|
||||
<script> |
||||
import {getAboutUs} from '@/api/user.js'; |
||||
export default { |
||||
|
||||
data() { |
||||
return { |
||||
aboutUsDetail:{}, |
||||
tagStyle: { |
||||
img: 'padding:0;margin:0;font-size:0;display:block;' |
||||
} |
||||
}; |
||||
|
||||
}, |
||||
mounted() { |
||||
this.getAbout() |
||||
}, |
||||
|
||||
methods: { |
||||
getAbout(){ |
||||
uni.showLoading({ |
||||
title: '加载中', |
||||
mask: true, |
||||
}) |
||||
getAboutUs().then(res=>{ |
||||
uni.hideLoading() |
||||
this.aboutUsDetail=res.data.routine_aboutUs.replace(/\<img/gi, '<img style="max-width:100%;height:auto;"') |
||||
console.log(res,'======='); |
||||
}) |
||||
} |
||||
|
||||
} |
||||
} |
||||
</script> |
||||
|
||||
<style lang="less" scoped> |
||||
.header { |
||||
.tab-title { |
||||
font-size: 32rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 600; |
||||
color: #2DB5AE; |
||||
line-height: 42rpx; |
||||
} |
||||
|
||||
.backImg { |
||||
width: 88rpx; |
||||
height: 62rpx; |
||||
padding-left: 26rpx; |
||||
|
||||
image { |
||||
width: 100%; |
||||
height: 100%; |
||||
} |
||||
} |
||||
} |
||||
|
||||
.img{ |
||||
width: 100%; |
||||
// height: 100%; |
||||
} |
||||
.conter { |
||||
font-size: 30rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 500; |
||||
color: #3A3A3C; |
||||
// line-height: 32rpx; |
||||
// padding: 0rpx 30rpx; |
||||
} |
||||
|
||||
</style> |
@ -1,210 +1,464 @@
|
||||
<template> |
||||
<view class="personal-data"> |
||||
<view class="wrapper"> |
||||
<view class="wrapList"> |
||||
<view class="item acea-row row-between-wrapper on"> |
||||
<view class="picTxt acea-row row-between-wrapper"> |
||||
<view class="pictrue" @tap="chooseImage"> |
||||
<div class="pictrue"> |
||||
<img :src="avatar" /> |
||||
</div> |
||||
<image :src="`${$VUE_APP_RESOURCES_URL}/images/alter.png`" class="alter" /> |
||||
</view> |
||||
<view class="text"> |
||||
<view class="name line1">{{ userInfo.nickname }}</view> |
||||
<view class="phone"> |
||||
绑定手机号: |
||||
<text v-if="userInfo.phone">{{ userInfo.phone }}</text> |
||||
<text v-else>未绑定</text> |
||||
</view> |
||||
<view class="personal-data"> |
||||
<view class="header"> |
||||
<cu-custom :isBack="true" :isCenter="true"> |
||||
<block slot="backText"> |
||||
<view class="backImg"> |
||||
<image src="@/static/images/back-btn.png" mode=""></image> |
||||
</view> |
||||
</block> |
||||
<block slot="content"> |
||||
<view class="tab-title">个人资料</view> |
||||
</block> |
||||
</cu-custom> |
||||
</view> |
||||
<!-- <view class="wrapper"> --> |
||||
<view class="wrapList acea-row row-between-wrapper"> |
||||
<!-- <view class="item acea-row row-between-wrapper on"> --> |
||||
<!-- <view class="picTxt acea-row row-between-wrapper"> --> |
||||
<view class="pictrue"> |
||||
<!-- <div class="pictrue"> @tap="chooseImage" --> |
||||
<image class="image" v-if="avatar" :src="avatar" /> |
||||
|
||||
<view class="noAvatar acea-row row-middle row-center" v-else> |
||||
<image src="../../../static/images/yanjie-logo.png" mode="widthFix"></image> |
||||
</view> |
||||
<!-- </div> --> |
||||
<!-- <image :src="`${$VUE_APP_RESOURCES_URL}/images/alter.png`" class="alter" /> --> |
||||
<button class="avatar-wrapper" open-type="chooseAvatar" @chooseavatar="onChooseAvatar"></button> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
<view class="list"> |
||||
<view class="item acea-row row-between-wrapper"> |
||||
<view>昵称</view> |
||||
<view class="input"> |
||||
<input type="text" v-model="userInfo.nickname" /> |
||||
<view class="text"> |
||||
<view class="name line1">{{ userInfo.nickname || '微信用户' }}</view> |
||||
<view v-if="userInfo.phone" class="phone">已绑定手机:{{ userInfo.phone }}</view> |
||||
<button v-else class="phone phone-btn" open-type="getPhoneNumber" @getphonenumber="phoneLogin">绑定手机号</button> |
||||
</view> |
||||
<!-- </view> --> |
||||
<!-- </view> --> |
||||
</view> |
||||
<view class="item acea-row row-between-wrapper"> |
||||
<view>ID号</view> |
||||
<view class="input acea-row row-between-wrapper"> |
||||
<input type="text" :value="userInfo.uid" disabled class="id" /> |
||||
<text class="iconfont icon-suozi"></text> |
||||
<!-- </view> --> |
||||
<view class="list"> |
||||
<view class="item acea-row row-between-wrapper"> |
||||
<view>昵称</view> |
||||
<view class="input"> |
||||
<input id="nickname-input" type="nickname" v-model="userInfo.nickname" @blur="getNickName()" /> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
<view class="item acea-row row-between-wrapper"> |
||||
<view>手机号</view> |
||||
<view class="input"> |
||||
<!-- <input type="text" v-model="userInfo.phone" placeholder="未绑定"/> --> |
||||
<input type="text" v-if="userInfo.phone" v-model="userInfo.phone" placeholder="未绑定"/> |
||||
<input type="text" v-else value="未绑定" disabled class="id" /> |
||||
<view class="item acea-row row-between-wrapper"> |
||||
<view>眼界ID</view> |
||||
<view class="input" style="color: #999999;"> |
||||
{{userInfo.uid}} |
||||
<!-- <input type="text" :value="userInfo.uid" disabled class="id" /> --> |
||||
<!-- <text class="iconfont icon-suozi"></text> --> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
<view class="item acea-row row-between-wrapper" @click="goChangePassword()"> |
||||
<view class="item acea-row row-between-wrapper"> |
||||
<view>生日</view> |
||||
<view class="input"> |
||||
<picker v-if="!userInfo.birthday" mode="date" :value="birthday" @change="bindDateChange"> |
||||
<view v-if="!birthday" class="empty">点击完善生日</view> |
||||
<view v-else>{{birthday}}</view> |
||||
</picker> |
||||
<view v-else>{{birthday}}</view> |
||||
</view> |
||||
</view> |
||||
<view class="item acea-row row-between-wrapper"> |
||||
<view>手机号</view> |
||||
<view class="input" style="color: #999999;"> |
||||
{{userInfo.phone?userInfo.phone:'未绑定'}} |
||||
<!-- <input type="text" v-if="userInfo.phone" v-model="userInfo.phone" placeholder="未绑定" disabled/> |
||||
<input type="text" v-else value="未绑定" disabled class="id" /> --> |
||||
</view> |
||||
</view> |
||||
<!-- <view class="item acea-row row-between-wrapper" @click="goChangePassword()"> |
||||
<view>密码</view> |
||||
<view class="input acea-row row-between-wrapper"> |
||||
<text>点击修改密码</text> |
||||
<text class="iconfont icon-suozi"></text> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
<view class="modifyBnt bg-color-red" @click="submit">保存修改</view> |
||||
<!-- #ifndef MP-WEIXIN --> |
||||
<view |
||||
class="logOut cart-color acea-row row-center-wrapper" |
||||
@click="logout" |
||||
>退出登录</view> |
||||
<!-- #endif --> |
||||
</view> |
||||
</view> --> |
||||
</view> |
||||
<view class="modifyBnt bg-color-red" @click="submit">保存</view> |
||||
<view class="modifyBnt cancel" @click="cancel">取消</view> |
||||
<!-- #ifndef MP-WEIXIN --> |
||||
<view class="logOut cart-color acea-row row-center-wrapper" @click="logout">退出登录</view> |
||||
<!-- #endif --> |
||||
</view> |
||||
</template> |
||||
<script> |
||||
import { mapGetters } from "vuex"; |
||||
import { trim, isWeixin, chooseImage } from "@/utils"; |
||||
import { VUE_APP_API_URL } from "@/config"; |
||||
import { |
||||
postUserEdit, |
||||
getLogout, |
||||
switchH5Login, |
||||
getUserInfo, |
||||
} from "@/api/user"; |
||||
import cookie from "@/utils/store/cookie"; |
||||
import store from "@//store"; |
||||
import dayjs from "dayjs"; |
||||
import { |
||||
mapGetters |
||||
} from "vuex"; |
||||
import { |
||||
trim, |
||||
isWeixin, |
||||
chooseImage |
||||
} from "@/utils"; |
||||
import { |
||||
VUE_APP_API_URL, |
||||
BXG_TENANT_ID |
||||
} from "@/config"; |
||||
import { |
||||
postUserEdit, |
||||
getLogout, |
||||
switchH5Login, |
||||
getUserInfo, |
||||
wxappBindingPhone |
||||
} from "@/api/user"; |
||||
import cookie from "@/utils/store/cookie"; |
||||
import store from "@/store"; |
||||
import dayjs from "dayjs"; |
||||
|
||||
export default { |
||||
name: "PersonalData", |
||||
components: { |
||||
// VueCoreImageUpload |
||||
}, |
||||
data: function () { |
||||
return { |
||||
avatar: "", |
||||
isWeixin: false, |
||||
currentAccounts: 0, |
||||
switchUserInfo: [], |
||||
userIndex: 0, |
||||
}; |
||||
}, |
||||
computed: mapGetters(["userInfo"]), |
||||
mounted: function () { |
||||
this.avatar = this.userInfo.avatar; |
||||
this.isWeixin = isWeixin(); |
||||
this.getUserInfo(); |
||||
}, |
||||
methods: { |
||||
goChangePassword() { |
||||
this.$yrouter.push("/pages/user/ChangePassword/index"); |
||||
}, |
||||
switchAccounts: function (index) { |
||||
let that = this; |
||||
this.userIndex = index; |
||||
let userInfo = this.switchUserInfo[this.userIndex]; |
||||
if (this.switchUserInfo.length <= 1) return true; |
||||
if (userInfo === undefined) { |
||||
uni.showToast({ |
||||
title: "切换的账号不存在", |
||||
icon: "none", |
||||
duration: 2000, |
||||
}); |
||||
return; |
||||
} |
||||
if (userInfo.user_type === "h5") { |
||||
switchH5Login() |
||||
.then(({ data }) => { |
||||
uni.hideLoading(); |
||||
const expires_time = dayjs(data.expires_time); |
||||
store.commit("login", data.token, expires_time); |
||||
that.$emit("changeswitch", false); |
||||
location.reload(); |
||||
}) |
||||
.catch((err) => { |
||||
uni.hideLoading(); |
||||
uni.showToast({ |
||||
title: |
||||
err.msg || err.response.data.msg || err.response.data.message, |
||||
icon: "none", |
||||
duration: 2000, |
||||
}); |
||||
}); |
||||
} else { |
||||
cookie.set("loginType", "wechat", 60); |
||||
uni.hideLoading(); |
||||
this.$store.commit("logout"); |
||||
this.$emit("changeswitch", false); |
||||
} |
||||
}, |
||||
getUserInfo: function () { |
||||
let that = this; |
||||
getUserInfo().then((res) => { |
||||
// let switchUserInfo = res.data.switchUserInfo; |
||||
// for (let i = 0; i < switchUserInfo.length; i++) { |
||||
// if (switchUserInfo[i].uid == that.userInfo.uid) that.userIndex = i; |
||||
// if ( |
||||
// !that.isWeixin && |
||||
// switchUserInfo[i].user_type != "h5" && |
||||
// switchUserInfo[i].phone === "" |
||||
// ) |
||||
// switchUserInfo.splice(i, 1); |
||||
// } |
||||
// that.$set(this, "switchUserInfo", switchUserInfo); |
||||
}); |
||||
}, |
||||
chooseImage() { |
||||
chooseImage((img) => { |
||||
this.avatar = img; |
||||
}); |
||||
}, |
||||
export default { |
||||
name: "PersonalData", |
||||
components: { |
||||
// VueCoreImageUpload |
||||
}, |
||||
data: function() { |
||||
return { |
||||
avatar: "", |
||||
isWeixin: false, |
||||
currentAccounts: 0, |
||||
switchUserInfo: [], |
||||
userIndex: 0, |
||||
birthday: '', |
||||
}; |
||||
}, |
||||
computed: mapGetters(["userInfo"]), |
||||
mounted: function() { |
||||
this.avatar = this.userInfo.avatar; |
||||
this.birthday = this.userInfo.birthday; |
||||
this.isWeixin = isWeixin(); |
||||
// this.getUserInfo(); |
||||
}, |
||||
methods: { |
||||
getNickName() { |
||||
uni.createSelectorQuery().in(this) // 注意这里要加上 in(this) |
||||
.select("#nickname-input") |
||||
.fields({ |
||||
properties: ["value"], |
||||
}) |
||||
.exec((res) => { |
||||
const nickName = res?. [0]?.value |
||||
let info = JSON.parse(JSON.stringify(this.userInfo)) |
||||
info.nickname = nickName |
||||
this.$store.commit('updateUserInfo', info) |
||||
console.log('昵称', nickName) |
||||
}) |
||||
}, |
||||
goChangePassword() { |
||||
this.$yrouter.push("/pages/user/ChangePassword/index"); |
||||
}, |
||||
switchAccounts: function(index) { |
||||
let that = this; |
||||
this.userIndex = index; |
||||
let userInfo = this.switchUserInfo[this.userIndex]; |
||||
if (this.switchUserInfo.length <= 1) return true; |
||||
if (userInfo === undefined) { |
||||
uni.showToast({ |
||||
title: "切换的账号不存在", |
||||
icon: "none", |
||||
duration: 2000, |
||||
}); |
||||
return; |
||||
} |
||||
if (userInfo.user_type === "h5") { |
||||
switchH5Login() |
||||
.then(({ |
||||
data |
||||
}) => { |
||||
uni.hideLoading(); |
||||
const expires_time = dayjs(data.expires_time); |
||||
store.commit("login", data.token, expires_time); |
||||
that.$emit("changeswitch", false); |
||||
location.reload(); |
||||
}) |
||||
.catch((err) => { |
||||
uni.hideLoading(); |
||||
uni.showToast({ |
||||
title: err.msg || err.response.data.msg || err.response.data.message, |
||||
icon: "none", |
||||
duration: 2000, |
||||
}); |
||||
}); |
||||
} else { |
||||
cookie.set("loginType", "wechat", 60); |
||||
uni.hideLoading(); |
||||
this.$store.commit("logout"); |
||||
this.$emit("changeswitch", false); |
||||
} |
||||
}, |
||||
getUserInfo: function() { |
||||
let that = this; |
||||
getUserInfo().then((res) => { |
||||
// let switchUserInfo = res.data.switchUserInfo; |
||||
// for (let i = 0; i < switchUserInfo.length; i++) { |
||||
// if (switchUserInfo[i].uid == that.userInfo.uid) that.userIndex = i; |
||||
// if ( |
||||
// !that.isWeixin && |
||||
// switchUserInfo[i].user_type != "h5" && |
||||
// switchUserInfo[i].phone === "" |
||||
// ) |
||||
// switchUserInfo.splice(i, 1); |
||||
// } |
||||
// that.$set(this, "switchUserInfo", switchUserInfo); |
||||
}); |
||||
}, |
||||
onChooseAvatar(e) { |
||||
uni.getImageInfo({ |
||||
src: e.detail.avatarUrl, |
||||
success: image => { |
||||
// console.log(image) |
||||
uni.showLoading({ title: '图片上传中', mask: true }) |
||||
uni.uploadFile({ |
||||
url: `${VUE_APP_API_URL}/api/upload`, |
||||
file: image, |
||||
filePath: image.path, |
||||
header: { |
||||
Authorization: 'Bearer ' + store.getters.token, |
||||
'tenant-id': BXG_TENANT_ID |
||||
}, |
||||
name: 'file', |
||||
success: res => { |
||||
this.avatar = JSON.parse(res.data).data; |
||||
console.log('this.avatar', this.avatar) |
||||
}, |
||||
fail: err => { |
||||
uni.showToast({ |
||||
title: '上传图片失败', |
||||
icon: 'none', |
||||
duration: 2000, |
||||
}) |
||||
}, |
||||
complete: res => { |
||||
uni.hideLoading() |
||||
}, |
||||
}) |
||||
}, |
||||
fail: err => { |
||||
uni.showToast({ |
||||
title: '获取图片信息失败', |
||||
icon: 'none', |
||||
duration: 2000, |
||||
}) |
||||
}, |
||||
}) |
||||
}, |
||||
chooseImage() { |
||||
chooseImage((img) => { |
||||
this.avatar = img; |
||||
}); |
||||
}, |
||||
bindDateChange(e) { |
||||
console.log(e) |
||||
this.birthday = e.detail.value; |
||||
}, |
||||
// 绑定微信用户手机号 |
||||
phoneLogin(e) { |
||||
console.log('绑定微信用户手机号', e.mp.detail.code) |
||||
if (e.mp.detail.errMsg == 'getPhoneNumber:ok') { |
||||
uni.showLoading({ |
||||
title: '绑定中', |
||||
}) |
||||
uni.login({ |
||||
success: (loginRes) => { |
||||
wxappBindingPhone({ |
||||
encryptedData: e.mp.detail.encryptedData, |
||||
iv: e.mp.detail.iv, |
||||
code: loginRes.code |
||||
}).then(res => { |
||||
uni.hideLoading(); |
||||
if(res.success) { |
||||
getUserInfo().then(user => { |
||||
this.userInfo.phone = user.phone; |
||||
store.dispatch('setUserInfo', user.data); |
||||
}) |
||||
} |
||||
uni.showToast({ |
||||
title: res.msg, |
||||
icon: 'success', |
||||
duration: 2000, |
||||
}) |
||||
}).catch(error => { |
||||
uni.hideLoading() |
||||
this.$store.dispatch('userInfo', true) |
||||
console.log(error) |
||||
uni.showToast({ |
||||
title: error.msg || error.response.data.msg || error.response.data.message, |
||||
icon: 'none', |
||||
duration: 2000, |
||||
}) |
||||
}) |
||||
} |
||||
}) |
||||
} else { |
||||
uni.showToast({ |
||||
title: '已拒绝授权', |
||||
icon: 'none', |
||||
duration: 2000, |
||||
}) |
||||
} |
||||
}, |
||||
|
||||
submit: function () { |
||||
let userInfo = this.userInfo; |
||||
postUserEdit({ |
||||
nickname: trim(this.userInfo.nickname), |
||||
avatar: this.avatar, |
||||
}).then( |
||||
(res) => { |
||||
this.$store.dispatch("userInfo", true); |
||||
uni.showToast({ |
||||
title: res.msg, |
||||
icon: "none", |
||||
duration: 2000, |
||||
}); |
||||
this.$yrouter.back(); |
||||
}, |
||||
(err) => { |
||||
uni.showToast({ |
||||
title: |
||||
err.msg || err.response.data.msg || err.response.data.message, |
||||
icon: "none", |
||||
duration: 2000, |
||||
}); |
||||
} |
||||
); |
||||
}, |
||||
logout: function () { |
||||
uni.showModal({ |
||||
title: "提示", |
||||
content: "确认退出登录?", |
||||
success: (res) => { |
||||
if (res.confirm) { |
||||
getLogout() |
||||
.then((res) => { |
||||
this.$store.commit("logout"); |
||||
this.$yrouter.replace({ |
||||
path: "/pages/user/Login/index", |
||||
query: {}, |
||||
}); |
||||
}) |
||||
.catch((err) => {}); |
||||
} else if (res.cancel) { |
||||
// console.log("用户点击取消"); |
||||
} |
||||
}, |
||||
}); |
||||
}, |
||||
}, |
||||
}; |
||||
submit: function() { |
||||
let userInfo = this.userInfo; |
||||
// console.log(userInfo, '=============='); |
||||
let data = { |
||||
nickname: '', |
||||
avatar: '' |
||||
}; |
||||
if (this.userInfo.nickname) { |
||||
data.nickname = trim(this.userInfo.nickname); |
||||
} |
||||
if (this.avatar) { |
||||
data.avatar = this.avatar; |
||||
} |
||||
if(this.birthday) { |
||||
data.birthday = this.birthday; |
||||
} |
||||
if (!this.userInfo.nickname && !this.avatar && !this.birthday) return |
||||
postUserEdit(data).then( |
||||
(res) => { |
||||
this.$store.dispatch("userInfo", true); |
||||
uni.showToast({ |
||||
title: res.msg, |
||||
icon: "none", |
||||
duration: 2000, |
||||
}); |
||||
this.$yrouter.back(); |
||||
}, |
||||
(err) => { |
||||
uni.showToast({ |
||||
title: err.msg || err.response.data.msg || err.response.data.message, |
||||
icon: "none", |
||||
duration: 2000, |
||||
}); |
||||
} |
||||
); |
||||
}, |
||||
cancel() { |
||||
this.$yrouter.back(); |
||||
}, |
||||
logout: function() { |
||||
uni.showModal({ |
||||
title: "提示", |
||||
content: "确认退出登录?", |
||||
success: (res) => { |
||||
if (res.confirm) { |
||||
getLogout() |
||||
.then((res) => { |
||||
this.$store.commit("logout"); |
||||
this.$yrouter.replace({ |
||||
path: "/pages/user/Login/index", |
||||
query: {}, |
||||
}); |
||||
}) |
||||
.catch((err) => {}); |
||||
} else if (res.cancel) { |
||||
// console.log("用户点击取消"); |
||||
} |
||||
}, |
||||
}); |
||||
}, |
||||
}, |
||||
}; |
||||
</script> |
||||
<style lang="less" scoped> |
||||
.header { |
||||
.tab-title { |
||||
font-size: 32rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 600; |
||||
color: #2DB5AE; |
||||
line-height: 42rpx; |
||||
} |
||||
.backImg { |
||||
width: 88rpx; |
||||
height: 62rpx; |
||||
padding-left: 26rpx; |
||||
image { |
||||
width: 100%; |
||||
height: 100%; |
||||
} |
||||
} |
||||
} |
||||
|
||||
.wrapList { |
||||
padding: 20rpx 32rpx 32rpx; |
||||
|
||||
.pictrue { |
||||
width: 100rpx; |
||||
height: 100rpx; |
||||
box-shadow: 0rpx 0rpx 20rpx 10rpx rgba(0, 0, 0, 0.08); |
||||
background: linear-gradient(135deg, rgba(27, 141, 204, 1), rgba(57, 211, 150, 1)); |
||||
padding: 4rpx; |
||||
border-radius: 50%; |
||||
position: relative; |
||||
|
||||
.image { |
||||
width: 100%; |
||||
height: 100%; |
||||
border-radius: 50%; |
||||
} |
||||
|
||||
.noAvatar { |
||||
width: 100%; |
||||
height: 100%; |
||||
border-radius: 50%; |
||||
background: #F1F1F1; |
||||
|
||||
image { |
||||
width: 90%; |
||||
} |
||||
} |
||||
|
||||
.avatar-wrapper { |
||||
width: 100rpx; |
||||
height: 100rpx; |
||||
border-radius: 50%; |
||||
opacity: 0; |
||||
position: absolute; |
||||
top: 0; |
||||
left: 0; |
||||
z-index: 1; |
||||
} |
||||
} |
||||
|
||||
.text { |
||||
width: 586rpx; |
||||
padding-left: 24rpx; |
||||
|
||||
.name { |
||||
font-size: 15px; |
||||
font-family: PingFangSC-Semibold, PingFang SC; |
||||
font-weight: 600; |
||||
color: #3A3A3C; |
||||
line-height: 21px; |
||||
padding-bottom: 10rpx; |
||||
} |
||||
|
||||
.phone { |
||||
font-size: 24rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 500; |
||||
color: #3A3A3C; |
||||
line-height: 32rpx; |
||||
} |
||||
.phone-btn { |
||||
width: 136rpx; |
||||
height: 32rpx; |
||||
background: #F1F1F1; |
||||
border: 2rpx solid #2DB5AE; |
||||
font-size: 20rpx; |
||||
color: #2DB5AE; |
||||
line-height: 28rpx; |
||||
text-align: center; |
||||
border-radius: 8rpx; |
||||
margin: 0; |
||||
padding: 0; |
||||
&::after{ |
||||
border:none; |
||||
} |
||||
} |
||||
} |
||||
} |
||||
</style> |
||||
|
@ -0,0 +1,135 @@
|
||||
<template> |
||||
<view> |
||||
<view class="header"> |
||||
<cu-custom :isBack="true" :isCenter="true"> |
||||
<block slot="backText"> |
||||
<view class="backImg"> |
||||
<image src="@/static/images/back-btn.png" mode=""></image> |
||||
</view> |
||||
</block> |
||||
<block slot="content"> |
||||
<view class="tab-title">常见问题</view> |
||||
</block> |
||||
</cu-custom> |
||||
</view> |
||||
<view class="problem-box" v-for="(item,index) in problemList" :key="index"> |
||||
<view class="problem-item acea-row row-between row-middle" @click="tapSwitch(index)"> |
||||
<view class="text-box line2"> |
||||
{{item.problem}} |
||||
</view> |
||||
<image class="img" :src="`../../../static/images/picker-${number==index?'up':'down'}.png`" mode=""> |
||||
</image> |
||||
</view> |
||||
|
||||
<view class="problem-list" v-if="index==number"> |
||||
<view class="item"> |
||||
{{item.answer}} |
||||
</view> |
||||
</view> |
||||
</view> |
||||
|
||||
</view> |
||||
</template> |
||||
|
||||
<script> |
||||
|
||||
import { |
||||
getProblem |
||||
} from '@/api/user.js' |
||||
export default { |
||||
|
||||
data() { |
||||
return { |
||||
number: -1, |
||||
problemList:[] |
||||
|
||||
}; |
||||
}, |
||||
onLoad() { |
||||
this.getMenu() |
||||
}, |
||||
|
||||
methods: { |
||||
getMenu() { |
||||
uni.showLoading({ |
||||
title: '加载中', |
||||
mask: true, |
||||
}) |
||||
getProblem().then(res => { |
||||
uni.hideLoading() |
||||
this.problemList=res.data.routine_problem |
||||
// console.log(this.problemList, '======'); |
||||
}) |
||||
}, |
||||
tapSwitch(index) { |
||||
if (this.number === index) { |
||||
this.number = -1 |
||||
return |
||||
} |
||||
this.number = index |
||||
} |
||||
} |
||||
} |
||||
</script> |
||||
|
||||
<style lang="less" scoped> |
||||
.header { |
||||
.tab-title { |
||||
font-size: 32rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 600; |
||||
color: #2DB5AE; |
||||
line-height: 42rpx; |
||||
} |
||||
|
||||
.backImg { |
||||
width: 88rpx; |
||||
height: 62rpx; |
||||
padding-left: 26rpx; |
||||
|
||||
image { |
||||
width: 100%; |
||||
height: 100%; |
||||
} |
||||
} |
||||
} |
||||
|
||||
.problem-box { |
||||
margin: 30rpx; |
||||
padding: 30rpx 30rpx 0 30rpx; |
||||
background-color: white; |
||||
border-radius: 16rpx; |
||||
|
||||
.problem-item { |
||||
flex-wrap: nowrap; |
||||
|
||||
.text-box { |
||||
width: 75%; |
||||
font-size: 30rpx; |
||||
} |
||||
|
||||
padding-bottom: 30rpx; |
||||
|
||||
.img { |
||||
width: 30rpx; |
||||
height: 20rpx; |
||||
} |
||||
|
||||
|
||||
} |
||||
|
||||
.problem-list { |
||||
border-top: 1rpx solid rgb(240, 240, 240); |
||||
|
||||
.item { |
||||
margin-top: 20rpx; |
||||
font-size: 24rpx; |
||||
color: #999; |
||||
} |
||||
} |
||||
|
||||
.problem-list:last-child { |
||||
padding-bottom: 30rpx; |
||||
} |
||||
} |
||||
</style> |
@ -1,72 +1,390 @@
|
||||
<template> |
||||
<view ref="container"> |
||||
<div class="coupon-list" v-if="couponsList.length > 0"> |
||||
<div class="item acea-row row-center-wrapper" v-cloak v-for="(item, index) in couponsList" :key="index"> |
||||
<div class="money" :class="item._type === 0 ? 'moneyGray' : ''"> |
||||
<div> |
||||
¥<span class="num">{{ item.couponPrice }}</span> |
||||
</div> |
||||
<div class="pic-num">满{{ item.useMinPrice }}元可用</div> |
||||
</div> |
||||
<div class="text"> |
||||
<div class="condition line1"> |
||||
{{ item.couponTitle }} |
||||
</div> |
||||
<div class="data acea-row row-between-wrapper"> |
||||
<div v-if="item.endTime === 0">不限时</div> |
||||
<div v-else>{{ item.createTime }}-{{ item.endTime }}</div> |
||||
<div class="bnt gray" v-if="item._type === 0">{{ item._msg }}</div> |
||||
<div class="bnt bg-color-red" v-else>{{ item._msg }}</div> |
||||
</div> |
||||
</div> |
||||
</div> |
||||
</div> |
||||
<!--暂无优惠券--> |
||||
<view class="noCommodity" v-if="couponsList.length === 0 && loading === true"> |
||||
<view class="noPictrue"> |
||||
<image :src="`${$VUE_APP_RESOURCES_URL}/images/noCoupon.png`" class="image" /> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
<view ref="container"> |
||||
<view class="header"> |
||||
<cu-custom :isBack="true" :isCenter="true"> |
||||
<block slot="backText"> |
||||
<view class="backImg"> |
||||
<image src="@/static/images/back-btn.png" mode=""></image> |
||||
</view> |
||||
</block> |
||||
<block slot="content"> |
||||
<view class="tab-title">我的券包</view> |
||||
</block> |
||||
</cu-custom> |
||||
</view> |
||||
|
||||
<view class="content" :style="'min-height:calc(100vh - '+CustomBar+'px);'"> |
||||
<view class="nav-box" :style="'top:'+CustomBar+'px'"> |
||||
<view class="nav acea-row row-around"> |
||||
<view class="item" @click="setType(0)"> |
||||
<view :class="'title ' + (navType == 0? 'active' : '')">待领取</view> |
||||
</view> |
||||
<view class="item" @click="setType(1)"> |
||||
<view :class="'title ' + (navType === 1 ? 'active' : '')">已领取</view> |
||||
</view> |
||||
<view class="item" @click="setType(2)"> |
||||
<view :class="'title acea-row row-middle ' + (navType === 2 ? 'active' : '')">已失效</view> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
|
||||
<view class="coupon-list" v-if="couponsList.length > 0"> |
||||
<view class="item acea-row row-between" v-cloak v-for="(item, index) in couponsList" :key="index"> |
||||
<image class="coupon-bg" src="@/static/images/coupon-bg.png" mode=""></image> |
||||
<view class="coupon-left"> |
||||
<image v-if="item._msg == '已过期'" class="left-bg" src="@/static/images/coupon-bg3.png" mode=""></image> |
||||
<image v-else class="left-bg" src="@/static/images/coupon-bg2.png" mode=""></image> |
||||
<view class="text-box"> |
||||
<view v-if="item.image.length>0" class="wrapper acea-row row-middle"> |
||||
<image class="img" :src="img" mode="" v-for="(img,imgIndex) in item.image.slice(0,3)" :key="imgIndex"></image> |
||||
</view> |
||||
<view v-else class="money">¥{{ item.couponPrice }}</view> |
||||
<!-- <view class="money">7<text>折</text></view> --> |
||||
<view class="line"></view> |
||||
<view class="tip acea-row row-between"> |
||||
<view class="">{{item.cname}}</view> |
||||
<view v-if="item.endTime === 0">不限时</view> |
||||
<view v-else>{{navType===0? item.startTime : item.useStartTime }}-{{navType===0? item.endTime:item.useEndTime}}</view> |
||||
</view> |
||||
</view> |
||||
</view> |
||||
<view class="coupon-right acea-row row-center-column"> |
||||
<image v-if="item._msg == '已过期'" class="tag" |
||||
src="../../../../static/images/failure-icon.png" mode=""></image> |
||||
<image v-else-if="item.isUse" class="tag" src="../../../../static/images/gotCoupon-icon.png" mode=""> |
||||
<image v-else-if="item._msg=='可使用'" class="tag" src="../../../../static/images/gotCoupon-icon.png" mode=""> |
||||
</image> |
||||
<view :class="'type '+(item._msg == '已过期'?'col-fail':'')">{{(item.image.length>0?(item.couponPrice)+'元' :'满减券') || '折扣券'}}</view> |
||||
<view :class="'tip '+(item._msg == '已过期'?'col-fail':'')">满{{ item.useMinPrice }}可用</view> |
||||
<view v-if="item._msg == '已过期'" class="btn btn-fail">不可用</view> |
||||
<view v-else class="btn" @click="getCoupon(item.id,index)">{{navType===0 && item.isUse? '已领取' : (navType===0 ?'立刻领取' :'去使用')}}</view> |
||||
<!-- <view class="btn btn-white">去使用</view> --> |
||||
</view> |
||||
<!-- <div class="money" :class="item._type === 0 ? 'moneyGray' : ''"> |
||||
<div> |
||||
¥<span class="num">{{ item.couponPrice }}</span> |
||||
</div> |
||||
<div class="pic-num">满{{ item.useMinPrice }}元可用</div> |
||||
</div> |
||||
<div class="text"> |
||||
<div class="condition line1">{{ item.couponTitle }}</div> |
||||
<div class="data acea-row row-between-wrapper"> |
||||
<div v-if="item.endTime === 0">不限时</div> |
||||
<div v-else>{{ item.createTime }}-{{ item.endTime }}</div> |
||||
<div class="bnt gray" v-if="item._type === 0">{{ item._msg }}</div> |
||||
<div class="bnt bg-color-red" v-else>{{ item._msg }}</div> |
||||
</div> |
||||
</div> --> |
||||
</view> |
||||
</view> |
||||
|
||||
<!--暂无优惠券--> |
||||
<view class="noCommodity" v-if="couponsList.length === 0 && loading === false" style="padding-top:208rpx;"> |
||||
<view class="noPictrue"> |
||||
<!-- <image :src="`${$VUE_APP_RESOURCES_URL}/images/noCoupon.png`" class="image" /> --> |
||||
<image src="@/static/images/no-more.png" class="image" /> |
||||
</view> |
||||
<view class="text-big"> |
||||
什么都没有,大概被外星人带走了 |
||||
</view> |
||||
<view class="text-small"> |
||||
快去领取福利优惠券吧 |
||||
</view> |
||||
</view> |
||||
|
||||
</view> |
||||
|
||||
</view> |
||||
</template> |
||||
<script> |
||||
import { getCouponsUser } from '@/api/user' |
||||
import DataFormatT from '@/components/DataFormatT' |
||||
|
||||
const NAME = 'UserCoupon' |
||||
|
||||
export default { |
||||
name: 'UserCoupon', |
||||
components: { |
||||
DataFormatT, |
||||
}, |
||||
props: {}, |
||||
data: function() { |
||||
return { |
||||
couponsList: [], |
||||
loading: false, |
||||
} |
||||
}, |
||||
watch: { |
||||
$yroute: function(n) { |
||||
var that = this |
||||
if (n.name === NAME) { |
||||
that.getUseCoupons() |
||||
} |
||||
}, |
||||
}, |
||||
mounted: function() { |
||||
this.getUseCoupons() |
||||
}, |
||||
methods: { |
||||
getUseCoupons: function() { |
||||
let that = this, |
||||
type = 0 |
||||
getCouponsUser(type).then(res => { |
||||
that.couponsList = res.data |
||||
that.loading = true |
||||
}) |
||||
}, |
||||
}, |
||||
} |
||||
import { |
||||
getCouponsUser, |
||||
getCouponReceive, |
||||
getCanReceive, |
||||
getUserFailure |
||||
} from '@/api/user' |
||||
import DataFormatT from '@/components/DataFormatT' |
||||
|
||||
const NAME = 'UserCoupon' |
||||
|
||||
export default { |
||||
name: 'UserCoupon', |
||||
components: { |
||||
DataFormatT, |
||||
}, |
||||
props: {}, |
||||
data: function() { |
||||
return { |
||||
CustomBar: this.CustomBar, |
||||
navType: 1, |
||||
couponsList: [], |
||||
loading: false, |
||||
page: 1, |
||||
limit: 10, |
||||
} |
||||
}, |
||||
watch: { |
||||
$yroute: function(n) { |
||||
var that = this |
||||
if (n.name === NAME) { |
||||
that.getUseCoupons() |
||||
} |
||||
}, |
||||
}, |
||||
mounted: function() { |
||||
this.getUseCoupons(1) |
||||
}, |
||||
methods: { |
||||
setType(i) { |
||||
uni.showLoading({ |
||||
title:'' |
||||
}) |
||||
if (this.navType == i) return; |
||||
this.navType = i; |
||||
this.couponsList=[]; |
||||
this.page= 1, |
||||
this.limit= 10, |
||||
this.getUseCoupons(i); |
||||
}, |
||||
// 领取 |
||||
getCoupon: function(id, index) { |
||||
let that = this |
||||
if(that.navType===2) return |
||||
if(that.navType===1){ |
||||
that.$yrouter.push({ |
||||
path: '/pages/shop/brands/index', |
||||
}) |
||||
return |
||||
} |
||||
let list = that.couponsList, |
||||
tmplIds = ['lOOnpYASRMKy81gh5tNMR7OXSHMKw05x-aosYjvhK-E', 'lejbsmRtheMLXEGNx_UhVHuq5P6Yjwfokc183n9oMek']; |
||||
uni.requestSubscribeMessage({ |
||||
tmplIds, |
||||
fail(err) { |
||||
console.log("requestSubscribeMessage err", err) |
||||
}, |
||||
complete() { |
||||
getCouponReceive(id).then(function(res) { |
||||
list[index].isUse = true |
||||
uni.showToast({ |
||||
title: '领取成功', |
||||
icon: 'success', |
||||
duration: 2000, |
||||
}) |
||||
}).catch(function(err) { |
||||
uni.showToast({ |
||||
title: err.msg || err.response.data.msg || err.response.data.message, |
||||
icon: 'none', |
||||
duration: 2000, |
||||
}) |
||||
}) |
||||
} |
||||
}) |
||||
}, |
||||
|
||||
getUseCoupons: function(i) { |
||||
if (this.loading) return //阻止下次请求(false可以进行请求); |
||||
// if (this.loadend) return //阻止结束当前请求(false可以进行请求); |
||||
this.loading = true |
||||
let q = { |
||||
page: this.page, |
||||
limit: this.limit |
||||
} |
||||
let type = 0 |
||||
if (i === 1) { |
||||
// 用户已领取列表 |
||||
getCouponsUser(type).then(res => { |
||||
res.data.forEach(item=>{ |
||||
if(item._msg!=='已过期'){ |
||||
this.couponsList.push(item) |
||||
} |
||||
}) |
||||
// this.couponsList = res.data |
||||
this.loading = false |
||||
}) |
||||
}else if(i===0){ |
||||
getCanReceive(q).then(res => { |
||||
res.data.forEach(item=>{ |
||||
if(!item.isUse){ |
||||
this.couponsList.push(item) |
||||
} |
||||
}) |
||||
this.loading = false |
||||
this.page = this.page + 1 |
||||
}) |
||||
}else{ |
||||
getUserFailure(type).then(res=>{ |
||||
res.data.forEach(item=>{ |
||||
if(item._msg==='已过期'){ |
||||
this.couponsList.push(item) |
||||
} |
||||
}) |
||||
this.loading = false |
||||
}) |
||||
} |
||||
uni.hideLoading(); |
||||
}, |
||||
// getUseCoupons: function(i) { |
||||
// if (this.loading) return //阻止下次请求(false可以进行请求); |
||||
// // if (this.loadend) return //阻止结束当前请求(false可以进行请求); |
||||
// this.loading = true |
||||
// let q = { |
||||
// page: this.page, |
||||
// limit: this.limit |
||||
// } |
||||
// let type = 0 |
||||
// if (i === 1) { |
||||
// // 用户已领取列表 |
||||
// getCouponsUser(type).then(res => { |
||||
// this.couponsList = res.data |
||||
// this.loading = false |
||||
// }) |
||||
// }else if(i===0){ |
||||
// getCoupon(q).then(res => { |
||||
// res.data.forEach(item=>{ |
||||
// if(!item.isUse){ |
||||
// this.couponsList.push(item) |
||||
// } |
||||
// }) |
||||
// this.loading = false |
||||
// this.page = this.page + 1 |
||||
// }) |
||||
// }else{ |
||||
// this.loading = false |
||||
// } |
||||
// }, |
||||
|
||||
}, |
||||
} |
||||
</script> |
||||
|
||||
<style lang="less" scoped> |
||||
.coupon-list{ |
||||
.wrapper{ |
||||
padding: 0 15rpx; |
||||
box-sizing: content-box; |
||||
height: 100%; |
||||
.img{ |
||||
width: 110rpx; |
||||
height: 110rpx; |
||||
border-radius: 16rpx; |
||||
margin:33rpx 37rpx 14rpx 0; |
||||
background-color: #fff; |
||||
} |
||||
.img:nth-child(3){ |
||||
margin-right: 0; |
||||
} |
||||
} |
||||
} |
||||
|
||||
.header { |
||||
.tab-title { |
||||
font-size: 32rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 600; |
||||
color: #2DB5AE; |
||||
line-height: 42rpx; |
||||
} |
||||
|
||||
.backImg { |
||||
width: 88rpx; |
||||
height: 62rpx; |
||||
padding-left: 26rpx; |
||||
|
||||
image { |
||||
width: 100%; |
||||
height: 100%; |
||||
} |
||||
} |
||||
} |
||||
|
||||
.content { |
||||
width: 100%; |
||||
height: 100%; |
||||
overflow-y: scroll; |
||||
background: #FFFFFF; |
||||
border-radius: 28rpx 28rpx 0rpx 0rpx; |
||||
|
||||
.nav-box { |
||||
width: 100vw; |
||||
padding-top: 4rpx; |
||||
position: fixed; |
||||
left: 0; |
||||
z-index: 5; |
||||
background: #F1F1F1; |
||||
} |
||||
|
||||
.nav { |
||||
width: 100vw; |
||||
background: #FFFFFF; |
||||
height: 88rpx; |
||||
padding: 34rpx 52rpx 12rpx; |
||||
border-radius: 28rpx 28rpx 0rpx 0rpx; |
||||
|
||||
.item { |
||||
text-align: center; |
||||
position: relative; |
||||
|
||||
.title { |
||||
font-size: 26rpx; |
||||
font-family: PingFang SC; |
||||
font-weight: 500; |
||||
color: #3A3A3C; |
||||
line-height: 38rpx; |
||||
} |
||||
|
||||
.active { |
||||
color: #2DB5AE; |
||||
font-weight: 600; |
||||
} |
||||
|
||||
.title::after { |
||||
display: block; |
||||
content: ''; |
||||
width: 100%; |
||||
height: 2rpx; |
||||
background: #2DB5AE; |
||||
position: absolute; |
||||
bottom: 0; |
||||
left: 0; |
||||
opacity: 0; |
||||
transform: scaleX(0); |
||||
transition: all .2s cubic-bezier(.18, .89, .17, .88), opacity .15s ease; |
||||
} |
||||
|
||||
.active::after { |
||||
opacity: 1; |
||||
transform: scaleX(1); |
||||
} |
||||
} |
||||
} |
||||
|
||||
.coupon-list { |
||||
padding-top: 104rpx; |
||||
} |
||||
.noCommodity{ |
||||
.noPictrue{ |
||||
width: 428rpx; |
||||
height: 526rpx; |
||||
} |
||||
.text-big{ |
||||
padding: 0 30rpx; |
||||
text-align: center; |
||||
font-family: PingFangSC-Medium, PingFang SC; |
||||
font-style: 36rpx; |
||||
font-weight: 600; |
||||
color: #3A3A3C; |
||||
line-height: 50rpx; |
||||
} |
||||
.text-small{ |
||||
padding: 0 80rpx; |
||||
font-family: PingFangSC-Medium, PingFang SC; |
||||
text-align: center; |
||||
font-style: 28rpx; |
||||
font-weight: 400; |
||||
color: #3A3A3C; |
||||
line-height: 40rpx; |
||||
} |
||||
} |
||||
} |
||||
</style> |
||||
|
Before Width: | Height: | Size: 1.6 KiB After Width: | Height: | Size: 442 B |
Before Width: | Height: | Size: 1.6 KiB After Width: | Height: | Size: 448 B |
Before Width: | Height: | Size: 1.6 KiB After Width: | Height: | Size: 361 B |
Before Width: | Height: | Size: 1.8 KiB After Width: | Height: | Size: 361 B |
Before Width: | Height: | Size: 1.6 KiB After Width: | Height: | Size: 535 B |
Before Width: | Height: | Size: 1.5 KiB After Width: | Height: | Size: 523 B |
Before Width: | Height: | Size: 1.5 KiB After Width: | Height: | Size: 483 B |
Before Width: | Height: | Size: 1.6 KiB After Width: | Height: | Size: 490 B |
After Width: | Height: | Size: 1.0 KiB |
After Width: | Height: | Size: 823 B |
After Width: | Height: | Size: 469 B |
After Width: | Height: | Size: 618 B |
After Width: | Height: | Size: 559 B |
After Width: | Height: | Size: 470 B |
After Width: | Height: | Size: 373 B |
After Width: | Height: | Size: 787 B |
After Width: | Height: | Size: 437 B |
After Width: | Height: | Size: 314 B |
After Width: | Height: | Size: 284 B |
After Width: | Height: | Size: 2.0 KiB |
After Width: | Height: | Size: 8.4 KiB |