mirror of https://gitee.com/xiaonuobase/snowy
【更新】设置抽屉内的一些bug修复,以及少数功能代码优化
parent
ea0ffa53ef
commit
9d0c481f85
|
@ -10,8 +10,8 @@
|
|||
"license": "Apache-2.0",
|
||||
"author": "yubaoshan",
|
||||
"scripts": {
|
||||
"serve": "vite",
|
||||
"dev": "vite --mode development",
|
||||
"serve": "vite --host 0.0.0.0",
|
||||
"dev": "vite --mode development --host 0.0.0.0",
|
||||
"preview": "vite preview",
|
||||
"build": "vite build --mode production",
|
||||
"prod": "vite --mode production"
|
||||
|
|
|
@ -1,5 +1,12 @@
|
|||
<template>
|
||||
<xn-form-container ref="signModel" v-model:visible="visible" :width="700" title="电子签名" @close="handleClear" @ok="handleOk">
|
||||
<xn-form-container
|
||||
ref="signModel"
|
||||
v-model:visible="visible"
|
||||
:width="700"
|
||||
title="电子签名"
|
||||
@close="handleClear"
|
||||
@ok="handleOk"
|
||||
>
|
||||
<a-row :gutter="5">
|
||||
<a-col :span="15">
|
||||
<div style="border: 1px solid rgb(236 236 236)">
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
<span>{{ a.tips }}</span>
|
||||
</template>
|
||||
<div :class="['snowy-setting-checkbox-item', a.style]" @click="setSideStyle(a.value)">
|
||||
<check-outlined v-if="sideStyle === a.value" class="snowy-setting-checkbox-item-select-icon" />
|
||||
<check-outlined v-if="theme === a.value" class="snowy-setting-checkbox-item-select-icon" />
|
||||
</div>
|
||||
</a-tooltip>
|
||||
</div>
|
||||
|
@ -56,7 +56,7 @@
|
|||
style="float: right"
|
||||
:checked="topHanderThemeColorSpread"
|
||||
:disabled="!topHanderThemeColorOpen"
|
||||
@change="changeTopHanderThemeColorOpen"
|
||||
@change="changeTopHanderThemeColorSpread"
|
||||
/>
|
||||
</h4>
|
||||
</span>
|
||||
|
@ -81,7 +81,7 @@
|
|||
<a-form-item label="表单风格">
|
||||
<a-select
|
||||
:value="formStyle"
|
||||
class="w-[80px]"
|
||||
style="width: 80px"
|
||||
size="small"
|
||||
:options="xnFormStyleOptions"
|
||||
@change="formStyleChange"
|
||||
|
@ -97,8 +97,8 @@
|
|||
</template>
|
||||
|
||||
<script>
|
||||
import { colorList } from '../../config/settingConfig'
|
||||
import { ThemeModeEnum } from '../../utils/enum'
|
||||
import { colorList } from '@/config/settingConfig'
|
||||
import { ThemeModeEnum } from '@/utils/enum'
|
||||
import { globalStore } from '@/store'
|
||||
import { mapState, mapStores } from 'pinia'
|
||||
import tool from '@/utils/tool'
|
||||
|
@ -112,12 +112,9 @@
|
|||
topHanderThemeColorSpread: 'TOP_HANDER_THEME_COLOR_SPREAD',
|
||||
moduleUnfoldOpen: 'MODULE_UNFOLD_OPEN'
|
||||
}
|
||||
|
||||
export default defineComponent({
|
||||
data() {
|
||||
return {
|
||||
// 整体风格
|
||||
sideStyle: tool.data.get('SNOWY_THEME') || this.theme,
|
||||
sideStyleList: [
|
||||
{
|
||||
tips: '暗色主题风格',
|
||||
|
@ -182,8 +179,12 @@
|
|||
this.toggleState('topHanderThemeColorOpen')
|
||||
if (!this.topHanderThemeColorOpen) {
|
||||
this.globalStore.topHanderThemeColorSpread = false
|
||||
tool.data.set('SNOWY_TOP_HANDER_THEME_COLOR_SPREAD', false)
|
||||
}
|
||||
},
|
||||
changeTopHanderThemeColorSpread() {
|
||||
this.toggleState('topHanderThemeColorSpread')
|
||||
},
|
||||
toggleState(stateName) {
|
||||
this.globalStore.toggleConfig(stateName)
|
||||
const toolDataName = toolDataNameMap[stateName]
|
||||
|
@ -192,18 +193,15 @@
|
|||
// 设置整体风格主题
|
||||
setSideStyle(value) {
|
||||
this.globalStore.setTheme(value)
|
||||
this.sideStyle = value
|
||||
tool.data.set('SNOWY_THEME', value)
|
||||
},
|
||||
// 设置整体界面布局
|
||||
layoutStyle(value) {
|
||||
this.globalStore.setLayout(value)
|
||||
tool.data.set('SNOWY_LAYOUT', value)
|
||||
this.layout = value
|
||||
},
|
||||
// 切换颜色
|
||||
tagColor(value) {
|
||||
this.globalStore.themeColor = value
|
||||
tool.data.set('SNOWY_THEME_COLOR', value)
|
||||
this.globalStore.setThemeColor(value)
|
||||
},
|
||||
|
|
|
@ -79,9 +79,9 @@
|
|||
},
|
||||
computed: {
|
||||
...mapState(viewTagsStore, ['viewTags']),
|
||||
tagList() {
|
||||
return this.viewTags
|
||||
}
|
||||
tagList() {
|
||||
return this.viewTags
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
$route(to) {
|
||||
|
|
|
@ -185,6 +185,7 @@
|
|||
import { ThemeModeEnum } from '@/utils/enum'
|
||||
import { globalStore, keepAliveStore } from '@/store'
|
||||
import { mapState, mapActions } from 'pinia'
|
||||
import tool from '@/utils/tool'
|
||||
|
||||
export default defineComponent({
|
||||
name: 'Index',
|
||||
|
@ -220,6 +221,7 @@
|
|||
'menuIsCollapse',
|
||||
'breadcrumbOpen',
|
||||
'topHanderThemeColorOpen',
|
||||
'topHanderThemeColorSpread',
|
||||
'topHanderThemeColor',
|
||||
'sideUniqueOpen',
|
||||
'sysBaseConfig'
|
||||
|
@ -264,7 +266,7 @@
|
|||
window.addEventListener('resize', this.onLayoutResize)
|
||||
this.moduleMenu = this.$router.getMenu()
|
||||
// 获取缓存中的菜单模块是哪个
|
||||
const menuModuleId = this.$TOOL.data.get('SNOWY_MENU_MODULE_ID')
|
||||
const menuModuleId = tool.data.get('SNOWY_MENU_MODULE_ID')
|
||||
let menu = []
|
||||
if (menuModuleId) {
|
||||
// 防止切换一个无此应用的人
|
||||
|
@ -293,7 +295,7 @@
|
|||
const menus = menu.filter((item) => item.id === id)[0].children
|
||||
if (menus.length > 0) {
|
||||
// 将此模块的唯一值加入缓存
|
||||
this.$TOOL.data.set('SNOWY_MENU_MODULE_ID', id)
|
||||
tool.data.set('SNOWY_MENU_MODULE_ID', id)
|
||||
// 正儿八百的菜单
|
||||
this.menu = this.filterUrl(menus)
|
||||
// 然后将其跳转至指定界面,默认始终取排序第一的
|
||||
|
|
|
@ -1,3 +1,13 @@
|
|||
/**
|
||||
* Copyright [2022] [https://www.xiaonuo.vip]
|
||||
* Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点:
|
||||
* 1.请不要删除和修改根目录下的LICENSE文件。
|
||||
* 2.请不要删除和修改Snowy源码头部的版权声明。
|
||||
* 3.本项目代码可免费商业使用,商业使用请保留源码和相关描述文件的项目出处,作者声明等。
|
||||
* 4.分发源码时候,请注明软件出处 https://www.xiaonuo.vip
|
||||
* 5.不可二次分发开源参与同类竞品,如有想法可联系团队xiaonuobase@qq.com商议合作。
|
||||
* 6.若您的项目无法满足以上几点,需要更多功能代码,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip
|
||||
*/
|
||||
import { defineStore } from 'pinia'
|
||||
import { changeColor } from '@/utils/themeUtil'
|
||||
import config from '@/config'
|
||||
|
|
|
@ -1,11 +1,5 @@
|
|||
<template>
|
||||
<xn-form-container
|
||||
title="导入导出"
|
||||
:width="700"
|
||||
:visible="visible"
|
||||
:destroy-on-close="true"
|
||||
@close="onClose"
|
||||
>
|
||||
<xn-form-container title="导入导出" :width="700" :visible="visible" :destroy-on-close="true" @close="onClose">
|
||||
<span
|
||||
>导入数据格式严格按照系统模板进行数据录入,请点击
|
||||
<a-button type="primary" size="small" @click="downloadImportUserTemplate">下载模板</a-button>
|
||||
|
|
|
@ -1,11 +1,5 @@
|
|||
<template>
|
||||
<xn-form-container
|
||||
title="修改密码"
|
||||
:width="550"
|
||||
:visible="visible"
|
||||
:destroy-on-close="true"
|
||||
@close="onClose"
|
||||
>
|
||||
<xn-form-container title="修改密码" :width="550" :visible="visible" :destroy-on-close="true" @close="onClose">
|
||||
<a-form ref="formRef" :model="formState" :rules="rules" layout="vertical">
|
||||
<a-form-item label="旧密码:" name="password" has-feedback>
|
||||
<a-input
|
||||
|
|
|
@ -1,11 +1,5 @@
|
|||
<template>
|
||||
<xn-form-container
|
||||
title="详情"
|
||||
:width="700"
|
||||
:visible="visible"
|
||||
:destroy-on-close="true"
|
||||
@close="onClose"
|
||||
>
|
||||
<xn-form-container title="详情" :width="700" :visible="visible" :destroy-on-close="true" @close="onClose">
|
||||
<a-descriptions :column="1" size="middle" bordered class="mb-2">
|
||||
<a-descriptions-item label="主题">{{ formData.subject }}</a-descriptions-item>
|
||||
<a-descriptions-item label="发送时间">{{ formData.createTime }}</a-descriptions-item>
|
||||
|
|
Loading…
Reference in New Issue