[web2py] Problem of writing data with PyDal

2019-09-27 Thread tomasz bandura
Hello all, I noticed a very strange behaviour and i don't know what is a reason and how to solve this problem: 1. I have single Postgresql database and I use 2 separated application connected to it: a) standard web2py (2.16.1 stable version) application which reads and writes data With

Re: [web2py] Re: nginx, basic auth: internal error

2019-05-10 Thread tomasz bandura
No, I also clear the cache of browser to be sure there is no any active session. pt., 10 maj 2019 o 13:59 Jörg Schneider napisał(a): > Are you logged in in the admin application the same time (same browser) ? > > Am Mittwoch, 8. Mai 2019 08:49:34 UTC+2 schrieb tomasz bandura: &g

Re: [web2py] Re: nginx, basic auth: internal error

2019-05-08 Thread tomasz bandura
write a session file and > failing, you'll get an unrecoverable error. > > On Wednesday, 8 May 2019 07:49:34 UTC+1, tomasz bandura wrote: >> >> Hello, >> >> I use web2py (2.16.1) on 2 environments: >> 1. Embedded Rocket wsgi server >> 2. Deployed on nginx+

[web2py] nginx, basic auth: internal error

2019-05-08 Thread tomasz bandura
Hello, I use web2py (2.16.1) on 2 environments: 1. Embedded Rocket wsgi server 2. Deployed on nginx+uwsgi I have the same application on both env, connected to the same database. The application uses Basic Authentication, like in the example: def f1(): auth.basic() if auth.user: *##

[web2py] Datetime onSelect event

2018-04-16 Thread tomasz bandura
Hello, I need to do some action after selecting value in datetime field. After my investigation it looks the one way is to create my own datetime component with implemented 'onSelect' event. Another option is to use another datetime (jquery) control. I'd like to avoid it but i have no an idea

Re: [web2py] Import CSV issue - can't import new CSV

2018-02-08 Thread tomasz bandura
It looks You try to split date with '-' but you'll should use '/'. The result of splitting your date is whole date string, which is not a proper int value. 09.02.2018 03:37 "Peter Yoon" napisał(a): > Hello, > > I imported a csv to my table but there were issues in the csv.

Re: [web2py] confirm_registration form 'hardcoded' labels

2017-10-23 Thread tomasz bandura
Thanks, I will try to open an issue. Regarding button - label is translated...strange, I'll check it why :) T. 2017-10-23 19:09 GMT+02:00 Anthony : > Feel free to open an issue or submit a pull request. Note, looks like the > submit button label is hard coded as well. >

[web2py] confirm_registration form 'hardcoded' labels

2017-10-23 Thread tomasz bandura
Hello, I have to provide translation for 'confirm registration form' and I noticed different behaviour of first_name and last_name labels ( compared to 'password' fields). So I can only provide translation for Password and Confirm Password labels. In the *gluon.tools.py *

Re: [web2py] Re: Email with body from 'response.render'

2017-09-15 Thread tomasz bandura
Thank you , solved Tom 2017-09-14 23:40 GMT+02:00 黄祥 : > had you tried to use *.html file? > e.g. > *controllers/default.py* > def mail(): > table_id = request.args(0) > message = response.render('templates/mail/test.html', dict(table_id = > table_id) ) > >

[web2py] Email with body from 'response.render'

2017-09-14 Thread tomasz bandura
Hello, What is a difference in sending a html body from string and from template? 1. When i try to send email with body from string (e.g. 'html body' ) - it is send as expected: *html body* 2. But when I put this string into template and create body with , for example,

[web2py] Exception during password reset

2017-09-13 Thread tomasz bandura
Hello, My web2py version:' 2.15.4-stable+timestamp.2017.09.02.04.02.22' When I try reset password application raises exception: 'ascii' codec can't decode byte 0xc5 in position 9: ordinal not in range(128) (...) Function argument list (obj=, charset='utf-8', errors='strict') It looks the

[web2py] change_password validator

2017-08-18 Thread tomasz bandura
Hello, For the user registration I use just default validator (IS_STRONG) which has defined only minimum lenght (4). The problem is during password changing (form=auth() --> default/user/change_password) - validator is ignored and I can set password with length=1 Should I set a validator

Re: [web2py] Re: Remove current element from IS_IN_DB validator content

2017-07-14 Thread tomasz bandura
It works, Thank you! 2017-07-14 13:12 GMT+02:00 Leonel Câmara : > Assuming request.args(0) is the id of the record you're editing you can > just do. > > db.next_step.requires = IS_IN_DB( db(db.t_step.id != request.args(0)),' > t_step.id',db.t_step.name) > > -- >

[web2py] Remove current element from IS_IN_DB validator content

