{{title}}
-{{subTitle}}
- -
-
-
-
-
-
-
\ No newline at end of file
diff --git a/babel.config.js b/babel.config.js
deleted file mode 100644
index 91be244..0000000
--- a/babel.config.js
+++ /dev/null
@@ -1,5 +0,0 @@
-module.exports = {
- presets: [
- '@vue/app',
- ],
-};
diff --git a/deploy/preview.sh b/deploy/preview.sh
deleted file mode 100755
index ac67ed6..0000000
--- a/deploy/preview.sh
+++ /dev/null
@@ -1,27 +0,0 @@
-#!/usr/bin/env sh
-
-# 确保脚本抛出遇到的错误
-set -e
-
-# 生成静态文件
-npm run build
-
-# 进入生成的文件夹
-cd dist
-
-# 如果是发布到自定义域名
-# echo 'www.example.com' > CNAME
-
-git init
-git add -A
-git commit -m 'deploy'
-
-# 如果发布到 https://
-
- 当前版本: ${packJson.version}
-${dayjs(res.created_at).format('YYYY年M月D日')}更新 版本号: ${res.tag_name}
-此信息只在开发环境提示
-- - - 详细信息 - -
- `.trim(), - }); - }); - } - vm.$store.commit('d2adminUpdateSet', update); - vm.$store.commit('d2adminReleasesSet', res); - }) - .catch((err) => { - console.log('checkUpdate error', err); - }); -}; - -export default util; diff --git a/src/main.js b/src/main.js deleted file mode 100755 index d2fba3c..0000000 --- a/src/main.js +++ /dev/null @@ -1,79 +0,0 @@ -// polyfill -import 'babel-polyfill'; - -// ElementUI -import ElementUI from 'element-ui'; -import 'element-ui/lib/theme-chalk/index.css'; - -import util from '@/libs/util'; -import store from '@/store/index'; -// 框架内的路由 -import { frameInRoutes } from '@/router/routes'; -// font-awesome -import '@/assets/library/font-awesome-4.7.0/css/font-awesome.min.css'; -// 全局注册的组件 -import '@/components'; -// 异步请求库 -import '@/plugin/axios'; - -// Vue -import Vue from 'vue'; -import App from './App.vue'; - -// 路由 -import router from './router/index'; - -Vue.use(ElementUI); - -Vue.config.productionTip = false; - -Vue.prototype.$env = process.env.NODE_ENV; - -Vue.prototype.$baseUrl = process.env.BASE_URL; - -/* eslint-disable no-new */ - -new Vue({ - router, - store, - render: h => h(App), - created() { - // 处理路由 得到每一级的路由设置 - this.getAllTagFromRoutes(); - }, - mounted() { - // DB -> store 加载用户名 - this.$store.commit('d2adminUsernameLoad'); - // DB -> store 加载版本更新弹窗的设置 - this.$store.commit('d2adminUpdateNotifyLoad'); - // DB -> store 加载主题 - this.$store.commit('d2adminThemeLoad'); - // DB -> store 数据库加载上次退出时的多页列表 - this.$store.commit('d2adminPageOpenedListLoad'); - // D2Admin 开发环境检查更新 - util.checkUpdate(this); - // 完整版 - console.log('D2Admin 完整版项目地址:https://github.com/d2-projects/d2-admin'); - }, - methods: { - /** - * 处理路由 得到每一级的路由设置 - */ - getAllTagFromRoutes() { - // 所有加载在主框架内的页面 - const tagPool = []; - function push(routes) { - routes.forEach((route) => { - if (route.children) { - push(route.children); - } else { - const { meta, name, path } = route; - tagPool.push({ meta, name, path }); - } - }); - } - push(frameInRoutes); - this.$store.commit('d2adminTagPoolSet', tagPool); - }, - }, -}).$mount('#app'); diff --git a/src/menu/index.js b/src/menu/index.js deleted file mode 100644 index d51420a..0000000 --- a/src/menu/index.js +++ /dev/null @@ -1,58 +0,0 @@ -const businessClass1 = { - path: '/business/class1', - title: '功能 1', - icon: 'cube', - children: (pre => [ - { path: `${pre}index`, title: '首页', icon: 'home' }, - { path: `${pre}page1`, title: '页面 1', icon: 'paperclip' }, - { path: `${pre}page2`, title: '页面 2', icon: 'paperclip' }, - ])('/business/class1/'), -}; - -const businessClass2 = { - path: '/business/class2', - title: '功能 2', - icon: 'cube', - children: (pre => [ - { path: `${pre}index`, title: '首页', icon: 'home' }, - { - title: '功能 2-1', - icon: 'cube', - children: [ - { path: `${pre}class2-1/page1`, title: '页面 1', icon: 'paperclip' }, - { path: `${pre}class2-1/page2`, title: '页面 2', icon: 'paperclip' }, - ], - }, - { path: `${pre}page1`, title: '页面 1', icon: 'paperclip' }, - { path: `${pre}page2`, title: '页面 2', icon: 'paperclip' }, - ])('/business/class2/'), -}; - -const setting = { - path: '/core/setting', - title: '设置', - icon: 'cog', - children: (pre => [ - { path: `${pre}index`, title: '设置首页', icon: 'home' }, - { path: `${pre}releases`, title: '版本', icon: 'info-circle' }, - ])('/core/setting/'), -}; - -// 菜单 侧边栏 -export const side = [ - businessClass1, - businessClass2, - setting, -]; - -// 菜单 顶栏 -export default [ - { - path: '/index', - title: '首页', - icon: 'home', - }, - businessClass1, - businessClass2, - setting, -]; diff --git a/src/pages/business/class1/index/index.vue b/src/pages/business/class1/index/index.vue deleted file mode 100644 index 0e4189e..0000000 --- a/src/pages/business/class1/index/index.vue +++ /dev/null @@ -1,9 +0,0 @@ - -
-
-
-
-
-
-
-
- 更新日期 {{dayjs(releases.created_at).format('YYYY年M月D日')}}
- - {{releases.html_url}} - -