Merge remote-tracking branch 'swagger-api/master'
This commit is contained in:
23
dist/swagger-ui.js
vendored
23
dist/swagger-ui.js
vendored
@@ -25543,6 +25543,9 @@ SwaggerUi.Views.OperationView = Backbone.View.extend({
|
|||||||
statusCode = ref5[q];
|
statusCode = ref5[q];
|
||||||
statusCode.isXML = isXML;
|
statusCode.isXML = isXML;
|
||||||
statusCode.isJSON = isJSON;
|
statusCode.isJSON = isJSON;
|
||||||
|
if (!_.isUndefined(statusCode.headers)) {
|
||||||
|
statusCode.headers = this.parseHeadersType(statusCode.headers);
|
||||||
|
}
|
||||||
this.addStatusCode(statusCode);
|
this.addStatusCode(statusCode);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -25550,6 +25553,26 @@ SwaggerUi.Views.OperationView = Backbone.View.extend({
|
|||||||
return this;
|
return this;
|
||||||
},
|
},
|
||||||
|
|
||||||
|
parseHeadersType: function (headers) {
|
||||||
|
var map = {
|
||||||
|
'string': {
|
||||||
|
'date-time': 'dateTime',
|
||||||
|
'date' : 'date'
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
_.forEach(headers, function (header) {
|
||||||
|
var value;
|
||||||
|
header = header || {};
|
||||||
|
value = map[header.type] && map[header.type][header.format];
|
||||||
|
if (!_.isUndefined(value)) {
|
||||||
|
header.type = value;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
return headers;
|
||||||
|
},
|
||||||
|
|
||||||
contains: function (produces, type) {
|
contains: function (produces, type) {
|
||||||
return produces.filter(function (val) {
|
return produces.filter(function (val) {
|
||||||
if (val.indexOf(type) > -1) {
|
if (val.indexOf(type) > -1) {
|
||||||
|
|||||||
4
dist/swagger-ui.min.js
vendored
4
dist/swagger-ui.min.js
vendored
File diff suppressed because one or more lines are too long
@@ -246,6 +246,9 @@ SwaggerUi.Views.OperationView = Backbone.View.extend({
|
|||||||
statusCode = ref5[q];
|
statusCode = ref5[q];
|
||||||
statusCode.isXML = isXML;
|
statusCode.isXML = isXML;
|
||||||
statusCode.isJSON = isJSON;
|
statusCode.isJSON = isJSON;
|
||||||
|
if (!_.isUndefined(statusCode.headers)) {
|
||||||
|
statusCode.headers = this.parseHeadersType(statusCode.headers);
|
||||||
|
}
|
||||||
this.addStatusCode(statusCode);
|
this.addStatusCode(statusCode);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -253,6 +256,26 @@ SwaggerUi.Views.OperationView = Backbone.View.extend({
|
|||||||
return this;
|
return this;
|
||||||
},
|
},
|
||||||
|
|
||||||
|
parseHeadersType: function (headers) {
|
||||||
|
var map = {
|
||||||
|
'string': {
|
||||||
|
'date-time': 'dateTime',
|
||||||
|
'date' : 'date'
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
_.forEach(headers, function (header) {
|
||||||
|
var value;
|
||||||
|
header = header || {};
|
||||||
|
value = map[header.type] && map[header.type][header.format];
|
||||||
|
if (!_.isUndefined(value)) {
|
||||||
|
header.type = value;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
return headers;
|
||||||
|
},
|
||||||
|
|
||||||
contains: function (produces, type) {
|
contains: function (produces, type) {
|
||||||
return produces.filter(function (val) {
|
return produces.filter(function (val) {
|
||||||
if (val.indexOf(type) > -1) {
|
if (val.indexOf(type) > -1) {
|
||||||
|
|||||||
Reference in New Issue
Block a user