Browse Source

Fixed exception on user-not-found in form

master
Sebastian Lohff 11 years ago
parent
commit
f97a501f1c
  1. 2
      k4ever/transaction/forms.py
  2. 2
      k4ever/urls.py

2
k4ever/transaction/forms.py

@ -35,5 +35,5 @@ class VirtualTransactionForm(forms.ModelForm): @@ -35,5 +35,5 @@ class VirtualTransactionForm(forms.ModelForm):
try:
user = User.objects.get(username=self.cleaned_data['recipient'])
except User.DoesNotExist:
raise ValidationError(u"Emfpänger '%s' konnte nicht gefunden werden" % self.cleaned_data['user'])
raise ValidationError(u"Emfpänger '%s' konnte nicht gefunden werden" % self.cleaned_data['recipient'])
return user

2
k4ever/urls.py

@ -20,6 +20,8 @@ urlpatterns = patterns('', @@ -20,6 +20,8 @@ urlpatterns = patterns('',
(r'^transaction/', include('transaction.urls')),
(r'^store/', include('buyable.urls')),
(r'^media/(?P<path>.*)$', 'django.views.static.serve', {'document_root': 'media'}),
(r'^docs/(?P<path>.*)$', 'django.views.static.serve', {'document_root': 'docs'}),
# Uncomment the next line to enable the admin:
(r'^admin/', include(admin.site.urls)),

Loading…
Cancel
Save