mirror of
https://github.com/chillzhuang/Saber.git
synced 2024-11-05 10:09:40 +08:00
🎉 3.0.1.RELEASE 架构升级适配 SpringCloud 2020.0.1
This commit is contained in:
parent
3ba18c8d97
commit
33352fb5f2
@ -1,9 +1,9 @@
|
|||||||
<p align="center">
|
<p align="center">
|
||||||
<img src="https://img.shields.io/badge/Release-V3.0.0-green.svg" alt="Downloads">
|
<img src="https://img.shields.io/badge/Release-V3.0.1-green.svg" alt="Downloads">
|
||||||
<img src="https://img.shields.io/badge/JDK-1.8+-green.svg" alt="Build Status">
|
<img src="https://img.shields.io/badge/JDK-1.8+-green.svg" alt="Build Status">
|
||||||
<img src="https://img.shields.io/badge/license-Apache%202-blue.svg" alt="Build Status">
|
<img src="https://img.shields.io/badge/license-Apache%202-blue.svg" alt="Build Status">
|
||||||
<img src="https://img.shields.io/badge/Spring%20Cloud-2020-blue.svg" alt="Coverage Status">
|
<img src="https://img.shields.io/badge/Spring%20Cloud-2020-blue.svg" alt="Coverage Status">
|
||||||
<img src="https://img.shields.io/badge/Spring%20Boot-2.4.1-blue.svg" alt="Downloads">
|
<img src="https://img.shields.io/badge/Spring%20Boot-2.4.2-blue.svg" alt="Downloads">
|
||||||
<a target="_blank" href="https://bladex.vip">
|
<a target="_blank" href="https://bladex.vip">
|
||||||
<img src="https://img.shields.io/badge/Author-Small%20Chill-ff69b4.svg" alt="Downloads">
|
<img src="https://img.shields.io/badge/Author-Small%20Chill-ff69b4.svg" alt="Downloads">
|
||||||
</a>
|
</a>
|
||||||
@ -75,7 +75,7 @@ SpringBlade
|
|||||||
## 项目地址
|
## 项目地址
|
||||||
* 后端Gitee地址:[https://gitee.com/smallc/SpringBlade](https://gitee.com/smallc/SpringBlade)
|
* 后端Gitee地址:[https://gitee.com/smallc/SpringBlade](https://gitee.com/smallc/SpringBlade)
|
||||||
* 后端Github地址:[https://github.com/chillzhuang/SpringBlade](https://github.com/chillzhuang/SpringBlade)
|
* 后端Github地址:[https://github.com/chillzhuang/SpringBlade](https://github.com/chillzhuang/SpringBlade)
|
||||||
* 后端SpringBoot版:[https://gitee.com/smallc/SpringBlade/tree/2.0-boot/](https://gitee.com/smallc/SpringBlade/tree/2.0-boot/)
|
* 后端SpringBoot版:[https://gitee.com/smallc/SpringBlade/tree/boot/](https://gitee.com/smallc/SpringBlade/tree/boot/)
|
||||||
* 前端框架Sword(基于React):[https://gitee.com/smallc/Sword](https://gitee.com/smallc/Sword)
|
* 前端框架Sword(基于React):[https://gitee.com/smallc/Sword](https://gitee.com/smallc/Sword)
|
||||||
* 前端框架Saber(基于Vue):[https://gitee.com/smallc/Saber](https://gitee.com/smallc/Saber)
|
* 前端框架Saber(基于Vue):[https://gitee.com/smallc/Saber](https://gitee.com/smallc/Saber)
|
||||||
* 核心框架项目地址:[https://github.com/chillzhuang/blade-tool](https://github.com/chillzhuang/blade-tool)
|
* 核心框架项目地址:[https://github.com/chillzhuang/blade-tool](https://github.com/chillzhuang/blade-tool)
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "saber-admin",
|
"name": "saber-admin",
|
||||||
"version": "3.0.0",
|
"version": "3.0.1",
|
||||||
"private": true,
|
"private": true,
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"serve": "vue-cli-service serve",
|
"serve": "vue-cli-service serve",
|
||||||
|
8
public/cdn/avue/2.7.5/avue.min.js
vendored
8
public/cdn/avue/2.7.5/avue.min.js
vendored
File diff suppressed because one or more lines are too long
8
public/cdn/avue/2.7.6/avue.min.js
vendored
Normal file
8
public/cdn/avue/2.7.6/avue.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
@ -12,7 +12,7 @@
|
|||||||
<link rel="stylesheet" href="<%= BASE_URL %>cdn/element-ui/2.13.2/theme-chalk/index.css">
|
<link rel="stylesheet" href="<%= BASE_URL %>cdn/element-ui/2.13.2/theme-chalk/index.css">
|
||||||
<link rel="stylesheet" href="<%= BASE_URL %>cdn/animate/3.5.2/animate.css">
|
<link rel="stylesheet" href="<%= BASE_URL %>cdn/animate/3.5.2/animate.css">
|
||||||
<link rel="stylesheet" href="<%= BASE_URL %>cdn/iconfont/1.0.0/index.css">
|
<link rel="stylesheet" href="<%= BASE_URL %>cdn/iconfont/1.0.0/index.css">
|
||||||
<link rel="stylesheet" href="<%= BASE_URL %>cdn/avue/2.7.5/index.css">
|
<link rel="stylesheet" href="<%= BASE_URL %>cdn/avue/2.7.6/index.css">
|
||||||
<link rel="icon" href="<%= BASE_URL %>favicon.png">
|
<link rel="icon" href="<%= BASE_URL %>favicon.png">
|
||||||
<title>Saber企业级开发平台</title>
|
<title>Saber企业级开发平台</title>
|
||||||
<style>
|
<style>
|
||||||
@ -103,7 +103,7 @@
|
|||||||
<script src="<%= BASE_URL %>cdn/vue-router/3.0.1/vue-router.min.js" charset="utf-8"></script>
|
<script src="<%= BASE_URL %>cdn/vue-router/3.0.1/vue-router.min.js" charset="utf-8"></script>
|
||||||
<script src="<%= BASE_URL %>cdn/axios/1.0.0/axios.min.js" charset="utf-8"></script>
|
<script src="<%= BASE_URL %>cdn/axios/1.0.0/axios.min.js" charset="utf-8"></script>
|
||||||
<script src="<%= BASE_URL %>cdn/element-ui/2.13.2/index.js" charset="utf-8"></script>
|
<script src="<%= BASE_URL %>cdn/element-ui/2.13.2/index.js" charset="utf-8"></script>
|
||||||
<script src="<%= BASE_URL %>cdn/avue/2.7.5/avue.min.js" charset="utf-8"></script>
|
<script src="<%= BASE_URL %>cdn/avue/2.7.6/avue.min.js" charset="utf-8"></script>
|
||||||
</body>
|
</body>
|
||||||
|
|
||||||
</html>
|
</html>
|
||||||
|
@ -1,9 +1,10 @@
|
|||||||
export default {
|
export default {
|
||||||
column: [{
|
tabs: true,
|
||||||
label: '个人信息',
|
tabsActive: 1,
|
||||||
prop: 'info',
|
group: [
|
||||||
option: {
|
{
|
||||||
submitText: '修改',
|
label: '个人信息',
|
||||||
|
prop: 'info',
|
||||||
column: [{
|
column: [{
|
||||||
label: '头像',
|
label: '头像',
|
||||||
type: 'upload',
|
type: 'upload',
|
||||||
@ -42,12 +43,10 @@ export default {
|
|||||||
span: 12,
|
span: 12,
|
||||||
row: true,
|
row: true,
|
||||||
}]
|
}]
|
||||||
}
|
},
|
||||||
}, {
|
{
|
||||||
label: '修改密码',
|
label: '修改密码',
|
||||||
prop: 'password',
|
prop: 'password',
|
||||||
option: {
|
|
||||||
submitText: '修改',
|
|
||||||
column: [{
|
column: [{
|
||||||
label: '原密码',
|
label: '原密码',
|
||||||
span: 12,
|
span: 12,
|
||||||
@ -68,5 +67,5 @@ export default {
|
|||||||
prop: 'newPassword1'
|
prop: 'newPassword1'
|
||||||
}]
|
}]
|
||||||
}
|
}
|
||||||
}]
|
],
|
||||||
}
|
}
|
||||||
|
93
src/util/func.js
Normal file
93
src/util/func.js
Normal file
@ -0,0 +1,93 @@
|
|||||||
|
/**
|
||||||
|
* 通用工具类
|
||||||
|
*/
|
||||||
|
export default class func {
|
||||||
|
/**
|
||||||
|
* 不为空
|
||||||
|
* @param val
|
||||||
|
* @returns {boolean}
|
||||||
|
*/
|
||||||
|
static notEmpty(val) {
|
||||||
|
return !this.isEmpty(val);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 是否为定义
|
||||||
|
* @param val
|
||||||
|
* @returns {boolean}
|
||||||
|
*/
|
||||||
|
static isUndefined(val) {
|
||||||
|
return val === null || typeof val === 'undefined';
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 为空
|
||||||
|
* @param val
|
||||||
|
* @returns {boolean}
|
||||||
|
*/
|
||||||
|
static isEmpty(val) {
|
||||||
|
if (
|
||||||
|
val === null ||
|
||||||
|
typeof val === 'undefined' ||
|
||||||
|
(typeof val === 'string' && val === '' && val !== 'undefined')
|
||||||
|
) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 强转int型
|
||||||
|
* @param val
|
||||||
|
* @param defaultValue
|
||||||
|
* @returns {number}
|
||||||
|
*/
|
||||||
|
static toInt(val, defaultValue) {
|
||||||
|
if (this.isEmpty(val)) {
|
||||||
|
return defaultValue === undefined ? -1 : defaultValue;
|
||||||
|
}
|
||||||
|
const num = parseInt(val, 0);
|
||||||
|
return Number.isNaN(num) ? (defaultValue === undefined ? -1 : defaultValue) : num;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Json强转为Form类型
|
||||||
|
* @param obj
|
||||||
|
* @returns {FormData}
|
||||||
|
*/
|
||||||
|
static toFormData(obj) {
|
||||||
|
const data = new FormData();
|
||||||
|
Object.keys(obj).forEach(key => {
|
||||||
|
data.append(key, Array.isArray(obj[key]) ? obj[key].join(',') : obj[key]);
|
||||||
|
});
|
||||||
|
return data;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* date类转为字符串格式
|
||||||
|
* @param date
|
||||||
|
* @param format
|
||||||
|
* @returns {null}
|
||||||
|
*/
|
||||||
|
static format(date, format = 'YYYY-MM-DD HH:mm:ss') {
|
||||||
|
return date ? date.format(format) : null;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 根据逗号联合
|
||||||
|
* @param arr
|
||||||
|
* @returns {string}
|
||||||
|
*/
|
||||||
|
static join(arr) {
|
||||||
|
return arr ? arr.join(',') : '';
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 根据逗号分隔
|
||||||
|
* @param str
|
||||||
|
* @returns {string}
|
||||||
|
*/
|
||||||
|
static split(str) {
|
||||||
|
return str ? String(str).split(',') : '';
|
||||||
|
}
|
||||||
|
}
|
@ -116,7 +116,7 @@
|
|||||||
{
|
{
|
||||||
label: "菜单图标",
|
label: "菜单图标",
|
||||||
prop: "source",
|
prop: "source",
|
||||||
type: "icon-select",
|
type: "icon",
|
||||||
slot: true,
|
slot: true,
|
||||||
iconList: iconList,
|
iconList: iconList,
|
||||||
rules: [
|
rules: [
|
||||||
|
@ -1,83 +1,92 @@
|
|||||||
<template>
|
<template>
|
||||||
<div>
|
<div>
|
||||||
<basic-container>
|
<basic-container>
|
||||||
<avue-tabs :option="option"
|
<avue-form :option="option"
|
||||||
v-model="form"
|
v-model="form"
|
||||||
@change="handleChange"
|
@tab-click="handleTabClick"
|
||||||
@submit="handleSubmit"></avue-tabs>
|
@submit="handleSubmit"></avue-form>
|
||||||
</basic-container>
|
</basic-container>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import option from "@/const/user/info";
|
import option from "@/const/user/info";
|
||||||
import {getUserInfo, update, updatePassword} from "@/api/system/user";
|
import {getUserInfo, update, updatePassword} from "@/api/system/user";
|
||||||
|
import func from "@/util/func";
|
||||||
|
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
type: "info",
|
index: 0,
|
||||||
option: option,
|
option: option,
|
||||||
form: {}
|
form: {}
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
this.handleWitch();
|
this.handleWitch();
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
handleSubmit() {
|
handleSubmit(form, done) {
|
||||||
if (this.type === "info") {
|
if (this.index === 0) {
|
||||||
update(this.form).then(res => {
|
update(form).then(res => {
|
||||||
if (res.data.success) {
|
if (res.data.success) {
|
||||||
this.$message({
|
this.$message({
|
||||||
type: "success",
|
type: "success",
|
||||||
message: "修改信息成功!"
|
message: "修改信息成功!"
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
this.$message({
|
this.$message({
|
||||||
type: "error",
|
type: "error",
|
||||||
message: res.data.msg
|
message: res.data.msg
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
})
|
done();
|
||||||
} else {
|
}, error => {
|
||||||
updatePassword(this.form.oldPassword, this.form.newPassword, this.form.newPassword1).then(res => {
|
window.console.log(error);
|
||||||
if (res.data.success) {
|
done();
|
||||||
this.$message({
|
})
|
||||||
type: "success",
|
} else {
|
||||||
message: "修改密码成功!"
|
updatePassword(form.oldPassword, form.newPassword, form.newPassword1).then(res => {
|
||||||
});
|
if (res.data.success) {
|
||||||
} else {
|
this.$message({
|
||||||
this.$message({
|
type: "success",
|
||||||
type: "error",
|
message: "修改密码成功!"
|
||||||
message: res.data.msg
|
});
|
||||||
});
|
} else {
|
||||||
}
|
this.$message({
|
||||||
})
|
type: "error",
|
||||||
}
|
message: res.data.msg
|
||||||
},
|
});
|
||||||
handleWitch() {
|
}
|
||||||
if (this.type === "info") {
|
done();
|
||||||
getUserInfo().then(res => {
|
}, error => {
|
||||||
const user = res.data.data;
|
window.console.log(error);
|
||||||
this.form = {
|
done();
|
||||||
id: user.id,
|
})
|
||||||
avatar: user.avatar,
|
|
||||||
name: user.name,
|
|
||||||
realName: user.realName,
|
|
||||||
phone: user.phone,
|
|
||||||
email: user.email,
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
|
||||||
},
|
|
||||||
handleChange(item) {
|
|
||||||
this.type = item.prop;
|
|
||||||
this.handleWitch();
|
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
handleWitch() {
|
||||||
|
if (this.index === 0) {
|
||||||
|
getUserInfo().then(res => {
|
||||||
|
const user = res.data.data;
|
||||||
|
this.form = {
|
||||||
|
id: user.id,
|
||||||
|
avatar: user.avatar,
|
||||||
|
name: user.name,
|
||||||
|
realName: user.realName,
|
||||||
|
phone: user.phone,
|
||||||
|
email: user.email,
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
},
|
||||||
|
handleTabClick(tabs) {
|
||||||
|
this.index = func.toInt(tabs.index);
|
||||||
|
this.handleWitch();
|
||||||
}
|
}
|
||||||
};
|
}
|
||||||
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style>
|
<style>
|
||||||
|
@ -125,6 +125,19 @@
|
|||||||
<el-row>
|
<el-row>
|
||||||
<basic-container>
|
<basic-container>
|
||||||
<el-collapse v-model="logActiveNames" @change="handleChange">
|
<el-collapse v-model="logActiveNames" @change="handleChange">
|
||||||
|
<el-collapse-item title="3.0.1.发布 新增Swagger独立网关,优化代码生成" name="23">
|
||||||
|
<div>1.升级 SpringBoot 至 2.4.2</div>
|
||||||
|
<div>2.升级 SpringCloud 至 2020.0.1</div>
|
||||||
|
<div>3.升级 Mybatis-Plus 至 3.4.2</div>
|
||||||
|
<div>4.升级 Avue 至 2.7.6</div>
|
||||||
|
<div>5.升级适配 Knife4j 2.0.8</div>
|
||||||
|
<div>6.新增独立的Swagger网关</div>
|
||||||
|
<div>7.新增代码生成的SqlServer驱动判断</div>
|
||||||
|
<div>8.新增代码生成菜单Sql的ID</div>
|
||||||
|
<div>9.优化SentinelFeign实现以适配最新API</div>
|
||||||
|
<div>10.优化Saber个人中心实现以适配最新API</div>
|
||||||
|
<div>11.修复Saber菜单图标选择失效的问题</div>
|
||||||
|
</el-collapse-item>
|
||||||
<el-collapse-item title="3.0.0.发布 架构升级适配SpringCloud2020" name="22">
|
<el-collapse-item title="3.0.0.发布 架构升级适配SpringCloud2020" name="22">
|
||||||
<div>1.升级 SpringBoot 至 2.4.1</div>
|
<div>1.升级 SpringBoot 至 2.4.1</div>
|
||||||
<div>2.升级 SpringCloud 至 2020.0.0</div>
|
<div>2.升级 SpringCloud 至 2020.0.0</div>
|
||||||
@ -364,7 +377,7 @@
|
|||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
activeNames: ['1', '2', '3', '5'],
|
activeNames: ['1', '2', '3', '5'],
|
||||||
logActiveNames: ['22']
|
logActiveNames: ['23']
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
|
Loading…
Reference in New Issue
Block a user