This commit is contained in:
Anna Bodnia
2016-06-13 14:30:30 +03:00
parent adc8920101
commit a2ce3e797a
3 changed files with 16 additions and 13 deletions

17
dist/swagger-ui.js vendored
View File

@@ -19748,9 +19748,7 @@ SwaggerUi.Views.AuthView = Backbone.View.extend({
e.preventDefault(); e.preventDefault();
this.authsCollectionView.collection.forEach(function (auth) { this.authsCollectionView.collection.forEach(function (auth) {
var name = auth.get('type') === 'basic' ? 'basic' : auth.get('title'); window.swaggerUi.api.clientAuthorizations.remove(auth.get('title'));
window.swaggerUi.api.clientAuthorizations.remove(name);
}); });
this.router.load(); this.router.load();
@@ -19914,12 +19912,9 @@ SwaggerUi.Views.BasicAuthView = Backbone.View.extend({
if (!this.model.get('username')) { if (!this.model.get('username')) {
this.$(this.selectors.usernameInput).addClass(this.cls.error); this.$(this.selectors.usernameInput).addClass(this.cls.error);
} }
if (!this.model.get('password')) {
this.$(this.selectors.passwordInput).addClass(this.cls.error);
}
} }
}); });
'use strict'; 'use strict';
SwaggerUi.Views.ContentTypeView = Backbone.View.extend({ SwaggerUi.Views.ContentTypeView = Backbone.View.extend({
@@ -21968,15 +21963,19 @@ SwaggerUi.partials.signature = (function () {
var value; var value;
var items = definition.items; var items = definition.items;
var xml = definition.xml || {}; var xml = definition.xml || {};
var namespace = getNamespace(xml);
var attributes = [];
if (!items) { return getErrorMessage(); } if (!items) { return getErrorMessage(); }
value = createSchemaXML(name, items, models, config); value = createSchemaXML(name, items, models, config);
xml = xml || {}; if (namespace) {
attributes.push(namespace);
}
if (xml.wrapped) { if (xml.wrapped) {
value = wrapTag(name, value); value = wrapTag(name, value, attributes);
} }
return value; return value;

File diff suppressed because one or more lines are too long

View File

@@ -719,15 +719,19 @@ SwaggerUi.partials.signature = (function () {
var value; var value;
var items = definition.items; var items = definition.items;
var xml = definition.xml || {}; var xml = definition.xml || {};
var namespace = getNamespace(xml);
var attributes = [];
if (!items) { return getErrorMessage(); } if (!items) { return getErrorMessage(); }
value = createSchemaXML(name, items, models, config); value = createSchemaXML(name, items, models, config);
xml = xml || {}; if (namespace) {
attributes.push(namespace);
}
if (xml.wrapped) { if (xml.wrapped) {
value = wrapTag(name, value); value = wrapTag(name, value, attributes);
} }
return value; return value;