!61 2022-1-20 He

Merge pull request !61 from Admin/sit-He-v3
This commit is contained in:
Admin 2022-01-20 14:19:34 +00:00 committed by Gitee
commit cf87ca57bc
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
5 changed files with 636 additions and 489 deletions

View File

@ -144,10 +144,6 @@
}
}
}
/deep/.el-dialog {
width: 80%;
position: relative;
}
.rc-discount {
position: relative;
width: 100%;
@ -169,8 +165,7 @@
align-items: center;
justify-content: center;
color: #e1001a;
padding-right: 21px;
width: 30%;
width: 34%;
float: left;
height: 100%;
i {
@ -190,7 +185,7 @@
.rc-right {
display: flex;
flex-direction: column;
margin-left: 36px;
padding-left: 20px;
justify-content: center;
height: 100%;
i {
@ -204,7 +199,7 @@
}
span {
display: block;
margin-top: 8px;
margin-top: 2px;
}
em {
font-style: normal;
@ -405,11 +400,6 @@
}
}
}
/deep/.el-dialog {
width: 440px;
height: 432px;
position: relative;
}
.rc-discount {
position: relative;
img {
@ -430,8 +420,7 @@
align-items: center;
justify-content: center;
color: #e1001a;
padding-right: 21px;
width: 30%;
width: 34%;
float: left;
height: 100%;
i {
@ -451,7 +440,7 @@
.rc-right {
display: flex;
flex-direction: column;
margin-left: 36px;
padding-left: 20px;
justify-content: center;
height: 100%;
i {
@ -465,7 +454,7 @@
}
span {
display: block;
margin-top: 8px;
margin-top: 2px;
}
em {
font-style: normal;
@ -587,3 +576,16 @@
}
}
.rc-carousel__gallery-thumbnail{
display: inline;
.rc-img--square{
border: 1px solid #ddd;
border-radius: 3px;
}
&.rc-carousel__gallery-thumbnail--active{
.rc-img--square{
border: 1px solid #E2001A;
}
}
}

View File

@ -0,0 +1,127 @@
<template>
<div>
<van-address-edit
:area-list="areaList"
:address-info="{
name: editAddressData.name,
tel: editAddressData.tel,
addressDetail: editAddressData.detailAddress,
areaCode: areaCode,
}"
show-delete
show-set-default
show-search-result
:search-result="searchResult"
@save="onSave"
@delete="onDelete"
/>
</div>
</template>
<script>
import { Toast } from "vant";
import { areaList } from "@vant/area-data";
var _ = require("lodash");
import { memberAddress } from "../../ajax/getData";
export default {
data() {
return {
areaList,
searchResult: [],
areaCode: "",
};
},
props: ["editAddressData"],
computed: {},
methods: {
async onSave(content) {
// Toast('save');
let provinceId = Number(content.areaCode.substring(0, 2)); //id
let cityId = Number(content.areaCode.substring(2, 4)); //id
let districtId = Number(content.areaCode.substring(4, 7)); //
//id / id/id/
let memberId = JSON.parse(localStorage.getItem("userInfo")).data.id;
let postData = {
memberId,
provinceId: 25,
cityId: 36,
districtId: 418,
// provinceId,
// cityId,
// districtId,
detailAddress: content.addressDetail,
recipient: content.name,
recipientPhone: content.tel,
default: content.default,
};
let saveType = this.editAddressData.saveType ? "update" : "add";
let data = await memberAddress(saveType, postData);
if (data) {
this.$message({
type: "warning",
message: data.msg,
});
if (data.code == "0") {
this.$emit("isClose", false);
}
}
},
async onDelete() {
// Toast("delete");
let postData = {
ids: this.editAddressData.id,
memberId: this.editAddressData.memberId,
};
let data = await memberAddress("delete", postData);
if (data) {
this.$message({
type: "warning",
message: data.msg,
});
if (data.code == "0") {
this.$emit("isClose", false);
}
}
},
async areaCodeInit() {
var city = this.editAddressData.city;
var district = this.editAddressData.district;
this.areaCode = "1310001";
// _.forEach(this.areaList.city_list, (o, c) => {
// if (o == city) {
// // let cityId = String(_.take(c, 2));
// let cityId = c.substring(0, 4);
// _.forEach(this.areaList.county_list, (i, a) => {
// if (i == district) {
// // let districtId = String(_.take(a, 2));
// let districtId = a.substring(0, 4);
// if (cityId == districtId) {
// this.areaCode = a;
// }
// }
// });
// }
// });
},
},
mounted() {
this.areaCodeInit();
},
};
</script>
<style>
.van-area {
width: 400px;
margin: 0 auto;
border: 1px solid #808285;
}
.van-popup {
background-color: transparent;
}
.van-overlay {
background-color: transparent;
}
.v-modal {
background: transparent;
}
</style>

View File

@ -366,6 +366,7 @@ ul li ol li em strong i {
.diallog_width{
width: 100%;
max-width: 440px;
margin: 0 auto;
}
.el-dialog{
width: 100%;

View File

@ -95,10 +95,10 @@
</div>
<el-dialog :visible.sync="dialogAdd" class="diallog_width" width="'100%">
<div class="tc dl_cont" v-if="dialogAdd">
<!-- <myAddress
<myAddress
@isClose="dialogCtrl"
:editAddressData="editAddressData"
></myAddress> -->
></myAddress>
</div>
</el-dialog>
</div>
@ -108,7 +108,8 @@
import Myheader from "~/components/header.vue";
import { userin, memberAddress, generateOrderWX } from "../../ajax/getData";
import tabs from "@/components/tabs.vue";
// import myAddress from "../address/address.vue";
import myAddress from "../address/address.vue";
import itemMixin from "../../../smart-admin-web/src/components/main/components/side-menu/item-mixin";
export default {
middleware: "metaTitle",
@ -311,7 +312,7 @@ export default {
components: {
Myheader,
tabs,
// myAddress,
myAddress,
},
};
</script>

View File

@ -1,49 +1,92 @@
<template>
<div>
<div class="user" v-for="(item,index) in newlist" :key="index">
<div>
<div class="user">
<Myheader></Myheader>
<unlogin></unlogin>
<tabs></tabs>
<div class="online" id="fixed-catbar-seperator"></div>
<div class="rc-top"></div>
<div class="rc-usermain ts-product-detail rc-max-width--xl rc-layout-container rc-two-column rc-border-bottom rc-border-colour--brand4">
<div
class="
rc-usermain
ts-product-detail
rc-max-width--xl
rc-layout-container rc-two-column rc-border-bottom
rc-border-colour--brand4
"
>
<div class="rc-column">
<div data-js-carousel="" data-image-gallery="true">
<div class="rc-carousel rc-carousel__gallery-image" data-zoom-container="328b2e5f-6904-4cac-9709-51ed18d2500f" data-zoom-factor="2">
<div
class="rc-carousel rc-carousel__gallery-image"
data-zoom-container="328b2e5f-6904-4cac-9709-51ed18d2500f"
data-zoom-factor="2"
>
<!-- Big images-->
<div v-for="(item, index) in productAttachmentList" :key="index">
<div>
<div>
<img src="https://cdn.royalcanin-weshare-online.io/m2kia2QBG95Xk-RBC8jn/v1/medium-maxi-giant-pos-2012-packshots-ma-ad-shn-packshot?w=420&fm=jpg&auto=compress" alt="Product alt text" />
<img :src="item.attachmentPath" />
<!-- <img
src="https://cdn.royalcanin-weshare-online.io/m2kia2QBG95Xk-RBC8jn/v1/medium-maxi-giant-pos-2012-packshots-ma-ad-shn-packshot?w=420&fm=jpg&auto=compress"
alt="Product alt text"
/> -->
</div>
</div>
<div>
<!-- <div>
<div>
<img src="https://cdn.royalcanin-weshare-online.io/m2kia2QBG95Xk-RBC8jn/v1/medium-maxi-giant-pos-2012-packshots-ma-ad-shn-packshot?w=420&fm=jpg&auto=compress" alt="Product alt text" />
</div>
</div>
</div> -->
<!-- Big images end-->
</div>
<div class="rc-carousel__gallery-thumbnails-wrapper">
<div class="rc-carousel rc-carousel__gallery-thumbnails">
<!-- Thunb images-->
<div class="rc-carousel__gallery-thumbnail">
<figure class="rc-img--square" style="background-image: url('https://cdn.royalcanin-weshare-online.io/m2kia2QBG95Xk-RBC8jn/v1/medium-maxi-giant-pos-2012-packshots-ma-ad-shn-packshot?w=64&fm=jpg&auto=compress')">
<figcaption class="rc-screen-reader-text">Product caption text</figcaption>
<div class="rc-carousel__gallery-thumbnail tns-item tns-slide-active"
v-for="(item, index) in productAttachmentList"
:key="index"
>
<div class="rc-img--square">
<img :src="item.attachmentPath" />
</div>
</div>
<!-- <div class="rc-carousel__gallery-thumbnail">
<figure
class="rc-img--square"
style="
background-image: url('https://cdn.royalcanin-weshare-online.io/m2kia2QBG95Xk-RBC8jn/v1/medium-maxi-giant-pos-2012-packshots-ma-ad-shn-packshot?w=64&fm=jpg&auto=compress');
"
>
<figcaption class="rc-screen-reader-text">
Product caption text
</figcaption>
</figure>
</div>
<div class="rc-carousel__gallery-thumbnail">
<figure class="rc-img--square" style="background-image: url('https://cdn.royalcanin-weshare-online.io/UCEUa2QBaxEApS7L_-Xz/v2/fbn-2013-graphiccodes-packshots-siam-ad-int-fbn-packshot?w=64&fm=jpg&auto=compress')">
<figcaption class="rc-screen-reader-text">Product caption text</figcaption>
<figure
class="rc-img--square"
style="
background-image: url('https://cdn.royalcanin-weshare-online.io/UCEUa2QBaxEApS7L_-Xz/v2/fbn-2013-graphiccodes-packshots-siam-ad-int-fbn-packshot?w=64&fm=jpg&auto=compress');
"
>
<figcaption class="rc-screen-reader-text">
Product caption text
</figcaption>
</figure>
</div>
</div> -->
<!-- Thunb images end-->
</div>
</div>
</div>
</div>
<div class="ts-product-header rc-column" id="328b2e5f-6904-4cac-9709-51ed18d2500f">
<div
class="ts-product-header rc-column"
id="328b2e5f-6904-4cac-9709-51ed18d2500f"
v-for="(item, index) in newlist"
:key="index"
>
<div class="usermain">
<div class="online bold rc-md-down"></div>
<div class="rc-main">
@ -57,7 +100,9 @@
<div class="rc-productdetail">
<i class="ts-row-title">商品价格</i>
<span class="ts-realprice">{{ item.rsp }}</span>
<span class="ts-remove ts-ecprice">{{ item.ecPrice }} </span>
<span class="ts-remove ts-ecprice"
>{{ item.ecPrice }}
</span>
</div>
<div class="rc-productdetai">
<div>
@ -83,7 +128,7 @@
{{ item.title }}
</em> -->
<em class='active'>
<em class="active">
{{ item.specifications }}
</em>
</div>
@ -91,9 +136,17 @@
<div class="rc-main">
<div class="rc-produnnum">
<div><i class="ts-row-title">商品数量</i></div>
<img src="../../assets/image/userjian.png" alt="" @click="sub()" />
<strong>{{sales_num}}</strong>
<img src="../../assets/image/userjia.png" alt="" @click="plus()" />
<img
src="../../assets/image/userjian.png"
alt=""
@click="sub()"
/>
<strong>{{ sales_num }}</strong>
<img
src="../../assets/image/userjia.png"
alt=""
@click="plus()"
/>
</div>
</div>
<div class="rc-main rc-md-up">
@ -105,56 +158,59 @@
<ul>
<li>
<span
><i class="ts-row-title">服务说明</i><i>当天14点前完成付款即日安排发货;当天14点后完成付款次日安排发货(周日及国家法定节假日顺延至下一个工作日发货,活动期间发货或有延迟敬请理解)</i></span
><i class="ts-row-title">服务说明</i
><i
>当天14点前完成付款即日安排发货;当天14点后完成付款次日安排发货(周日及国家法定节假日顺延至下一个工作日发货,活动期间发货或有延迟敬请理解)</i
></span
>
</li>
<li>
<span
><i class="ts-row-title">商品运费</i><i>全场包邮(港澳除外)</i></span
><i class="ts-row-title">商品运费</i
><i>全场包邮(港澳除外)</i></span
>
</li>
<li>
<span
><i class="ts-row-title">商品编号</i><i>{{ item.brandCode }}</i></span
><i class="ts-row-title">商品编号</i
><i>{{ item.brandCode }}</i></span
>
</li>
</ul>
</div>
<div class="rc-button" v-if="!userbuy">
<span @click="usertanchu(item,0)">加入购物车</span>
<span @click="usertanchu(item,1)">立即购买</span>
<div class="rc-button" v-if="userbuy">
<span @click="usertanchu(item, 0)">加入购物车</span>
<span @click="usertanchu(item, 1)">立即购买</span>
</div>
</div>
<div class="online bold rc-md-down"></div>
</div>
</div>
</div>
</div>
<div class="rc-footimage rc-main">
<img :src=item.showImgFile alt="">
<!-- <img :src="item.showImgFile" alt="" /> -->
</div>
<div class="rc-fixright" >
<ul >
<li v-for="(userfixed,index) in fixedlist" :key="index" @click="lianxi(userfixed,index)">
<img :src="userfixed.catimage" alt="">
<span> {{userfixed.title}}</span>
<div class="rc-fixright">
<ul>
<li
v-for="(userfixed, index) in fixedlist"
:key="index"
@click="lianxi(userfixed, index)"
>
<img :src="userfixed.catimage" alt="" />
<span> {{ userfixed.title }}</span>
</li>
</ul>
<div class="tuntop" @click="toTop" v-show="gotop">
<img src="../../assets/image/turntop.png" alt="">
<img src="../../assets/image/turntop.png" alt="" />
<span>回到顶部</span>
</div>
</div>
<Myfooter v-on:litentop='showmesg'></Myfooter>
<Myfooter v-on:litentop="showmesg"></Myfooter>
</div>
<el-dialog
:visible.sync="dialogInfo1"
hegight="700px"
@close='userclose'
>
<el-dialog :visible.sync="dialogInfo1" @close="userclose">
<div class="rs-dis">
<div
class="rc-discount"
@ -172,7 +228,7 @@
<i>
{{ item.couponDesc }}
</i>
<div class="rc-main" id="rc-main">
<div>
<span>有效期</span>
<em>{{ item.validTo }}</em>
</div>
@ -180,40 +236,29 @@
<span @click="usergetconf(item)">立即领取</span>
</div>
</div>
</div>
</div>
</div>
</el-dialog>
<el-dialog
:visible.sync="dialogInfo2"
@close='userclose'
>
<el-dialog :visible.sync="dialogInfo2" @close="userclose">
<div class="rc-headera">
<div class="rc-title">
<img src="../../assets/error.png" alt="">
<img src="../../assets/error.png" alt="" />
</div>
<div class="rc-logmain">
<h3>温馨提示</h3>
<span>请先点击下方进行登录/注册</span>
</div>
<nuxt-link :to="`/userlogin/login/`">
<div class="userer">
<span>立即登录</span>
</div>
</nuxt-link>
</div>
</el-dialog>
<div class="rc-button rc-md-down">
<span @click="usertanchu(item,0)">加入购物车</span>
<span @click="usertanchu(item,1)">立即购买</span>
<span @click="usertanchu(item, 0)">加入购物车</span>
<span @click="usertanchu(item, 1)">立即购买</span>
</div>
</div>
</template>
@ -221,35 +266,42 @@
<script>
import Myheader from "~/components/header.vue";
import tabs from "@/components/tabs.vue";
import unlogin from "~/components/unlogin.vue";
import unlogin from "~/components/unlogin.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");
import Myfooter from "~/components/rc-footer.vue";
import {
goodsmessage,
getConfig,
postCourseId,
getdraw,
alldiscount,
} from "../../ajax/getData";
const settings = require("@/config");
export default {
// middleware: 'metaTitle',
// // middleware: 'metaTitle',
// meta: {title: ''},
data() {
return {
tableLabelTest:[],
tableLabelTest: [],
userimage: require("../../assets/image/unused.png"),
activeIndexa:0,
activeIndexa: 0,
gotop: false,
dialogInfo1:false,
dialogInfo1: false,
name: [],
userlist:[],
drawlist:[],//
alldraw:[],
userlistmenu:[],
msg:['11111111'],
parent_msg:['111'],
usermessage:[],
dialogInfo2:false,
productCode:'',//code
productlist:[],
userbuy:true,
sales_num:1,
userlist: [],
drawlist: [], //
alldraw: [],
userlistmenu: [],
msg: ["11111111"],
parent_msg: ["111"],
usermessage: [],
dialogInfo2: false,
productCode: "", //code
productlist: [],
userbuy: true,
sales_num: 1,
productAttachmentList: [],
usernewlist: [
{
price: "30",
@ -272,23 +324,17 @@ export default {
{
title: "购物车",
catimage: require("../../assets/buy.png"),
},
{
title: "在线客服",
catimage: require("../../assets/service.png"),
},
{
title: "营养专家",
catimage: require("../../assets/consult.png"),
},
],
newlist: [
{
price: "167.00",
@ -309,104 +355,106 @@ export default {
},
],
};
},
components: {
Myheader,
tabs,
unlogin,
Myfooter
Myfooter,
},
mounted() {
window.addEventListener("scroll", this.handleScroll, true);
if(this.usermessage!=='' ||this.usermessage.data!==undefined){
this.usermessage= JSON.parse(localStorage.getItem("userInfo"));
let stype=this.$route.query.stype;
this.productCode=this.$route.query.productCode;
console.log(this.productCode)
if (this.usermessage !== "" || this.usermessage.data !== undefined) {
this.usermessage = JSON.parse(localStorage.getItem("userInfo"));
let stype = this.$route.query.stype;
this.productCode = this.$route.query.productCode;
// console.log(this.productCode);
this.userquery(this.productCode);
console.log(this.userlistmenu)
this.$nextTick(()=>{
})
if(stype==1){
this.userbuy=true;
}else if(stype==2){
console.log('这是要消失的')
// console.log(this.userlistmenu);
this.$nextTick(() => {});
if (stype == 1) {
this.userbuy = true;
} else if (stype == 2) {
// console.log("");
this.$nextTick(() => {
this.userbuy=false;
})
this.userbuy = false;
});
}
}
},
methods: {
...mapMutations(["changemessage"]),
handleScroll(e)
{
let fixedCatbarSeperator = document.querySelector("#fixed-catbar-seperator");
let scrolltop = document.documentElement.scrollTop || document.body.scrollTop;
if(fixedCatbarSeperator!=='null' ){
if((scrolltop-fixedCatbarSeperator.offsetTop))
{
this.gotop = true
}
else
{
handleScroll(e) {
let fixedCatbarSeperator = document.querySelector(
"#fixed-catbar-seperator"
);
let scrolltop =
document.documentElement.scrollTop || document.body.scrollTop;
if (fixedCatbarSeperator !== "null") {
if (scrolltop - fixedCatbarSeperator.offsetTop) {
this.gotop = true;
} else {
this.gotop = false;
}
}
},
lianxi(item,index){
console.log(item,index);
if(item.title=='在线客服'){
lianxi(item, index) {
console.log(item, index);
if (item.title == "在线客服") {
var option = {
customer: {id: '', name: '', email: '', mobile: '', memberId: '999999'}
}
customer: {
id: "",
name: "",
email: "",
mobile: "",
memberId: "999999",
},
};
dis_livchat(option);
}
if(item.title=='购物车'){
console.log('---12314');
if (item.title == "购物车") {
this.$router.push({
path: "../../myorder/userrecord",
});
}
if(item.title=='营养专家'){
if (item.title == "营养专家") {
var option = {
customer: {id: '', name: '', email: '', mobile: '', memberId: '999999'}
}
customer: {
id: "",
name: "",
email: "",
mobile: "",
memberId: "999999",
},
};
dis_livchat(option);
}
},
toTop() {
let top = document.documentElement.scrollTop || document.body.scrollTop;
//
const timeTop = setInterval(() => {
document.body.scrollTop = document.documentElement.scrollTop = top -= 400;
document.body.scrollTop =
document.documentElement.scrollTop =
top -=
400;
if (top <= 0) {
clearInterval(timeTop);
}
}, 10);
},
showmesg(){
console.log('-----');
showmesg() {
this.toTop();
},
toTop() {
let top = document.documentElement.scrollTop || document.body.scrollTop;
//
const timeTop = setInterval(() => {
document.body.scrollTop = document.documentElement.scrollTop = top -= 400;
document.body.scrollTop =
document.documentElement.scrollTop =
top -=
400;
if (top <= 0) {
clearInterval(timeTop);
}
@ -414,193 +462,161 @@ this.usermessage= JSON.parse(localStorage.getItem("userInfo"));
},
//
usergetconf(item){
usergetconf(item) {
console.log(item);
if(this.usermessage.data!==''||this.usermessage.data!==undefined){
this.getconf(this.usermessage.data.id,item.couponId);
}
},
if (this.usermessage.data !== "" || this.usermessage.data !== undefined) {
this.getconf(this.usermessage.data.id, item.couponId);
}
},
//
async getconf(memberId,couponId) {
let data = await getConfig(memberId,couponId);
if(data){
async getconf(memberId, couponId) {
let data = await getConfig(memberId, couponId);
if (data) {
this.$message({
type: 'warning',
message: data.msg
type: "warning",
message: data.msg,
});
console.log(data);
}
},
// changeName(newName){
// this.name = newName;
// },
userclose(){
console.log('这是关闭的');
this.userlist=[];
userclose() {
this.userlist = [];
},
async userquery() {
console.log("-----");
let data = await goodsmessage(this.productCode);
if(data){
this.newlist=data.data;
if (data) {
this.newlist = data.data;
}
this.productAttachmentList = this.newlist[0].productAttachmentList;
this.userlistmenu=this.newlist[0].productAttachmentList;
let changemess=JSON.stringify(this.userlistmenu);
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)
this.parent_msg = this.userlistmenu;
console.log(this.userlistmenu);
},
//
async userdraw(mobile) {
let data = await getdraw(mobile);
if(data){
this.drawlist=data.data;
if (data) {
this.drawlist = data.data;
}
},
//
async alldrawlist(memberId) {
let data = await alldiscount(memberId);
let userlist=[];
let menulsit=[];
if(data){
this.alldraw=data;
let userlist = [];
let menulsit = [];
if (data) {
this.alldraw = data;
// console.log(this.alldraw.data);
let alllist=[];
this.userlist=this.alldraw.data;
this.userlist.forEach((element,index)=>{
if(typeof element.productCodes=='string'){
let alllist = [];
this.userlist = this.alldraw.data;
this.userlist.forEach((element, index) => {
if (typeof element.productCodes == "string") {
userlist.push(element);
// let s=element.productCodes.split(',');
// console.log(s.indexOf(this.productCode) != -1 )
// console.log('')
}
})
let menualist=[];
userlist.filter(item=>{
});
let menualist = [];
userlist.filter((item) => {
console.log(item);
item.productCodes=item.productCodes.split(',')
item.productCodes.forEach(element=>{
if(element==this.productCode &&item.activityId!==10){
console.log(element)
console.log(this.productCode)
item.productCodes = item.productCodes.split(",");
item.productCodes.forEach((element) => {
if (element == this.productCode && item.activityId !== 10) {
console.log(element);
console.log(this.productCode);
menualist.push(item);
console.log('----');
console.log("----");
}
})
})
this.usernewlist=menualist;
});
});
this.usernewlist = menualist;
console.log(this.usernewlist);
}
},
plus(num,index){
this.sales_num= parseInt(this.sales_num) + 1;
console.log( this.sales_num);
} ,
plus(num, index) {
this.sales_num = parseInt(this.sales_num) + 1;
},
//
sub(num,index){
if( this.sales_num <= 1){
sub(num, index) {
if (this.sales_num <= 1) {
this.sales_num = 1;
}
else{
} else {
this.sales_num = parseInt(this.sales_num) - 1;
}
},
async courseId(item) {
console.log(item);
console.log(this.usermessage);
// let userid=JSON.parse(location.getItem('userInfo'));
// let mobile=JSON.parse(location.getItem('userInfo'));
// console.log(userid,mobile);
let data = await postCourseId( this.productCode,this.sales_num,this.usermessage.data.id,this.usermessage.data.mobile,item.picFile,item.productName,item.basePrice,item.specifications);
if(data){
this.productlist=data;
let data = await postCourseId(
this.productCode,
this.sales_num,
this.usermessage.data.id,
this.usermessage.data.mobile,
item.picFile,
item.productName,
item.basePrice,
item.specifications
);
if (data) {
this.productlist = data;
}
console.log(data);
},
usertanchu(item,orderm){
let user= localStorage.getItem("userInfo");
if(user==undefined||user==null||user==''){
this.dialogInfo2=true;
return
}else{
usertanchu(item, orderm) {
let user = localStorage.getItem("userInfo");
if (user == undefined || user == null || user == "") {
this.dialogInfo2 = true;
return;
} else {
this.courseId(item);
if(orderm==0){
if (orderm == 0) {
this.$message({
type: 'warning',
message: '加入购物车成功'
type: "warning",
message: "加入购物车成功",
});
}
if(orderm==1){
if (orderm == 1) {
this.$router.push({
path: "/myorder/userrecord",
});
}
}
},
userget(){
let user= localStorage.getItem("userInfo");
if(user==undefined||user==null||user==''){
this.dialogInfo2=true;
return
}else{
},
userget() {
let user = localStorage.getItem("userInfo");
if (user == undefined || user == null || user == "") {
this.dialogInfo2 = true;
return;
} else {
this.userdraw(this.usermessage.data.mobile);
this.alldrawlist(this.usermessage.data.id);
this.dialogInfo1=true;
this.dialogInfo1 = true;
}
},
selectsearch(item, index) {
this.activeIndexa=index;
this.activeIndexa = index;
},
},
onceproduct(){
},
onceproduct() {},
};
</script>
<style lang="less" scoped>