mango r264 - in branches/django: . mango



Author: ovitters
Date: Fri Jun 27 20:40:03 2008
New Revision: 264
URL: http://svn.gnome.org/viewvc/mango?rev=264&view=rev

Log:
	* mango/views.py (add_mirror): Ensure active column is set to 1 when a
	new mirror is added.


Modified:
   branches/django/   (props changed)
   branches/django/ChangeLog
   branches/django/mango/views.py

Modified: branches/django/mango/views.py
==============================================================================
--- branches/django/mango/views.py	(original)
+++ branches/django/mango/views.py	Fri Jun 27 20:40:03 2008
@@ -213,7 +213,9 @@
     doc, pagenode = get_xmldoc('New mirror', request, 'newftpmirror')
 
     if request.method == 'POST':
-        f = models.FtpmirrorsForm(request.POST)
+        p = request.POST.copy()
+        p['active'] = '1'
+        f = models.FtpmirrorsForm(p)
         if add_form_errors_to_xml(pagenode, f):
             mirror = f.save()
             return HttpResponseRedirect(u'../edit/%s' % unicode(mirror.id))



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]