ziggurat_foundations icon indicating copy to clipboard operation
ziggurat_foundations copied to clipboard

Improve documentation

Open ergo opened this issue 9 years ago • 5 comments

Documentation is lacking, contributions are welcome

ergo avatar Jun 13 '15 18:06 ergo

I think a tutorial, including an example app would be good. I am happy to write both the app and the tutorial, areas I think need covering.... (anyone else please add what you think we should cover).

Setting up the project Extending the mixins Elaborating on the RootFactory Adding in request.user to the pyramid app Adding and deleting users Assigning users to groups Adding permissions Assigning groups to permissions The login/logout routines, as well as how to customize Adding permission based access to views Providing an example view for approving a user account with the use of security code

EDIT: Add in example of adding an example get_session_callable in the models, so it can be returned as a function as required by the ini file:

ziggurat_foundations.session_provider_callable = yourapp.models.meta:get_session_callable

Also looking at the above assumes the user has a meta file and a folder for models, all other examples assume one model file, shall we provide this as well for the example?

crooksey avatar Aug 19 '15 09:08 crooksey

Now fixed?

crooksey avatar Oct 28 '15 13:10 crooksey

A lot better.

ergo avatar Nov 13 '15 18:11 ergo

Might as well post my minor corrections in here, right? :-)

In "Cofiguring groupfinder and session factorys" (Typos in the header - "Configuring" and "factories") you have root_factory='intranet.models.RootFactory', but I guess that should be root_factory='<my_project>.models.RootFactory' instead.

peletiah avatar Dec 14 '15 17:12 peletiah

On "adding a resource that the user will own": It would be useful to have a note that one must add __possible_permissions__ to the Resource-class in model containing a list of permission-names (e.g. "read")

permission.user_name = "foo" does not work. Should that be permission.user_id = user.id and permission.resource_id = resource.id?

peletiah avatar Dec 14 '15 19:12 peletiah