add platform
This commit is contained in:
1 parent
fc378d4903
commit
f805eaaa1e
8 files changed
+99
-24
No files matched your search
@@ -1,12 +1,12 @@
|
|||||||
<template>
|
<template>
|
||||||
<el-menu class="h-full">
|
<el-menu class="h-full" router>
|
||||||
<el-menu-item>
|
<el-menu-item index="/content/article">
|
||||||
<el-icon class="mr-2">
|
<el-icon class="mr-2">
|
||||||
<document />
|
<document />
|
||||||
</el-icon>
|
</el-icon>
|
||||||
<template #title>{{ $t('content.nav.article') }}</template>
|
<template #title>{{ $t('content.nav.article') }}</template>
|
||||||
</el-menu-item>
|
</el-menu-item>
|
||||||
<el-menu-item>
|
<el-menu-item index="/content/platform">
|
||||||
<el-icon class="mr-2">
|
<el-icon class="mr-2">
|
||||||
<box />
|
<box />
|
||||||
</el-icon>
|
</el-icon>
|
||||||
@@ -17,11 +17,20 @@
|
|||||||
|
|
||||||
<script lang="ts">
|
<script lang="ts">
|
||||||
import { Document, Box } from '@element-plus/icons';
|
import { Document, Box } from '@element-plus/icons';
|
||||||
|
import routes from '@/router/content';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
Document,
|
Document,
|
||||||
Box
|
Box
|
||||||
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
routes
|
||||||
|
};
|
||||||
|
},
|
||||||
|
mounted() {
|
||||||
|
console.log(routes);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
@@ -19,4 +19,5 @@ const i18n = createI18n({
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
export const t = i18n.global.t;
|
||||||
export default i18n;
|
export default i18n;
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
<template>
|
||||||
|
<div>dd</div>
|
||||||
|
</template>
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
<template>
|
||||||
|
<div>dd</div>
|
||||||
|
</template>
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
<template>
|
||||||
|
|
||||||
|
</template>
|
||||||
@@ -0,0 +1,39 @@
|
|||||||
|
<template>
|
||||||
|
<el-card shadow="hover">
|
||||||
|
<el-table :data="tableData" style="width: 100%" height="250">
|
||||||
|
<el-table-column fixed prop="date" label="日期" width="150"> </el-table-column>
|
||||||
|
<el-table-column prop="name" label="姓名" width="120"> </el-table-column>
|
||||||
|
<el-table-column prop="province" label="省份" width="120"> </el-table-column>
|
||||||
|
<el-table-column prop="city" label="市区" width="320"> </el-table-column>
|
||||||
|
<el-table-column prop="address" label="地址" width="600"> </el-table-column>
|
||||||
|
<el-table-column prop="zip" label="邮编" width="120"> </el-table-column>
|
||||||
|
</el-table>
|
||||||
|
</el-card>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script lang="ts">
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
tableData: [
|
||||||
|
{
|
||||||
|
date: '2016-05-03',
|
||||||
|
name: '王小虎',
|
||||||
|
province: '上海',
|
||||||
|
city: '普陀区',
|
||||||
|
address: '上海市普陀区金沙江路 1518 弄',
|
||||||
|
zip: 200333
|
||||||
|
},
|
||||||
|
{
|
||||||
|
date: '2016-05-02',
|
||||||
|
name: '王小虎',
|
||||||
|
province: '上海',
|
||||||
|
city: '普陀区',
|
||||||
|
address: '上海市普陀区金沙江路 1518 弄',
|
||||||
|
zip: 200333
|
||||||
|
}
|
||||||
|
]
|
||||||
|
};
|
||||||
|
}
|
||||||
|
};
|
||||||
|
</script>
|
||||||
@@ -0,0 +1,36 @@
|
|||||||
|
import i18n, { t } from '../i18n';
|
||||||
|
|
||||||
|
export default {
|
||||||
|
path: '/content',
|
||||||
|
name: 'content',
|
||||||
|
meta: {
|
||||||
|
title: t('common.nav.content')
|
||||||
|
},
|
||||||
|
component: () => import('@/layouts/Content.vue'),
|
||||||
|
children: [
|
||||||
|
{
|
||||||
|
path: 'editor',
|
||||||
|
name: 'editor',
|
||||||
|
meta: {
|
||||||
|
title: t('common.nav.editor')
|
||||||
|
},
|
||||||
|
component: () => import('@/pages/content/Editor.vue')
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: 'article',
|
||||||
|
name: 'article',
|
||||||
|
meta: {
|
||||||
|
title: t('common.nav.article')
|
||||||
|
},
|
||||||
|
component: () => import('@/pages/content/Article.vue')
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: 'platform',
|
||||||
|
name: 'platform',
|
||||||
|
meta: {
|
||||||
|
title: t('common.nav.platform')
|
||||||
|
},
|
||||||
|
component: () => import('@/pages/content/platform/Index.vue')
|
||||||
|
}
|
||||||
|
]
|
||||||
|
};
|
||||||
+2
-21
@@ -1,7 +1,5 @@
|
|||||||
import { createRouter, createWebHistory, createWebHashHistory } from 'vue-router';
|
import { createRouter, createWebHistory, createWebHashHistory } from 'vue-router';
|
||||||
import i18n from '../i18n';
|
import content from './content';
|
||||||
|
|
||||||
const t = i18n.global.t;
|
|
||||||
|
|
||||||
const routes = [
|
const routes = [
|
||||||
{
|
{
|
||||||
@@ -9,24 +7,7 @@ const routes = [
|
|||||||
name: 'home',
|
name: 'home',
|
||||||
component: () => import('@/pages/Home.vue')
|
component: () => import('@/pages/Home.vue')
|
||||||
},
|
},
|
||||||
{
|
content
|
||||||
path: '/content',
|
|
||||||
name: 'content',
|
|
||||||
meta: {
|
|
||||||
title: t('common.nav.content')
|
|
||||||
},
|
|
||||||
component: () => import('@/layouts/Content.vue'),
|
|
||||||
children: [
|
|
||||||
{
|
|
||||||
path: 'editor',
|
|
||||||
name: 'editor',
|
|
||||||
meta: {
|
|
||||||
title: t('common.nav.editor')
|
|
||||||
},
|
|
||||||
component: () => import('@/pages/content/Editor.vue')
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
];
|
];
|
||||||
|
|
||||||
const router = createRouter({
|
const router = createRouter({
|
||||||
|
|||||||
Reference in new issue
Block a user