This repository has been archived by the owner on Aug 10, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Changed errors to responseCodes; Updated README;
- Loading branch information
Showing
10 changed files
with
72 additions
and
49 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
15 changes: 0 additions & 15 deletions
15
tests/fixtures/app/layouts/partials/apiDoc/partials/method/errors.volt
This file was deleted.
Oops, something went wrong.
2 changes: 1 addition & 1 deletion
2
tests/fixtures/app/layouts/partials/apiDoc/partials/method/requestContentType.volt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
{% if method['requestContentType'] is defined and method['requestContentType']|length > 0 %} | ||
<pre>Content-Type: <span class="label label-primary"><h5 style="display:inline;">{{ method['requestContentType'] }}</h5></span></pre> | ||
<pre>Content-Type: <span class="label label-primary">{{ method['requestContentType'] }}</span></pre> | ||
{% endif %} |
31 changes: 31 additions & 0 deletions
31
tests/fixtures/app/layouts/partials/apiDoc/partials/method/responseCodes.volt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
{% if method['responseCodes'] is defined and method['responseCodes'] is type('array') and method['responseCodes']|length > 0 %} | ||
<h4>Errors</h4> | ||
<table class="table table-bordered table-hover"> | ||
<tr> | ||
<th>Code</th> | ||
<th>Type</th> | ||
<th>Description</th> | ||
</tr> | ||
{% for responseCode in method['responseCodes'] %} | ||
<tr> | ||
{% if responseCode['code'] < 200 %} | ||
<td><span class="label label-info">{{ responseCode['code'] }}</span></td> | ||
{% endif %} | ||
{% if responseCode['code'] >= 200 and responseCode['code'] < 300 %} | ||
<td><span class="label label-success">{{ responseCode['code'] }}</span></td> | ||
{% endif %} | ||
{% if responseCode['code'] >= 300 and responseCode['code'] < 400 %} | ||
<td><span class="label label-default">{{ responseCode['code'] }}</span></td> | ||
{% endif %} | ||
{% if responseCode['code'] >= 400 and responseCode['code'] < 500 %} | ||
<td><span class="label label-warning">{{ responseCode['code'] }}</span></td> | ||
{% endif %} | ||
{% if responseCode['code'] >= 500 and responseCode['code'] %} | ||
<td><span class="label label-danger">{{ responseCode['code'] }}</span></td> | ||
{% endif %} | ||
<td>{{ responseCode['type'] }}</td> | ||
<td>{{ responseCode['description'] }}</td> | ||
</tr> | ||
{% endfor %} | ||
</table> | ||
{% endif %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters