service categories
This commit is contained in:
parent
79a8c6f280
commit
17b6c4c9ee
6 changed files with 154 additions and 5 deletions
|
@ -12,6 +12,23 @@
|
|||
<input type="text" class="form-control" id="search" name="search" value="{{ request.GET.search }}">
|
||||
</div>
|
||||
|
||||
<div class="mb-3">
|
||||
<label for="category" class="form-label">Category</label>
|
||||
<select class="form-select" id="category" name="category">
|
||||
<option value="">All Categories</option>
|
||||
{% for category in categories %}
|
||||
<option value="{{ category.id }}" {% if request.GET.category == category.id|stringformat:'i' %}selected{% endif %}>
|
||||
{{ category.name }}
|
||||
</option>
|
||||
{% for subcategory in category.children.all %}
|
||||
<option value="{{ subcategory.id }}" {% if request.GET.category == subcategory.id|stringformat:'i' %}selected{% endif %}>
|
||||
{{ subcategory.name }}
|
||||
</option>
|
||||
{% endfor %}
|
||||
{% endfor %}
|
||||
</select>
|
||||
</div>
|
||||
|
||||
<div class="mb-3">
|
||||
<label for="cloud_provider" class="form-label">Cloud Provider</label>
|
||||
<select class="form-select" id="cloud_provider" name="cloud_provider">
|
||||
|
@ -76,6 +93,11 @@
|
|||
</div>
|
||||
</div>
|
||||
<p class="card-text">{{ service.description|truncatewords:30 }}</p>
|
||||
<div class="mb-2">
|
||||
{% for category in service.categories.all %}
|
||||
<span class="badge bg-secondary me-1">{{ category.full_path }}</span>
|
||||
{% endfor %}
|
||||
</div>
|
||||
<p class="card-text">
|
||||
<small class="text-muted">
|
||||
Service Level: {{ service.service_level.name }}<br>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue