Closed dward2nd closed 2 years ago
I think I want a few more changes. My biggest question would be: Is there a specific reason, that we cannot use a single input element to handle both cases?
In my opinion, I prefer it to be just a normal text box rather than textarea
. But that would be interesting if we can just use textarea
to handle searching in both ways. What do you think?
I think I want a few more changes. My biggest question would be: Is there a specific reason, that we cannot use a single input element to handle both cases?
In my opinion, I prefer it to be just a normal text box rather than
textarea
. But that would be interesting if we can just usetextarea
to handle searching in both ways. What do you think?
Yes, I think it would be a good idea to explore. I suggest you give it a try, but if it is more complicated code, then we can stay with two inputs.
Closing this for now, might reopened when we get back to this feature.
This is the continuous work from the previous pull request #110 suggested by @saemideluxe.
To enter the advanced search mode, type
=
at the beginning of the search text box.This will bring the DjangoQL completion as well. Users can begin to type in using DjangoQL syntax instead of finding the substring like we used to do it before.
Known Issues
DjangoQL completion cannot identify the children model's field of the BrowseView. For instance, in basxconnect, the Person BrowseView is the BrowseView for the Person model, which NaturalPerson derived from. There are
first_name
andlast_name
fields in NaturalPerson but DjangoQL cannot recognize them. This can be problematic when you need to search something more specific.The normal mode still uses the
Q()
solution instead of the DjangoQL'sapply_search()
, which may be continued soon.