Compare commits
No commits in common. 'main' and 'fix/goods-0525' have entirely different histories.
main
...
fix/goods-
Before Width: | Height: | Size: 756 B After Width: | Height: | Size: 2.0 KiB |
Before Width: | Height: | Size: 762 B After Width: | Height: | Size: 1.9 KiB |
Before Width: | Height: | Size: 850 B After Width: | Height: | Size: 2.0 KiB |
Before Width: | Height: | Size: 613 B After Width: | Height: | Size: 3.2 KiB |
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 3.3 KiB |
Before Width: | Height: | Size: 1.0 KiB |
Before Width: | Height: | Size: 972 B |
Before Width: | Height: | Size: 445 B |
Before Width: | Height: | Size: 445 B |
Before Width: | Height: | Size: 33 KiB |
Before Width: | Height: | Size: 375 B |
Before Width: | Height: | Size: 386 B |
Before Width: | Height: | Size: 386 B |
Before Width: | Height: | Size: 26 KiB |
Before Width: | Height: | Size: 1.6 KiB |
Before Width: | Height: | Size: 83 KiB |
Before Width: | Height: | Size: 11 KiB |
Before Width: | Height: | Size: 4.8 KiB |
Before Width: | Height: | Size: 3.1 KiB |
Before Width: | Height: | Size: 3.3 KiB |
Before Width: | Height: | Size: 14 KiB |
Before Width: | Height: | Size: 1.8 KiB |
Before Width: | Height: | Size: 28 KiB |
Before Width: | Height: | Size: 1.7 KiB |
Before Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 64 KiB |
Before Width: | Height: | Size: 179 KiB |
Before Width: | Height: | Size: 1.8 KiB |
Before Width: | Height: | Size: 215 KiB |
Before Width: | Height: | Size: 242 KiB |
Before Width: | Height: | Size: 9.8 KiB |
Before Width: | Height: | Size: 9.4 KiB |
@ -1,58 +0,0 @@
|
||||
<!--
|
||||
* @Author: ch
|
||||
* @Date: 2022-06-23 10:40:04
|
||||
* @LastEditors: ch
|
||||
* @LastEditTime: 2022-06-30 22:11:19
|
||||
* @Description: file content
|
||||
-->
|
||||
<template>
|
||||
<div class="follow">
|
||||
<b class="follow--title">{{day}}追评:</b>
|
||||
<p class="follow--ctx">{{followComment.commentContent}}</p>
|
||||
<UiImgs v-if="imgs.length" :list="imgs" class="follow--imgs" />
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import UiImgs from './UiImgs.vue';
|
||||
export default {
|
||||
components: { UiImgs },
|
||||
props : {
|
||||
followComment : {
|
||||
type : Object,
|
||||
default : () => ({})
|
||||
},
|
||||
commentTime : {
|
||||
type : String,
|
||||
default : ''
|
||||
}
|
||||
},
|
||||
computed:{
|
||||
day(){
|
||||
const followTime = (new Date(this.followComment.createTime)).getTime();
|
||||
const commentTime = (new Date(this.commentTime)).getTime();
|
||||
const day = Math.floor((followTime - commentTime) / (24 * 60 * 60 * 1000));
|
||||
return day > 0 ? `${day}天后` : `当天`;
|
||||
},
|
||||
imgs (){
|
||||
let urls = this.followComment.pictureUrl || '';
|
||||
return urls ? urls.split(',') : [];
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
.follow{
|
||||
margin-top: 30px;
|
||||
&--title{
|
||||
color: #FF6A19;
|
||||
font-weight: normal;
|
||||
}
|
||||
&--ctx{
|
||||
line-height: 24px;
|
||||
word-break: break-all;
|
||||
}
|
||||
&--imgs{
|
||||
margin-top: 10px;
|
||||
}
|
||||
}
|
||||
</style>
|
@ -1,205 +0,0 @@
|
||||
<!--
|
||||
* @Author: ch
|
||||
* @Date: 2022-06-25 15:29:43
|
||||
* @LastEditors: ch
|
||||
* @LastEditTime: 2022-06-30 22:53:16
|
||||
* @Description: file content
|
||||
-->
|
||||
<template>
|
||||
|
||||
<div class="submit">
|
||||
<p class="rate-box" v-if="type === COMMENT.TYPE.COMMENT">
|
||||
<b>满意度评分</b>
|
||||
<el-rate v-model="rate"></el-rate>
|
||||
<span>{{reteDesc}}</span>
|
||||
</p>
|
||||
<el-input type="textarea" class="textarea" placeholder="从多个维度评价,可以帮助更多想买的人哦~"
|
||||
v-model="commentContent" show-word-limit :maxlength="500" :rows="6"/>
|
||||
<div class="operation">
|
||||
<el-upload list-type="picture-card"
|
||||
:on-remove="handleRemove" :limit="6"
|
||||
:action="uploadAction" :data="uploadData"
|
||||
:before-upload="handleBeforeUpload"
|
||||
:on-exceed="handleUploadExceed"
|
||||
:on-error="handleUploadError">
|
||||
<i class="el-icon-plus"></i>
|
||||
<p class="upload-txt">我要晒图</p>
|
||||
</el-upload>
|
||||
<UiButton class="upload-btn" :disabled="isDisabled" @click="handleSubmit">发表评论</UiButton>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import {ApiPostComment} from '@/plugins/api/comment';
|
||||
import {ApiPostGetOssConfig} from '@/plugins/api/oss';
|
||||
import {COMMENT} from '@/constants';
|
||||
|
||||
export default {
|
||||
props : {
|
||||
type : {
|
||||
type : String | Number,
|
||||
default : COMMENT.TYPE.COMMENT
|
||||
},
|
||||
commentDetail : {
|
||||
type : Object,
|
||||
default : () => ({})
|
||||
}
|
||||
},
|
||||
data(){
|
||||
return {
|
||||
COMMENT,
|
||||
rate: 5,
|
||||
commentContent : '',
|
||||
uploadData : {},
|
||||
uploadAction : '',
|
||||
fileList : []
|
||||
}
|
||||
},
|
||||
computed:{
|
||||
isEdit(){
|
||||
return (this.commentContent || this.fileList.length > 0) ? true : false
|
||||
},
|
||||
reteDesc(){
|
||||
return COMMENT.RATE_LEVEL[this.rate];
|
||||
},
|
||||
isDisabled(){
|
||||
let status = false
|
||||
if(this.type === COMMENT.TYPE.COMMENT){
|
||||
status = !this.rate || !this.commentContent.trim();
|
||||
}
|
||||
if(this.type === COMMENT.TYPE.FOLLOW_COMMENT){
|
||||
status = !this.commentContent.trim();
|
||||
}
|
||||
return status;
|
||||
}
|
||||
},
|
||||
watch : {
|
||||
isEdit(val){
|
||||
this.$emit('editStatusChange', val)
|
||||
}
|
||||
},
|
||||
methods : {
|
||||
async handleSubmit(){
|
||||
let data = {
|
||||
commentContent : this.commentContent,
|
||||
commentType : this.type,
|
||||
orderProductId : this.commentDetail.orderProductId,
|
||||
pictureUrl : this.fileList.map(i => i.url).join(',')
|
||||
}
|
||||
if(this.type === COMMENT.TYPE.COMMENT){
|
||||
data.productId = this.commentDetail.productId;
|
||||
data.commentScore = this.rate;
|
||||
}else if(this.type === COMMENT.TYPE.FOLLOW_COMMENT){
|
||||
data.originId = data.parentId = this.commentDetail.id;
|
||||
}
|
||||
const {error, result} = await ApiPostComment(data);
|
||||
if(error){
|
||||
this.$message.error(error.message);
|
||||
return false;
|
||||
}
|
||||
this.commentContent = '';
|
||||
this.fileList = [];
|
||||
this.$nextTick(()=>{
|
||||
this.$emit('submit',result);
|
||||
})
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 获取OSS鉴权信息
|
||||
* configId 自定义文件夹 图片存储的文件夹名称
|
||||
* serviceName 服务名
|
||||
*/
|
||||
async getOssCon(){
|
||||
const {error, result} = await ApiPostGetOssConfig({
|
||||
configId : 'account-comment/',
|
||||
serviceName : 'comment'
|
||||
});
|
||||
if(error){
|
||||
this.$message.error(error.message);
|
||||
return false
|
||||
}
|
||||
return result
|
||||
|
||||
},
|
||||
|
||||
async handleBeforeUpload(file) {
|
||||
let result = await this.getOssCon();
|
||||
if(result){
|
||||
this.uploadAction = result.host;
|
||||
this.uploadData = {
|
||||
...this.uploadData,
|
||||
policy : result.policy,
|
||||
OSSAccessKeyId: result.accessId,
|
||||
success_action_status: 200,
|
||||
signature: result.signature,
|
||||
}
|
||||
}
|
||||
Object.assign(this.uploadData, {
|
||||
key: `${result.dir}${"${filename}"}`,
|
||||
name: file.name,
|
||||
});
|
||||
this.fileList.push({
|
||||
url : `${result.host}/${result.dir}${file.name}`,
|
||||
uid : file.uid
|
||||
})
|
||||
},
|
||||
|
||||
handleUploadError(error, file) {
|
||||
this.handleRemove(file)
|
||||
},
|
||||
handleRemove(file) {
|
||||
this.fileList = this.fileList.filter(i => i.uid != file.uid );
|
||||
},
|
||||
handleUploadExceed(){
|
||||
this.$message.warning('最多只能上传6张照片哦~')
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.rate-box{
|
||||
display: flex;
|
||||
b{
|
||||
font-weight: normal;
|
||||
margin-right: 10px;
|
||||
color: #666;
|
||||
}
|
||||
span{
|
||||
color: #FF6A19;
|
||||
margin-left: 10px;
|
||||
}
|
||||
}
|
||||
.textarea{
|
||||
height: 138px;
|
||||
margin-top: 30px;
|
||||
}
|
||||
.operation{
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
margin-top: 15px;
|
||||
.upload-txt{
|
||||
font-size: 12px;
|
||||
color: #999;
|
||||
}
|
||||
.upload-btn{
|
||||
height: 40px;
|
||||
width: 100px;
|
||||
border-radius: 4px;
|
||||
font-size: 14px;
|
||||
padding: 0;
|
||||
}
|
||||
}
|
||||
/deep/{
|
||||
.el-upload--picture-card,.el-upload-list__item{
|
||||
height: 70px !important;
|
||||
width: 70px !important;
|
||||
line-height: 20px;
|
||||
}
|
||||
.el-upload--picture-card{
|
||||
padding-top: 10px;
|
||||
}
|
||||
}
|
||||
</style>
|
@ -1,137 +0,0 @@
|
||||
<!--
|
||||
* @Author: ch
|
||||
* @Date: 2022-06-24 19:07:45
|
||||
* @LastEditors: ch
|
||||
* @LastEditTime: 2022-06-30 19:40:36
|
||||
* @Description: file content
|
||||
-->
|
||||
<template>
|
||||
<div class="preview-imgs">
|
||||
<ul>
|
||||
<li v-for="(i, idx) in list" :key="idx" :class="{'active' : curIndex == idx}" >
|
||||
<img :src="i" @click="curIndex = idx"/>
|
||||
</li>
|
||||
</ul>
|
||||
<p v-if="curIndex > -1">
|
||||
<img :src="list[curIndex]" @click="curIndex = -1"/>
|
||||
<span class="prev" @click="prev" v-if="curIndex > 0"></span>
|
||||
<span class="next" @click="next" v-if="curIndex < list.length-1"></span>
|
||||
</p>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
export default {
|
||||
props : {
|
||||
list : {
|
||||
type : Array,
|
||||
default : () => ([])
|
||||
}
|
||||
},
|
||||
data(){
|
||||
return {
|
||||
curIndex : -1,
|
||||
}
|
||||
},
|
||||
methods:{
|
||||
next(){
|
||||
this.curIndex++;
|
||||
},
|
||||
prev(){
|
||||
this.curIndex--;
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
.preview-imgs{
|
||||
ul{
|
||||
display: flex;
|
||||
}
|
||||
li{
|
||||
width: 46px;
|
||||
height : 46px;
|
||||
border: 1px solid #eee;
|
||||
margin-right: 10px;
|
||||
padding: 1px;
|
||||
cursor: pointer;
|
||||
img{
|
||||
width: 42px;
|
||||
height: 42px;
|
||||
object-fit: contain;
|
||||
}
|
||||
&.active{
|
||||
border-color: #FF512B;
|
||||
position: relative;
|
||||
&::after{
|
||||
content: '';
|
||||
height: 3px;
|
||||
width: 3px;
|
||||
bottom: -7px;
|
||||
left: 17px;
|
||||
display: block;
|
||||
position: absolute;
|
||||
// transform: rotate(45deg);
|
||||
border: 3px solid #FF512B;
|
||||
border-left-color: transparent;
|
||||
border-right-color: transparent;
|
||||
border-bottom-color: transparent;
|
||||
}
|
||||
}
|
||||
}
|
||||
p{
|
||||
width: 300px;
|
||||
margin-top: 20px;
|
||||
position: relative;
|
||||
border: 1px solid #eee;
|
||||
img{
|
||||
width: 300px;
|
||||
height: 300px;
|
||||
object-fit: contain;
|
||||
cursor: zoom-out;
|
||||
}
|
||||
&:hover span{
|
||||
display: block;
|
||||
}
|
||||
span{
|
||||
display: none;
|
||||
position: absolute;
|
||||
width: 40px;
|
||||
height: 40px;
|
||||
background: rgba(0,0,0, .5);
|
||||
top : 130px;
|
||||
cursor: pointer;
|
||||
&::after,&::before{
|
||||
position: absolute;
|
||||
display: block;
|
||||
content: '';
|
||||
background: #fff;
|
||||
height: 20px;
|
||||
width: 4px;
|
||||
border-radius: 4px;
|
||||
left: 16px;
|
||||
top: 4px;
|
||||
transform: rotate(45deg);
|
||||
}
|
||||
&::after{
|
||||
transform: rotate(-45deg);
|
||||
top: 16px;
|
||||
}
|
||||
&.prev{
|
||||
left: 10px;
|
||||
|
||||
}
|
||||
&.next{
|
||||
right: 10px;
|
||||
&::after{
|
||||
left: 20px;
|
||||
transform: rotate(45deg);
|
||||
}
|
||||
&::before{
|
||||
left: 20px;
|
||||
transform: rotate(-45deg);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
@ -1,60 +0,0 @@
|
||||
<!--
|
||||
* @Author: ch
|
||||
* @Date: 2022-05-04 17:56:39
|
||||
* @LastEditors: ch
|
||||
* @LastEditTime: 2022-06-02 17:49:00
|
||||
* @Description: file content
|
||||
-->
|
||||
<template>
|
||||
<div class="layout">
|
||||
<BsLogin :visible.sync="loginVisible" />
|
||||
<Header :is-sticky="isSticky" />
|
||||
<div class="layout-content">
|
||||
<Nuxt />
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import BsLogin from "@/components/BsLogin.vue";
|
||||
import Header from "./module/header/index.vue";
|
||||
import Footer from "./module/footer/index.vue";
|
||||
|
||||
export default {
|
||||
name: "down",
|
||||
components: { Header, Footer, BsLogin },
|
||||
data() {
|
||||
return {
|
||||
isSticky: false,
|
||||
};
|
||||
},
|
||||
computed: {
|
||||
loginVisible: {
|
||||
get() {
|
||||
return this.$store.state.loginVisible;
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit("setLoginVisible", val);
|
||||
},
|
||||
},
|
||||
},
|
||||
mounted() {
|
||||
// 监听滚动事件
|
||||
window.addEventListener("scroll", this.scrollEventMethod);
|
||||
},
|
||||
destroyed() {
|
||||
window.removeEventListener("scroll", this.scrollEventMethod);
|
||||
},
|
||||
methods: {
|
||||
scrollEventMethod() {
|
||||
this.isSticky = window.scrollY > 300;
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
.layout {
|
||||
.layout-content {
|
||||
min-height: calc(100vh - 400px);
|
||||
}
|
||||
}
|
||||
</style>
|
@ -1,114 +0,0 @@
|
||||
<!--
|
||||
* @Author: ch
|
||||
* @Date: 2022-05-08 01:11:33
|
||||
* @LastEditors: ch
|
||||
* @LastEditTime: 2022-06-28 10:39:35
|
||||
* @Description: file content
|
||||
-->
|
||||
<template>
|
||||
<div>
|
||||
<div class="main">
|
||||
<img class="icon" src="@/assets/img/order/pay_success.png" />
|
||||
<p>评价成功</p>
|
||||
<div>
|
||||
<UiButton type="grey" @click="$router.back()" :radius="true">返回</UiButton>
|
||||
</div>
|
||||
<div v-if="goodsList.length">
|
||||
<b class="product-title">这些宝贝还在等你得评价哦~</b>
|
||||
<ul class="product">
|
||||
<li v-for="(item, idx) in goodsList" :key="idx">
|
||||
<img :src="item.productPicture"/>
|
||||
<p>{{item.productName}}</p>
|
||||
<UiButton type="grey" @click="$router.replace(`/account/comment?orderId=${item.orderId}`)" >
|
||||
{{item.commentStatus == 1 ? '立即评价' : '立即追评'}}
|
||||
</UiButton>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<BsChosen class="chosen"/>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import UiButton from '@/components/UiButton.vue';
|
||||
import {ApiGetCommentOrderDetailList} from '@/plugins/api/order';
|
||||
export default {
|
||||
components: { UiButton },
|
||||
data(){
|
||||
return {
|
||||
goodsList : []
|
||||
}
|
||||
},
|
||||
mounted(){
|
||||
this.getAwaitGoodsList();
|
||||
},
|
||||
methods:{
|
||||
|
||||
async getAwaitGoodsList (){
|
||||
const {error, result} = await ApiGetCommentOrderDetailList({
|
||||
length:6,
|
||||
pageIndex : 1
|
||||
});
|
||||
if(error){
|
||||
this.$message.warning(error.message)
|
||||
}
|
||||
this.goodsList = result.records.map(item => {
|
||||
return {
|
||||
productPicture : item.productImageUrl,
|
||||
productName : item.productName,
|
||||
commentStatus : item.commentStatus,
|
||||
orderId : item.orderId
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
.main{
|
||||
@include layout-box;
|
||||
text-align: center;
|
||||
padding: 100px 0 40px;
|
||||
}
|
||||
.icon{
|
||||
width: 239px;
|
||||
}
|
||||
b{
|
||||
display: block;
|
||||
}
|
||||
p{
|
||||
margin: 10px 0 25px 0;
|
||||
color: #999;
|
||||
}
|
||||
button{
|
||||
margin: 0 10px 30px;
|
||||
}
|
||||
.product-title{
|
||||
height: 40px;
|
||||
line-height: 40px;
|
||||
text-align: left;
|
||||
background: #F7F7F7;
|
||||
font-weight: normal;
|
||||
color: #666;
|
||||
padding: 0 16px;
|
||||
}
|
||||
.product{
|
||||
display: flex;
|
||||
// justify-content: flex-start;
|
||||
li{
|
||||
margin:40px 0 0 48px;
|
||||
width: 140px;
|
||||
img{
|
||||
width: 140px;
|
||||
height: 140px;
|
||||
object-fit: contain;
|
||||
|
||||
}
|
||||
p{
|
||||
@include ellipses(2);
|
||||
height: 40px;
|
||||
margin: 10px 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
@ -1,59 +0,0 @@
|
||||
<!--
|
||||
* @Author: ch
|
||||
* @Date: 2022-05-08 01:11:33
|
||||
* @LastEditors: ch
|
||||
* @LastEditTime: 2022-06-27 15:37:53
|
||||
* @Description: file content
|
||||
-->
|
||||
<template>
|
||||
<div>
|
||||
<div class="main">
|
||||
<img class="icon" src="@/assets/img/order/pay_success.png" />
|
||||
<!-- <b>交易成功</b> -->
|
||||
<p>交易成功</p>
|
||||
<div>
|
||||
<UiButton type="grey" @click="$router.replace(`/`)" :radius="true">返回首页</UiButton>
|
||||
<UiButton type="yellow_gradual" @click="$router.replace(`./comment?orderId=${orderId}`)" :radius="true">去评价</UiButton>
|
||||
</div>
|
||||
</div>
|
||||
<BsChosen class="chosen"/>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import UiButton from '@/components/UiButton.vue';
|
||||
import {ApiGetOrderPaySatus} from '@/plugins/api/order';
|
||||
export default {
|
||||
components: { UiButton },
|
||||
data(){
|
||||
return {
|
||||
orderId : this.$route.query.orderId
|
||||
}
|
||||
},
|
||||
mounted(){
|
||||
|
||||
|
||||
},
|
||||
methods:{
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
.main{
|
||||
@include layout-box;
|
||||
text-align: center;
|
||||
padding: 100px 0 40px;
|
||||
}
|
||||
.icon{
|
||||
width: 239px;
|
||||
}
|
||||
b{
|
||||
display: block;
|
||||
}
|
||||
p{
|
||||
margin: 10px 0 25px 0;
|
||||
color: #999;
|
||||
}
|
||||
button{
|
||||
margin: 0 10px 30px;
|
||||
}
|
||||
</style>
|
@ -1,231 +0,0 @@
|
||||
<!--
|
||||
* @Author: ch
|
||||
* @Date: 2022-05-26 16:08:17
|
||||
* @LastEditors: ch
|
||||
* @LastEditTime: 2022-06-02 17:56:04
|
||||
* @Description: file content
|
||||
-->
|
||||
<template>
|
||||
<div class="main">
|
||||
<h2 class="title">下载马士兵严选APP</h2>
|
||||
<p class="desc"><b>精选好物</b><span></span><b>精致生活</b></p>
|
||||
<ul class="group">
|
||||
<li class="group--item">
|
||||
<div class="qrcode">
|
||||
<img class="qrcode--img" src="@/assets/img/down/app-qrcode.png"/>
|
||||
<img class="qrcode--icon" src="@/assets/img/down/android.png"/>
|
||||
</div>
|
||||
<span class="group--item-title">Android</span>
|
||||
</li>
|
||||
<li class="group--item">
|
||||
<div class="qrcode qrcode__disabled">
|
||||
<img class="qrcode--img" src="@/assets/img/down/app-qrcode.png"/>
|
||||
<img class="qrcode--icon" src="@/assets/img/down/ios.png"/>
|
||||
</div>
|
||||
<span class="group--item-title">iOS</span>
|
||||
<span class="group--item-btn">规划中...</span>
|
||||
</li>
|
||||
<li class="group--item">
|
||||
<div class="qrcode">
|
||||
<img class="qrcode--img" src="@/assets/img/down/wx-qrcode.jpg"/>
|
||||
<img class="qrcode--icon" src="@/assets/img/down/wx.png"/>
|
||||
</div>
|
||||
<span class="group--item-title">微信公众号</span>
|
||||
</li>
|
||||
<li class="group--item">
|
||||
<div class="qrcode">
|
||||
<img class="qrcode--img" src="@/assets/img/down/h5-qrcode.png"/>
|
||||
<img class="qrcode--icon" src="@/assets/img/down/browser.png"/>
|
||||
</div>
|
||||
<span class="group--item-title">H5</span>
|
||||
</li>
|
||||
</ul>
|
||||
<div class="bg">
|
||||
<i class="bg--icon1"></i>
|
||||
<i class="bg--icon2"></i>
|
||||
<i class="bg--icon3"></i>
|
||||
<i class="bg--icon4"></i>
|
||||
<i class="bg--icon5"></i>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
export default {
|
||||
layout : 'down'
|
||||
}
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
.main{
|
||||
height: calc(100vh - 132px);
|
||||
overflow: hidden;
|
||||
position: relative;
|
||||
}
|
||||
.title{
|
||||
text-align: center;
|
||||
font-size: 40px;
|
||||
font-family: 'PingFang SC-粗体, PingFang SC';
|
||||
font-weight: bold;
|
||||
color: #191919;
|
||||
margin-top: 115px;
|
||||
}
|
||||
.desc{
|
||||
text-align: center;
|
||||
font-size: 24px;
|
||||
font-family: 'PingFang SC-常规体, PingFang SC';
|
||||
color: #A8A8A8;
|
||||
line-height: 21px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
margin-top: 24px;
|
||||
span{
|
||||
margin: 0 15px;
|
||||
display: inline-block;
|
||||
width: 6px;
|
||||
height: 6px;
|
||||
background: #A8A8A8;
|
||||
border-radius: 6px;
|
||||
}
|
||||
}
|
||||
.group{
|
||||
width: 930px;
|
||||
margin: 73px auto;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
z-index: 1;
|
||||
position: relative;
|
||||
&--item{
|
||||
text-align: center;
|
||||
&-title{
|
||||
display: block;
|
||||
font-size: 20px;
|
||||
margin: 25px 0;
|
||||
}
|
||||
&-btn{
|
||||
border: 1px solid #ddd;
|
||||
color: #A7A7A7;
|
||||
font-size: 16px;
|
||||
width: 142px;
|
||||
height: 40px;
|
||||
line-height: 40px;
|
||||
display: inline-block;
|
||||
}
|
||||
}
|
||||
}
|
||||
// .qrcode--img:hover + .qrcode--icon{
|
||||
// opacity: 0;
|
||||
// }
|
||||
.qrcode{
|
||||
width: 180px;
|
||||
height: 180px;
|
||||
background: url('@/assets/img/down/qrcode.png') no-repeat #F4F3F3 right top;
|
||||
background-size: 52px;
|
||||
cursor: pointer;
|
||||
text-align: center;
|
||||
position: relative;
|
||||
&--icon{
|
||||
position: absolute;
|
||||
z-index: 1;
|
||||
width: 57px;
|
||||
height: 96px;
|
||||
left: 62px;
|
||||
top: 42px;
|
||||
transition: opacity .8s;
|
||||
opacity: 1;
|
||||
}
|
||||
&--img{
|
||||
position: absolute;
|
||||
z-index: 2;
|
||||
left: 0;
|
||||
top: 0;
|
||||
transition: opacity 1s;
|
||||
opacity: 0;
|
||||
&:hover{
|
||||
opacity: 1;
|
||||
+ .qrcode--icon{
|
||||
opacity: 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
&__disabled{
|
||||
cursor: no-drop;
|
||||
.qrcode--img:hover{
|
||||
opacity: 0;
|
||||
+ .qrcode--icon{
|
||||
opacity: 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.bg{
|
||||
width: 1920px;
|
||||
height: 100%;
|
||||
@include adj(transform, translateX(-50%));
|
||||
z-index: 0;
|
||||
position: absolute;
|
||||
left: 50%;
|
||||
top: 0;
|
||||
i{
|
||||
position: absolute;
|
||||
display: block;
|
||||
background-size: 100%;
|
||||
}
|
||||
&--icon1{
|
||||
bottom: 45px;
|
||||
width: 152px;
|
||||
height: 257px;
|
||||
background-image: url('@/assets/img/down/bg1.png');
|
||||
}
|
||||
&--icon2{
|
||||
top: 148px;
|
||||
left: 140px;
|
||||
width: 197px;
|
||||
height: 214px;
|
||||
background-image: url('@/assets/img/down/bg2.png');
|
||||
animation: float 4s ease-in-out infinite;
|
||||
}
|
||||
&--icon3{
|
||||
top: 549px;
|
||||
left: 960px;
|
||||
width: 116px;
|
||||
height: 126px;
|
||||
background-image: url('@/assets/img/down/bg3.png');
|
||||
animation: float 5s ease-in-out infinite;
|
||||
}
|
||||
&--icon4{
|
||||
top: 456px;
|
||||
right: 261px;
|
||||
width: 133px;
|
||||
height: 137px;
|
||||
background-image: url('@/assets/img/down/bg4.png');
|
||||
animation: float 4s ease-in-out infinite;
|
||||
}
|
||||
|
||||
&--icon5{
|
||||
top: -72px;
|
||||
right: -20px;
|
||||
width: 200px;
|
||||
height: 200px;
|
||||
box-shadow: 0 0 50px #ffc9b6;
|
||||
background: #FFF8F2;
|
||||
border-radius: 50%;
|
||||
filter: blur(50px);
|
||||
// background-image: url('@/assets/img/down/bg5.png');
|
||||
// background-size: 246px !important ;
|
||||
// background-repeat: no-repeat;
|
||||
// background-position: center;
|
||||
}
|
||||
}
|
||||
@keyframes float {
|
||||
0% {
|
||||
transform: translateY(0px);
|
||||
}
|
||||
50% {
|
||||
transform: translateY(-50px);
|
||||
}
|
||||
100% {
|
||||
transform: translateY(0px);
|
||||
}
|
||||
}
|
||||
</style>
|
@ -1,84 +0,0 @@
|
||||
<!--
|
||||
* @Author: ch
|
||||
* @Date: 2022-06-25 07:24:32
|
||||
* @LastEditors: ch
|
||||
* @LastEditTime: 2022-06-29 14:19:36
|
||||
* @Description: file content
|
||||
-->
|
||||
<template>
|
||||
<div class="header">
|
||||
<div class="header--layout">
|
||||
<ul>
|
||||
<li @click="handleJump('detail')" :class="{'active': tabKey =='detail'}">商品详情</li>
|
||||
<li @click="handleJump('comment')" :class="{'active': tabKey =='comment'}">商品评价</li>
|
||||
</ul>
|
||||
<UiButton @click="handleAddCart">加入购物车</UiButton>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import UiButton from '@/components/UiButton.vue'
|
||||
export default {
|
||||
components: { UiButton },
|
||||
props:{
|
||||
tabKey : {
|
||||
type : String,
|
||||
default : 'detail'
|
||||
}
|
||||
},
|
||||
data(){
|
||||
return {}
|
||||
},
|
||||
methods:{
|
||||
handleJump(val){
|
||||
this.$emit('jump', val)
|
||||
},
|
||||
handleAddCart(){
|
||||
this.$emit('addCart')
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
.header{
|
||||
position: fixed;
|
||||
top: 0;
|
||||
left: 0;
|
||||
right: 0;
|
||||
height: 70px;
|
||||
background: #fff;
|
||||
z-index: 11;
|
||||
&--layout{
|
||||
@include layout-box;
|
||||
padding-left: 256px;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
height: 100%;
|
||||
ul{
|
||||
display: flex;
|
||||
font-size: 16px;
|
||||
li{
|
||||
margin-right: 50px;
|
||||
height: 70px;
|
||||
line-height: 70px;
|
||||
&.active{
|
||||
color: #FF6A19;
|
||||
position: relative;
|
||||
&::after{
|
||||
display: block;
|
||||
content: '';
|
||||
position: absolute;
|
||||
height: 2px;
|
||||
width: 40px;
|
||||
background: #FF6A19;
|
||||
bottom: 0;
|
||||
left: 50%;
|
||||
transform: translateX(-50%);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
@ -1,22 +0,0 @@
|
||||
/*
|
||||
* @Author: ch
|
||||
* @Date: 2022-05-31 11:17:38
|
||||
* @LastEditors: ch
|
||||
* @LastEditTime: 2022-06-01 15:53:53
|
||||
* @Description: file content
|
||||
*/
|
||||
|
||||
import {ToAsyncAwait} from '@/plugins/utils';
|
||||
import { AD_PLATFORM } from '../dicts/ad';
|
||||
import {axios} from "../axios";
|
||||
import ENV from '../config/env';
|
||||
|
||||
const BASE_URL = `${ENV.base_url}/mall/marketing`;
|
||||
|
||||
// 获取广告列表
|
||||
export const ApiGetAdList = (params) => ToAsyncAwait(axios.get(`${BASE_URL}/app/advertisement`, {
|
||||
params: {
|
||||
platform : AD_PLATFORM.PC,
|
||||
...params
|
||||
}
|
||||
}))
|
@ -1,86 +0,0 @@
|
||||
/*
|
||||
* @Author: ch
|
||||
* @Date: 2022-06-20 11:38:48
|
||||
* @LastEditors: ch
|
||||
* @LastEditTime: 2022-06-30 11:48:53
|
||||
* @Description: file content
|
||||
*/
|
||||
|
||||
import {axiosTk} from "../axiosTk";
|
||||
import {axios} from "../axios";
|
||||
import { ToAsyncAwait } from "../utils";
|
||||
import ENV from '../config/env';
|
||||
|
||||
const BASE_URL = `${ENV.base_url}/mall/comment`;
|
||||
|
||||
/**
|
||||
* 根据商品获取评论列表未
|
||||
* @param {*} param0
|
||||
*/
|
||||
export const ApiGetCommentList = (params) =>
|
||||
ToAsyncAwait(axiosTk.get(`${BASE_URL}/app/comment`, {
|
||||
params,
|
||||
headers: {
|
||||
notVerifyToken : true
|
||||
}
|
||||
}));
|
||||
|
||||
/**
|
||||
* 根据商品获取评论总数
|
||||
* @param {*} param0
|
||||
*/
|
||||
export const ApiGetCommentCount = ({productId}) =>
|
||||
ToAsyncAwait(axiosTk.get(`${BASE_URL}/app/comment/getAllCommentCountByProductId/${productId}`,{
|
||||
headers: {
|
||||
notVerifyToken : true
|
||||
}
|
||||
}));
|
||||
/**
|
||||
* 根据商品获取标签评论总数
|
||||
* @param {*} param0
|
||||
*/
|
||||
export const ApiGetCommentTabCount = ({productId}) =>
|
||||
ToAsyncAwait(axiosTk.get(`${BASE_URL}/app/comment/listCommentLabel/${productId}`,{
|
||||
headers: {
|
||||
notVerifyToken : true
|
||||
}
|
||||
}));
|
||||
/**
|
||||
* 获取订单评论详情
|
||||
* @param {*} param0
|
||||
*/
|
||||
export const ApiGetOrderCommentDetail = ({orderId}) =>
|
||||
ToAsyncAwait(axiosTk.get(`${BASE_URL}/app/comment/listOrderCommentByOrderId/${orderId}`));
|
||||
/**
|
||||
* 获取商品满意度
|
||||
* @param {*} param0
|
||||
*/
|
||||
export const ApiGetProductSatisfaction = ({productId}) =>
|
||||
ToAsyncAwait(axios.get(`${BASE_URL}/app/comment/getProductSatisfaction/${productId}`));
|
||||
/**
|
||||
* 获取评论详情
|
||||
* @param {*} param0
|
||||
*/
|
||||
export const ApiGetCommentDetail = ({commentId}) =>
|
||||
ToAsyncAwait(axiosTk.get(`${BASE_URL}/app/comment/getCommentDetail/${commentId}`, {
|
||||
headers: {
|
||||
notVerifyToken : true
|
||||
}
|
||||
}));
|
||||
/**
|
||||
* 新增评论
|
||||
* @param {*} param0
|
||||
*/
|
||||
export const ApiPostComment = (data) =>
|
||||
ToAsyncAwait(axiosTk.post(`${BASE_URL}/app/comment`, data));
|
||||
|
||||
|
||||
/**
|
||||
* 更新评论有用数
|
||||
* @param {*} param0
|
||||
*/
|
||||
export const ApiPutCommentUseful = (data) =>
|
||||
ToAsyncAwait(axiosTk.put(`${BASE_URL}/app/comment/updateUsefulCount`, data));
|
||||
|
||||
|
||||
|
@ -1,21 +0,0 @@
|
||||
/*
|
||||
* @Author: ch
|
||||
* @Date: 2022-06-12 14:06:01
|
||||
* @LastEditors: ch
|
||||
* @LastEditTime: 2022-06-14 21:14:54
|
||||
* @Description: file content
|
||||
*/
|
||||
|
||||
import {axiosTk} from "../axiosTk";
|
||||
import { ToAsyncAwait } from "../utils";
|
||||
import ENV from '../config/env';
|
||||
const BASE_URL = `${ENV.base_url}/mall/im`;
|
||||
|
||||
/**
|
||||
* 获取soket登录秘钥
|
||||
*/
|
||||
export const ApiGetSoketTicket = () => ToAsyncAwait(axiosTk.get(`${BASE_URL}/ticket`, {
|
||||
params: {
|
||||
ticketType: 'CONNECT_TICKET'
|
||||
}
|
||||
}));
|
@ -1,26 +0,0 @@
|
||||
/*
|
||||
* @Author: ch
|
||||
* @Date: 2022-05-08 00:44:22
|
||||
* @LastEditors: ch
|
||||
* @LastEditTime: 2022-06-29 14:51:00
|
||||
* @Description: file content
|
||||
*/
|
||||
|
||||
|
||||
import {axiosTk} from "../axiosTk";
|
||||
import {ToAsyncAwait} from "@/plugins/utils";
|
||||
import ENV from '../config/env';
|
||||
|
||||
const BASE_URL = `${ENV.base_url}/mall/trade`;
|
||||
/**
|
||||
* 获取微信支付二维码
|
||||
* @param {*} data
|
||||
*/
|
||||
export const ApiPostWxPayCdoeImg = (data) =>
|
||||
ToAsyncAwait(axiosTk.post(`${BASE_URL}/payCenter/wxPay/nativeData`, data));
|
||||
/**
|
||||
* 获取支付宝支付二维码
|
||||
* @param {*} data
|
||||
*/
|
||||
export const ApiPostAliPayCdoeImg = (data) =>
|
||||
ToAsyncAwait(axiosTk.post(`${BASE_URL}/payCenter/aliPay/qr`, data));
|
@ -0,0 +1,17 @@
|
||||
/*
|
||||
* @Author: ch
|
||||
* @Date: 2022-05-08 00:44:22
|
||||
* @LastEditors: ch
|
||||
* @LastEditTime: 2022-05-08 00:47:55
|
||||
* @Description: file content
|
||||
*/
|
||||
|
||||
|
||||
import {axiosTk} from "../axiosTk";
|
||||
import {ToAsyncAwait} from "@/plugins/utils";
|
||||
import ENV from '../config/env';
|
||||
|
||||
const BASE_URL = `${ENV.base_url}/mall/trade`;
|
||||
|
||||
export const ApiPostPayCdoeImg = (data) =>
|
||||
ToAsyncAwait(axiosTk.post(`${BASE_URL}/pay/wxPay/nativeImage`, data));
|
@ -1,58 +0,0 @@
|
||||
/*
|
||||
* @Author: ch
|
||||
* @Date: 2022-06-12 14:04:56
|
||||
* @LastEditors: ch
|
||||
* @LastEditTime: 2022-06-13 20:27:34
|
||||
* @Description: file content
|
||||
*/
|
||||
|
||||
import MsbIm from '@/plugins/msbIm' ;
|
||||
import { ToAsyncAwait, FormatJsonSearch } from './utils';
|
||||
import { ApiGetSoketTicket } from '@/plugins/api/im';
|
||||
import ENV from '@/plugins/config/env';
|
||||
const Im = new MsbIm({
|
||||
reconnect: true,
|
||||
});
|
||||
let ImInit = null;
|
||||
export default ({store }) => {
|
||||
ImInit = async () => {
|
||||
const { error, result } = await ApiGetSoketTicket();
|
||||
if (error) {
|
||||
return false;
|
||||
}
|
||||
const par = FormatJsonSearch({
|
||||
client: result.client,
|
||||
ticket: result.ticket,
|
||||
// 1普通用户 2客服链接
|
||||
connect: 1,
|
||||
user: store.state.userInfo.id,
|
||||
nickname: store.state.userInfo.nickname,
|
||||
avatar : store.state.userInfo.avatar
|
||||
})
|
||||
return await ToAsyncAwait(Im.init({
|
||||
url: `${ENV.imUrl}/ws${par}`
|
||||
}))
|
||||
|
||||
};
|
||||
|
||||
Im.interceptors.dataChangeAfter = () => {
|
||||
let data = Im.sessionData.find(i => {
|
||||
return (i.type === 4 && (typeof i.payload === 'string' ? JSON.parse(i.payload).type === 'system' : false));
|
||||
}) || {}
|
||||
let msgCount = data.unreadCount || 0;
|
||||
store.commit('setSocketMsgData', JSON.parse(JSON.stringify(data)));
|
||||
store.commit('setUnreadCount', msgCount);
|
||||
}
|
||||
|
||||
Im.interceptors.onClose = () => {
|
||||
Im.setSessionData([]);
|
||||
Im.setCurSessionId(null);
|
||||
store.commit('setSocketMsgData', {});
|
||||
store.commit('setUnreadCount', 0);
|
||||
}
|
||||
|
||||
}
|
||||
export {
|
||||
Im,
|
||||
ImInit
|
||||
}
|
@ -1,42 +0,0 @@
|
||||
/*
|
||||
* @Author: ch
|
||||
* @Date: 2022-05-31 11:05:08
|
||||
* @LastEditors: ch
|
||||
* @LastEditTime: 2022-05-31 17:23:02
|
||||
* @Description: file content
|
||||
*/
|
||||
|
||||
|
||||
const AD_PLATFORM = {
|
||||
PC: 2,
|
||||
MOBILE : 1
|
||||
}
|
||||
const AD_LOCATION = {
|
||||
// 首页轮播图
|
||||
HOME_BANNER: 1,
|
||||
// 首页精装区
|
||||
HOME_HARDCOVER: 2,
|
||||
// 分类banner
|
||||
CATEGORY_BANNER : 3
|
||||
|
||||
}
|
||||
|
||||
const AD_JUMP_TYPE = {
|
||||
// 商品详情
|
||||
GOODS: 1,
|
||||
// 分类
|
||||
CATEGORY: 2,
|
||||
// 链接
|
||||
LINK: 3,
|
||||
// 不跳转
|
||||
NO_JUMP : 4
|
||||
|
||||
}
|
||||
export {
|
||||
// 广告所属平台
|
||||
AD_PLATFORM,
|
||||
// 广告位置
|
||||
AD_LOCATION,
|
||||
// 广告跳转类型
|
||||
AD_JUMP_TYPE
|
||||
}
|