📜  如果查询集为空 django - Python 代码示例

📅  最后修改于: 2022-03-11 14:45:27.183000             🧑  作者: Mango

代码示例4
# check if queryset is empty (django)
if not myQueryset:
    # Do this...
else:
    # Do that...