mirror of
https://gitee.com/lab1024/smart-admin.git
synced 2025-10-02 02:06:38 +08:00
Index content / bug completed, method of login checking in store/index.js added
This commit is contained in:
parent
60c6a6b8b4
commit
debf618d7e
@ -41,6 +41,36 @@ body{
|
|||||||
top:0;
|
top:0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
input[type=checkbox]{
|
||||||
|
position:relative;
|
||||||
|
cursor: pointer;
|
||||||
|
border:none;
|
||||||
|
border: 1px solid #d7d7d7;
|
||||||
|
border-radius: 3px;
|
||||||
|
width: 1.5rem;
|
||||||
|
height: 1.5rem;
|
||||||
|
&:before {
|
||||||
|
top: 0;
|
||||||
|
left: 0;
|
||||||
|
content: "";
|
||||||
|
width: 1.5rem;
|
||||||
|
height: 1.5rem;
|
||||||
|
position: absolute;
|
||||||
|
display: inline-block;
|
||||||
|
background-color: #fff;
|
||||||
|
background-image: url("../image/rc-select.png");
|
||||||
|
background-size: contain;
|
||||||
|
}
|
||||||
|
&:checked:before {
|
||||||
|
background-image: url("../image/rc-unselect.png");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
label {
|
||||||
|
input[type=checkbox] {
|
||||||
|
top:.375rem;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
.userloding {
|
.userloding {
|
||||||
background: url(../image/onloading.png) center center no-repeat;
|
background: url(../image/onloading.png) center center no-repeat;
|
||||||
width: 3.12rem;
|
width: 3.12rem;
|
||||||
@ -139,12 +169,13 @@ img, picture {
|
|||||||
font-size: 1.125rem;
|
font-size: 1.125rem;
|
||||||
margin-top: .5rem;
|
margin-top: .5rem;
|
||||||
display: block;
|
display: block;
|
||||||
|
min-height:1.6rem;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
img{
|
img{
|
||||||
width:10rem;
|
width:10rem;
|
||||||
height:10rem;
|
//min-height:19.875rem;
|
||||||
object-fit: contain;
|
object-fit: contain;
|
||||||
display: flex;
|
display: flex;
|
||||||
margin: 0 auto;
|
margin: 0 auto;
|
||||||
@ -340,6 +371,14 @@ img, picture {
|
|||||||
html {
|
html {
|
||||||
//font-size:100px;
|
//font-size:100px;
|
||||||
}
|
}
|
||||||
|
label {
|
||||||
|
input[type=checkbox] {
|
||||||
|
top:.25rem;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.rc-header__nav--primary{
|
||||||
|
overflow:hidden;
|
||||||
|
}
|
||||||
.ts-login--xs .rc-screen-reader{
|
.ts-login--xs .rc-screen-reader{
|
||||||
left:7%;
|
left:7%;
|
||||||
top:22%;
|
top:22%;
|
||||||
@ -445,10 +484,6 @@ img, picture {
|
|||||||
max-width:20rem;
|
max-width:20rem;
|
||||||
min-width:18.75rem;
|
min-width:18.75rem;
|
||||||
width:22.8vw;
|
width:22.8vw;
|
||||||
//margin-right:.875rem;
|
|
||||||
margin-left:2vw;
|
|
||||||
padding-left:1px;
|
|
||||||
padding-right:1px;
|
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
.rc-column{
|
.rc-column{
|
||||||
span{
|
span{
|
||||||
@ -625,14 +660,7 @@ img, picture {
|
|||||||
}
|
}
|
||||||
@media screen and (min-width: 769px) and (max-width: 1370px)
|
@media screen and (min-width: 769px) and (max-width: 1370px)
|
||||||
{
|
{
|
||||||
.ts-product-list {
|
|
||||||
display:flex;
|
|
||||||
//justify-content: space-between;
|
|
||||||
li{
|
|
||||||
margin-left:0;
|
|
||||||
margin-right:0;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
.rc_contline {
|
.rc_contline {
|
||||||
border-bottom: 3px solid #f6f6f6;
|
border-bottom: 3px solid #f6f6f6;
|
||||||
|
@ -46,8 +46,8 @@
|
|||||||
.uservideo{
|
.uservideo{
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
video{
|
video{
|
||||||
height:100%;
|
width:100%;
|
||||||
width:auto;
|
height:auto;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
.ul-dog{
|
.ul-dog{
|
||||||
@ -179,50 +179,43 @@
|
|||||||
display: none;
|
display: none;
|
||||||
}
|
}
|
||||||
#xxxFullScreen {
|
#xxxFullScreen {
|
||||||
background-color: white;
|
background-color: white;
|
||||||
margin-top: 0.40rem;
|
margin-top: 0.40rem;
|
||||||
#swiper1 {
|
.swiper-container{
|
||||||
overflow: hidden;
|
height: 6.45rem;
|
||||||
}
|
}
|
||||||
.swiper-container{
|
.swiper-container {
|
||||||
height: 6.45rem;
|
width: 100%;
|
||||||
}
|
height: 100%;
|
||||||
.swiper-container, .swiper-container2 {
|
position: relative;
|
||||||
width: 100%;
|
}
|
||||||
// overflow: visible !important;
|
.swiper-container .swiper-wrapper .swiper-slide {
|
||||||
height: 100%;
|
width: 17.25rem;
|
||||||
position: relative;
|
//height: 6.45rem !important; //Auto adaption
|
||||||
}
|
}
|
||||||
#swiper1 .swiper-container .swiper-wrapper .swiper-slide {
|
|
||||||
width: 17.25rem;
|
/* 上一张 */
|
||||||
//height: 6.45rem !important; //Auto adaption
|
swiper-container .swiper-wrapper .swiper-slide-prev {
|
||||||
}
|
margin-top: 0.05rem;
|
||||||
|
height: 100%;
|
||||||
/* 上一张 */
|
}
|
||||||
#swiper1 .swiper-container .swiper-wrapper .swiper-slide-prev {
|
/* 下一张 */
|
||||||
margin-top: 0.05rem;
|
.swiper-container .swiper-wrapper .swiper-slide-next {
|
||||||
height: 100%;
|
margin-top: 0.05rem;
|
||||||
|
height: 100%;
|
||||||
}
|
}
|
||||||
/* 下一张 */
|
.swiper-container .swiper-wrapper .swiper-slide-active {
|
||||||
#swiper1 .swiper-container .swiper-wrapper .swiper-slide-next {
|
height: 100%;
|
||||||
margin-top: 0.05rem;
|
}
|
||||||
height: 100%;
|
.uservideo{
|
||||||
|
width: 100%;
|
||||||
}
|
height:auto;
|
||||||
.swiper-container .swiper-wrapper .swiper-slide-active {
|
display: block;
|
||||||
height: 100%;
|
video{
|
||||||
|
max-width:100%;
|
||||||
}
|
max-height:100%;
|
||||||
.uservideo{
|
}
|
||||||
width: 100%;
|
|
||||||
height:auto;
|
|
||||||
display: block;
|
|
||||||
video{
|
|
||||||
max-width:100%;
|
|
||||||
max-height:100%;
|
|
||||||
}
|
}
|
||||||
}
|
|
||||||
}
|
}
|
||||||
.sw-center{
|
.sw-center{
|
||||||
width: 100%;
|
width: 100%;
|
||||||
@ -476,7 +469,7 @@
|
|||||||
text-overflow: ellipsis;
|
text-overflow: ellipsis;
|
||||||
display: -webkit-box;
|
display: -webkit-box;
|
||||||
-webkit-box-orient: vertical;
|
-webkit-box-orient: vertical;
|
||||||
-webkit-line-clamp: 2; /* 这里是超出几行省略 */
|
-webkit-line-clamp: 2;
|
||||||
color: #666666;
|
color: #666666;
|
||||||
margin-top: 0.16rem;
|
margin-top: 0.16rem;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
|
@ -120,20 +120,19 @@
|
|||||||
margin: 0 auto;
|
margin: 0 auto;
|
||||||
}
|
}
|
||||||
.rc-button {
|
.rc-button {
|
||||||
font-size: 14px;
|
font-size: 14px;
|
||||||
width:335px;
|
width:335px;
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
margin: 0 auto;
|
margin: 0 auto;
|
||||||
color: #333333;
|
color: #333333;
|
||||||
}
|
|
||||||
.rc-button span {
|
|
||||||
border-bottom: 1px solid #333333;
|
|
||||||
}
|
}
|
||||||
.rc-button span {
|
.rc-button span {
|
||||||
margin-left: 20px;
|
margin-left: 20px;
|
||||||
margin-top: 24px;
|
margin-top: 24px;
|
||||||
|
border-bottom: 1px solid #333333;
|
||||||
|
padding-bottom:.5rem;
|
||||||
}
|
}
|
||||||
.rc-button span:last-child {
|
.rc-button span:last-child {
|
||||||
margin-right: 20px;
|
margin-right: 20px;
|
||||||
@ -142,7 +141,7 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
// /* 最小768px最大1920 *pc端/
|
// /* 最小768px最大1920 *pc端/
|
||||||
@media screen and (min-width: 768px) and (max-width: 1920px) {
|
@media screen and (min-width: 769px) {
|
||||||
.usecheck{
|
.usecheck{
|
||||||
display: flex;
|
display: flex;
|
||||||
text-align: left;
|
text-align: left;
|
||||||
@ -232,7 +231,6 @@ margin-top: 24px;
|
|||||||
}
|
}
|
||||||
.rc-button {
|
.rc-button {
|
||||||
.rc-styled-link{
|
.rc-styled-link{
|
||||||
padding-bottom:3px;
|
|
||||||
border-bottom:1px solid #333;
|
border-bottom:1px solid #333;
|
||||||
&:hover{
|
&:hover{
|
||||||
border-bottom:1px solid #e2001a;
|
border-bottom:1px solid #e2001a;
|
||||||
|
@ -42,7 +42,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</a>
|
</a>
|
||||||
|
|
||||||
<a class="rc-md-up rc-btn rc-btn--icon rc-icon ts-login--xs rc-iconography rc-interactive" aria-label="login" @click="turnlogin">
|
<a class="rc-xl-up rc-btn rc-btn--icon rc-icon ts-login--xs rc-iconography rc-interactive" aria-label="login" @click="turnlogin">
|
||||||
<span class="rc-screen-reader-text">
|
<span class="rc-screen-reader-text">
|
||||||
登录
|
登录
|
||||||
</span>
|
</span>
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
<div class="ts-banner-swiper-container">
|
<div class="ts-banner-swiper-container">
|
||||||
<swiper :options="headerSwiperOption">
|
<swiper :options="headerSwiperOption">
|
||||||
<swiper-slide>
|
<swiper-slide>
|
||||||
<a href="#" target="_blank">
|
<a href="/" target="_blank">
|
||||||
<picture>
|
<picture>
|
||||||
<source media="(max-width: 768px)" srcset="/images/banner/one.jpg">
|
<source media="(max-width: 768px)" srcset="/images/banner/one.jpg">
|
||||||
<source media="(min-width: 769px)" srcset="/images/banner/pc-banner1.png">
|
<source media="(min-width: 769px)" srcset="/images/banner/pc-banner1.png">
|
||||||
@ -16,7 +16,7 @@
|
|||||||
</swiper-slide>
|
</swiper-slide>
|
||||||
|
|
||||||
<swiper-slide>
|
<swiper-slide>
|
||||||
<a href="#" target="_blank">
|
<a href="/" target="_blank">
|
||||||
<picture>
|
<picture>
|
||||||
<source media="(max-width: 768px)" srcset="/images/banner/two.jpg">
|
<source media="(max-width: 768px)" srcset="/images/banner/two.jpg">
|
||||||
<source media="(min-width: 769px)" srcset="/images/banner/pc-banner2.png">
|
<source media="(min-width: 769px)" srcset="/images/banner/pc-banner2.png">
|
||||||
@ -26,7 +26,7 @@
|
|||||||
</swiper-slide>
|
</swiper-slide>
|
||||||
|
|
||||||
<swiper-slide>
|
<swiper-slide>
|
||||||
<a href="#" target="_blank">
|
<a href="/" target="_blank">
|
||||||
<picture>
|
<picture>
|
||||||
<source media="(max-width: 768px)" srcset="/images/banner/three.jpg">
|
<source media="(max-width: 768px)" srcset="/images/banner/three.jpg">
|
||||||
<source media="(min-width: 769px)" srcset="/images/banner/pc-banner3.png">
|
<source media="(min-width: 769px)" srcset="/images/banner/pc-banner3.png">
|
||||||
@ -36,7 +36,7 @@
|
|||||||
</swiper-slide>
|
</swiper-slide>
|
||||||
|
|
||||||
<swiper-slide>
|
<swiper-slide>
|
||||||
<a href="#" target="_blank">
|
<a href="/" target="_blank">
|
||||||
<picture>
|
<picture>
|
||||||
<source media="(max-width: 768px)" srcset="/images/banner/four.jpg">
|
<source media="(max-width: 768px)" srcset="/images/banner/four.jpg">
|
||||||
<source media="(min-width: 769px)" srcset="/images/banner/pc-banner4.png">
|
<source media="(min-width: 769px)" srcset="/images/banner/pc-banner4.png">
|
||||||
@ -952,7 +952,12 @@
|
|||||||
catimage: "/images/cat/one.jpg",
|
catimage: "/images/cat/one.jpg",
|
||||||
productimage: "/images/cat/star-1.png",
|
productimage: "/images/cat/star-1.png",
|
||||||
detail:'为10柔软细腻慕斯 适合离乳期幼猫舔食',
|
detail:'为10柔软细腻慕斯 适合离乳期幼猫舔食',
|
||||||
price:'¥77',
|
price:'¥372',
|
||||||
|
productList:[
|
||||||
|
{
|
||||||
|
productCode : "80240008F24"
|
||||||
|
}
|
||||||
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: "幼猫成长专属",
|
title: "幼猫成长专属",
|
||||||
@ -960,7 +965,12 @@
|
|||||||
catimage: "/images/cat/two.jpg",
|
catimage: "/images/cat/two.jpg",
|
||||||
productimage: "/images/cat/star-2.png",
|
productimage: "/images/cat/star-2.png",
|
||||||
detail:'支持幼猫自身保护力 为快速生长提供足够能量',
|
detail:'支持幼猫自身保护力 为快速生长提供足够能量',
|
||||||
price:'¥147',
|
price:'¥33',
|
||||||
|
productList:[
|
||||||
|
{
|
||||||
|
productCode : "20030040"
|
||||||
|
}
|
||||||
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: "室内成猫专属",
|
title: "室内成猫专属",
|
||||||
@ -968,7 +978,12 @@
|
|||||||
catimage: "/images/cat/three.jpg",
|
catimage: "/images/cat/three.jpg",
|
||||||
productimage: "/images/cat/star-3.png",
|
productimage: "/images/cat/star-3.png",
|
||||||
detail:'高易消化蛋白 减少粪便量和异味',
|
detail:'高易消化蛋白 减少粪便量和异味',
|
||||||
price:'¥140',
|
price:'¥157',
|
||||||
|
productList:[
|
||||||
|
{
|
||||||
|
productCode : "21100200"
|
||||||
|
}
|
||||||
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: "英短成猫专属",
|
title: "英短成猫专属",
|
||||||
@ -976,7 +991,12 @@
|
|||||||
catimage: "/images/cat/four.jpg",
|
catimage: "/images/cat/four.jpg",
|
||||||
productimage: "/images/cat/star-4.png",
|
productimage: "/images/cat/star-4.png",
|
||||||
detail:'增强肌肉质量 支持骨骼与关节健康',
|
detail:'增强肌肉质量 支持骨骼与关节健康',
|
||||||
price:'¥183',
|
price:'¥402',
|
||||||
|
productList:[
|
||||||
|
{
|
||||||
|
productCode : "23040450"
|
||||||
|
}
|
||||||
|
]
|
||||||
},
|
},
|
||||||
|
|
||||||
],
|
],
|
||||||
@ -988,85 +1008,62 @@
|
|||||||
catimage: "/images/dog/one.jpg",
|
catimage: "/images/dog/one.jpg",
|
||||||
productimage: "/images/dog/star-1.png",
|
productimage: "/images/dog/star-1.png",
|
||||||
detail:'柔软细腻慕斯 适合离乳期幼犬舔食',
|
detail:'柔软细腻慕斯 适合离乳期幼犬舔食',
|
||||||
price:'¥77',
|
price:'¥359',
|
||||||
|
productList:[
|
||||||
|
{
|
||||||
|
productCode : "81220020F12"
|
||||||
|
}
|
||||||
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: "贵宾成犬专属",
|
title: "贵宾成犬专属",
|
||||||
video:"/images/dog/two.mp4",
|
video:"/images/dog/two.mp4",
|
||||||
catimage: "/images/dog/two.jpg",
|
catimage: "/images/dog/two.jpg",
|
||||||
productimage: "/images/cat/star-2.png",
|
productimage: "/images/dog/star-2.png",
|
||||||
detail:'护肤靓毛 理想体态',
|
detail:'护肤靓毛 理想体态',
|
||||||
price:'¥241',
|
price:'¥562',
|
||||||
|
productList:[
|
||||||
|
{
|
||||||
|
productCode : "14200300"
|
||||||
|
}
|
||||||
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: "小型犬成犬专属",
|
title: "小型犬成犬专属",
|
||||||
video:"/images/dog/three.mp4",
|
video:"/images/dog/three.mp4",
|
||||||
catimage: "/images/dog/three.jpg",
|
catimage: "/images/dog/three.jpg",
|
||||||
productimage: "/images/cat/star-3.png",
|
productimage: "/images/dog/star-3.png",
|
||||||
detail:'亮泽被毛 呵护牙齿',
|
detail:'亮泽被毛 呵护牙齿',
|
||||||
price:'¥121',
|
price:'¥57',
|
||||||
|
productList:[
|
||||||
|
{
|
||||||
|
productCode : "16020080"
|
||||||
|
}
|
||||||
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: "离乳期全价奶糕",
|
title: "离乳期全价奶糕",
|
||||||
video:"/images/dog/four.mp4",
|
video:"/images/dog/four.mp4",
|
||||||
catimage: "/images/dog/four.jpg",
|
catimage: "/images/dog/four.jpg",
|
||||||
productimage: "/images/cat/star-4.png",
|
productimage: "/images/dog/star-4.png",
|
||||||
detail:'高易再水合颗粒 帮助增强保护健康成长',
|
detail:'高易再水合颗粒 帮助增强保护健康成长',
|
||||||
price:'¥88',
|
price:'¥263',
|
||||||
|
productList:[
|
||||||
|
{
|
||||||
|
productCode : "17220400"
|
||||||
|
}
|
||||||
|
]
|
||||||
},
|
},
|
||||||
|
|
||||||
],
|
],
|
||||||
rccontair: [
|
rccontair: [
|
||||||
{
|
{
|
||||||
title: "皇家英国短毛猫全价湿粮",
|
title: "",
|
||||||
price:'¥123.45',
|
price:'',
|
||||||
ordernum: 1,
|
ordernum: 1,
|
||||||
catimage: require("../assets/image/rc-cat.png"),
|
catimage: "",
|
||||||
},
|
},
|
||||||
|
],
|
||||||
{
|
|
||||||
title: "皇家英国短毛猫全价湿粮",
|
|
||||||
price:'¥123.45',
|
|
||||||
ordernum: "2",
|
|
||||||
catimage: require("../assets/image/rc-cat.png"),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
title: "皇家英国短毛猫全价湿粮",
|
|
||||||
price:'¥123.45',
|
|
||||||
ordernum: "2",
|
|
||||||
catimage: require("../assets/image/rc-cat.png"),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
title: "皇家英国短毛猫全价湿粮",
|
|
||||||
price:'¥123.45',
|
|
||||||
ordernum: "2",
|
|
||||||
catimage: require("../assets/image/rc-cat.png"),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
title: "皇家英国短毛猫全价湿粮",
|
|
||||||
price:'¥123.45',
|
|
||||||
ordernum: "2",
|
|
||||||
catimage: require("../assets/image/rc-dog.png"),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
title: "皇家英国短毛猫全价湿粮",
|
|
||||||
price:'¥123.45',
|
|
||||||
ordernum: "2",
|
|
||||||
catimage: require("../assets/image/rc-dog.png"),
|
|
||||||
},
|
|
||||||
// {
|
|
||||||
// title: "皇家英国短毛猫全价湿粮",
|
|
||||||
// price:'¥123.45',
|
|
||||||
// ordernum: "2",
|
|
||||||
// catimage: require("../assets/image/rc-dog.png"),
|
|
||||||
// },
|
|
||||||
// {
|
|
||||||
// title: "皇家英国短毛猫全价湿粮",
|
|
||||||
// price:'¥123.45',
|
|
||||||
// ordernum: "2",
|
|
||||||
// catimage: require("../assets/image/rc-dog.png"),
|
|
||||||
// },
|
|
||||||
],
|
|
||||||
|
|
||||||
headerSwiperOption: {
|
headerSwiperOption: {
|
||||||
loop: true,
|
loop: true,
|
||||||
|
@ -99,6 +99,10 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="online bold"></div>
|
<div class="online bold"></div>
|
||||||
|
<div class="ts-btn" v-if="!islogin">
|
||||||
|
<div class="ts-standard-btn center" @click="logout">退出登录</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@ -141,6 +145,7 @@ import Myheader from '~/components/header.vue'
|
|||||||
import MyFooter from '~/components/rc-footer.vue'
|
import MyFooter from '~/components/rc-footer.vue'
|
||||||
import FixRight from "~/components/fixed-right.vue";
|
import FixRight from "~/components/fixed-right.vue";
|
||||||
import tabs from "@/components/tabs.vue";
|
import tabs from "@/components/tabs.vue";
|
||||||
|
import { mapMutations } from "vuex";
|
||||||
export default {
|
export default {
|
||||||
middleware: 'metaTitle',
|
middleware: 'metaTitle',
|
||||||
// middleware: 'metaTitle',
|
// middleware: 'metaTitle',
|
||||||
@ -150,7 +155,7 @@ export default {
|
|||||||
userlog:false,
|
userlog:false,
|
||||||
islogin:false,
|
islogin:false,
|
||||||
dialogInfo1:false,
|
dialogInfo1:false,
|
||||||
userid:null,
|
userid:null,
|
||||||
usertitle:'',
|
usertitle:'',
|
||||||
rcvalue:5000,
|
rcvalue:5000,
|
||||||
usermessage:'关注皇家爱宠荟,修改个人资料',
|
usermessage:'关注皇家爱宠荟,修改个人资料',
|
||||||
@ -211,24 +216,30 @@ export default {
|
|||||||
|
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
userinter(){
|
...mapMutations(["logoutSystem","checkIsLogin"]),
|
||||||
let user= localStorage.getItem("userInfo");
|
logout() {
|
||||||
if(user==undefined||user==null||user==''){
|
this.logoutSystem();
|
||||||
this.$message({
|
this.$router.push({
|
||||||
type: 'warning',
|
path: "/",
|
||||||
message: '您还未登录'
|
});
|
||||||
});
|
},
|
||||||
return
|
userinter(){
|
||||||
|
let user= this.checkIsLogin();
|
||||||
}else{
|
if(!user){
|
||||||
this.$router.push({
|
this.$message({
|
||||||
path: "/personal/integral/",
|
type: 'warning',
|
||||||
query: {
|
message: '您还未登录'
|
||||||
stype: 1,
|
});
|
||||||
},
|
return
|
||||||
});
|
} else {
|
||||||
}
|
this.$router.push({
|
||||||
},
|
path: "/personal/integral/",
|
||||||
|
query: {
|
||||||
|
stype: 1,
|
||||||
|
},
|
||||||
|
});
|
||||||
|
}
|
||||||
|
},
|
||||||
findall(){
|
findall(){
|
||||||
console.log('PPP');
|
console.log('PPP');
|
||||||
console.log(this.userid.length);
|
console.log(this.userid.length);
|
||||||
@ -304,64 +315,58 @@ obligation(item,index){
|
|||||||
open(){
|
open(){
|
||||||
|
|
||||||
},
|
},
|
||||||
ifadroind(){
|
ifadroind(){
|
||||||
var sUserAgent = navigator.userAgent.toLowerCase();
|
var sUserAgent = navigator.userAgent.toLowerCase();
|
||||||
var bIsIpad = sUserAgent.match(/ipad/i) == "ipad";
|
var bIsIpad = sUserAgent.match(/ipad/i) == "ipad";
|
||||||
var bIsIphoneOs = sUserAgent.match(/iphone os/i) == "iphone os";
|
var bIsIphoneOs = sUserAgent.match(/iphone os/i) == "iphone os";
|
||||||
var bIsMidp = sUserAgent.match(/midp/i) == "midp";
|
var bIsMidp = sUserAgent.match(/midp/i) == "midp";
|
||||||
var bIsUc7 = sUserAgent.match(/rv:1.2.3.4/i) == "rv:1.2.3.4";
|
var bIsUc7 = sUserAgent.match(/rv:1.2.3.4/i) == "rv:1.2.3.4";
|
||||||
var bIsUc = sUserAgent.match(/ucweb/i) == "ucweb";
|
var bIsUc = sUserAgent.match(/ucweb/i) == "ucweb";
|
||||||
var bIsAndroid = sUserAgent.match(/android/i) == "android";
|
var bIsAndroid = sUserAgent.match(/android/i) == "android";
|
||||||
var bIsCE = sUserAgent.match(/windows ce/i) == "windows ce";
|
var bIsCE = sUserAgent.match(/windows ce/i) == "windows ce";
|
||||||
var bIsWM = sUserAgent.match(/windows mobile/i) == "windows mobile";
|
var bIsWM = sUserAgent.match(/windows mobile/i) == "windows mobile";
|
||||||
|
|
||||||
if (!(bIsIpad || bIsIphoneOs || bIsMidp || bIsUc7 || bIsUc || bIsAndroid || bIsCE || bIsWM)) {
|
if (!(bIsIpad || bIsIphoneOs || bIsMidp || bIsUc7 || bIsUc || bIsAndroid || bIsCE || bIsWM)) {
|
||||||
if(this.userlog==true){
|
if(this.userlog==true){
|
||||||
this.usermessage='关注皇家爱宠荟,修改个人资料',
|
this.usermessage='关注皇家爱宠荟,修改个人资料',
|
||||||
this.dialogInfo1=true;
|
this.dialogInfo1=true;
|
||||||
}else{
|
}else{
|
||||||
this.dialogInfo1=false;
|
this.dialogInfo1=false;
|
||||||
this.usermessage='关注皇家爱宠荟,兑换更多福利';
|
this.usermessage='关注皇家爱宠荟,兑换更多福利';
|
||||||
}
|
}
|
||||||
|
return false;
|
||||||
}else{
|
} else {
|
||||||
this.dialogInfo1=false;
|
this.dialogInfo1=false;
|
||||||
window.location.href="weixin://dl/business/?t=BE1OA2AngRs";
|
return true;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
openaddress(item,index){
|
openaddress(item,index){
|
||||||
console.log(item,index);
|
let user= localStorage.getItem("userInfo");
|
||||||
let user= localStorage.getItem("userInfo");
|
if(user==undefined||user==null||user==''){
|
||||||
if(user==undefined||user==null||user==''){
|
this.$message({
|
||||||
console.log('---=');
|
type: 'warning',
|
||||||
this.$message({
|
message: '您还未登录'
|
||||||
type: 'warning',
|
});
|
||||||
message: '您还未登录'
|
return
|
||||||
});
|
|
||||||
return
|
|
||||||
|
|
||||||
}else{
|
}else{
|
||||||
if(item.title=='收货地址'){
|
if(item.title=='收货地址'){
|
||||||
|
this.$router.push({
|
||||||
this.$router.push({
|
path: `/useraddress/openaddress/`
|
||||||
path: `/useraddress/openaddress/`
|
})
|
||||||
})
|
}
|
||||||
console.log('这是地址的跳转');
|
|
||||||
|
|
||||||
}
|
|
||||||
if(index==0){
|
if(index==0){
|
||||||
this.userlog=true
|
this.userlog=true
|
||||||
this.ifadroind();
|
let isMobile = this.ifadroind();
|
||||||
|
if(isMobile)
|
||||||
|
window.location.href="weixin://dl/business/?t=BE1OA2AngRs";
|
||||||
}
|
}
|
||||||
|
|
||||||
if(index==1){
|
if(index==1){
|
||||||
this.$router.push({
|
this.$router.push({
|
||||||
path: `/personal/discount/`
|
path: `/personal/discount/`
|
||||||
})
|
})
|
||||||
console.log('这是地址的跳转');
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
},
|
},
|
||||||
@ -372,43 +377,37 @@ this.$router.push({
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
console.log(this.islogin)
|
|
||||||
console.log(this.userid);
|
|
||||||
let userwidth=0;
|
let userwidth=0;
|
||||||
this.ifadroind();
|
this.ifadroind();
|
||||||
let user= JSON.parse(localStorage.getItem("userInfo"));
|
let user= this.checkIsLogin();
|
||||||
console.log(user)
|
if(user){
|
||||||
if(user!==null){
|
this.userid=user.data;
|
||||||
console.log('11')
|
this.islogin=false;
|
||||||
this.userid=user.data;
|
this.usertitle=this.userid.memberName;
|
||||||
console.log(this.userid);
|
this.rcrcord=this.userid.availiblePoint;
|
||||||
this.usertitle=this.userid.memberName;
|
if(this.userid.memberLevel==1){
|
||||||
|
let userlength=this.userid.availiblePoint.toString().length;
|
||||||
this.rcrcord=this.userid.availiblePoint;
|
this.userimage=require('../../assets/image/rc-new.png');
|
||||||
|
this.userorder='新手铲屎官';
|
||||||
if(this.userid.memberLevel==1){
|
this.uservalue=5000; //新手总积分
|
||||||
let userlength=this.userid.availiblePoint.toString().length;
|
this.rcvalue=this.uservalue-this.userid.availiblePoint; //新手总积分减去本身的积分
|
||||||
this.userimage=require('../../assets/image/rc-new.png');
|
if(userlength==1||userlength==2||userlength==3||userlength==4){
|
||||||
this.userorder='新手铲屎官';
|
userwidth=this.userid.availiblePoint/100
|
||||||
this.uservalue=5000; //新手总积分
|
console.log(userwidth);
|
||||||
this.rcvalue=this.uservalue-this.userid.availiblePoint; //新手总积分减去本身的积分
|
}
|
||||||
if(userlength==1||userlength==2||userlength==3||userlength==4){
|
}
|
||||||
userwidth=this.userid.availiblePoint/100
|
else if(this.userid.memberLevel==2){
|
||||||
console.log(userwidth);
|
this.userimage=require('../../assets/image/rc-new2.png');
|
||||||
}
|
this.userorder='资深铲屎官';
|
||||||
}
|
this.uservalue=10000;
|
||||||
else if(this.userid.memberLevel==2){
|
this.rcvalue=this.uservalue-this.userid.availiblePoint;
|
||||||
this.userimage=require('../../assets/image/rc-new2.png');
|
userwidth=this.userid.availiblePoint/100
|
||||||
this.userorder='资深铲屎官';
|
}else if( this.userid.memberLevel==3){
|
||||||
this.uservalue=10000;
|
this.userimage=require('../../assets/image/rc-new1.png');
|
||||||
this.rcvalue=this.uservalue-this.userid.availiblePoint;
|
this.userorder='金牌铲屎官';
|
||||||
userwidth=this.userid.availiblePoint/100
|
this.usrnewlist=this.goldmedal;
|
||||||
}else if( this.userid.memberLevel==3){
|
userwidth=100
|
||||||
this.userimage=require('../../assets/image/rc-new1.png');
|
}
|
||||||
this.userorder='金牌铲屎官';
|
|
||||||
this.usrnewlist=this.goldmedal;
|
|
||||||
userwidth=100
|
|
||||||
}
|
|
||||||
this.$refs.userblock.style.width=userwidth+'%';
|
this.$refs.userblock.style.width=userwidth+'%';
|
||||||
let tagEle=document.querySelector('.ts-point-tag');
|
let tagEle=document.querySelector('.ts-point-tag');
|
||||||
if(tagEle){
|
if(tagEle){
|
||||||
@ -418,17 +417,13 @@ this.$router.push({
|
|||||||
tagEleLeft=0;
|
tagEleLeft=0;
|
||||||
tagEle.style.left=tagEleLeft+"%";
|
tagEle.style.left=tagEleLeft+"%";
|
||||||
}
|
}
|
||||||
} else{
|
} else {
|
||||||
console.log('---');
|
this.userid='';
|
||||||
this.userid=[];
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if(this.userid==undefined ||this.userid==''||this.userid==null){
|
if(this.userid==undefined ||this.userid==''||this.userid==null){
|
||||||
console.log(this.userid)
|
this.islogin=true;
|
||||||
this.islogin=true;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
||||||
|
@ -732,13 +732,20 @@ export default {
|
|||||||
openclose() {
|
openclose() {
|
||||||
this.dialogInfo1 = false;
|
this.dialogInfo1 = false;
|
||||||
},
|
},
|
||||||
selectproduce() {
|
selectproduce(item,index){
|
||||||
this.$router.push({
|
if(item.productList[0]==undefined){
|
||||||
path: "/productdetails/producted",
|
item.productlist[0].productCode=0;
|
||||||
query: {
|
}
|
||||||
stype: 1,
|
if(item.productList[0]==undefined){
|
||||||
},
|
item.productlist[0]=[];
|
||||||
});
|
}
|
||||||
|
this.$router.push({
|
||||||
|
path: "/productdetails/producted",
|
||||||
|
query: {
|
||||||
|
stype: 1,
|
||||||
|
productCode:item.productList[0].productCode
|
||||||
|
},
|
||||||
|
});
|
||||||
},
|
},
|
||||||
ifadroind() {
|
ifadroind() {
|
||||||
var sUserAgent = navigator.userAgent.toLowerCase();
|
var sUserAgent = navigator.userAgent.toLowerCase();
|
||||||
|
@ -14,6 +14,7 @@
|
|||||||
show-action
|
show-action
|
||||||
placeholder="请输入搜索关键词"
|
placeholder="请输入搜索关键词"
|
||||||
@search="onSearch"
|
@search="onSearch"
|
||||||
|
@cancel="onCancel"
|
||||||
class="rc-keyword"
|
class="rc-keyword"
|
||||||
>
|
>
|
||||||
<template #action>
|
<template #action>
|
||||||
@ -664,14 +665,20 @@ export default {
|
|||||||
element.checked = false;
|
element.checked = false;
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
selectproduce(item) {
|
selectproduce(item,index){
|
||||||
this.$router.push({
|
if(item.productList[0]==undefined){
|
||||||
path: "/productdetails/producted",
|
item.productlist[0].productCode=0;
|
||||||
query: {
|
}
|
||||||
stype: 1,
|
if(item.productList[0]==undefined){
|
||||||
productCode: item.productList[0].productCode,
|
item.productlist[0]=[];
|
||||||
},
|
}
|
||||||
});
|
this.$router.push({
|
||||||
|
path: "/productdetails/producted",
|
||||||
|
query: {
|
||||||
|
stype: 1,
|
||||||
|
productCode:item.productList[0].productCode
|
||||||
|
},
|
||||||
|
});
|
||||||
},
|
},
|
||||||
checkRxGoods(toggleSwitch){
|
checkRxGoods(toggleSwitch){
|
||||||
let _self = this;
|
let _self = this;
|
||||||
@ -769,6 +776,10 @@ export default {
|
|||||||
onSearch(e) {
|
onSearch(e) {
|
||||||
this.usetmessage(this.activeIndex1, this.value);
|
this.usetmessage(this.activeIndex1, this.value);
|
||||||
},
|
},
|
||||||
|
onCancel() {
|
||||||
|
debugger;
|
||||||
|
this.value='';
|
||||||
|
},
|
||||||
selectGoods(item, index, onlyRefreshCategory) {
|
selectGoods(item, index, onlyRefreshCategory) {
|
||||||
this.activeIndex1 = index;
|
this.activeIndex1 = index;
|
||||||
this.resetAllOptions();
|
this.resetAllOptions();
|
||||||
|
@ -25,21 +25,24 @@ const mutations = {
|
|||||||
// },
|
// },
|
||||||
changeClod(state, val) {
|
changeClod(state, val) {
|
||||||
localStorage.setItem('userInfo', val.cloud);
|
localStorage.setItem('userInfo', val.cloud);
|
||||||
console.log(state,val);
|
|
||||||
},
|
},
|
||||||
|
logoutSystem(state) {
|
||||||
|
localStorage.removeItem('userInfo')
|
||||||
|
},
|
||||||
|
checkIsLogin() {
|
||||||
|
let rawUserInfoStr = localStorage.getItem('userInfo');
|
||||||
|
let rawUserInfo = JSON.parse(rawUserInfoStr);
|
||||||
|
if(rawUserInfo && rawUserInfo.hasOwnProperty('xaccessToken') && rawUserInfo['xaccessToken'].length>36)
|
||||||
|
return rawUserInfo;
|
||||||
|
return false;
|
||||||
|
},
|
||||||
changemessage(state, val) {
|
changemessage(state, val) {
|
||||||
localStorage.setItem('message', val.data);
|
localStorage.setItem('message', val.data);
|
||||||
console.log(state,val);
|
|
||||||
},
|
},
|
||||||
selectMenu(state, val) {
|
selectMenu(state, val) {
|
||||||
let result = state.tabsList.findIndex(item => item.name === val.data.name)
|
let result = state.tabsList.findIndex(item => item.name === val.data.name)
|
||||||
result === -1 ? state.tabsList.push(val.data) : ''
|
result === -1 ? state.tabsList.push(val.data) : ''
|
||||||
|
},
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
},
|
|
||||||
|
|
||||||
// changeMenu(state, user){
|
// changeMenu(state, user){
|
||||||
// // console.log("vuex存储的变化",JSON.parse(user))
|
// // console.log("vuex存储的变化",JSON.parse(user))
|
||||||
|
Loading…
Reference in New Issue
Block a user