Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

list字段filter过滤错误 #9

Open
youthv opened this issue Dec 12, 2022 · 1 comment
Open

list字段filter过滤错误 #9

youthv opened this issue Dec 12, 2022 · 1 comment
Labels
help wanted Extra attention is needed

Comments

@youthv
Copy link

youthv commented Dec 12, 2022

在数据模型中,有省、市、区三个字段,并且设置为Filter,在筛选时如果选择了一个省,默认业务需求应该是,市和区的筛选框默认和该省级联,但是目前是即时先选择了省,那么市和区显示的过滤列表还是全部的,这样就造成了,如果选择了非该省的市和区,则显示无数据的情况。

@Deali-Axy
Copy link
Owner

这个应该是Django-Filters这个库相关的,这种特殊场景需要自己编写Filter类,具体可以看一下Django-Filter的文档,或者我写的这篇博客:https://blog.sblt.deali.cn:9000/Blog/Post/588574511180dd52

@Deali-Axy Deali-Axy added the help wanted Extra attention is needed label Aug 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants