feat: 未登录打开个人中心跳转首页

merge-requests/60/head
xiaoguang 2 years ago
parent 4f90c93ebd
commit 7190f03a69

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.9 KiB

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.0 KiB

After

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.6 KiB

After

Width:  |  Height:  |  Size: 2.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.7 KiB

After

Width:  |  Height:  |  Size: 2.4 KiB

@ -50,9 +50,3 @@ export default {
},
};
</script>
<style lang="scss" scoped>
.layout-footer {
height: 189px;
background: #ddd;
}
</style>

@ -5,10 +5,13 @@
<div
v-for="(item, index) in promiseList"
:key="index"
class="wrap-promise-item"
class="wrap-promise-item flex flex-middle"
>
<img :src="item.icon" />
<span>{{ item.label }}</span>
<div class="wrap-promise-item__info">
<strong>{{ item.label }}</strong>
<p class="promise-item-info__desc">{{ item.desc }}</p>
</div>
</div>
</div>
<div class="layout-footer-wrap__line"></div>
@ -27,18 +30,22 @@ export default {
promiseList: [
{
label: "马士兵严选",
desc: "甄选优品",
icon: require("~/assets/img/layout/footer-1.png"),
},
{
label: "100%正品",
desc: "正品保障",
icon: require("~/assets/img/layout/footer-2.png"),
},
{
label: "365天质保",
desc: "品质护航 购物无忧",
icon: require("~/assets/img/layout/footer-3.png"),
},
{
label: "售后无忧",
desc: "无忧退货",
icon: require("~/assets/img/layout/footer-4.png"),
},
],
@ -48,21 +55,24 @@ export default {
</script>
<style lang="scss" scoped>
.layout-footer {
height: 189px;
background: #dddddd;
background: #eeeeee;
.layout-footer-wrap {
@include layout-box;
.layout-footer-wrap__promise {
width: 1060px;
margin: 0 auto;
padding: 25px 0;
padding: 42px 72px;
.wrap-promise-item {
font-weight: bold;
color: #999999;
font-size: 18px;
margin-left: 20px;
img {
width: 52px;
height: 52px;
width: 48px;
height: 48px;
margin-right: 20px;
}
.wrap-promise-item__info {
color: #999999;
font-size: 18px;
.promise-item-info__desc {
margin-top: 6px;
font-size: 14px;
}
}
}
}
@ -72,12 +82,13 @@ export default {
background: #cccccc;
}
.layout-footer-wrap__address {
width: 500px;
width: 496px;
margin: 0 auto;
padding: 20px 0;
font-size: 12px;
color: #797979;
color: #999999;
text-align: center;
line-height: 20px;
}
}
}

@ -35,7 +35,7 @@
</div>
<!-- 右侧二级分类 -->
<div
v-show="categroyTwoVisible"
v-show="true || categroyTwoVisible"
class="tab-category-menu__right flex-1"
>
<div
@ -171,6 +171,7 @@ export default {
position: absolute;
top: 38px;
left: 0;
height: 360px;
font-size: 14px;
color: #333333;
.tab-category-menu__left {
@ -178,9 +179,13 @@ export default {
padding: 15px 0;
background: #ffffff;
.menu-left__item {
height: 50px;
height: 36px;
cursor: pointer;
padding: 0 24px 0 41px;
margin-top: 23px;
&:first-child {
margin-top: 0;
}
&:hover,
&--light {
color: #ff875b;
@ -198,12 +203,16 @@ export default {
border: 1px solid #eeeeee;
background: #ffffff;
.category-menu-right__wrap {
height: 50px;
line-height: 50px;
height: 36px;
margin-top: 23px;
line-height: 36px;
padding: 0 16px;
font-size: 12px;
color: #999999;
white-space: nowrap;
&:first-child {
margin-top: 0;
}
&:hover,
&--light {
background: #f8f8f8;

@ -312,7 +312,7 @@ export default {
color: #ff7f39 !important;
}
.header-box-tab__common {
width: 160px;
margin-left: 78px;
height: 100%;
font-size: 16px;
color: #666666;

@ -8,7 +8,7 @@
export default {
// Global page headers: https://go.nuxtjs.dev/config-head
head: {
title: 'shop-pc',
title: '马士兵严选',
htmlAttrs: {
lang: 'zh'
},
@ -19,7 +19,7 @@ export default {
{ name: 'format-detection', content: 'telephone=no' }
],
link: [
{ rel: 'icon', type: 'image/x-icon', href: '/favicon.ico' }
{ rel: 'icon', type: 'image/x-icon', href: '/logo.png' }
]
},
router: {
@ -45,6 +45,7 @@ export default {
'@plugins/axiosTk.js',
'@plugins/vue-inject.js',
'@/plugins/v-distpicker',
'@/plugins/router'
],
// Auto import components: https://go.nuxtjs.dev/config-components

@ -170,7 +170,7 @@ export default {
background: #f8f8f8;
.home-wrap {
@include layout-box;
padding: 30px 0 30px 0;
padding: 30px 0;
.home-wrap-select {
margin-top: 30px;
&__header {

@ -14,7 +14,7 @@
:key="item.id"
@click="onBannerClick(item.id)"
>
<el-image :src="item.url" fit="fill"></el-image>
<el-image :src="item.url" fit="cover"></el-image>
</el-carousel-item>
</el-carousel>
</div>
@ -34,7 +34,7 @@ export default {
id: 30,
},
{
url: "https://msb-edu-dev.oss-cn-beijing.aliyuncs.com/uc/account-avatar/2banner.png",
url: "https://msb-edu-dev.oss-cn-beijing.aliyuncs.com/uc/account-avatar/goods15.jpg",
id: 15,
},
{

@ -184,7 +184,6 @@ export default {
<style lang="scss" scoped>
.home-pick {
color: #333333;
margin-top: 30px;
&--label {
font-size: 24px;
margin-bottom: 16px;

@ -0,0 +1,15 @@
export default ({ app }) => {
app.router.beforeEach((to, from, next) => {
if (app.store.state.token) {
next();
return;
}
// 未登录打开个人中心相关页面,跳首页
if (/\/account/.test(to.path)) {
next("/");
return;
}
next();
});
};

Binary file not shown.

Before

Width:  |  Height:  |  Size: 8.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 763 B

Loading…
Cancel
Save