On Tuesday, August 30, 2011 2:44:44 PM UTC-4, rami wrote:
>
>
> Anthony, I do have a question though. Looking at your first approach, 
> how do I even know what generic_patterns or views I need for my 
> functions.


It depends on how you want your functions to be accessed. As long as a given 
function has a specific named view associated with it, then you don't need a 
generic view at all. For example, if you have function 'myfunc' in 
/controllers/default.py, as long as you have a /views/default/myfunc.html 
view, you don't need a generic view for that function. Generic views are 
only used/needed when you don't have a specific view for a function.

There's some explanation near the end of this book 
section: http://web2py.com/book/default/chapter/03#Say-Hello

There is more detailed discussion in the context of services (JSON, 
XML): http://web2py.com/book/default/chapter/09#Generic-Views

Anthony

Reply via email to