mirror of
https://github.com/paperless-ngx/paperless-ngx.git
synced 2025-04-17 10:13:56 -05:00
Add and configure DjangoQL
This commit is contained in:
parent
0256dcbe32
commit
4efb153e86
1
Pipfile
1
Pipfile
@ -34,6 +34,7 @@ pytest-django = "*"
|
|||||||
pytest-sugar = "*"
|
pytest-sugar = "*"
|
||||||
pytest-env = "*"
|
pytest-env = "*"
|
||||||
pytest-xdist = "*"
|
pytest-xdist = "*"
|
||||||
|
djangoql = "*"
|
||||||
|
|
||||||
[dev-packages]
|
[dev-packages]
|
||||||
ipython = "*"
|
ipython = "*"
|
||||||
|
14
Pipfile.lock
generated
14
Pipfile.lock
generated
@ -155,6 +155,13 @@
|
|||||||
"index": "pypi",
|
"index": "pypi",
|
||||||
"version": "==2.0.0"
|
"version": "==2.0.0"
|
||||||
},
|
},
|
||||||
|
"djangoql": {
|
||||||
|
"hashes": [
|
||||||
|
"sha256:7c488ec4e3362e5389ba3c1169d1ff9a27c4222601f32c6dbf6130ce04330d76"
|
||||||
|
],
|
||||||
|
"index": "pypi",
|
||||||
|
"version": "==0.12.3"
|
||||||
|
},
|
||||||
"djangorestframework": {
|
"djangorestframework": {
|
||||||
"hashes": [
|
"hashes": [
|
||||||
"sha256:607865b0bb1598b153793892101d881466bd5a991de12bd6229abb18b1c86136",
|
"sha256:607865b0bb1598b153793892101d881466bd5a991de12bd6229abb18b1c86136",
|
||||||
@ -365,6 +372,13 @@
|
|||||||
],
|
],
|
||||||
"version": "==0.8.0"
|
"version": "==0.8.0"
|
||||||
},
|
},
|
||||||
|
"ply": {
|
||||||
|
"hashes": [
|
||||||
|
"sha256:00c7c1aaa88358b9c765b6d3000c6eec0ba42abca5351b095321aef446081da3",
|
||||||
|
"sha256:096f9b8350b65ebd2fd1346b12452efe5b9607f7482813ffca50c22722a807ce"
|
||||||
|
],
|
||||||
|
"version": "==3.11"
|
||||||
|
},
|
||||||
"py": {
|
"py": {
|
||||||
"hashes": [
|
"hashes": [
|
||||||
"sha256:bf92637198836372b520efcba9e020c330123be8ce527e535d185ed4b6f45694",
|
"sha256:bf92637198836372b520efcba9e020c330123be8ce527e535d185ed4b6f45694",
|
||||||
|
@ -19,6 +19,7 @@ django==2.0.9
|
|||||||
djangorestframework==3.9.0
|
djangorestframework==3.9.0
|
||||||
docopt==0.6.2
|
docopt==0.6.2
|
||||||
docutils==0.14
|
docutils==0.14
|
||||||
|
djangoql==0.12.3
|
||||||
execnet==1.5.0
|
execnet==1.5.0
|
||||||
factory-boy==2.11.1
|
factory-boy==2.11.1
|
||||||
faker==0.9.2
|
faker==0.9.2
|
||||||
|
@ -11,6 +11,7 @@ from django.urls import reverse
|
|||||||
from django.utils.html import format_html, format_html_join
|
from django.utils.html import format_html, format_html_join
|
||||||
from django.utils.http import urlquote
|
from django.utils.http import urlquote
|
||||||
from django.utils.safestring import mark_safe
|
from django.utils.safestring import mark_safe
|
||||||
|
from djangoql.admin import DjangoQLSearchMixin
|
||||||
|
|
||||||
from documents.actions import (
|
from documents.actions import (
|
||||||
add_tag_to_selected,
|
add_tag_to_selected,
|
||||||
@ -165,7 +166,7 @@ class TagAdmin(CommonAdmin):
|
|||||||
document_count.admin_order_field = "document_count"
|
document_count.admin_order_field = "document_count"
|
||||||
|
|
||||||
|
|
||||||
class DocumentAdmin(CommonAdmin):
|
class DocumentAdmin(DjangoQLSearchMixin, CommonAdmin):
|
||||||
|
|
||||||
class Media:
|
class Media:
|
||||||
css = {
|
css = {
|
||||||
|
@ -83,7 +83,7 @@ INSTALLED_APPS = [
|
|||||||
"rest_framework",
|
"rest_framework",
|
||||||
"crispy_forms",
|
"crispy_forms",
|
||||||
"django_filters",
|
"django_filters",
|
||||||
|
"djangoql",
|
||||||
]
|
]
|
||||||
|
|
||||||
if os.getenv("PAPERLESS_INSTALLED_APPS"):
|
if os.getenv("PAPERLESS_INSTALLED_APPS"):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user