Re: [web2py] py4web questions
See my answer https://groups.google.com/d/msg/web2py/cgg6M7B_wkI/lWd-Ytt3DQAJ On Monday, 20 January 2020 22:55:28 UTC-8, Bruno Sarverry wrote: > > Hello John! did you solve it? I have the same problem. > > El jueves, 26 de septiembre de 2019, 6:05:52 (UTC-3), John Bannister > escribió: >> >> Hi Massimo, >> >> Have one more question which may or may not be related. >> >> I have multiple controllers all including the same layout.html. In the >> layout.html the navbar should display the user logged in (or not). I see in >> the _scaffold app the login menu is created using globals().get('user') >> which works fine if we are returning the user=auth.get_user() to the >> template. >> >> Question is do I need to return user=auth.get_user() from each action or >> is there some way of accessing the user/login information from the >> templates and in particular layout.html? >> >> And one more which is how to deal with images in py4web? I have tried to >> upload an image using field of type upload using standard Form. When I look >> at the record again or try to edit it says no image selected. Guess there >> is the equivalent of download missing somewhere. Any help appreciated. >> >> John >> -Original Message- >> From: web...@googlegroups.com [mailto:web...@googlegroups.com] On Behalf >> Of Massimo Di Pierro >> Sent: 26 September 2019 09:02 >> To: web2py-users >> Subject: [web2py] py4web questions >> >> Good question. I will try post a tutorial in the next few days. But the >> idea is you associate tags to a user and then give permissions based on the >> tags. The tag API is very simple so I recommend you meanwhile look at the >> source. >> >> -- >> Resources: >> - http://web2py.com >> - http://web2py.com/book (Documentation) >> - http://github.com/web2py/web2py (Source code) >> - https://code.google.com/p/web2py/issues/list (Report Issues) >> --- >> You received this message because you are subscribed to the Google Groups >> "web2py-users" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to web...@googlegroups.com. >> To view this discussion on the web visit >> https://groups.google.com/d/msgid/web2py/b6009627-7b67-405f-a98e-1dbcb5dbb1e2%40googlegroups.com. >> >> >> >> -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to web2py+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/web2py/b594d875-42fd-48c1-bd38-6c42e316ed14%40googlegroups.com.
Re: [web2py] py4web questions
Hello John! did you solve it? I have the same problem. El jueves, 26 de septiembre de 2019, 6:05:52 (UTC-3), John Bannister escribió: > > Hi Massimo, > > Have one more question which may or may not be related. > > I have multiple controllers all including the same layout.html. In the > layout.html the navbar should display the user logged in (or not). I see in > the _scaffold app the login menu is created using globals().get('user') > which works fine if we are returning the user=auth.get_user() to the > template. > > Question is do I need to return user=auth.get_user() from each action or > is there some way of accessing the user/login information from the > templates and in particular layout.html? > > And one more which is how to deal with images in py4web? I have tried to > upload an image using field of type upload using standard Form. When I look > at the record again or try to edit it says no image selected. Guess there > is the equivalent of download missing somewhere. Any help appreciated. > > John > -Original Message- > From: web...@googlegroups.com [mailto: > web...@googlegroups.com ] On Behalf Of Massimo Di Pierro > Sent: 26 September 2019 09:02 > To: web2py-users > Subject: [web2py] py4web questions > > Good question. I will try post a tutorial in the next few days. But the > idea is you associate tags to a user and then give permissions based on the > tags. The tag API is very simple so I recommend you meanwhile look at the > source. > > -- > Resources: > - http://web2py.com > - http://web2py.com/book (Documentation) > - http://github.com/web2py/web2py (Source code) > - https://code.google.com/p/web2py/issues/list (Report Issues) > --- > You received this message because you are subscribed to the Google Groups > "web2py-users" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to web...@googlegroups.com . > To view this discussion on the web visit > https://groups.google.com/d/msgid/web2py/b6009627-7b67-405f-a98e-1dbcb5dbb1e2%40googlegroups.com. > > > > -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to web2py+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/web2py/3dcd57f6-5e68-4af3-b207-6a0e95f235a1%40googlegroups.com.
RE: [web2py] py4web questions
Thanks Massimo much appreciated and looking forward to the tutorial. Will check out the tag API in the meantime. -Original Message- From: web2py@googlegroups.com [mailto:web2py@googlegroups.com] On Behalf Of Massimo Di Pierro Sent: 26 September 2019 09:02 To: web2py-users Subject: [web2py] py4web questions Good question. I will try post a tutorial in the next few days. But the idea is you associate tags to a user and then give permissions based on the tags. The tag API is very simple so I recommend you meanwhile look at the source. -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to web2py+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/web2py/b6009627-7b67-405f-a98e-1dbcb5dbb1e2%40googlegroups.com. -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to web2py+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/web2py/018701d57440%24c135dfc0%2443a19f40%24%40gmail.com.