models:
class UserExtendedProfile(models.Model):
...
class UserExtendedProfileFavourites(models.Model):
userextendedprofile = models.ForeignKey(UserExtendedProfile,
edit_inline=models.TABULAR, num_in_admin=5, max_num_in_admin=5,
num_extra_on_change=1)
...
views:
...
user_extended_profile.save()
# set favourites
user_extended_profile.userextendedprofilefavourites_set = [fav1,
fav2, fav3]
now, when saving the related favourites, the _old_ favourites are not
deleted but the new ones are added.
I thought it´s possible to update the favourites in a way that the
old ones are deleted and the new ones are added. Am I wrong with my
assumption or do I use the wrong code?
thanks,
patrick