版本升级1.0.3,swagger文档优化

This commit is contained in:
暮光:城中城
2019-08-17 21:16:32 +08:00
parent 2c11dbdcf0
commit 4d6b09d640
17 changed files with 409 additions and 41 deletions

View File

@@ -127,8 +127,18 @@
app.oldLocation = item.location;
app.addNewDocumentInput = item.location;
app.rewriteDomainUrl = item.rewriteDomainUrl;
app.addNewSwaggerJson = "";
app.openVisit = (item.openVisit == 1);
$('#addNewDocumentModal').modal({moveable: true});
if (item.location.indexOf('proxy-api-docs') > 0) {
var docId = item.location.substring(item.location.indexOf("?id=") + 4);
// 获取文档内容
ajaxTemp(urlBase + "swagger-mg-ui/document/proxy-api-docs", "get", "text", {id: docId}, function (json) {
app.addNewSwaggerJson = json;
$('#addNewDocumentModal').modal({moveable: true});
});
} else {
$('#addNewDocumentModal').modal({moveable: true});
}
},
addNewDocument: function(){
app.openVisit = false;