许成详 6 年前
父节点
当前提交
05b9b1d3f1

+ 2104
- 1014
package-lock.json
文件差异内容过多而无法显示
查看文件


+ 6
- 1
package.json 查看文件

9
     "build": "node build/build.js"
9
     "build": "node build/build.js"
10
   },
10
   },
11
   "dependencies": {
11
   "dependencies": {
12
-    "vue": "^2.0.1"
12
+    "node-sass": "^4.9.3",
13
+    "sass-loader": "^7.1.0",
14
+    "vant": "^1.1.16",
15
+    "vue": "^2.0.1",
16
+    "vue-router": "^3.0.1",
17
+    "vuex": "^3.0.1"
13
   },
18
   },
14
   "devDependencies": {
19
   "devDependencies": {
15
     "autoprefixer": "^6.4.0",
20
     "autoprefixer": "^6.4.0",

+ 4
- 0
src/module/sales/sales.js 查看文件

1
 import Vue from 'vue'
1
 import Vue from 'vue'
2
 import App from './App'
2
 import App from './App'
3
+import Vant from 'vant'
4
+import 'vant/lib/vant-css/index.css'
5
+
6
+Vue.use(Vant)
3
 
7
 
4
 /* eslint-disable no-new */
8
 /* eslint-disable no-new */
5
 new Vue({
9
 new Vue({

+ 3
- 1
src/module/user/App.vue 查看文件

1
 <template>
1
 <template>
2
-  <div id="app"></div>
2
+  <div id="app">
3
+    <router-view></router-view>
4
+  </div>
3
 </template>
5
 </template>
4
 
6
 
5
 <script>
7
 <script>

+ 17
- 0
src/module/user/router.js 查看文件

1
+import Vue from 'vue'
2
+import Router from 'vue-router'
3
+
4
+import userCenter from './userCenter/index'
5
+
6
+Vue.use(Router)
7
+
8
+const router = new Router({
9
+  routes: [{
10
+    path: '/userCenter',
11
+    name: 'userCenter',
12
+    component: userCenter,
13
+    children: []
14
+  }]
15
+})
16
+
17
+export default router

+ 2
- 1
src/module/user/user.html 查看文件

2
 <html>
2
 <html>
3
 <head>
3
 <head>
4
   <meta charset="utf-8">
4
   <meta charset="utf-8">
5
-  <title>vue-demo</title>
5
+  <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no" charset="utf-8" />
6
+  <title>城的空间</title>
6
 </head>
7
 </head>
7
 <body>
8
 <body>
8
 <div id="app"></div>
9
 <div id="app"></div>

+ 11
- 1
src/module/user/user.js 查看文件

1
 import Vue from 'vue'
1
 import Vue from 'vue'
2
 import App from './App'
2
 import App from './App'
3
+import Vant from 'vant'
4
+import 'vant/lib/vant-css/index.css'
5
+import router from './router'
6
+import store from '../../store/index'
7
+import Vuex from 'vuex'
8
+
9
+Vue.use(Vant)
10
+Vue.use(Vuex)
3
 
11
 
4
 /* eslint-disable no-new */
12
 /* eslint-disable no-new */
5
 new Vue({
13
 new Vue({
6
   el: '#app',
14
   el: '#app',
7
   template: '<App/>',
15
   template: '<App/>',
8
-  components: { App }
16
+  components: { App },
17
+  router,
18
+  store,
9
 })
19
 })

+ 34
- 0
src/module/user/userCenter/index.vue 查看文件

1
+<template>
2
+  <div class="mainPage">
3
+    用户中心
4
+  </div>
5
+</template>
6
+
7
+<script>
8
+
9
+export default {
10
+  name: '',
11
+  data () {
12
+    return {
13
+      
14
+    }
15
+  },
16
+  computed: {
17
+    
18
+  },
19
+  components: {
20
+    
21
+  },
22
+  created () {
23
+    
24
+  },
25
+  methods: {
26
+    
27
+  }
28
+}
29
+</script>
30
+
31
+<!-- Add "scoped" attribute to limit CSS to this component only -->
32
+<style lang="scss" scoped>
33
+@import "page.scss";
34
+</style>

+ 0
- 0
src/module/user/userCenter/page.scss 查看文件


+ 1
- 0
src/store/index.js 查看文件

1
+