|
|
|
@ -229,7 +229,7 @@
|
|
|
|
|
var mixin = {
|
|
|
|
|
data: {
|
|
|
|
|
activeIndex: 'home',
|
|
|
|
|
contextPath: '${context?default("")}',
|
|
|
|
|
context: '${context?default("")}',
|
|
|
|
|
homePath: '${home?default("")}',
|
|
|
|
|
isSubmit: false,
|
|
|
|
|
result: [],
|
|
|
|
@ -402,6 +402,8 @@
|
|
|
|
|
data: {
|
|
|
|
|
loadingTip: '',
|
|
|
|
|
loadingBar: '',
|
|
|
|
|
context: '${context?default("")}',
|
|
|
|
|
homePath: '${home?default("")}'
|
|
|
|
|
},
|
|
|
|
|
methods: {
|
|
|
|
|
tipShow: function (msg) {
|
|
|
|
@ -500,23 +502,21 @@
|
|
|
|
|
toOpen: function (url) {
|
|
|
|
|
this.tipShow();
|
|
|
|
|
var url = url.substring(0, 1) == "/" ? url.substring(1) : url;
|
|
|
|
|
$("body").append($("<a id='wb-open' href='" + this.contextPath + "/" + url + "' target='_self' style='dispaly:none;'></a>"))
|
|
|
|
|
$("body").append($("<a id='wb-open' href='" + this.context + "/" + url + "' target='_self' style='dispaly:none;'></a>"))
|
|
|
|
|
document.getElementById("wb-open").click();
|
|
|
|
|
$("#wb-open").remove();
|
|
|
|
|
},
|
|
|
|
|
toOpenNew: function (url) {
|
|
|
|
|
var url = url.substring(0, 1) == "/" ? url.substring(1) : url;
|
|
|
|
|
$("body").append($("<a id='wb-open' href='" + this.contextPath + "/" + url + "' target='_blank' style='dispaly:none;'></a>"))
|
|
|
|
|
$("body").append($("<a id='wb-open' href='" + this.context + "/" + url + "' target='_blank' style='dispaly:none;'></a>"))
|
|
|
|
|
document.getElementById("wb-open").click();
|
|
|
|
|
$("#wb-open").remove();
|
|
|
|
|
},
|
|
|
|
|
toHome: function () {
|
|
|
|
|
this.tipShow();
|
|
|
|
|
location.href = this.contextPath + "/"
|
|
|
|
|
location.href = this.context + "/"
|
|
|
|
|
},
|
|
|
|
|
/**
|
|
|
|
|
* 滚动屏蔽至顶部
|
|
|
|
|
*/
|
|
|
|
|
// 滚动屏蔽至顶部
|
|
|
|
|
scrollToTop: function () {
|
|
|
|
|
var distance = document.documentElement.scrollTop || document.body.scrollTop;
|
|
|
|
|
var step = distance / 10;
|
|
|
|
@ -529,10 +529,7 @@
|
|
|
|
|
}
|
|
|
|
|
})();
|
|
|
|
|
},
|
|
|
|
|
/**
|
|
|
|
|
* 控制任一目标滚动到顶部
|
|
|
|
|
* select jquery对象
|
|
|
|
|
*/
|
|
|
|
|
// 控制任一目标滚动到顶部
|
|
|
|
|
scrollToTop: function (select) {
|
|
|
|
|
var distance = $(select).scrollTop();
|
|
|
|
|
var step = distance / 10;
|
|
|
|
@ -576,6 +573,27 @@
|
|
|
|
|
wscript.SendKeys("{F11}");
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
setCookie:function (name, value, expiretime) {
|
|
|
|
|
var exdate = new Date();
|
|
|
|
|
exdate.setDate(exdate.getTime() + expiretime);
|
|
|
|
|
document.cookie = name + "=" + encodeURIComponent(value) + ";expires=" + exdate.toGMTString() + ";path=/";
|
|
|
|
|
},
|
|
|
|
|
getCookie:function (name) {
|
|
|
|
|
if (document.cookie.length > 0) {
|
|
|
|
|
c_start = document.cookie.indexOf(name + "=")
|
|
|
|
|
if (c_start != -1){
|
|
|
|
|
c_start = c_start + name.length + 1
|
|
|
|
|
c_end = document.cookie.indexOf(";", c_start)
|
|
|
|
|
if (c_end == -1)
|
|
|
|
|
c_end = document.cookie.length
|
|
|
|
|
return decodeURIComponent(document.cookie.substring(c_start, c_end))
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
return ""
|
|
|
|
|
},
|
|
|
|
|
clearCookie:function (name) {
|
|
|
|
|
this.setCookie(name, "", -1);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|