Skip to content

Commit e37fbd0

Browse files
committed
set query params to fixed search section
1 parent c190786 commit e37fbd0

File tree

5 files changed

+8
-3
lines changed

5 files changed

+8
-3
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
## Why Django Log Reader?
99

1010
- Reading files based on Linux commands speeds up the display of file content
11+
- Search in files based on Linux commands
1112
- Download the result of the content
1213
- Display all files according to the pattern defined in the `settings.py`
1314
- Simple interface

docs/index.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ Why Django Log Reader?
1111
=========================
1212

1313
* Reading files based on Linux commands speeds up the display of file content
14+
* Search in files based on Linux commands
1415
* Download the result of the content
1516
* Display all files according to the pattern defined in the ``settings.py``
1617
* Simple interface

log_reader/static/log_reader/css/log_reader.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
color: #ffffff;
66
cursor: pointer;
77
border: 1px solid #d0d0d0;
8-
position: fixed;
8+
position: absolute;
99
right: 315px;
1010
top: 156px;
1111
}

log_reader/templates/log_reader/admin/change_list.html

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,10 +29,13 @@ <h1>File Logs</h1>
2929
{% if django_version >= '3' %}<div class="changelist-form-container">{% endif %}
3030

3131
<div id="toolbar">
32-
<form id="changelist-search" method="get">
32+
<form id="changelist-search" action="{{ request.get_full_path }}" method="get">
3333
<div><!-- DIV needed for valid HTML -->
3434
<label for="searchbar"><img src="{% static "admin/img/search.svg" %}" alt="Search"></label>
3535
<input type="text" size="40" name="q" value="{{ request.GET.q }}" id="searchbar" autofocus="">
36+
{% if request.GET.file_name %}
37+
<input type="hidden" name="file_name" value="{{ request.GET.file_name }}">
38+
{% endif %}
3639
<input type="submit" value="Search">
3740
</div>
3841
</form>

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99

1010
setup(
1111
name='django-log-reader',
12-
version='1.1.8',
12+
version='1.1.9',
1313
zip_safe=False,
1414
packages=find_packages(),
1515
include_package_data=True,

0 commit comments

Comments
 (0)