代码优化

master
wayn 1 year ago
parent c75aa28551
commit 136af69952

@ -2,5 +2,6 @@
ENV = 'development' ENV = 'development'
# base api # base api
VUE_APP_BASE_PATH = '/mall'
VUE_APP_BASE_API = '/dev-api' VUE_APP_BASE_API = '/dev-api'
VUE_APP_BASE_URL = 'http://localhost:82' VUE_APP_BASE_URL = 'http://localhost:82'

@ -2,5 +2,6 @@
ENV = 'production' ENV = 'production'
# base api # base api
VUE_APP_BASE_PATH = '/mall'
VUE_APP_BASE_API = '/mobile-api' VUE_APP_BASE_API = '/mobile-api'
VUE_APP_BASE_URL = 'http://localhost:82' VUE_APP_BASE_URL = 'http://localhost:82'

@ -23,7 +23,7 @@
"lodash": "^4.17.21", "lodash": "^4.17.21",
"mockjs": "^1.1.0", "mockjs": "^1.1.0",
"normalize.css": "^8.0.1", "normalize.css": "^8.0.1",
"vant": "^2.12.13", "vant": "^2.12.54",
"vue": "^2.6.12", "vue": "^2.6.12",
"vue-clipboard2": "^0.3.1", "vue-clipboard2": "^0.3.1",
"vue-content-loader": "^0.2.3", "vue-content-loader": "^0.2.3",

@ -2,10 +2,10 @@
<div> <div>
<div class="tabbar"> <div class="tabbar">
<van-tabbar v-model="active" :active-color="variables.theme" :fixed="false" route> <van-tabbar v-model="active" :active-color="variables.theme" :fixed="false" route>
<van-tabbar-item to="/" icon="wap-home">首页</van-tabbar-item> <van-tabbar-item :to="{name: 'Home'}" icon="wap-home">首页</van-tabbar-item>
<van-tabbar-item to="/category" icon="bars">分类</van-tabbar-item> <van-tabbar-item :to="{name: 'Category'}" icon="bars">分类</van-tabbar-item>
<van-tabbar-item to="/cart" icon="shopping-cart">购物车</van-tabbar-item> <van-tabbar-item :to="{name: 'Cart'}" icon="shopping-cart">购物车</van-tabbar-item>
<van-tabbar-item to="/user" icon="manager">我的</van-tabbar-item> <van-tabbar-item :to="{name: 'User'}" icon="manager">我的</van-tabbar-item>
</van-tabbar> </van-tabbar>
</div> </div>
<div class="tabbar--placeholder" style="width:100%;height:50px" /> <div class="tabbar--placeholder" style="width:100%;height:50px" />

@ -1,5 +1,5 @@
// base color // base color
$theme: #1c99e2c0; $theme: #f1574f;
$bg-gradient: linear-gradient(90deg, #0af, #0085ff); $bg-gradient: linear-gradient(90deg, #0af, #0085ff);
$black: #333; $black: #333;
$gray: #0000008a; $gray: #0000008a;

@ -91,7 +91,6 @@ export default {
// //
onSubmit() { onSubmit() {
this.loading = true this.loading = true
console.log(process.env.VUE_APP_BASE_PATH)
this.$store this.$store
.dispatch('user/login', this.form) .dispatch('user/login', this.form)
.then(() => { .then(() => {

Loading…
Cancel
Save