html中的多个复选框,如果选择None
,则希望用户重定向到同一页。
我可以通过Javascript来实现吗?或者
if request.method == 'POST':
if 'trackid' in request.POST.getlist and request.POST.getlist('trackid')!= "":
new_check = request.POST.getlist('trackid')
else:
return redirect('app:frontview')
哦。。我收到这个错误argument of type 'instancemethod' is not iterable
您需要在^{} 中检查密钥的成员资格,而不是在QueryDict的方法中。
以下行:
应替换为:
相关问题 更多 >
编程相关推荐