mirror of
https://gitee.com/lab1024/smart-admin.git
synced 2025-11-07 03:03:47 +08:00
【V3.2.0】1、左侧菜单Logo和标题固定;2、Excel导出添加水印;3、长时间不在线自动返回登录页;4、移除sa-token的 token-prefix 配置;5、升级 ant deign vue到最新版4.2;6、登录页面引入登录类型图标方式;7、文件预览组件的文件下载方式为接口方式下载;
This commit is contained in:
5882
smart-admin-web/javascript-ant-design-vue3/package-lock.json
generated
5882
smart-admin-web/javascript-ant-design-vue3/package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@@ -19,7 +19,7 @@
|
||||
"dependencies": {
|
||||
"@wangeditor/editor": "5.1.14",
|
||||
"@wangeditor/editor-for-vue": "5.1.12",
|
||||
"ant-design-vue": "4.1.2",
|
||||
"ant-design-vue": "4.2.0",
|
||||
"axios": "1.6.8",
|
||||
"clipboard": "2.0.11",
|
||||
"crypto-js": "4.1.1",
|
||||
|
||||
@@ -33,7 +33,7 @@ export const appDefaultConfig = {
|
||||
// 网站名称
|
||||
websiteName: 'SmartAdmin 3.X',
|
||||
// 主题颜色
|
||||
primaryColor: 'red',
|
||||
primaryColor: '#1677ff',
|
||||
// 紧凑
|
||||
compactFlag: false,
|
||||
};
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
<!--
|
||||
* 传统菜单
|
||||
*
|
||||
* @Author: 1024创新实验室-主任:卓大
|
||||
* @Date: 2022-09-06 20:29:12
|
||||
* @Wechat: zhuda1024
|
||||
* @Email: lab1024@163.com
|
||||
* @Copyright 1024创新实验室 ( https://1024lab.net ),Since 2012
|
||||
*
|
||||
* @Author: 1024创新实验室-主任:卓大
|
||||
* @Date: 2022-09-06 20:29:12
|
||||
* @Wechat: zhuda1024
|
||||
* @Email: lab1024@163.com
|
||||
* @Copyright 1024创新实验室 ( https://1024lab.net ),Since 2012
|
||||
-->
|
||||
<template>
|
||||
<!--左侧菜单分为两部分:1、顶部logo区域,包含 logo和名称;2、下方菜单区域-->
|
||||
@@ -21,7 +21,9 @@
|
||||
</div>
|
||||
|
||||
<!-- 2、下方菜单区域: 这里使用一个递归菜单解决 -->
|
||||
<RecursionMenu :collapsed="collapsed" ref="menuRef" />
|
||||
<div class="menu">
|
||||
<RecursionMenu :collapsed="collapsed" ref="menuRef" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
@@ -60,6 +62,13 @@
|
||||
function onGoHome() {
|
||||
router.push({ name: HOME_PAGE_NAME });
|
||||
}
|
||||
|
||||
const color = computed(() => {
|
||||
let isLight = useAppConfigStore().$state.sideMenuTheme === 'light';
|
||||
return {
|
||||
background: isLight ? '#FFFFFF' : '#001529',
|
||||
};
|
||||
});
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
@@ -75,7 +84,9 @@
|
||||
height: @header-user-height;
|
||||
line-height: @header-user-height;
|
||||
padding: 0px 15px 0px 15px;
|
||||
width: 100%;
|
||||
background-color: v-bind('color.background');
|
||||
position: fixed;
|
||||
width: 80px;
|
||||
z-index: 21;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
@@ -89,7 +100,9 @@
|
||||
.logo {
|
||||
height: @header-user-height;
|
||||
line-height: @header-user-height;
|
||||
background-color: v-bind('color.background');
|
||||
padding: 0px 15px 0px 15px;
|
||||
position: fixed;
|
||||
z-index: 21;
|
||||
display: flex;
|
||||
cursor: pointer;
|
||||
@@ -115,6 +128,6 @@
|
||||
}
|
||||
}
|
||||
.menu {
|
||||
padding: 16px 0;
|
||||
margin-top: @header-user-height;
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -23,6 +23,12 @@ const smartAxios = axios.create({
|
||||
baseURL: import.meta.env.VITE_APP_API_URL,
|
||||
});
|
||||
|
||||
// 退出系统
|
||||
function logout() {
|
||||
localClear();
|
||||
location.href = '/';
|
||||
}
|
||||
|
||||
// ================================= 请求拦截器 =================================
|
||||
|
||||
smartAxios.interceptors.request.use(
|
||||
@@ -73,10 +79,7 @@ smartAxios.interceptors.response.use(
|
||||
if (res.code === 30007 || res.code === 30008) {
|
||||
message.destroy();
|
||||
message.error('您没有登录,请重新登录');
|
||||
localClear();
|
||||
setTimeout(() => {
|
||||
location.href = '/';
|
||||
}, 300);
|
||||
setTimeout(logout, 300);
|
||||
return Promise.reject(response);
|
||||
}
|
||||
|
||||
@@ -94,15 +97,9 @@ smartAxios.interceptors.response.use(
|
||||
Modal.error({
|
||||
title: '重要提醒',
|
||||
content: res.msg,
|
||||
onOk() {
|
||||
return new Promise((resolve, reject) => {
|
||||
localClear();
|
||||
setTimeout(() => {
|
||||
location.href = '/';
|
||||
}, 300);
|
||||
}).catch(() => console.log('Oops errors!'));
|
||||
},
|
||||
onOk: logout,
|
||||
});
|
||||
setTimeout(logout, 3000);
|
||||
return Promise.reject(response);
|
||||
}
|
||||
message.destroy();
|
||||
|
||||
@@ -5,12 +5,13 @@ export const themeColors = [
|
||||
activeColor: '#0958d9',
|
||||
hoverColor: '#bae0ff',
|
||||
},
|
||||
// 紫色
|
||||
// 绿色
|
||||
{
|
||||
primaryColor: '#722ED1',
|
||||
activeColor: '#531dab',
|
||||
hoverColor: '#9254de',
|
||||
primaryColor: '#00b96b',
|
||||
activeColor: '#00945b',
|
||||
hoverColor: '#20c77c',
|
||||
},
|
||||
|
||||
// 红色
|
||||
{
|
||||
primaryColor: '#F5222D',
|
||||
@@ -29,10 +30,10 @@ export const themeColors = [
|
||||
activeColor: '#c41d7f',
|
||||
hoverColor: '#f759ab',
|
||||
},
|
||||
// 绿色
|
||||
// 紫色
|
||||
{
|
||||
primaryColor: '#52C41A',
|
||||
activeColor: '#389e0d',
|
||||
hoverColor: '#73d13d',
|
||||
primaryColor: '#722ED1',
|
||||
activeColor: '#531dab',
|
||||
hoverColor: '#9254de',
|
||||
},
|
||||
];
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
<!--
|
||||
* 公司列表
|
||||
*
|
||||
* @Author: 1024创新实验室-主任:卓大
|
||||
*
|
||||
* @Author: 1024创新实验室-主任:卓大
|
||||
* @Date: 2022-08-15 20:15:49
|
||||
* @Wechat: zhuda1024
|
||||
* @Email: lab1024@163.com
|
||||
* @Copyright 1024创新实验室 ( https://1024lab.net ),Since 2012
|
||||
* @Wechat: zhuda1024
|
||||
* @Email: lab1024@163.com
|
||||
* @Copyright 1024创新实验室 ( https://1024lab.net ),Since 2012
|
||||
-->
|
||||
<template>
|
||||
<a-form class="smart-query-form" v-privilege="'oa:enterprise:query'">
|
||||
@@ -50,7 +50,7 @@
|
||||
<template #icon>
|
||||
<FileExcelOutlined />
|
||||
</template>
|
||||
导出数据
|
||||
导出数据(带水印)
|
||||
</a-button>
|
||||
</div>
|
||||
<div class="smart-table-setting-block">
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
<!--
|
||||
* 登录
|
||||
*
|
||||
* @Author: 1024创新实验室-主任:卓大
|
||||
* @Date: 2022-09-12 22:34:00
|
||||
* @Wechat: zhuda1024
|
||||
* @Email: lab1024@163.com
|
||||
* @Copyright 1024创新实验室 ( https://1024lab.net ),Since 2012
|
||||
*
|
||||
* @Author: 1024创新实验室-主任:卓大
|
||||
* @Date: 2022-09-12 22:34:00
|
||||
* @Wechat: zhuda1024
|
||||
* @Email: lab1024@163.com
|
||||
* @Copyright 1024创新实验室 ( https://1024lab.net ),Since 2012
|
||||
*
|
||||
-->
|
||||
<template>
|
||||
@@ -154,7 +154,7 @@
|
||||
notification['success']({
|
||||
message: '温馨提示',
|
||||
description: 'SmartAdmin 提供 9种 登录背景风格哦!',
|
||||
duration: null,
|
||||
duration: 8,
|
||||
onClick: () => {},
|
||||
btn: () =>
|
||||
h(
|
||||
|
||||
Reference in New Issue
Block a user