diff --git a/README.md b/README.md index a55ca49..3ddfead 100644 --- a/README.md +++ b/README.md @@ -115,7 +115,7 @@ this.$store.commit('setLoginOut') this.$store.state.userInfo // 登录拦截 -// 示例:点击购买课程前需要判断当前用户是否登录 +// 示例:点击购买课程前需要判断当前用户是否登录,未登录则弹出登录弹窗 function onPurchaseCourse() { if (!this.$isLoginValidate()) { return; diff --git a/static/images/goods/left.png b/assets/img/goods/left.png similarity index 100% rename from static/images/goods/left.png rename to assets/img/goods/left.png diff --git a/static/images/goods/more.png b/assets/img/goods/more.png similarity index 100% rename from static/images/goods/more.png rename to assets/img/goods/more.png diff --git a/static/images/goods/right.png b/assets/img/goods/right.png similarity index 100% rename from static/images/goods/right.png rename to assets/img/goods/right.png diff --git a/static/images/goods/sort-b1.png b/assets/img/goods/sort-b1.png similarity index 100% rename from static/images/goods/sort-b1.png rename to assets/img/goods/sort-b1.png diff --git a/static/images/goods/sort-b2.png b/assets/img/goods/sort-b2.png similarity index 100% rename from static/images/goods/sort-b2.png rename to assets/img/goods/sort-b2.png diff --git a/static/images/goods/sort-t1.png b/assets/img/goods/sort-t1.png similarity index 100% rename from static/images/goods/sort-t1.png rename to assets/img/goods/sort-t1.png diff --git a/static/images/goods/sort-t2.png b/assets/img/goods/sort-t2.png similarity index 100% rename from static/images/goods/sort-t2.png rename to assets/img/goods/sort-t2.png diff --git a/static/images/layout/footer-1.png b/assets/img/layout/footer-1.png similarity index 100% rename from static/images/layout/footer-1.png rename to assets/img/layout/footer-1.png diff --git a/static/images/layout/footer-2.png b/assets/img/layout/footer-2.png similarity index 100% rename from static/images/layout/footer-2.png rename to assets/img/layout/footer-2.png diff --git a/static/images/layout/footer-3.png b/assets/img/layout/footer-3.png similarity index 100% rename from static/images/layout/footer-3.png rename to assets/img/layout/footer-3.png diff --git a/static/images/layout/footer-4.png b/assets/img/layout/footer-4.png similarity index 100% rename from static/images/layout/footer-4.png rename to assets/img/layout/footer-4.png diff --git a/static/images/layout/icon-arrow.png b/assets/img/layout/icon-arrow.png similarity index 100% rename from static/images/layout/icon-arrow.png rename to assets/img/layout/icon-arrow.png diff --git a/static/images/layout/icon-category.png b/assets/img/layout/icon-category.png similarity index 100% rename from static/images/layout/icon-category.png rename to assets/img/layout/icon-category.png diff --git a/static/images/layout/icon-login-sticky.png b/assets/img/layout/icon-login-sticky.png similarity index 100% rename from static/images/layout/icon-login-sticky.png rename to assets/img/layout/icon-login-sticky.png diff --git a/static/images/layout/icon-message.png b/assets/img/layout/icon-message.png similarity index 100% rename from static/images/layout/icon-message.png rename to assets/img/layout/icon-message.png diff --git a/static/images/layout/icon-order.png b/assets/img/layout/icon-order.png similarity index 100% rename from static/images/layout/icon-order.png rename to assets/img/layout/icon-order.png diff --git a/static/images/layout/icon-phone.png b/assets/img/layout/icon-phone.png similarity index 100% rename from static/images/layout/icon-phone.png rename to assets/img/layout/icon-phone.png diff --git a/static/images/layout/icon-search-sticky.png b/assets/img/layout/icon-search-sticky.png similarity index 100% rename from static/images/layout/icon-search-sticky.png rename to assets/img/layout/icon-search-sticky.png diff --git a/static/images/layout/icon-search.png b/assets/img/layout/icon-search.png similarity index 100% rename from static/images/layout/icon-search.png rename to assets/img/layout/icon-search.png diff --git a/static/images/layout/icon-shop-sticky.png b/assets/img/layout/icon-shop-sticky.png similarity index 100% rename from static/images/layout/icon-shop-sticky.png rename to assets/img/layout/icon-shop-sticky.png diff --git a/static/images/layout/icon-shop.png b/assets/img/layout/icon-shop.png similarity index 100% rename from static/images/layout/icon-shop.png rename to assets/img/layout/icon-shop.png diff --git a/static/images/layout/icon-up-light.png b/assets/img/layout/icon-up-light.png similarity index 100% rename from static/images/layout/icon-up-light.png rename to assets/img/layout/icon-up-light.png diff --git a/static/images/layout/icon-up.png b/assets/img/layout/icon-up.png similarity index 100% rename from static/images/layout/icon-up.png rename to assets/img/layout/icon-up.png diff --git a/static/images/layout/logo-sticky.png b/assets/img/layout/logo-sticky.png similarity index 100% rename from static/images/layout/logo-sticky.png rename to assets/img/layout/logo-sticky.png diff --git a/static/images/layout/logo.png b/assets/img/layout/logo.png similarity index 100% rename from static/images/layout/logo.png rename to assets/img/layout/logo.png diff --git a/static/images/login/icon-accept.png b/assets/img/login/icon-accept.png similarity index 100% rename from static/images/login/icon-accept.png rename to assets/img/login/icon-accept.png diff --git a/static/images/login/icon-close.png b/assets/img/login/icon-close.png similarity index 100% rename from static/images/login/icon-close.png rename to assets/img/login/icon-close.png diff --git a/static/images/login/icon-logo.png b/assets/img/login/icon-logo.png similarity index 100% rename from static/images/login/icon-logo.png rename to assets/img/login/icon-logo.png diff --git a/components/BsLogin.vue b/components/BsLogin.vue index 8a76a80..17e4000 100644 --- a/components/BsLogin.vue +++ b/components/BsLogin.vue @@ -10,7 +10,7 @@
@@ -43,7 +43,7 @@
@@ -53,7 +53,7 @@
- +
diff --git a/layouts/module/footer/index.vue b/layouts/module/footer/index.vue index c7d4263..37ed298 100644 --- a/layouts/module/footer/index.vue +++ b/layouts/module/footer/index.vue @@ -27,19 +27,19 @@ export default { promiseList: [ { label: "马士兵严选", - icon: require("@/static/images/layout/footer-1.png"), + icon: require("~/assets/img/layout/footer-1.png"), }, { label: "马士兵严选", - icon: require("@/static/images/layout/footer-2.png"), + icon: require("~/assets/img/layout/footer-2.png"), }, { label: "马士兵严选", - icon: require("@/static/images/layout/footer-3.png"), + icon: require("~/assets/img/layout/footer-3.png"), }, { label: "马士兵严选", - icon: require("@/static/images/layout/footer-4.png"), + icon: require("~/assets/img/layout/footer-4.png"), }, ], }; diff --git a/layouts/module/header/HeaderInfoBar.vue b/layouts/module/header/HeaderInfoBar.vue index 84af96f..a97ff74 100644 --- a/layouts/module/header/HeaderInfoBar.vue +++ b/layouts/module/header/HeaderInfoBar.vue @@ -32,7 +32,7 @@ :command="item.value" > {{ item.label }} - + @@ -50,7 +50,7 @@ class="header-wrap-content__common flex flex-middle" @click="onJumpPersonalPage('message')" > - + 消息
33
@@ -60,12 +60,12 @@ class="header-wrap-content__common flex flex-middle" @click="onJumpPersonalPage('order/list')" > - + 我的订单
- + 下载app
@@ -105,8 +105,8 @@ export default { ...mapState(["userInfo", "token"]), menuIcon() { return this.menuVisible - ? require("@/static/images/layout/icon-up-light.png") - : require("@/static/images/layout/icon-up.png"); + ? require("~/assets/img/layout/icon-up-light.png") + : require("~/assets/img/layout/icon-up.png"); }, }, methods: { diff --git a/layouts/module/header/index.vue b/layouts/module/header/index.vue index 4f4ff3a..2d1ec76 100644 --- a/layouts/module/header/index.vue +++ b/layouts/module/header/index.vue @@ -6,7 +6,7 @@
- +
- + 3
@@ -48,7 +48,7 @@
- + 购物车
3
@@ -83,7 +83,7 @@ @mouseleave="handleCategoryChange(false)" >
- + 热门分类
- \ No newline at end of file + diff --git a/pages/goods/detail/_id.vue b/pages/goods/detail/_id.vue index 68bf1f5..b46df9d 100644 --- a/pages/goods/detail/_id.vue +++ b/pages/goods/detail/_id.vue @@ -21,7 +21,7 @@
左侧切换 @@ -44,7 +44,7 @@
右侧切换 @@ -68,7 +68,7 @@ > 服务
diff --git a/pages/goods/list/module/SortItem.vue b/pages/goods/list/module/SortItem.vue index ea36522..c887235 100644 --- a/pages/goods/list/module/SortItem.vue +++ b/pages/goods/list/module/SortItem.vue @@ -4,22 +4,22 @@
sort sort sort sort
diff --git a/plugins/vue-inject.js b/plugins/vue-inject.js index 7d8acb5..0ea1a64 100644 --- a/plugins/vue-inject.js +++ b/plugins/vue-inject.js @@ -2,7 +2,7 @@ import Vue from "vue"; import { TOKEN_KEY } from "@/constants"; const injectOptions = { - // 是否需要登录拦截 + // 是否需要登录拦截,如果未登录,会默认唤起登录弹窗 $isLoginValidate() { if (this.$cookies.get(TOKEN_KEY)) { return true;