I'm not 100% sure what the question is. Are you asking if the
additional fields on AlbumSongMap are accessible directly from the
Album or Song models? If so, then no that's not the case with the
current patch. It is however possible to use the QuerySet API to
query for Album or Song objects given a certain property on
AlbumSongMap. To actually set those fields to be something other than
null or the default, right now you have to query for, change, and save
it through AlbumSongMap's manager.
I do think that there's a bit room for improvement here in terms of
syntactical sugar. The problem is that with
album_instance.songs.add(...), that 'add' function takes *args and
adds each arg to the song set. We could do something like
album_instance.songs.add_extra(song, extra={'is_remix' : True}) but
I'm not extremely happy with that syntax or with the fact that we'd be
duplicating functionality. A way to respect DRY might be to do
something like album_instance.songs.add({'instance' : song, 'extra' :
{'is_remix' : True}}, ...) and have 'add' check whether each arg is an
instance or a dictionary, but that syntax is horrible IMHO. If
someone could propose a better syntax, I'd be happy to implement it,
but right now I see no elegant solution.
Hopefully I've answered your question! If not, just keep asking and
eventually I'll catch on.
Thanks,
Eric Florenzano