Merge pull request #2214 from bodnia/feature/issue-2077

Namespaces for arrays
This commit is contained in:
Ron
2016-06-17 14:55:04 -07:00
committed by GitHub
3 changed files with 50 additions and 217 deletions

230
dist/swagger-ui.js vendored

File diff suppressed because one or more lines are too long

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;