2017-07-14 Thread tomasz bandura
Hello, I created my model with self reference, something like this: db.define_table('t_step', Field('name'), Field('next_step', 'reference t_step') then I prepared SQLFORM with field validator IS_IN_DB: IS_IN_DB( db,'t_step.id',db.t_step.name) It works properly but I would like to add

[web2py] Error during populating dummy data

2013-10-26 Thread tomasz bandura
Hello, I noticed an error when I try to populate dummy data (i.e. populate(db.mytable,100)): My table : db.define_table('parameters_dict', Field('name','string',length=16) ) Error: class 'gluon.contrib.pg8000.errors.ProgrammingError' ('ERROR', '22001', 'value too long for type character

Re: [web2py] How to call a web service from web2py application?

2013-02-12 Thread tomasz bandura
Did you read http://web2py.com/books/default/chapter/29/14#Twitter-API? It is an example of Twitter RESTful+ json. T. 2013/2/12 at matifa...@gmail.com Want to call a web service from a web2py application. The service supports get/posts methos for taking input and gives response in json.

Re: [web2py] get table records using vars

2012-12-11 Thread tomasz bandura
Hello, For example: entries = db(db.entry.tags.contains(*request.vars.tag* )).select(db.entry.ALL) for tag in URL: {{=URL('default', 'index', vars=dict(tag=nnn))}} T. 2012/12/11 Hassan Alnatour halna...@gardeniatelco.com Dear ALL , Is there a way that i can get table records for table

Re: [web2py] get table records using vars

2012-12-11 Thread tomasz bandura
Ok, To complete my example: You should define two tables (db.py) db.define_table('tag',Field('name',length=16),format='%(name)s') db.define_table('entry', Field('title',length=64), # (...) some other fields Field('tags','list:reference tag')) 2012/12/11 hasan alnator

Re: [web2py] Re: framework benchmarks - web2py surprisingly slow?

2012-10-02 Thread tomasz bandura
Hello, Maybe i am not quite on a topic but... back to the beginning of the subject, I found the performance tests for web.py, which in my opinion should achieve good results (because it is simple). Tests are also primitive (just 'hello world'), only prepared for different environment: apache and

Re: [web2py] LOAD Ajax

2012-09-10 Thread tomasz bandura
try LOAD() with extension=False 2012/9/10 Hassan Alnatour halna...@gardeniatelco.com Dear ALL , i am having problems when i use the LOAD() in the page.load if i add any CSS with images like background:url(); and when i use the function URL('page') the url is rendered as

[web2py] URL() on *.load page

2012-08-23 Thread tomasz bandura
Hello, How to properly generate url on LOAD page (with ajax=False)? Image html tag: img src={{=URL('static','images/cat1.png')}} / Is rendered as: img src=/myapp/static/images.load/cat1.png/ Regards, Tomasz --

[web2py] Re: URL() on *.load page

2012-08-23 Thread tomasz bandura
... extension=False this is a little confusing ( it is appended to the function ), but it works 2012/8/23 tomasz bandura tomasz.band...@gmail.com Hello, How to properly generate url on LOAD page (with ajax=False)? Image html tag: img src={{=URL('static','images/cat1.png

Re: [web2py] Re: Chrome:LOAD and ajax problem

2012-08-03 Thread tomasz bandura
issue... Regards, Tomasz 2012/8/3 tomasz bandura tomasz.band...@gmail.com Hello, Application attached. default.py and advert.py have a function: def show(): return dict(test_message='show.load - default.py') and on the index.html there are LOAD declarations: {{=LOAD('advert','show.load

Re: [web2py] Re: Chrome:LOAD and ajax problem

2012-08-01 Thread tomasz bandura
...@gmail.com What do you mean it doesn't work? What happens? Can you show some code? On Tuesday, July 31, 2012 12:01:00 AM UTC-4, tomasz bandura wrote: Hello, I noticed the 'LOAD' function (with Ajax=true) doesn't work under Chrome , when it is used on layout page. Unfortunately Firebug doesn't

Re: [web2py] Re: web2py hangs while creating the mysql tables

2012-08-01 Thread tomasz bandura
Is it 'long' a mysql's reserved word? Regards Tomasz 2012/8/1 Aurelijus Useckas aurelijus.usec...@gmail.com this is the trigger i guess: db.define_table('maps', Field('name'), Field('last_name'), Field('long'), Field('lat'), format='%(name)s') On Wednesday, August

Re: [web2py] Re: web2py hangs while creating the mysql tables

2012-08-01 Thread tomasz bandura
Please look at: http://dev.mysql.com/doc/refman/5.0/en/reserved-words.html and probably it causes an error please try with different field's name. T. 2012/8/1 Aurelijus aurelijus.usec...@gmail.com I really have no clue.. Could it be? On Wed, Aug 1, 2012 at 3:36 PM, tomasz bandura

Re: [web2py] Re: Chrome:LOAD and ajax problem

2012-08-01 Thread tomasz bandura
Hello, It does not load at all.. During some test i found the case when it works: I create a new application ( version.: 1.99.7) and then create the same action 'show' , 'show.view' for two controllers: default.py and advert.py and when i put: {{=LOAD('advert','show.load',ajax=True)}} |

[web2py] Chrome:LOAD and ajax problem

2012-07-30 Thread tomasz bandura
Hello, I noticed the 'LOAD' function (with Ajax=true) doesn't work under Chrome , when it is used on layout page. Unfortunately Firebug doesn't show an error message, and only response is empty. The same page under Firefox works correctly. Is it any special way to declare LOAD on layout?

[web2py] Polish translation - small mistake

2012-05-24 Thread tomasz bandura
Hello, There is a misspelling in the Polish translation: 'try something like': 'sprób*ó*j czegos takiego jak' sholud be: 'try something like': 'sprób*u*j czegos takiego jak' Best regards Tomasz [source: dictionary http://www.sjp.pl/spr%F3bowa%E6]