You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Documents should not know about "driver" and store odd fields like couchrest-type. IIRC it was already discussed several months ago, but unfortunately I can not find a thread. The idea:
Use document_type field name by default
Use global ExtendedDocument.set_inheritance_field "couchrest-type" for legacy
Use ExtendedDocument.set_inheritance_field in any class
Interestingly, I also do not like the couchrest-type field and was thinking of ways to change it in CouchRest Model. My main reason for this is that I'm creating a couchapp which uses the same DB and having couchrest-type in all the views doesn't make much sense.
I think my preference would be to go minimal, and just use "type" as opposed to "document_type" by default. Most Rails developers are used to not using the 'type' field as it is used for STI. Anyone else can change it to something more complicated.
I do however think we should offer a migration script for people who want to change the column name.
Issue from: http://github.com/couchrest/couchrest/issues#issue/25
Documents should not know about "driver" and store odd fields like couchrest-type. IIRC it was already discussed several months ago, but unfortunately I can not find a thread. The idea:
My fork http://github.com/wildchild/couchrest/commits/document_type
Related ticket: http://jchris.lighthouseapp.com/projects/17807/tickets/22-lets-use-couchrest_type
Thoughts?
The text was updated successfully, but these errors were encountered: