Skip to content
This repository has been archived by the owner on Jan 23, 2024. It is now read-only.

Validate related_resource forms #9

Open
anemitz opened this issue Sep 11, 2012 · 1 comment
Open

Validate related_resource forms #9

anemitz opened this issue Sep 11, 2012 · 1 comment
Labels

Comments

@anemitz
Copy link
Member

anemitz commented Sep 11, 2012

class FooResource(Resource):
   form = FooForm
   document = FooDocument

class BarResource(Resource):
    document = BarDocument
    related_resources = {
        'foos': FooResource
    }

In the above scenario, submitting a BarDocument with a list of Foo's should validate using the FooResource.form before saving.

@wojcikstefan
Copy link
Member

We moved away from forms and are using schemas instead. That being said, it would be ideal if a similar logic applied to Foo#schema.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants