Opened 15 years ago

Last modified 13 years ago

#11992 closed

modelformset_factory — at Initial Version

Reported by: unk2k <northcustoms@…> Owned by: nobody
Component: Forms Version: 1.1
Severity: Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

Environment:

Request Method: POST
Request URL: http://panel.raf-leasing.ru:8000/company/finance/2544400/
Django Version: 1.2 pre-alpha
Python Version: 2.6.2
Installed Applications:
['sessions', 'company', 'auth', 'lib']
Installed Middleware:
('django.middleware.common.CommonMiddleware',

'sessions.middleware.SessionMiddleware',
'auth.middleware.AuthMiddleware',
'django.middleware.transaction.TransactionMiddleware')

Traceback:
File "/usr/local/lib/python2.6/dist-packages/django/core/handlers/base.py" in get_response

  1. response = callback(request, *callback_args, callback_kwargs)

File "/home/r00t/django/rafpaneloracle2/lib/isauth.py" in wrap

  1. return f(request, *args, kwargs)

File "/home/r00t/django/rafpaneloracle2/lib/render.py" in wrapper

  1. output = func(request, *args, kw)

File "/home/r00t/django/rafpaneloracle2/company/views.py" in finance

  1. formset = FinanceSet(request.POST, queryset=Finance.objects.filter(company_id=company.id, quarterin=quarter, yearin=year))

File "/home/r00t/django/rafpaneloracle2/company/forms.py" in init

  1. super (FinanceForm,self ).init(*args,kwargs) # populates the post

File "/usr/local/lib/python2.6/dist-packages/django/forms/models.py" in init

  1. super(BaseModelFormSet, self).init(defaults)

File "/usr/local/lib/python2.6/dist-packages/django/forms/formsets.py" in init

  1. self._construct_forms()

File "/usr/local/lib/python2.6/dist-packages/django/forms/formsets.py" in _construct_forms

  1. self.forms.append(self._construct_form(i))

File "/usr/local/lib/python2.6/dist-packages/django/forms/models.py" in _construct_form

  1. pk = self.data[pk_key]

File "/usr/local/lib/python2.6/dist-packages/django/utils/datastructures.py" in getitem

  1. raise MultiValueDictKeyError, "Key %r not found in %r" % (key, self)

Exception Type: MultiValueDictKeyError at /company/finance/2544400/
Exception Value: Key 'form-0-id' not found in <QueryDict: {u'form-0-capital': [u'0,00'], u'form-0-actives': [u'0,00'], u'form-2-charity': [u'0,00'], u'form-3-income': [u'0,00'], u'form-1-actives': [u'0,00'], u'form-1-charity': [u'0,00'], u'form-0-income': [u'0,00'], u'form-1-capital': [u'0,00'], u'form-3-capital': [u'0,00'], u'form-3-actives': [u'0,00'], u'form-TOTAL_FORMS': [u'4'], u'form-3-charity': [u'0,00'], u'form-2-capital': [u'0,00'], u'form-2-actives': [u'0,00'], u'form-0-charity': [u'0,00'], u'form-INITIAL_FORMS': [u'4'], u'form-2-income': [u'0,00'], u'form-1-income': [u'0,00']}>

Change History (0)

Note: See TracTickets for help on using tickets.
Back to Top