Added the account primary key to the search query in the accounting application.
This commit is contained in:
1 parent
00180d28b9
commit
70d725d2af
1 file changed
+2
-1
+2
-1
@@ -783,7 +783,8 @@ def search(request: HttpRequest) -> HttpResponse:
|
|||||||
if re.match("^[0-9]{9}$", query):
|
if re.match("^[0-9]{9}$", query):
|
||||||
conditions = conditions\
|
conditions = conditions\
|
||||||
| Q(pk=int(query))\
|
| Q(pk=int(query))\
|
||||||
| Q(transaction__pk=int(query))
|
| Q(transaction__pk=int(query))\
|
||||||
|
| Q(account__pk=int(query))
|
||||||
if re.match("^[0-9]{4}$", query):
|
if re.match("^[0-9]{4}$", query):
|
||||||
conditions = conditions\
|
conditions = conditions\
|
||||||
| Q(transaction__date__year=int(query))
|
| Q(transaction__date__year=int(query))
|
||||||
|
|||||||
Reference in new issue
Block a user