From 47404574f74cff0832c0914210572f6e99361963 Mon Sep 17 00:00:00 2001 From: yujialong <479214531@qq.com> Date: Fri, 4 Mar 2022 17:49:06 +0800 Subject: [PATCH] =?UTF-8?q?=E7=B3=BB=E7=BB=9F=E8=AE=BE=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/assets/css/main.css | 37 ++ src/components/Sidebar.vue | 5 + src/components/codemirror.vue | 5 +- src/router/index.js | 10 + src/views/serve/backstage/index.vue | 38 -- src/views/system/dic.vue | 270 ++++++++++++ src/views/system/index.vue | 69 ++++ src/views/system/log.vue | 263 ++++++++++++ src/views/system/manageLog.vue | 263 ++++++++++++ src/views/system/role.vue | 270 ++++++++++++ src/views/system/staff.vue | 620 ++++++++++++++++++++++++++++ src/views/system/staffSide.vue | 387 +++++++++++++++++ 12 files changed, 2198 insertions(+), 39 deletions(-) create mode 100644 src/views/system/dic.vue create mode 100644 src/views/system/index.vue create mode 100644 src/views/system/log.vue create mode 100644 src/views/system/manageLog.vue create mode 100644 src/views/system/role.vue create mode 100644 src/views/system/staff.vue create mode 100644 src/views/system/staffSide.vue diff --git a/src/assets/css/main.css b/src/assets/css/main.css index 079740a..ff56652 100644 --- a/src/assets/css/main.css +++ b/src/assets/css/main.css @@ -61,6 +61,12 @@ li { color: #585858; border-left: 3px solid #9278ff; } +.page { + position: relative; + padding: 24px; + background-color: #fff; + border-radius: 8px; +} .tool { display: flex; justify-content: space-between; @@ -84,6 +90,37 @@ li { white-space: nowrap; } +.tabs { + display: flex; + align-items: center; + padding: 0 24px; + border-bottom: 1px solid rgba(0, 0, 0, .06); +} +.tabs .item { + position: relative; + padding: 20px 0; + margin-right: 40px; + font-size: 16px; + color: rgba(0, 0, 0, 0.65); + cursor: pointer; +} +.tabs .item.active { + font-weight: 500; + color: rgba(0, 0, 0, 0.85); +} +.tabs .item:after { + content: ''; + position: absolute; + bottom: 0; + left: 0; + width: 100%; + height: 3px; + border-bottom: 3px solid transparent; + border-radius: 2px; +} +.tabs .item.active:after { + border-bottom-color: #9278ff; +} .crumbs { margin: 10px 0; diff --git a/src/components/Sidebar.vue b/src/components/Sidebar.vue index 180f3ad..91385a6 100644 --- a/src/components/Sidebar.vue +++ b/src/components/Sidebar.vue @@ -85,6 +85,11 @@ export default { index: 'configure', title: '服务配置' }, + { + icon: 'el-icon-office-building', + index: 'system', + title: '系统配置' + }, ], onRoutes:'customer' }; diff --git a/src/components/codemirror.vue b/src/components/codemirror.vue index e7fb26a..4578605 100644 --- a/src/components/codemirror.vue +++ b/src/components/codemirror.vue @@ -133,7 +133,7 @@ export default { // 页面加载完后重置编辑框大小 ready() { const code = this.$refs.codemirror.codemirror - code.setSize("auto", "calc(100vh - 167px)"); + code.setSize("auto", "calc(100vh - 400px)"); code.on('keypress', function() { // 显示智能提示 code.showHint() @@ -151,6 +151,9 @@ export default { this.loadIns = Loading.service({ background: 'transparent' }) + code = code.replace(/\.savefig\(([\u4e00-\u9fa5\w]*?['"])/mg, str => { + return str + Date.now() + }) // 把代码传给后端,在后端运行Python代码 this.$post(this.api.runPythonCode, { code diff --git a/src/router/index.js b/src/router/index.js index 738b95e..5ec8759 100644 --- a/src/router/index.js +++ b/src/router/index.js @@ -107,6 +107,16 @@ let router = new Router({ component: () => import( '../views/data/Data.vue'), // meta: { title: '数据管理' } }, + { + path: '/system', + component: () => import( '../views/system'), + // meta: { title: '数据管理' } + }, + { + path: '/manageLog', + component: () => import( '../views/system/manageLog'), + // meta: { title: '数据管理' } + }, { path: '/permission', component: () => import('../views/customer/Permission.vue'), diff --git a/src/views/serve/backstage/index.vue b/src/views/serve/backstage/index.vue index fdf1fa2..57d18f4 100644 --- a/src/views/serve/backstage/index.vue +++ b/src/views/serve/backstage/index.vue @@ -46,43 +46,5 @@ export default { \ No newline at end of file diff --git a/src/views/system/dic.vue b/src/views/system/dic.vue new file mode 100644 index 0000000..b471bfe --- /dev/null +++ b/src/views/system/dic.vue @@ -0,0 +1,270 @@ + + + + \ No newline at end of file diff --git a/src/views/system/index.vue b/src/views/system/index.vue new file mode 100644 index 0000000..a66ca2b --- /dev/null +++ b/src/views/system/index.vue @@ -0,0 +1,69 @@ + + + + + \ No newline at end of file diff --git a/src/views/system/log.vue b/src/views/system/log.vue new file mode 100644 index 0000000..c0ad681 --- /dev/null +++ b/src/views/system/log.vue @@ -0,0 +1,263 @@ + + + + \ No newline at end of file diff --git a/src/views/system/manageLog.vue b/src/views/system/manageLog.vue new file mode 100644 index 0000000..c0ad681 --- /dev/null +++ b/src/views/system/manageLog.vue @@ -0,0 +1,263 @@ + + + + \ No newline at end of file diff --git a/src/views/system/role.vue b/src/views/system/role.vue new file mode 100644 index 0000000..deb9baf --- /dev/null +++ b/src/views/system/role.vue @@ -0,0 +1,270 @@ + + + + \ No newline at end of file diff --git a/src/views/system/staff.vue b/src/views/system/staff.vue new file mode 100644 index 0000000..151527e --- /dev/null +++ b/src/views/system/staff.vue @@ -0,0 +1,620 @@ + + + \ No newline at end of file diff --git a/src/views/system/staffSide.vue b/src/views/system/staffSide.vue new file mode 100644 index 0000000..c77057f --- /dev/null +++ b/src/views/system/staffSide.vue @@ -0,0 +1,387 @@ + + +