From 616602928af3a784b1ff61b3898f3f70962496f1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=87=95=E9=B9=8F?= Date: Thu, 3 Dec 2020 11:00:06 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E9=85=8D=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- public/favicon.ico | Bin 0 -> 1150 bytes public/index.html | 20 +++++++++++ src/app/App.vue | 62 ++++++++++++++++++++++++++++++++ src/app/main.js | 28 +++++++++++++++ src/{subpage => app}/router.js | 4 +-- src/index/App.vue | 1 + src/index/router.js | 4 +-- src/router/router.js | 26 ++++++++++++++ src/subpage/App.vue | 29 --------------- src/subpage/main.js | 12 ------- src/subpage/views/About.vue | 5 --- src/subpage/views/Home.vue | 21 ----------- src/{index => }/views/About.vue | 0 src/{index => }/views/Home.vue | 0 vue.config.js | 6 ++-- 15 files changed, 144 insertions(+), 74 deletions(-) create mode 100644 public/favicon.ico create mode 100644 public/index.html create mode 100644 src/app/App.vue create mode 100644 src/app/main.js rename src/{subpage => app}/router.js (78%) create mode 100644 src/router/router.js delete mode 100644 src/subpage/App.vue delete mode 100644 src/subpage/main.js delete mode 100644 src/subpage/views/About.vue delete mode 100644 src/subpage/views/Home.vue rename src/{index => }/views/About.vue (100%) rename src/{index => }/views/Home.vue (100%) diff --git a/public/favicon.ico b/public/favicon.ico new file mode 100644 index 0000000000000000000000000000000000000000..c7b9a43c8cd16d0b434adaf513fcacb340809a11 GIT binary patch literal 1150 zcmchVOGsN$5QZm2NTI$erQpKHrdQX(jn+pVxKN`Ng)RzW5+8_2Xb@Y)Dkd6tq9V8u z3WAh^C@KZ1kA;tohzs}b3NC_*QmUXr$oP*rH(2mdT{z*(KX=aj=bX$9kqMvFRKj;Q zwI&d~A);J>5-PDega~WT5us%#Dc(Y}C4WpP?+fS;FaZ*z_CFzgiW=w{I02=q_TUz( z?=^H2uwoIK1n%|Ay21~QgjV1emYtWttJdz^L#=DjJ@Ex*9UPc*7<=rZo*_NAh4PxA zqkso~Ioa1y$e+3kIkXi29YNLi&lW}vY6C}ut4{8ou(7w=$_=$v{yJ$h?y!&bJfq*( zL_NQRF37$6e>%9erGV?p^lRFD?|5J_eupXaS;QluyrOmBT>PJhirMYb*i?(4Tf=j~?VvnUlY_ zDCVuuk3E&T9aP~Cr-0i-MaKUjf_|U!=R&t}_CfD=d${p~HH`BPaqb9aXT}UI$iGRg z>0^GlZ`vM4?;$*LhfI(RG|XK4GF+@-W*W}YJT5&2N_ZyZuaM_Ry=%PWx>r0P(Rc?> jRc4}SfGA>*agjwN{7E7DEm(*)%rSx{B0<6wBoglxJAy|R literal 0 HcmV?d00001 diff --git a/public/index.html b/public/index.html new file mode 100644 index 0000000..b395b3a --- /dev/null +++ b/public/index.html @@ -0,0 +1,20 @@ + + + + + + + + + 首页 + + + + +
+ + + + \ No newline at end of file diff --git a/src/app/App.vue b/src/app/App.vue new file mode 100644 index 0000000..77c736b --- /dev/null +++ b/src/app/App.vue @@ -0,0 +1,62 @@ + + + diff --git a/src/app/main.js b/src/app/main.js new file mode 100644 index 0000000..2ef8c82 --- /dev/null +++ b/src/app/main.js @@ -0,0 +1,28 @@ +import Vue from 'vue' +import App from './App.vue' +import router from './router' +import store from '@/store' + +Vue.config.productionTip = false + + +router.beforeEach((to, from, next) => { + if (!to.query.appId) { + if (from.query.appId) { + to.query.appId = from.query.appId + } else { + to.query.appId = window.location.href.match(/appId=(.*)/)[1] + } + } + next() +}) + +router.afterEach((to, from) => { + +}) + +new Vue({ + router, + store, + render: h => h(App) +}).$mount('#app') diff --git a/src/subpage/router.js b/src/app/router.js similarity index 78% rename from src/subpage/router.js rename to src/app/router.js index 9e03a62..b855f2e 100644 --- a/src/subpage/router.js +++ b/src/app/router.js @@ -1,7 +1,7 @@ import Vue from 'vue' import Router from 'vue-router' -import Home from './views/Home.vue' -import About from './views/About.vue' +import Home from '@/views/Home.vue' +import About from '@/views/About.vue' Vue.use(Router) diff --git a/src/index/App.vue b/src/index/App.vue index 97c3ca7..74adaa8 100644 --- a/src/index/App.vue +++ b/src/index/App.vue @@ -1,6 +1,7 @@