diff --git a/frontend/src/api/commonAjax.js b/frontend/src/api/commonAjax.js new file mode 100644 index 0000000000..ea149fb020 --- /dev/null +++ b/frontend/src/api/commonAjax.js @@ -0,0 +1,38 @@ +import request from '@/utils/request' + +export function post(url, data) { + return request({ + url: url, + method: 'post', + loading: true, + data + }) +} + +export function get(url) { + return request({ + url: url, + method: 'get', + loading: true + }) +} + +export function fileUpload(url, file, files, param) { + const formData = new FormData() + if (file) { + formData.append('file', file) + } + if (files) { + files.forEach(f => { + formData.append('files', f) + }) + } + formData.append('request', new Blob([JSON.stringify(param)], { type: 'application/json' })) + return request({ + method: 'POST', + loading: true, + url: url, + data: formData + }) +} +export default { fileUpload } diff --git a/frontend/src/components/RightPanel/index.vue b/frontend/src/components/RightPanel/index.vue index 55e8c1e5c0..9f555c5871 100644 --- a/frontend/src/components/RightPanel/index.vue +++ b/frontend/src/components/RightPanel/index.vue @@ -63,6 +63,7 @@ export default { closeSidebar(evt) { const parent = evt.target.closest('.rightPanel') if (!parent) { + debugger this.show = false window.removeEventListener('click', this.closeSidebar) } diff --git a/frontend/src/components/canvas/components/Toolbar.vue b/frontend/src/components/canvas/components/Toolbar.vue index 9342e441e7..15665d8499 100644 --- a/frontend/src/components/canvas/components/Toolbar.vue +++ b/frontend/src/components/canvas/components/Toolbar.vue @@ -12,6 +12,10 @@ 画布比例 % + + + + @@ -38,16 +42,12 @@ - - - + + diff --git a/frontend/src/views/panel/SubjectSetting/Slider.vue b/frontend/src/views/panel/SubjectSetting/Slider.vue new file mode 100644 index 0000000000..ad1b694fbe --- /dev/null +++ b/frontend/src/views/panel/SubjectSetting/Slider.vue @@ -0,0 +1,251 @@ + + + + + L + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + R + + + + + + + + + + + B + + + + + + 保存个人主题 + + + + + + + + diff --git a/frontend/src/views/panel/SubjectSetting/SubjectTemplateItem.vue b/frontend/src/views/panel/SubjectSetting/SubjectTemplateItem.vue new file mode 100644 index 0000000000..b1d5398989 --- /dev/null +++ b/frontend/src/views/panel/SubjectSetting/SubjectTemplateItem.vue @@ -0,0 +1,157 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Preset style 1 + + + + + + + + diff --git a/frontend/src/views/panel/SubjectSetting/index.vue b/frontend/src/views/panel/SubjectSetting/index.vue new file mode 100644 index 0000000000..2daf7bcf69 --- /dev/null +++ b/frontend/src/views/panel/SubjectSetting/index.vue @@ -0,0 +1,90 @@ + + + 仪表盘主题 + + + + + + + + + + + + + + + + + 控制反馈:通过界面样式和交互动效让用户可以清晰的感知自己的操作; + 页面反馈:操作后,通过页面元素的变化清晰地展现当前状态。 + + + 简化流程:设计简洁直观的操作流程; + 清晰明确:语言表达清晰且表意明确,让用户快速理解进而作出决策; + 帮助用户识别:界面简单直白,让用户快速识别而非回忆,减少用户记忆负担。 + + + 用户决策:根据场景可给予用户操作建议或安全提示,但不能代替用户进行决策; + 结果可控:用户可以自由的进行操作,包括撤销、回退和终止当前操作等。 + + + + + + + + + diff --git a/frontend/src/views/panel/edit/index.vue b/frontend/src/views/panel/edit/index.vue index 037ff93909..8769dfb7f4 100644 --- a/frontend/src/views/panel/edit/index.vue +++ b/frontend/src/views/panel/edit/index.vue @@ -6,7 +6,7 @@ 名称:{{ panelInfo.name || '测试仪表板' }} - + @@ -47,8 +47,9 @@ - - + + + @@ -112,6 +113,7 @@ import DeAsideContainer from '@/components/dataease/DeAsideContainer' import { addClass, removeClass } from '@/utils' import FilterGroup from '../filter' import ViewSelect from '../ViewSelect' +import SubjectSetting from '../SubjectSetting' import bus from '@/utils/bus' import Editor from '@/components/canvas/components/Editor/index' import { deepCopy } from '@/components/canvas/utils/utils' @@ -139,7 +141,8 @@ export default { ViewSelect, Editor, Toolbar, - FilterDialog + FilterDialog, + SubjectSetting }, data() { return { @@ -192,6 +195,7 @@ export default { mounted() { this.insertToBody() bus.$on('component-on-drag', () => { + debugger this.show = false }) @@ -225,6 +229,7 @@ export default { this.$router.replace('/panel/index') }, showPanel(type) { + debugger this.show = !this.show this.showIndex = type }, @@ -234,7 +239,10 @@ export default { closeSidebar(evt) { const parent = evt.target.closest('.button-div-class') const self = evt.target.closest('.leftPanel') - if (!parent && !self) { + // 点击样式按钮 排除 + const stick = evt.target.closest('.el-icon-magic-stick') + if (!parent && !self && !stick) { + debugger this.show = false window.removeEventListener('click', this.closeSidebar) this.showIndex = -1 @@ -283,6 +291,7 @@ export default { this.currentFilterCom.style.left = e.offsetX this.currentFilterCom.id = newComponentId if (this.currentWidget.filterDialog) { + debugger this.show = false this.openFilterDiolog() return @@ -392,7 +401,7 @@ export default { .leftPanel { width: 100%; - max-width: 240px; + max-width: 300px; height: calc(100vh - 91px); position: fixed; top: 91px; @@ -401,14 +410,14 @@ export default { transition: all .25s cubic-bezier(.7, .3, .1, 1); transform: translate(100%); background: #fff; - z-index: 40000; + z-index: 1003; } .show { transition: all .3s cubic-bezier(.7, .3, .1, 1); .leftPanel-background { - z-index: 20000; + z-index: 1002; opacity: 1; width: 100%; height: 100%; diff --git a/frontend/src/views/panel/panel.js b/frontend/src/views/panel/panel.js new file mode 100644 index 0000000000..f021c608d7 --- /dev/null +++ b/frontend/src/views/panel/panel.js @@ -0,0 +1,4 @@ +export const DEFAULT_BACKGROUND_COLOR = { + color: '#ffffff', + image: null +} diff --git a/frontend/src/views/panel/preview/index.vue b/frontend/src/views/panel/preview/index.vue index 7fd9a045f7..1af7b339e3 100644 --- a/frontend/src/views/panel/preview/index.vue +++ b/frontend/src/views/panel/preview/index.vue @@ -88,14 +88,14 @@ export default { transition: all .25s cubic-bezier(.7, .3, .1, 1); transform: translate(100%); background: #fff; - z-index: 40000; + z-index: 1003; } .show { transition: all .3s cubic-bezier(.7, .3, .1, 1); .leftPanel-background { - z-index: 20000; + z-index: 1002; opacity: 1; width: 100%; height: 100%; diff --git a/frontend/src/views/system/systemParamSettings/BaseSetting.vue b/frontend/src/views/system/systemParamSettings/BaseSetting.vue deleted file mode 100644 index c57a9e9edc..0000000000 --- a/frontend/src/views/system/systemParamSettings/BaseSetting.vue +++ /dev/null @@ -1,201 +0,0 @@ - - - {{ systemParams }} - - - - - - - - {{ $t('commons.upload') }} - - - - {{ $t('commons.upload') }} - - - - - - - - - - - - {{ $t('commons.edit') }} - - {{ $t('commons.save') }} - - {{ $t('commons.cancel') }} - - - - - - - diff --git a/frontend/src/views/system/systemParamSettings/EmailSetting.vue b/frontend/src/views/system/systemParamSettings/EmailSetting.vue index 8917a10545..7ec25228fa 100644 --- a/frontend/src/views/system/systemParamSettings/EmailSetting.vue +++ b/frontend/src/views/system/systemParamSettings/EmailSetting.vue @@ -98,6 +98,8 @@