2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-06-17 20:45:44 +00:00

search page now returns matching parts

- Searches 'name' and 'description' field
- Uses the JSON API
This commit is contained in:
Oliver Walters
2019-04-17 08:16:34 +10:00
parent fbf764e2ef
commit ca7182bf6b
3 changed files with 59 additions and 12 deletions

View File

@ -12,13 +12,7 @@
<li><a href="{% url 'company-index' %}">Companies</a></li>
</ul>
<ul class="nav navbar-nav navbar-right">
<form class="navbar-form navbar-left" action="{% url 'search' %}" method='post'>
{% csrf_token %}
<div class="form-group">
<input type="text" name='search' class="form-control" placeholder="Search">
</div>
<button type="submit" id='search-submit' class="btn btn-default">Submit</button>
</form>
{% include "search_form.html" %}
{% if user.is_authenticated %}
<li class='dropdown'>
<a class='dropdown-toggle' data-toggle='dropdown' href="#"><span class="glyphicon glyphicon-user"></span> <b>{{ user.get_username }}</b></a>