mirror of
https://github.com/nottinghamtec/PyRIGS.git
synced 2026-01-23 16:32:15 +00:00
Added search help page (very pretty)
This commit is contained in:
@@ -32,7 +32,8 @@
|
|||||||
|
|
||||||
<div class="panel panel-default">
|
<div class="panel panel-default">
|
||||||
<div class="panel-heading">
|
<div class="panel-heading">
|
||||||
<h4 class="panel-title">Search Rigboard</h4>
|
<h4 class="panel-title">Search Rigboard
|
||||||
|
<a href="{% url 'search_help' %}" class="pull-right modal-href"><span class="glyphicon glyphicon-question-sign"</span></a></h4>
|
||||||
</div>
|
</div>
|
||||||
<div class="list-group">
|
<div class="list-group">
|
||||||
<div class="list-group-item">
|
<div class="list-group-item">
|
||||||
|
|||||||
70
RIGS/templates/RIGS/search_help.html
Normal file
70
RIGS/templates/RIGS/search_help.html
Normal file
@@ -0,0 +1,70 @@
|
|||||||
|
{% extends request.is_ajax|yesno:"base_ajax.html,base.html" %}
|
||||||
|
|
||||||
|
{% block title %}Search Help{% endblock %}
|
||||||
|
|
||||||
|
{% block content %}
|
||||||
|
<div class="row">
|
||||||
|
{% if not request.is_ajax %}
|
||||||
|
<div class="col-sm-12">
|
||||||
|
<h1>Search Help</h1>
|
||||||
|
</div>
|
||||||
|
{% endif %}
|
||||||
|
<div class="col-sm-12">
|
||||||
|
<div class="panel panel-default">
|
||||||
|
<div class="panel-heading">
|
||||||
|
<h3 class="panel-title">Searching Events</h3>
|
||||||
|
</div>
|
||||||
|
<div class="panel-body">
|
||||||
|
<p>
|
||||||
|
Searches for entire query in:
|
||||||
|
<button type="button" class="btn btn-default btn-xs">name</button>
|
||||||
|
<button type="button" class="btn btn-default btn-xs">description</button> and
|
||||||
|
<button type="button" class="btn btn-default btn-xs">notes</button>
|
||||||
|
</p>
|
||||||
|
<p>You can search for an event by <button type="button" class="btn btn-default btn-xs">event_id</button> by entering an integer, or using the format <code>N01234</code></p>
|
||||||
|
<p>On the search results page you can also specify the date range for the <button type="button" class="btn btn-default btn-xs">start_date</button> of the event</p>
|
||||||
|
<p>Events are sorted in reverse <button type="button" class="btn btn-default btn-xs">start_date</button> order (most recent events at the top)</p>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="panel panel-default">
|
||||||
|
<div class="panel-heading">
|
||||||
|
<h3 class="panel-title">Searching People/Organisations/Venues</h3>
|
||||||
|
</div>
|
||||||
|
<div class="panel-body">
|
||||||
|
<p>
|
||||||
|
Searches for entire search phrase in:
|
||||||
|
<button type="button" class="btn btn-default btn-xs">name</button>
|
||||||
|
<button type="button" class="btn btn-default btn-xs">email</button>
|
||||||
|
<button type="button" class="btn btn-default btn-xs">address</button>
|
||||||
|
<button type="button" class="btn btn-default btn-xs">notes</button> and
|
||||||
|
<button type="button" class="btn btn-default btn-xs">phone</button>
|
||||||
|
</p>
|
||||||
|
<p>You can search for an entry by <button type="button" class="btn btn-default btn-xs">id</button> by entering an integer</p>
|
||||||
|
<p>Entries are sorted in alphabetical order by <button type="button" class="btn btn-default btn-xs">name</button></p>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
{% if perms.RIGS.view_invoice %}
|
||||||
|
<div class="panel panel-default">
|
||||||
|
<div class="panel-heading">
|
||||||
|
<h3 class="panel-title">Searching Invoices</h3>
|
||||||
|
</div>
|
||||||
|
<div class="panel-body">
|
||||||
|
<p>
|
||||||
|
Searches for entire search phrase in:
|
||||||
|
<button type="button" class="btn btn-default btn-xs">event__name</button>
|
||||||
|
</p>
|
||||||
|
<p>You can search for an event's invoice by entering the <button type="button" class="btn btn-default btn-xs">event_id</button> using the format <code>N01234</code></p>
|
||||||
|
<p>You can search for an invoice by <button type="button" class="btn btn-default btn-xs">invoice_id</button> using the format <code>#01234</code></p>
|
||||||
|
<p>Entering a raw integer will search by both <button type="button" class="btn btn-default btn-xs">invoice_id</button> and <button type="button" class="btn btn-default btn-xs">event_id</button></p>
|
||||||
|
<p>Entries are sorted in reverse <button type="button" class="btn btn-default btn-xs">invoice_date</button> order</p>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
{% endblock %}
|
||||||
@@ -13,6 +13,8 @@ urlpatterns = patterns('',
|
|||||||
url('^$', login_required(views.Index.as_view()), name='index'),
|
url('^$', login_required(views.Index.as_view()), name='index'),
|
||||||
url(r'^closemodal/$', views.CloseModal.as_view(), name='closemodal'),
|
url(r'^closemodal/$', views.CloseModal.as_view(), name='closemodal'),
|
||||||
|
|
||||||
|
url(r'^search_help/$', views.SearchHelp.as_view(), name='search_help'),
|
||||||
|
|
||||||
url('^user/login/$', 'RIGS.views.login', name='login'),
|
url('^user/login/$', 'RIGS.views.login', name='login'),
|
||||||
url(r'^user/password_reset/$', 'django.contrib.auth.views.password_reset', {'password_reset_form':forms.PasswordReset}),
|
url(r'^user/password_reset/$', 'django.contrib.auth.views.password_reset', {'password_reset_form':forms.PasswordReset}),
|
||||||
|
|
||||||
|
|||||||
@@ -35,6 +35,9 @@ def login(request, **kwargs):
|
|||||||
|
|
||||||
return login(request)
|
return login(request)
|
||||||
|
|
||||||
|
class SearchHelp(generic.TemplateView):
|
||||||
|
template_name = 'RIGS/search_help.html'
|
||||||
|
|
||||||
"""
|
"""
|
||||||
Called from a modal window (e.g. when an item is submitted to an event/invoice).
|
Called from a modal window (e.g. when an item is submitted to an event/invoice).
|
||||||
May optionally also include some javascript in a success message to cause a load of
|
May optionally also include some javascript in a success message to cause a load of
|
||||||
|
|||||||
Reference in New Issue
Block a user