This commit is contained in:
18
dist/lib/swagger.js
vendored
18
dist/lib/swagger.js
vendored
@@ -1,5 +1,5 @@
|
|||||||
// swagger.js
|
// swagger.js
|
||||||
// version 2.0.36
|
// version 2.0.37
|
||||||
|
|
||||||
var __bind = function(fn, me){
|
var __bind = function(fn, me){
|
||||||
return function(){
|
return function(){
|
||||||
@@ -79,7 +79,6 @@ Object.keys = Object.keys || (function () {
|
|||||||
};
|
};
|
||||||
})();
|
})();
|
||||||
|
|
||||||
|
|
||||||
var SwaggerApi = function(url, options) {
|
var SwaggerApi = function(url, options) {
|
||||||
this.url = null;
|
this.url = null;
|
||||||
this.debug = false;
|
this.debug = false;
|
||||||
@@ -158,6 +157,7 @@ SwaggerApi.prototype.buildFromSpec = function(response) {
|
|||||||
}
|
}
|
||||||
this.apis = {};
|
this.apis = {};
|
||||||
this.apisArray = [];
|
this.apisArray = [];
|
||||||
|
this.consumes = response.consumes;
|
||||||
this.produces = response.produces;
|
this.produces = response.produces;
|
||||||
this.authSchemes = response.authorizations;
|
this.authSchemes = response.authorizations;
|
||||||
if (response.info != null) {
|
if (response.info != null) {
|
||||||
@@ -175,13 +175,13 @@ SwaggerApi.prototype.buildFromSpec = function(response) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (response.basePath) {
|
if (response.basePath)
|
||||||
this.basePath = response.basePath;
|
this.basePath = response.basePath;
|
||||||
} else if (this.url.indexOf('?') > 0) {
|
else if (this.url.indexOf('?') > 0)
|
||||||
this.basePath = this.url.substring(0, this.url.lastIndexOf('?'));
|
this.basePath = this.url.substring(0, this.url.lastIndexOf('?'));
|
||||||
} else {
|
else
|
||||||
this.basePath = this.url;
|
this.basePath = this.url;
|
||||||
}
|
|
||||||
if (isApi) {
|
if (isApi) {
|
||||||
var newName = response.resourcePath.replace(/\//g, '');
|
var newName = response.resourcePath.replace(/\//g, '');
|
||||||
this.resourcePath = response.resourcePath;
|
this.resourcePath = response.resourcePath;
|
||||||
@@ -321,8 +321,8 @@ var SwaggerResource = function(resourceObj, api) {
|
|||||||
var _this = this;
|
var _this = this;
|
||||||
this.api = api;
|
this.api = api;
|
||||||
this.api = this.api;
|
this.api = this.api;
|
||||||
produces = [];
|
consumes = (this.consumes | []);
|
||||||
consumes = [];
|
produces = (this.produces | []);
|
||||||
this.path = this.api.resourcePath != null ? this.api.resourcePath : resourceObj.path;
|
this.path = this.api.resourcePath != null ? this.api.resourcePath : resourceObj.path;
|
||||||
this.description = resourceObj.description;
|
this.description = resourceObj.description;
|
||||||
|
|
||||||
@@ -1191,7 +1191,7 @@ var SwaggerRequest = function(type, url, params, opts, successCallback, errorCal
|
|||||||
SwaggerRequest.prototype.setHeaders = function(params, operation) {
|
SwaggerRequest.prototype.setHeaders = function(params, operation) {
|
||||||
// default type
|
// default type
|
||||||
var accepts = "application/json";
|
var accepts = "application/json";
|
||||||
var contentType = null;
|
var consumes = "application/json";
|
||||||
|
|
||||||
var allDefinedParams = this.operation.parameters;
|
var allDefinedParams = this.operation.parameters;
|
||||||
var definedFormParams = [];
|
var definedFormParams = [];
|
||||||
|
|||||||
2
dist/swagger-ui.js
vendored
2
dist/swagger-ui.js
vendored
@@ -1,5 +1,5 @@
|
|||||||
// swagger-ui.js
|
// swagger-ui.js
|
||||||
// version 2.0.21
|
// version 2.0.22
|
||||||
$(function() {
|
$(function() {
|
||||||
|
|
||||||
// Helper function for vertically aligning DOM elements
|
// Helper function for vertically aligning DOM elements
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
// swagger.js
|
// swagger.js
|
||||||
// version 2.0.36
|
// version 2.0.37
|
||||||
|
|
||||||
var __bind = function(fn, me){
|
var __bind = function(fn, me){
|
||||||
return function(){
|
return function(){
|
||||||
@@ -79,7 +79,6 @@ Object.keys = Object.keys || (function () {
|
|||||||
};
|
};
|
||||||
})();
|
})();
|
||||||
|
|
||||||
|
|
||||||
var SwaggerApi = function(url, options) {
|
var SwaggerApi = function(url, options) {
|
||||||
this.url = null;
|
this.url = null;
|
||||||
this.debug = false;
|
this.debug = false;
|
||||||
@@ -158,6 +157,7 @@ SwaggerApi.prototype.buildFromSpec = function(response) {
|
|||||||
}
|
}
|
||||||
this.apis = {};
|
this.apis = {};
|
||||||
this.apisArray = [];
|
this.apisArray = [];
|
||||||
|
this.consumes = response.consumes;
|
||||||
this.produces = response.produces;
|
this.produces = response.produces;
|
||||||
this.authSchemes = response.authorizations;
|
this.authSchemes = response.authorizations;
|
||||||
if (response.info != null) {
|
if (response.info != null) {
|
||||||
@@ -175,13 +175,13 @@ SwaggerApi.prototype.buildFromSpec = function(response) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (response.basePath) {
|
if (response.basePath)
|
||||||
this.basePath = response.basePath;
|
this.basePath = response.basePath;
|
||||||
} else if (this.url.indexOf('?') > 0) {
|
else if (this.url.indexOf('?') > 0)
|
||||||
this.basePath = this.url.substring(0, this.url.lastIndexOf('?'));
|
this.basePath = this.url.substring(0, this.url.lastIndexOf('?'));
|
||||||
} else {
|
else
|
||||||
this.basePath = this.url;
|
this.basePath = this.url;
|
||||||
}
|
|
||||||
if (isApi) {
|
if (isApi) {
|
||||||
var newName = response.resourcePath.replace(/\//g, '');
|
var newName = response.resourcePath.replace(/\//g, '');
|
||||||
this.resourcePath = response.resourcePath;
|
this.resourcePath = response.resourcePath;
|
||||||
@@ -321,8 +321,8 @@ var SwaggerResource = function(resourceObj, api) {
|
|||||||
var _this = this;
|
var _this = this;
|
||||||
this.api = api;
|
this.api = api;
|
||||||
this.api = this.api;
|
this.api = this.api;
|
||||||
produces = [];
|
consumes = (this.consumes | []);
|
||||||
consumes = [];
|
produces = (this.produces | []);
|
||||||
this.path = this.api.resourcePath != null ? this.api.resourcePath : resourceObj.path;
|
this.path = this.api.resourcePath != null ? this.api.resourcePath : resourceObj.path;
|
||||||
this.description = resourceObj.description;
|
this.description = resourceObj.description;
|
||||||
|
|
||||||
@@ -1191,7 +1191,7 @@ var SwaggerRequest = function(type, url, params, opts, successCallback, errorCal
|
|||||||
SwaggerRequest.prototype.setHeaders = function(params, operation) {
|
SwaggerRequest.prototype.setHeaders = function(params, operation) {
|
||||||
// default type
|
// default type
|
||||||
var accepts = "application/json";
|
var accepts = "application/json";
|
||||||
var contentType = null;
|
var consumes = "application/json";
|
||||||
|
|
||||||
var allDefinedParams = this.operation.parameters;
|
var allDefinedParams = this.operation.parameters;
|
||||||
var definedFormParams = [];
|
var definedFormParams = [];
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "swagger-ui",
|
"name": "swagger-ui",
|
||||||
"version": "2.0.21",
|
"version": "2.0.22",
|
||||||
"description": "Swagger UI is a dependency-free collection of HTML, Javascript, and CSS assets that dynamically generate beautiful documentation from a Swagger-compliant API",
|
"description": "Swagger UI is a dependency-free collection of HTML, Javascript, and CSS assets that dynamically generate beautiful documentation from a Swagger-compliant API",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "PATH=$PATH:./node_modules/.bin cake dist",
|
"build": "PATH=$PATH:./node_modules/.bin cake dist",
|
||||||
|
|||||||
Reference in New Issue
Block a user