public
Description: A high-level Python Web framework that encourages rapid development and clean, pragmatic design.
Homepage: http://www.djangoproject.com/
Clone URL: git://github.com/brosner/django.git
Search Repo:
Expanded the commit=False formset example.
brosner (author)
Mon May 12 16:46:03 -0700 2008
commit  9647b7262ae2741d1f5ba3a29c38b82481a2d05f
tree    ae15c4169881c6810a0c0cafa8c309f41b74a19a
parent  3f0e4c525166c6b06958686f9c9030c424d5d276
...
429
430
431
 
 
 
432
433
434
...
429
430
431
432
433
434
435
436
437
0
@@ -429,6 +429,9 @@
0
 
0
     # don't save to the database
0
     >>> unsaved_instances = formset.save(commit=False)
0
+ >>> for instance in unsaved_instances:
0
+ ... # do something with instance
0
+ ... instance.save()
0
 
0
 This gives you the ability to attach data to the instances before saving them
0
 to the database.

Comments

    No one has commented yet.