增加下载数,页面跳转、展示优化
This commit is contained in:
@@ -30,8 +30,8 @@ function validateResult(result) {
|
||||
if (result.errCode == 200) {
|
||||
return true;
|
||||
} else if (result.errCode == 400) {
|
||||
var href = encodeURI(window.location.href);
|
||||
window.location = "static/manage/login.html?returnUrl=" + href;
|
||||
var href = encodeURIComponent(window.location.href);
|
||||
window.location = "static/manage/login.html?redirect=" + href;
|
||||
} else {
|
||||
Toast.error(result.errMsg);
|
||||
}
|
||||
@@ -151,8 +151,8 @@ function getObjectFirstAttributeIfOnly(data) {
|
||||
function postService(url, param, success=function(){}, complete=function(){}){
|
||||
ajaxTemp(url, "POST", "JSON", param, function(result){
|
||||
if (result.errCode == 400) {
|
||||
var href = encodeURI(window.location.href);
|
||||
window.location = "static/manage/login.html?returnUrl=" + href;
|
||||
var href = encodeURIComponent(window.location.href);
|
||||
window.location = "static/manage/login.html?redirect=" + href;
|
||||
} else if (result.errCode != "200") {
|
||||
Toast.warn(result.errMsg);
|
||||
} else {
|
||||
@@ -185,8 +185,8 @@ function ajaxTemp(url, dataSentType, dataReceiveType, paramsStr, successFunction
|
||||
contentType : "application/x-www-form-urlencoded; charset=UTF-8",
|
||||
success : function(msg) {
|
||||
if (msg.errCode == 400) {
|
||||
var href = encodeURI(window.location.href);
|
||||
window.location = "static/manage/login.html?returnUrl=" + href;
|
||||
var href = encodeURIComponent(window.location.href);
|
||||
window.location = "static/manage/login.html?redirect=" + href;
|
||||
} else {
|
||||
if (typeof successFunction == "function") {
|
||||
successFunction(msg, id);
|
||||
|
||||
Reference in New Issue
Block a user