From c2208270bd47608abc0733e9d5e5fbddf3b36642 Mon Sep 17 00:00:00 2001
From: 疯狂的狮子li <15040126243@163.com>
Date: 星期二, 31 一月 2023 14:10:56 +0800
Subject: [PATCH] fix 修复 错误修改 sql 用户数据
---
ruoyi-ui/src/components/ThemePicker/index.vue | 26 ++++++++++++--------------
1 files changed, 12 insertions(+), 14 deletions(-)
diff --git a/ruoyi-ui/src/components/ThemePicker/index.vue b/ruoyi-ui/src/components/ThemePicker/index.vue
index 3879c5a..1714e1f 100644
--- a/ruoyi-ui/src/components/ThemePicker/index.vue
+++ b/ruoyi-ui/src/components/ThemePicker/index.vue
@@ -31,19 +31,21 @@
immediate: true
},
async theme(val) {
+ await this.setTheme(val)
+ }
+ },
+ created() {
+ if(this.defaultTheme !== ORIGINAL_THEME) {
+ this.setTheme(this.defaultTheme)
+ }
+ },
+
+ methods: {
+ async setTheme(val) {
const oldVal = this.chalk ? this.theme : ORIGINAL_THEME
if (typeof val !== 'string') return
const themeCluster = this.getThemeCluster(val.replace('#', ''))
const originalCluster = this.getThemeCluster(oldVal.replace('#', ''))
- console.log(themeCluster, originalCluster)
-
- const $message = this.$message({
- message: ' Compiling the theme',
- customClass: 'theme-message',
- type: 'success',
- duration: 0,
- iconClass: 'el-icon-loading'
- })
const getHandler = (variable, id) => {
return () => {
@@ -81,12 +83,8 @@
})
this.$emit('change', val)
+ },
- $message.close()
- }
- },
-
- methods: {
updateStyle(style, oldCluster, newCluster) {
let newStyle = style
oldCluster.forEach((color, index) => {
--
Gitblit v1.9.3