mirror of
https://gitee.com/lab1024/smart-admin.git
synced 2025-11-20 09:33:47 +08:00
2
This commit is contained in:
@@ -13,13 +13,14 @@
|
||||
|
||||
<div class="productdetails">
|
||||
<div class="rc-productdetail">
|
||||
<i>商品价格:</i>
|
||||
<i>商品价格</i>
|
||||
<span>¥{{ item.rsp }}</span>
|
||||
<i style="font-size:12px;color:#999999">¥{{item.ecPrice}}</i>
|
||||
</div>
|
||||
<div class="rc-productdetai">
|
||||
<div>
|
||||
<i>活动促销:</i>
|
||||
<span>{{ item.basePrice }}</span>
|
||||
<span>全场商品限时优惠</span>
|
||||
</div>
|
||||
<em @click="userget()">立即领取</em>
|
||||
</div>
|
||||
@@ -28,10 +29,14 @@
|
||||
<span @click="usertanchu(item,1)">立即购买</span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="online" style="height:3px;width:100%;background:#DDDDDD;margin-top:0.33rem"></div>
|
||||
|
||||
|
||||
<div class="rc-productdeta" v-if="userbuy">
|
||||
<div class="rc-prodtop">
|
||||
<span>商品规格</span>
|
||||
<div>
|
||||
<span>商品规格</span>:
|
||||
</div>
|
||||
<!-- <em v-for="(item, index) in stype" :key="index" @click="selectsearch(item, index)" :class="activeIndexa == index ? 'active' : 'unactive'">
|
||||
{{ item.title }}
|
||||
</em> -->
|
||||
@@ -41,7 +46,9 @@
|
||||
</em>
|
||||
</div>
|
||||
<div class="rc-produnnum">
|
||||
<span>商品数量:</span>
|
||||
<div>
|
||||
<span>商品数量</span>:
|
||||
</div>
|
||||
<img src="../../assets/image/userjian.png" alt="" @click="sub()" />
|
||||
<strong>{{sales_num}}</strong>
|
||||
<img
|
||||
@@ -53,28 +60,25 @@
|
||||
</div>
|
||||
|
||||
<div class="certification">
|
||||
<!-- <ul>
|
||||
<ul>
|
||||
<li>
|
||||
<span
|
||||
>服务说明:<i>{{ item.period }}</i></span
|
||||
>服务说明:<i>当天14点前完成付款即日安排发货;当天14点后完成付款次日安排发货(周日及国家法定节假日顺延至下一个工作日发货,活动期间发货或有延迟敬请理解)</i></span
|
||||
>
|
||||
</li>
|
||||
<li>
|
||||
<span
|
||||
>商品运费:<i>{{ item.starttime }}</i></span
|
||||
>商品运费:<i>全场包邮(港澳除外)</i></span
|
||||
>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
<span
|
||||
>商品编号:<i>{{ item.shangbianhao }}</i></span
|
||||
>商品编号:<i>{{ item.brandCode }}</i></span
|
||||
>
|
||||
</li>
|
||||
</ul> -->
|
||||
<div class="rc-button">
|
||||
<span @click="usertanchu(item,0)">加入购物车</span>
|
||||
<span @click="usertanchu(item,1)">立即购买</span>
|
||||
</div>
|
||||
</ul>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -88,6 +92,7 @@
|
||||
<img :src=item.showImgFile alt="">
|
||||
|
||||
</div>
|
||||
<Myfooter v-on:litentop='showmesg'></Myfooter>
|
||||
</div>
|
||||
<el-dialog
|
||||
:visible.sync="dialogInfo1"
|
||||
@@ -150,12 +155,18 @@
|
||||
|
||||
|
||||
</el-dialog>
|
||||
<div class="rc-button" style="width:100%">
|
||||
<span @click="usertanchu(item,0)">加入购物车</span>
|
||||
<span @click="usertanchu(item,1)">立即购买</span>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import Myheader from "~/components/header.vue";
|
||||
import Magnifier from "@/components/magnifier.vue";
|
||||
import { mapMutations } from "vuex";
|
||||
import Myfooter from "~/components/rc-footer.vue";
|
||||
import { goodsmessage,getConfig,postCourseId,getdraw,alldiscount } from "../../ajax/getData";
|
||||
const settings = require("@/config");
|
||||
export default {
|
||||
@@ -223,6 +234,8 @@ export default {
|
||||
components: {
|
||||
Myheader,
|
||||
Magnifier,
|
||||
Myfooter
|
||||
|
||||
},
|
||||
mounted() {
|
||||
|
||||
@@ -252,6 +265,22 @@ this.usermessage= JSON.parse(localStorage.getItem("userInfo"));
|
||||
|
||||
},
|
||||
methods: {
|
||||
...mapMutations(["changemessage"]),
|
||||
showmesg(){
|
||||
console.log('-----');
|
||||
this.toTop();
|
||||
},
|
||||
toTop() {
|
||||
let top = document.documentElement.scrollTop || document.body.scrollTop;
|
||||
// 实现滚动效果
|
||||
const timeTop = setInterval(() => {
|
||||
document.body.scrollTop = document.documentElement.scrollTop = top -= 400;
|
||||
if (top <= 0) {
|
||||
clearInterval(timeTop);
|
||||
}
|
||||
}, 10);
|
||||
},
|
||||
|
||||
//领取优惠券
|
||||
usergetconf(item){
|
||||
console.log(item);
|
||||
@@ -296,8 +325,12 @@ if(this.usermessage.data!==''||this.usermessage.data!==undefined){
|
||||
}
|
||||
|
||||
this.userlistmenu=this.newlist[0].productAttachmentList;
|
||||
let changemess=JSON.stringify(this.userlistmenu);
|
||||
console.log(changemess);
|
||||
this.changemessage({ data: changemess });
|
||||
this.parent_msg=this.userlistmenu;
|
||||
console.log( this.userlistmenu)
|
||||
|
||||
|
||||
},
|
||||
|
||||
@@ -425,11 +458,38 @@ usertanchu(item,orderm){
|
||||
},
|
||||
|
||||
};
|
||||
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
// 手机端
|
||||
@media screen and(min-width: 320px) and(max-width:768px) {
|
||||
.rc-button{
|
||||
width: 100%;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
position: fixed;
|
||||
justify-content: center;
|
||||
height: 60px;
|
||||
bottom: 0;
|
||||
background-color: white;
|
||||
|
||||
span{
|
||||
width: 160px;
|
||||
height: 48px;
|
||||
background: #E2001A;
|
||||
border-radius: 30px;
|
||||
font-size: 16px;
|
||||
color:#FFFFFF;
|
||||
display: block;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
span:last-child{
|
||||
margin-left: 40px;
|
||||
}
|
||||
}
|
||||
.rc-headera{
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
@@ -572,6 +632,10 @@ color: #E1001A;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
margin-top: 20px;
|
||||
img{
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
}
|
||||
.rc-header {
|
||||
width: 100%;
|
||||
@@ -593,27 +657,7 @@ color: #E1001A;
|
||||
}
|
||||
}
|
||||
.productdetails {
|
||||
.rc-button{
|
||||
width: 100%;
|
||||
padding-top: 33px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
span{
|
||||
width: 160px;
|
||||
height: 48px;
|
||||
background: #E2001A;
|
||||
border-radius: 30px;
|
||||
font-size: 16px;
|
||||
color:#FFFFFF;
|
||||
display: block;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
span:last-child{
|
||||
margin-left: 40px;
|
||||
}
|
||||
}
|
||||
|
||||
margin-top: 19px;
|
||||
.rc-productdetail {
|
||||
display: flex;
|
||||
@@ -656,7 +700,7 @@ justify-content: center;
|
||||
}
|
||||
|
||||
.rc-productdeta {
|
||||
margin-top: 56px;
|
||||
margin-top: 20px;
|
||||
.rc-prodtop {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
@@ -671,7 +715,7 @@ justify-content: center;
|
||||
justify-content: center;
|
||||
width: 59px;
|
||||
font-size: 16px;
|
||||
margin-left: 10px;
|
||||
margin-left: 4px;
|
||||
height: 39px;
|
||||
border-radius: 3px;
|
||||
}
|
||||
@@ -691,6 +735,8 @@ justify-content: center;
|
||||
width: 29px;
|
||||
height: 29px;
|
||||
display: block;
|
||||
margin-left: 5px;
|
||||
|
||||
}
|
||||
.rc-message {
|
||||
width: 29px;
|
||||
@@ -953,6 +999,9 @@ color: #E1001A;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
img{
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
.rc-main {
|
||||
|
||||
|
||||
@@ -1,8 +1,9 @@
|
||||
<template>
|
||||
<div>
|
||||
<Myheader></Myheader>
|
||||
|
||||
<div class="rc-top">
|
||||
|
||||
<div class="online" style="height:2px;width:100%;background:#DDDDDD;margin-top:0.23rem"></div>
|
||||
<div class="rc-main">
|
||||
<div class="usersearch">
|
||||
|
||||
@@ -70,6 +71,7 @@
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="online" style="height:2px;width:100%;background:#DDDDDD;margin-top:0.23rem"></div>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -200,7 +202,7 @@
|
||||
|
||||
<script>
|
||||
import Myheader from '~/components/header.vue'
|
||||
import { userstype,biaomessa } from "../../ajax/getData";
|
||||
import { userstype,biaomessa,biaomessage } from "../../ajax/getData";
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
@@ -383,8 +385,17 @@ export default {
|
||||
Myheader,
|
||||
},
|
||||
mounted(){
|
||||
|
||||
let stype=this.$route.query.stype;
|
||||
this.activeIndex=stype;
|
||||
console.log(stype);
|
||||
if(stype!==''&&stype!==undefined){
|
||||
this.onmessage(stype)
|
||||
}else{
|
||||
this.usetmessage();
|
||||
this.stypemessage();
|
||||
}
|
||||
|
||||
|
||||
},
|
||||
methods: {
|
||||
async usetmessage() {
|
||||
@@ -394,16 +405,17 @@ this.stypemessage();
|
||||
}
|
||||
console.log( this.rccontair);
|
||||
},
|
||||
//全部标签的查找
|
||||
async stypemessage() {
|
||||
let data = await userstype();
|
||||
async onmessage(stype) {
|
||||
let data = await biaomessage(stype);
|
||||
if(data){
|
||||
console.log(data);
|
||||
this.rccontair=data;
|
||||
}
|
||||
console.log( this.rccontair);
|
||||
},
|
||||
|
||||
|
||||
|
||||
|
||||
userbuy(){
|
||||
this.$router.push({
|
||||
path: "/myorder/userrecord",
|
||||
@@ -554,6 +566,10 @@ ul li ol li em strong i {
|
||||
|
||||
//手机端
|
||||
@media screen and (max-width: 768px) {
|
||||
.rc-top{
|
||||
position: relative;
|
||||
margin-top: 74px;
|
||||
}
|
||||
.usercontentshow{
|
||||
position: relative;
|
||||
z-index: 997;
|
||||
@@ -853,6 +869,7 @@ display: block;
|
||||
}
|
||||
.rc-click{
|
||||
max-height: 1.9rem;
|
||||
min-height: 1.9rem;
|
||||
}
|
||||
span{
|
||||
font-size: 0.16rem;
|
||||
|
||||
@@ -65,15 +65,15 @@ methods:{
|
||||
}
|
||||
console.log(data);
|
||||
},
|
||||
usertiao(item,index){
|
||||
if(item.price=='登出'){
|
||||
this.$router.push({
|
||||
path: "/productdetails/userdetails",
|
||||
// usertiao(item,index){
|
||||
// if(item.price=='登出'){
|
||||
// this.$router.push({
|
||||
// path: "/productdetails/userdetails",
|
||||
|
||||
});
|
||||
this.usernewlist[0].price='登录/注册'
|
||||
}
|
||||
},
|
||||
// });
|
||||
// this.usernewlist[0].price='登录/注册'
|
||||
// }
|
||||
// },
|
||||
usertiao(item,index){
|
||||
if(item.price=='登录/注册' ||index==0){
|
||||
this.$router.push({
|
||||
@@ -92,7 +92,7 @@ if(item.price=='登录/注册' ||index==0){
|
||||
this.$router.push({
|
||||
path: "/productdetails/productlist/",
|
||||
query: {
|
||||
stype: 1,
|
||||
stype: 0,
|
||||
},
|
||||
});
|
||||
|
||||
@@ -110,7 +110,7 @@ else if(item.price=='选购产品'){
|
||||
this.$router.push({
|
||||
path: "/productdetails/productlist/",
|
||||
query: {
|
||||
stype: 1,
|
||||
stype: '',
|
||||
},
|
||||
});
|
||||
|
||||
@@ -157,9 +157,11 @@ Myheader
|
||||
<style lang="less" scoped >
|
||||
//手机端
|
||||
@media screen and (max-width: 768px) {
|
||||
|
||||
.rc-header{
|
||||
width: 92%;
|
||||
margin: 0 auto;
|
||||
|
||||
ul{
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
|
||||
Reference in New Issue
Block a user