以下是我的表格:
class AdvancedSearchForm(forms.Form):
valueofres = forms.ChoiceField (label="res", choices = ((0, 0),(2.2, 2.2)), required= False)
以下是我的看法:
def advancedsearch(request):
if request.method == "POST":
search = AdvancedSearchForm(request.POST, request.FILES)
if search.is_valid():
new_search = search.save(commit=False)
为什么我收到错误消息'AdvancedSearchForm' object has no attribute 'save'
?