Re: [web2py] Re: 2.18.5 LI(_class="dropdown-divider") bug?

2019-04-12 Thread Martin Weissenboeck
Try this code: response.menu = [ [T('Lectures'), False, URL('default', 'subjects'), []], [T('Students'), False, URL('main', 'students'), []], [T('Professors'), False, URL('main', 'professors'), []], [T('Blog'), False, URL('default', 'blog')], [T('News'), False, URL('default', '

[web2py] Sorting a Rows object by a particular field

2019-04-12 Thread Dave S
Pro tip: do not call your controller function "sorted". Getting past that, I have a Rows object (call it "rowed") that I've created from munching through the results of a select(). (Why? because for presentation reasons, I do an aggregation with custom logic.) In the past, ordering was done

Re: [web2py] Re: Web3py

2019-04-12 Thread Kevin Keller
Any thoughts on merging / collaborating with weppy? http://weppy.org/ Uses web2py dal and yatl.. and has some nifty things to make queries and modelling easier.. On Fri, Apr 12, 2019 at 6:03 AM Massimo Di Pierro < massimo.dipie...@gmail.com> wrote: > There is a lot to do but at this point it

Re: [web2py] Re: 2.18.5 LI(_class="dropdown-divider") bug?

2019-04-12 Thread lucas
alright, I fixed it. apparently in old versions of layout.html the =MENU() is used to create the html menu from response.menu. that code has been updated at some web2py version and changed to: {{for _item in response.menu or []:}} {{if len(_item)<4 or not _item[3]:}}

[web2py] Re: Web3py

2019-04-12 Thread En Ware
I'm trying to wrap my ahead around how web3py works by looking at the source I see __init__.py is the main code for the actually todo app. Is this going to be the case for all applications ? or is this just for a sample ? On Thursday, April 11, 2019 at 11:03:29 PM UTC-5, Massimo Di Pierro

[web2py] Problem with oracle query

2019-04-12 Thread gliporace
Hi, I just updated my web2py installation from 2.11 to 2.18.5, but the apps who make use of cx_Oracle for connecting to a Oracle database show this error when ther try to query a table/view: Exception ORA-00942: table or view does not exist The old web2py installation run without problems on a

[web2py] Re: Web3py

2019-04-12 Thread Massimo Di Pierro
In web3py an application is a folder, for example "myapp". It must have: applications/ myapp/ __init__.py templates/ static/ databases/ otherwise the structure is free. You are free to create models/ and controllers/ and organize code like in the old web2py but the entry point

Re: [web2py] Re: Web3py

2019-04-12 Thread Massimo Di Pierro
May steel some ideas from weppy but I do not want an ORM. That can be optional if you like we can isolate it in a module. On Friday, 12 April 2019 04:40:51 UTC-7, Kevin Keller wrote: > > Any thoughts on merging / collaborating with weppy? > > http://weppy.org/ > > Uses web2py dal and yatl.. > an

Re: [web2py] Re: Web3py

2019-04-12 Thread Carlos Cesar Caballero Díaz
I reaaly would like to use an ORM with web3py, in my opinion ORMs are better for organization when apps grow big and I like a lot the fat models and thin controllers approach, and it is some messy with pydal right now (https://github.com/Medisur/journalmanagement/blob/master/models/citation

[web2py] Re: Web3py

2019-04-12 Thread En Ware
Not getting examples to work is /examples/form or examples ? On Friday, April 12, 2019 at 10:29:21 AM UTC-5, Massimo Di Pierro wrote: > > In web3py an application is a folder, for example "myapp". It must have: > > applications/ > myapp/ > __init__.py > templates/ > static/ > da

Re: [web2py] Re: Web3py

2019-04-12 Thread Kevin Keller
I'm interestes in the orm Carlos. keller...@gmail.com Happy to test it but also work on it with you. On Fri, 12 Apr 2019, 18:46 En Ware, wrote: > Not getting examples to work is /examples/form or examples ? > > On Friday, April 12, 2019 at 10:29:21 AM UTC-5, Massimo Di Pierro wrote: >> >> In

Re: [web2py] Re: Web3py

2019-04-12 Thread Massimo Di Pierro
Can you make it a module on pypi? Or should we include it in pydal? -- 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

[web2py] Does anyone know if it's possible & how I can distinguish, from web2py perspective, 2 browser tabs?

2019-04-12 Thread João Matos
Does anyone know if it is possible and how I can distinguish, from web2py perspective, 2 tabs or windows (not Firefox containers) from the same browser? -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.goog

[web2py] Is it possible to send all args & vars from a view/controller to another using POST instead of GET?

2019-04-12 Thread João Matos
Is it possible to send all args and vars from a view/controller to another view/controller using POST instead of GET? -- 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

[web2py] Re: Sorting a Rows object by a particular field

2019-04-12 Thread João Matos
The orderby of the DAL or the ORDER BY of the SQL engine you use wouldn't do the job? sexta-feira, 12 de Abril de 2019 às 11:03:10 UTC+1, Dave S escreveu: > > Pro tip: do not call your controller function "sorted". > > Getting past that, I have a Rows object (call it "rowed") that I've > creat

[web2py] Does web2py support SSE (server sent events) from HTML5?

2019-04-12 Thread João Matos
Does web2py support SSE (server sent events) from HTML5? https://www.w3schools.com/html/html5_serversentevents.asp -- 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 Issu

[web2py] Re: Sorting a Rows object by a particular field

2019-04-12 Thread Dave S
On Friday, April 12, 2019 at 3:16:31 PM UTC-7, João Matos wrote: > > The orderby of the DAL or the ORDER BY of the SQL engine you use wouldn't > do the job? > > No, because of my custom aggregation (funkystr is an artifact of that). However, your question suggested an experiment that I may remem

[web2py] Re: Sorting a Rows object by a particular field

2019-04-12 Thread João Matos
In my case the first seems to be working. Check this rows = db(db.auth_user.id < 3).select() print('***') print(rows) print('---') print(rows.sort(lambda r: r["id"], reverse=True)) -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Sourc

[web2py] Re: Is it possible to send all args & vars from a view/controller to another using POST instead of GET?

2019-04-12 Thread Dave S
On Friday, April 12, 2019 at 3:12:55 PM UTC-7, João Matos wrote: > > Is it possible to send all args and vars from a view/controller to another > view/controller using POST instead of GET? > Is this as a redirect or a fetch? fetch's 2nd argument, data, selects for POST if not null, and urlenc

[web2py] Re: Is it possible to send all args & vars from a view/controller to another using POST instead of GET?

2019-04-12 Thread João Matos
redirect sexta-feira, 12 de Abril de 2019 às 23:59:46 UTC+1, Dave S escreveu: > > > > On Friday, April 12, 2019 at 3:12:55 PM UTC-7, João Matos wrote: >> >> Is it possible to send all args and vars from a view/controller to >> another view/controller using POST instead of GET? >> > > Is this as a

[web2py] Re: Is it possible to send all args & vars from a view/controller to another using POST instead of GET?

2019-04-12 Thread Dave S
On Friday, April 12, 2019 at 4:25:48 PM UTC-7, João Matos wrote: > > redirect > Then it is actually the client (browser?) that accesses the other function, you're just telling it where to make the new request (you can put vars and args in the URL, but you don't control the method). Can you

[web2py] Re: Is it possible to send all args & vars from a view/controller to another using POST instead of GET?

2019-04-12 Thread João Matos
So no option for redirect with POST. That is a shame. The book mentions request.post_vars. In what situation would one use it? sábado, 13 de Abril de 2019 às 00:33:56 UTC+1, Dave S escreveu: > > > > On Friday, April 12, 2019 at 4:25:48 PM UTC-7, João Matos wrote: >> >> redirect >> > > > Then it

[web2py] How can I get the value from the hidden input field (outside the grid) while in the view?

2019-04-12 Thread João Matos
I wrote this {{extend 'layout.html'}}