Merge branch 'master' of https://gitee.com/y_project/RuoYi-Vue into dev
Conflicts: ruoyi-common/src/main/java/com/ruoyi/common/filter/XssHttpServletRequestWrapper.java ruoyi-ui/src/api/login.js
This commit is contained in:
commit
bdfd2f0787
@ -65,8 +65,8 @@ public class XssHttpServletRequestWrapper extends HttpServletRequestWrapper
|
|||||||
|
|
||||||
// xss过滤
|
// xss过滤
|
||||||
json = HtmlUtil.cleanHtmlTag(json).trim();
|
json = HtmlUtil.cleanHtmlTag(json).trim();
|
||||||
|
byte[] jsonBytes = json.getBytes(StandardCharsets.UTF_8);
|
||||||
final ByteArrayInputStream bis = IoUtil.toStream(json, StandardCharsets.UTF_8);
|
final ByteArrayInputStream bis = IoUtil.toStream(jsonBytes);
|
||||||
return new ServletInputStream()
|
return new ServletInputStream()
|
||||||
{
|
{
|
||||||
@Override
|
@Override
|
||||||
@ -81,6 +81,12 @@ public class XssHttpServletRequestWrapper extends HttpServletRequestWrapper
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public int available() throws IOException
|
||||||
|
{
|
||||||
|
return jsonBytes.length;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void setReadListener(ReadListener readListener)
|
public void setReadListener(ReadListener readListener)
|
||||||
{
|
{
|
||||||
|
@ -47,6 +47,7 @@ export function logout() {
|
|||||||
export function getCodeImg() {
|
export function getCodeImg() {
|
||||||
return request({
|
return request({
|
||||||
url: '/captchaImage',
|
url: '/captchaImage',
|
||||||
method: 'get'
|
method: 'get',
|
||||||
|
timeout: 20000
|
||||||
})
|
})
|
||||||
}
|
}
|
@ -31,12 +31,12 @@ export default {
|
|||||||
type: Array,
|
type: Array,
|
||||||
default: null,
|
default: null,
|
||||||
},
|
},
|
||||||
value: [String, Array],
|
value: [Number, String, Array],
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
values() {
|
values() {
|
||||||
if (this.value) {
|
if (this.value !== null && typeof this.value !== 'undefined') {
|
||||||
return Array.isArray(this.value) ? this.value : [this.value];
|
return Array.isArray(this.value) ? this.value : [String(this.value)];
|
||||||
} else {
|
} else {
|
||||||
return [];
|
return [];
|
||||||
}
|
}
|
||||||
|
@ -18,7 +18,7 @@ export function parseTime(time, pattern) {
|
|||||||
if ((typeof time === 'string') && (/^[0-9]+$/.test(time))) {
|
if ((typeof time === 'string') && (/^[0-9]+$/.test(time))) {
|
||||||
time = parseInt(time)
|
time = parseInt(time)
|
||||||
} else if (typeof time === 'string') {
|
} else if (typeof time === 'string') {
|
||||||
time = time.replace(new RegExp(/-/gm), '/');
|
time = time.replace(new RegExp(/-/gm), '/').replace('T', ' ').replace(new RegExp(/\.[\d]{3}/gm),'');
|
||||||
}
|
}
|
||||||
if ((typeof time === 'number') && (time.toString().length === 10)) {
|
if ((typeof time === 'number') && (time.toString().length === 10)) {
|
||||||
time = time * 1000
|
time = time * 1000
|
||||||
|
Loading…
x
Reference in New Issue
Block a user