Authored by bblu

nginx->gateway前台修改

... ... @@ -51,8 +51,9 @@ public class NginxSwitchCtrl {
*/
@RequestMapping(value = "switchNginxConf")
@ResponseBody
public BaseResponse switchNginxConf() {
public BaseResponse switchNginxConf(String cloudName) {
Map<String, String> map = new HashMap<>();
map.put("cloudName", cloudName);
return httpRestClient.defaultGet(HttpUriContants.SWITCH_NGINX, BaseResponse.class, map);
}
... ...
... ... @@ -47,10 +47,10 @@ function viewToChangeSuccess(resp) {
$(dialog3).empty();
var data = JSON.parse(resp);
var a = dialog3.dialog({
dialog3.dialog({
title: "切换结果",
backdrop: "static",
content: "<pre>" + data.data + "</pre>",
content: "<pre>" + data.data.result + "</pre>",
buttons: [{
text: "否",
className: "btn-danger",
... ... @@ -61,12 +61,14 @@ function viewToChangeSuccess(resp) {
text: "确定",
className: "btn-success",
onclick: function () {
sendAjax("post", "switchNginxConf", {}, "text", switchSuccess, errorFunc);
var param = {
cloudName: data.data.cloudName
};
sendAjax("post", "switchNginxConf", param, "text", switchSuccess, errorFunc);
}
}]
});
a.find(".modal-body").css({
height: "550px",
}).find(".modal-body").css({
height: "550px"
});
}
... ...