jfinkels / flask-restless

NO LONGER MAINTAINED - A Flask extension for creating simple ReSTful JSON APIs from SQLAlchemy models.
https://flask-restless.readthedocs.io
GNU Affero General Public License v3.0
1.02k stars 301 forks source link

Adds support and tests for association proxies #608

Closed jfinkels closed 7 years ago

jfinkels commented 7 years ago

This is a work-in-progress. This partially fixes issue #480. It does not yet provide documentation.

jfinkels commented 7 years ago

Right now this pull request is hiding a to-many relationship, say tags, if there is an association proxy to a scalar collection, say tag_names. I think maybe instead both the tags relationship and the tag_names "attribute" should be exposed, and the user has to explicitly decide whether to exclude the relationship. This should be changed before merging.

Natureshadow commented 7 years ago

@jfinkels, might we be able to have a synchronous chat about Veripeditus/veripeditus-server#53 ☺? This would probably fix both the bug in our project and this one here ;).

jfinkels commented 7 years ago

I'm going to merge this. @Natureshadow please test it out and report any problems in a new GitHub issue.