Skip to content

Replace read_only parameter with a list of HTTP methods #121

Description

@dantownsend

PiccoloCRUD has an option called read_only.

I think it's worth phasing this out in favour of an argument called methods.

It could be something like:

PiccoloCRUD(methods=[HTTP.get])

If read_only is provided in kwargs, then we can just map that to methods=[HTTP.get] and provide a deprecation warning.

It means you have more fine grained control over which methods to expose:

PiccoloCRUD(methods=[HTTP.get, HTTP.post])

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions