[web2py] Re: Can't access https after changed http port to 8000

2019-09-12 Thread Jirawat Kusolpredee
If anyone facing the same problem here what I did seem that mod_wsgi was obsoleted so I solved the problem by migrated to nginx with uwsgi. On Monday, August 12, 2019 at 12:34:32 AM UTC+7, Jirawat Kusolpredee wrote: > > I'm running a web server and do a port forward from router to server. > My

Re: [web2py] Re: How do I solve this error: NameError: name 'person_id' is not defined in KPax2

2019-09-12 Thread Massimo Di Pierro
Please do. KPax had some good idea. It should be ported to py4web. On Thursday, 12 September 2019 02:09:14 UTC-7, Lovedie JC wrote: > > Auth.iser.id works. > Just the cPickle issues. > Maybe I'll be on and off asking more about it. > Regards > > > On Thu, 12 Sep 2019, 09:16 Massimo Di Pierro

Re: [web2py] py4web has now a grid ...

2019-09-12 Thread Massimo Di Pierro
To clarify. I do not like SFC because I do not think js and html belong to the same file. py4web has a utils.js which implements a TFC Two-File-Components (I claim copyright). This is undocumented and you will not see it in other vue apps. Basically each component has on js and one html file.

Re: [web2py] py4web has now a grid ...

2019-09-12 Thread Massimo Di Pierro
This is really cool. I will make a version of mtable.html that uses it. On Thursday, 12 September 2019 05:52:52 UTC-7, Carlos Costa wrote: > > I liked it. > Much more faster and responsive. > > I didn't get how use search properly. > > I have on suggestion for letting grid more mobile friendly. >

Re: [web2py] py4web has now a grid ...

2019-09-12 Thread Massimo Di Pierro
Thank you. very valuable feedback. The point of the new grid is that it comes with a mtable.html template. We can change it to make it look more datatable. On Thursday, 12 September 2019 09:53:36 UTC-7, John Bannister wrote: > > Hi Massimo, > > > > Some feedback for you on the new grid (which

RE: [web2py] py4web has now a grid ...

2019-09-12 Thread John Bannister
Hi Massimo, Some feedback for you on the new grid (which is looking very cool) and which I played with a bit today. Basically I connected to a MySQL db and loaded some existing medium sized tables (~400K records) and sort of compared it with web2py grid (standard web2py) and also

[web2py] Determinign what information get displayed based on their content

2019-09-12 Thread mostwanted
In my database i have items i am selling, one of the fields is quantity which refers to the number of items still available for purchase, what i want is for that item not to be displayed when quantity reaches 0. Initially i had the items get deleted when quantity is zero until i realized that

Re: [web2py] py4web has now a grid ...

2019-09-12 Thread Carlos Costa
It's done. But I have a question: where will we put component styling? I add an table.css file and linked in layout.html but I think it belongs to the component. I wish we would use Vue SFC format. Now is possible to use SFC components without using bundlers. Em qui, 12 de set de 2019 às 09:52,

[web2py] Re: Overiding the auth table ID fields to allow for release over pillars (Development, Acceptance, Production)

2019-09-12 Thread Davidiam
We have looked in this further, and due to the autoincremented ID fields in the Auth tables, we are going to have a very complicated release process. The problem is that the ID will be used in all references to the users and groups but between pillars (DEV,ACC,PRO) the ID's may not be the same

Re: [web2py] py4web has now a grid ...

2019-09-12 Thread Carlos Costa
I liked it. Much more faster and responsive. I didn't get how use search properly. I have on suggestion for letting grid more mobile friendly. Take a look at this snippet https://codepen.io/andornagy/pen/EVXpbR It is pure CSS. It transform columns into rows in a card style table. I have used it,

[web2py] Re: How can I update the record in one table with value entry of another table as soon as the value is entered?

2019-09-12 Thread villas
Well done for getting it working... We're all learning from each other here! :) On Thursday, 12 September 2019 12:27:27 UTC+1, mostwanted wrote: > > Sorry @villas its just a bad habit that i have somehow over time gotten > used to but i will heed your advice, thank you. > > Mostwanted > > On

[web2py] Re: How can I update the record in one table with value entry of another table as soon as the value is entered?

2019-09-12 Thread mostwanted
Sorry @villas its just a bad habit that i have somehow over time gotten used to but i will heed your advice, thank you. Mostwanted On Thursday, September 12, 2019 at 12:43:29 PM UTC+2, villas wrote: > > for item1 in item1: > > I mentioned this to you before -- please do not do this! > It is a

[web2py] Re: How can I update the record in one table with value entry of another table as soon as the value is entered?

2019-09-12 Thread mostwanted
Thank you everyone for your input, i was finally was able to solve my problem, i added these two lines & erased everything else (smile) & it worked like a charm. diff=db.product(key).amount-value db(db.product.id==db.product(key).id).update(amount=diff) The whole code: total =

[web2py] Re: How can I update the record in one table with value entry of another table as soon as the value is entered?

2019-09-12 Thread villas
for item1 in item1: I mentioned this to you before -- please do not do this! It is a really bad practice which will cause terrible problems for you. For example, do this instead: for i in item1: Best wishes for your program. -- Resources: - http://web2py.com - http://web2py.com/book

Re: [web2py] Re: How do I solve this error: NameError: name 'person_id' is not defined in KPax2

2019-09-12 Thread Lovedie JC
Auth.iser.id works. Just the cPickle issues. Maybe I'll be on and off asking more about it. Regards On Thu, 12 Sep 2019, 09:16 Massimo Di Pierro wrote: > wow that is a very old app. It has some good ideas but it also has bugs. > It was a proof of concept. I believe person_id in that context

[web2py] Re: 1215 Cannot add foreign key constraint

2019-09-12 Thread Dave S
On Wednesday, September 11, 2019 at 1:55:04 PM UTC-7, Steve wrote: > > Hi Dave, > > After performing a Fake_migration_all=True the Db files where created in > de app/databases folder. > So, in de admin i can see all of the tables. > > But, unfortunatly the tables where NOT created in the

[web2py] py4web has now a grid ...

2019-09-12 Thread Massimo Di Pierro
... it is incomplete. It is experimental. The API is subject to change. But I could use some community feedback: from py4web.utils.publisher import Publisher, ALLOW_ALL_POLICY # exposes services necessary to access the db via ajax publisher = Publisher(db, policy=ALLOW_ALL_POLICY) # expose

[web2py] Re: How do I solve this error: NameError: name 'person_id' is not defined in KPax2

2019-09-12 Thread Massimo Di Pierro
wow that is a very old app. It has some good ideas but it also has bugs. It was a proof of concept. I believe person_id in that context should be session.person_id or auth.user.id But I cannot promise it will work with this change. On Tuesday, 10 September 2019 13:31:11 UTC-7, Maurice Waka