Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion doc/activedocs.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ The API list is generated from the service name and description, separated by a
## Prerequesites

* 3scale account with Developer Portal
* an OpenAPI Specification, version 2.0 (3scale ActiveDocs) for each service
* an OpenAPI Specification, version 2.0 or 3.0 (3scale ActiveDocs) for each service

Currently, this module expects that Services and ActiveDocs objects will have
the same system_name (in order to match a service with an ActiveDocs).
Expand Down
15 changes: 9 additions & 6 deletions documentation.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
{% cdn_asset /swagger-ui/2.2.10/swagger-ui.js %}
{% cdn_asset /swagger-ui/2.2.10/swagger-ui.css %}
{% content_for javascripts %}
{{ 'active_docs.js' | javascript_include_tag }}
{% endcontent_for %}

{% include 'shared/swagger_ui' %}
<div class="swagger-section">
<div id="message-bar" class="swagger-ui-wrap">&nbsp;</div>
<div id="swagger-ui-container" class="swagger-ui-wrap"></div>
</div>

<div class="api-list-container" style="display: none;">
<h1>API Catalog</h1>
Expand Down Expand Up @@ -29,8 +33,7 @@ <h1>API Catalog</h1>
if (searchParams.has("api")) {
var api = searchParams.get("api");
$(".api-list-container").css("display", "none");
window.swaggerUi.options['url'] = services[api].url;
window.swaggerUi.load();
SwaggerUI({ url: services[api].url, dom_id: "#swagger-ui-container" });
} else {
$(".api-list-container").css("display", "block");
var system_names = Object.keys(services).sort();
Expand All @@ -44,4 +47,4 @@ <h1>API Catalog</h1>
}
});

</script>
</script>