#5599: Cannot save value via OneToOneField
-----------------------+----------------------------------------------------
Reporter:  baumer1122  |       Owner:  nobody          
  Status:  new         |   Component:  Database wrapper
 Version:  SVN         |    Keywords:  onetoone        
   Stage:  Unreviewed  |   Has_patch:  0               
-----------------------+----------------------------------------------------
 Trying to save a value into a OneToOne child instance via it's parent has
 no effect.


 {{{
 >>> p = Place.objects.get(pk=1)
 >>> p.restaurant.waiters
 10
 >>> p.restaurant.waiters = 5
 >>> p.save()
 >>> p.restaurant.waiters
 10
 >>> p.restaurant.save()
 >>> p.restaurant.waiters
 10
 }}}

 Saving via the child works as expected.


 {{{
 >>> r = Restaurant.objects.get(pk=1)
 >>> r.waiters
 10
 >>> r.waiters = 5
 >>> r.save()
 >>> r.waiters
 5
 }}}

-- 
Ticket URL: <http://code.djangoproject.com/ticket/5599>
Django Code <http://code.djangoproject.com/>
The web framework for perfectionists with deadlines
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to