mirror of https://gitee.com/xiaonuobase/snowy
【更新】兼容formStyle
parent
2c6ec39122
commit
1ea621bf5a
|
@ -80,8 +80,8 @@
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
<a-form-item label="表单风格">
|
<a-form-item label="表单风格">
|
||||||
<a-select
|
<a-select
|
||||||
v-model:value="formStyle"
|
:value="formStyle"
|
||||||
style="width: 80px"
|
class="w-[80px]"
|
||||||
size="small"
|
size="small"
|
||||||
:options="xnFormStyleOptions"
|
:options="xnFormStyleOptions"
|
||||||
@change="formStyleChange"
|
@change="formStyleChange"
|
||||||
|
@ -172,7 +172,8 @@
|
||||||
'breadcrumbOpen',
|
'breadcrumbOpen',
|
||||||
'moduleUnfoldOpen',
|
'moduleUnfoldOpen',
|
||||||
'topHanderThemeColorOpen',
|
'topHanderThemeColorOpen',
|
||||||
'topHanderThemeColorSpread'
|
'topHanderThemeColorSpread',
|
||||||
|
'formStyle'
|
||||||
])
|
])
|
||||||
},
|
},
|
||||||
mounted() {},
|
mounted() {},
|
||||||
|
@ -209,7 +210,7 @@
|
||||||
// 切换表单风格
|
// 切换表单风格
|
||||||
formStyleChange(value) {
|
formStyleChange(value) {
|
||||||
tool.data.set('SNOWY_FORM_STYLE', value)
|
tool.data.set('SNOWY_FORM_STYLE', value)
|
||||||
this.$store.commit('SET_formStyle', value)
|
this.globalStore.setFormStyle(value)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
|
@ -42,6 +42,8 @@ export const globalStore = defineStore({
|
||||||
theme: getCacheConfig('SNOWY_THEME'),
|
theme: getCacheConfig('SNOWY_THEME'),
|
||||||
// 主题颜色
|
// 主题颜色
|
||||||
themeColor: toolDataGet('SNOWY_THEME_COLOR') || config.COLOR,
|
themeColor: toolDataGet('SNOWY_THEME_COLOR') || config.COLOR,
|
||||||
|
// 整体表单风格
|
||||||
|
formStyle: getCacheConfig('SNOWY_FORM_STYLE'),
|
||||||
// 用户信息
|
// 用户信息
|
||||||
userInfo: toolDataGet('USER_INFO') || {},
|
userInfo: toolDataGet('USER_INFO') || {},
|
||||||
// 系统配置
|
// 系统配置
|
||||||
|
@ -72,23 +74,8 @@ export const globalStore = defineStore({
|
||||||
toggleConfig(key) {
|
toggleConfig(key) {
|
||||||
this[key] = !this[key]
|
this[key] = !this[key]
|
||||||
},
|
},
|
||||||
toggle_SideUniqueOpen() {
|
setFormStyle(key) {
|
||||||
this.sideUniqueOpen = !this.sideUniqueOpen
|
this.formStyle = key
|
||||||
},
|
|
||||||
toggle_LayoutTagsOpen() {
|
|
||||||
this.layoutTagsOpen = !this.layoutTagsOpen
|
|
||||||
},
|
|
||||||
toggle_BreadcrumbOpen() {
|
|
||||||
this.breadcrumbOpen = !this.breadcrumbOpen
|
|
||||||
},
|
|
||||||
toggle_TopHanderThemeColorOpen() {
|
|
||||||
this.topHanderThemeColorOpen = !this.topHanderThemeColorOpen
|
|
||||||
},
|
|
||||||
toggle_TopHanderThemeColorSpread() {
|
|
||||||
this.topHanderThemeColorSpread = !this.topHanderThemeColorSpread
|
|
||||||
},
|
|
||||||
toggle_ModuleUnfoldOpen() {
|
|
||||||
this.moduleUnfoldOpen = !this.moduleUnfoldOpen
|
|
||||||
},
|
},
|
||||||
setUserInfo(key) {
|
setUserInfo(key) {
|
||||||
this.userInfo = key
|
this.userInfo = key
|
||||||
|
|
Loading…
Reference in New Issue