Hide index field for rule searches

This commit is contained in:
Mark Veidemanis 2023-02-08 17:46:43 +00:00
parent 1eea401657
commit 7e78c2857e
Signed by: m
GPG Key ID: 5ACFCEED46C0904F
1 changed files with 44 additions and 40 deletions

View File

@ -341,53 +341,57 @@
</div> </div>
</div> </div>
</div> </div>
<div class="column is-narrow rounded-tooltip">
<div class="field has-addons">
<div class="control has-icons-left">
<span class="select is-warning">
<select {% if not user.is_superuser %}disabled{% endif %} id="index" name="index">
{% if params.index == 'main' %}
<option selected value="main">Main</option>
{% elif params.index == None %}
<option selected value="main">Main</option>
{% else %}
<option value="main">Main</option>
{% endif %}
{% if params.index == 'internal' %} {% if params.rule is None %}
<option selected value="internal">Internal</option> <div class="column is-narrow rounded-tooltip">
{% else %} <div class="field has-addons">
<option value="internal">Internal</option> <div class="control has-icons-left">
{% endif %} <span class="select is-warning">
<select {% if not user.is_superuser %}disabled{% endif %} id="index" name="index">
{% if params.index == 'main' %}
<option selected value="main">Main</option>
{% elif params.index == None %}
<option selected value="main">Main</option>
{% else %}
<option value="main">Main</option>
{% endif %}
{% if params.index == 'meta' %} {% if params.index == 'internal' %}
<option selected value="meta">Meta</option> <option selected value="internal">Internal</option>
{% else %} {% else %}
<option value="meta">Meta</option> <option value="internal">Internal</option>
{% endif %} {% endif %}
{% if params.index == 'restricted' %} {% if params.index == 'meta' %}
<option selected value="restricted">Restricted</option> <option selected value="meta">Meta</option>
{% else %} {% else %}
<option value="restricted">Restricted</option> <option value="meta">Meta</option>
{% endif %} {% endif %}
</select> {% if params.index == 'restricted' %}
<span class="icon is-small is-left"> <option selected value="restricted">Restricted</option>
<i class="fas fa-magnifying-glass"></i> {% else %}
<option value="restricted">Restricted</option>
{% endif %}
</select>
<span class="icon is-small is-left">
<i class="fas fa-magnifying-glass"></i>
</span>
</span> </span>
</span> </div>
<p class="control">
<a class="button is-static">
index
</a>
</p>
</div> </div>
<p class="control"> {% if not user.is_superuser %}
<a class="button is-static"> <span class="tooltiptext tag is-danger is-light">No access</span>
index {% endif %}
</a>
</p>
</div> </div>
{% if not user.is_superuser %} {% endif %}
<span class="tooltiptext tag is-danger is-light">No access</span>
{% endif %}
</div>
</div> </div>
</div> </div>
<div class="block"> <div class="block">