There is a new undocumented feature in web2py: ASSIGNJ def index(): return dict(a={'whatever': ['you', 'want']})
# in view <script>{{=ASSIGNJS(whatever=whatever}}</script> now whatever is a JS variable. On Tuesday, 30 September 2014 09:00:20 UTC-5, Luca Liberti wrote: > > What I was looking for was exactly some hint on how to do some > "javascript" tuning from within web2py. I am aware this might be a > "borderline" question not > completely belonging to the forum. > > Thank you > > On Wed, Sep 24, 2014 at 9:22 PM, Niphlod <niph...@gmail.com> wrote: > >> let's break it down a bit..... >> It's one thing to have a field "prefilled" with a default value and it's >> a totally different one to have a field empty by default but when you click >> on it it "presets" the time to 00:00. >> >> The former needs a Field(...., default=something), the latter, given that >> the date(time) input is "managed" by a javascript component, needs a >> "javascript" tuning. >> >> Unfortunately, it seems that the version we're using can't accomodate for >> a "default time" for a datetime. >> >> -- >> 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 a topic in the >> Google Groups "web2py-users" group. >> To unsubscribe from this topic, visit >> https://groups.google.com/d/topic/web2py/AHiFwg2tZ4I/unsubscribe. >> To unsubscribe from this group and all its topics, send an email to >> web2py+unsubscr...@googlegroups.com. >> For more options, visit https://groups.google.com/d/optout. >> > > -- 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. For more options, visit https://groups.google.com/d/optout.