Re: [web2py] Re: how to create pdf report in web2py???

2016-05-18 Thread prashant joshi
https://vimeo.com/18601633 according to this video i have already done shown in this video after adding appreport plugins i,m getting error: Cannot import module 'applications.report.modules.modules' please suggest me what to do further???/ On Thu, May 19, 2016 at 12:29 AM, Dave S wrote: > >

[web2py] Re: How can I make a calculation in the view?

2016-05-18 Thread 黄祥
just do like usual in controller e.g. *controllers/default.py* def report_investor(): choose_investor = request.args(0) # query query_account = (db.account.investor == choose_investor) # row rows_account = db(query_account).select(orderby = ~db.account.id) return dict(rows_account = rows_account)

[web2py] How can I make a calculation in the view?

2016-05-18 Thread greenpoise
I have seen examples on how to calculate on DAL level using lambda. Could someone post an example (or point me to) of calculating values in the view? after an sql retrieval? or sql in the view? Thanks -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.

[web2py] Re: jqgrid Gurrido any experience

2016-05-18 Thread Henk huisman
Solved! In my controller that updated/deleted/added a row from the grid I changed the *return dict()* into just *return* Anyway, a very nice plugin. Op woensdag 18 mei 2016 21:30:27 UTC-4 schreef Henk huisman: > > jqgrid from Gurrido.net is a realy nice grid plugin. > > > I do not know what caus

[web2py] jqgrid Gurrido any experience

2016-05-18 Thread Henk huisman
jqgrid from Gurrido.net is a realy nice grid plugin. I do not know what causes the issue I am having with a grid I have a jqgrid that works fine on my local development machine with web2py 2.14.3. The load and edit ajax functions all work fine. If I put the same application on a remote we

[web2py] Re: list:reference how to show option popup instead of plain id's?

2016-05-18 Thread villas
If you specify more than one validator, e.g. [IS_NOT_EMPTY(), IS_IN_DB()] then you suppress the drop-down. From memory, you can simply re-specify the multiple widget with .widget In any case, this... > I have workaround: IS_IN_DB(, multiple=(1,999)) means you are asking to select at lea

[web2py] Re: Redirect after profile update

2016-05-18 Thread villas
Hi Ron, I said it was a similar function for good reason - I am simply trying to make corrections and help you get your code working :) One point is that you don't need to use profile_onaccept, you can simply redirect after using the normal auth.profile(). Best wishes. -- Resources: - http:/

[web2py] Re: Efficiency in compiled appliance

2016-05-18 Thread Niphlod
what would be the counter-arg here ? On Wednesday, May 18, 2016 at 9:42:50 PM UTC+2, Scott Hunter wrote: > > The web2py book, under Efficiency Tricks, says: > > >- Do not put many functions in the same controller but use many >controllers with few functions. > > When an appliance is comp

[web2py] Re: Empty cells while inserting module output into the database

2016-05-18 Thread Oguz Erkman
Yes, the context is correct. I am experimenting on building an NLP pipeline in web2py. I upload a text file and then I trigger different analysis tools from the web2py modules I create. The file passes through the tools one by one, tokenizer divides the and lemmatizer is one of those analysis t

[web2py] Efficiency in compiled appliance

2016-05-18 Thread Scott Hunter
The web2py book, under Efficiency Tricks, says: - Do not put many functions in the same controller but use many controllers with few functions. When an appliance is compiled, each of the functions is compiled into its own .pyc file, the same as would happen if they were in different func

Re: [web2py] Re: how to create pdf report in web2py???

2016-05-18 Thread Dave S
On Monday, May 16, 2016 at 1:49:55 PM UTC-7, Dragan Matic wrote: > > Here's a simple example, creating a PDF invoice in web2py app: > > This is the controller code: > def show_pdf_invoice(invoice_number, invoice): > from fpdf import FPDF > > pdf = FPDF() > pdf.add_page() > > pdf.s

[web2py] Re: Problem save datetime

2016-05-18 Thread Dave S
On Wednesday, May 18, 2016 at 9:55:57 AM UTC-7, Alessio Varalta wrote: > > Hi i have this table > > db.define_table('verbale', > > Field('partecipants',label=T('Partecipanti'),type="text",requires=IS_LENGTH(3000)), > Field('date_verbale_start',label=T('Data > inizio'),ty

Re: [web2py] how to develop ATC?

2016-05-18 Thread Dave S
On Wednesday, May 18, 2016 at 9:39:46 AM UTC-7, Richard wrote: > > :D > > I guess you may find someone who will help you to develop ATC with web2py > here, but with Django you would better to ask their mailing-list.. > > Richard > And we'd have to know something about what problem you were tr

[web2py] Re: web2py dynamic search form

2016-05-18 Thread Dave S
On Wednesday, May 18, 2016 at 6:58:03 AM UTC-7, Ghada Chabbouh wrote: > > pleasse i need a web2py dynamic search form > Does this help? SQLFORM.grid and SQLFORM.smartgrid These are two high level objects that create complex CRUD controls. They provide pagination, the ability to browse, search,

[web2py] Re: Empty cells while inserting module output into the database

2016-05-18 Thread Dave S
On Wednesday, May 18, 2016 at 6:58:03 AM UTC-7, Oguz Erkman wrote: > > Hello everyone, > > I am a novice programmer so please forgive me if my question is too simple. > > I created a module which finds lemmas of tokens in pretokenized text and > writes them into a file and into the database. > I

[web2py] Problem save datetime

2016-05-18 Thread Alessio Varalta
Hi i have this table db.define_table('verbale', Field('partecipants',label=T('Partecipanti'),type="text",requires=IS_LENGTH(3000)), Field('date_verbale_start',label=T('Data inizio'),type="datetime",requires=IS_DATETIME('%Y-%m-%d %H:%M:%S')), Field('date_verbal

Re: [web2py] how to develop ATC?

2016-05-18 Thread Richard Vézina
:D I guess you may find someone who will help you to develop ATC with web2py here, but with Django you would better to ask their mailing-list... Richard On Fri, May 13, 2016 at 9:12 AM, hafte agebash wrote: > how to develop ATC(agument trafic control simulation tool) using the > python-django?

Re: [web2py] posgresql connexion

2016-05-18 Thread Richard Vézina
Did you have a look in pg_hba.conf and /etc You have to allow the connection from local with password Richard On Sun, May 15, 2016 at 3:42 PM, Ghada Chabbouh wrote: > Hi every one > acctually i'm binginner in web2py , and i'm trying to develope a web app > i wrote this syntaxe: db = > DAL('p

[web2py] Re: posgresql connexion

2016-05-18 Thread Mirek Zvolský
You should create the database in Postgres database manager first (PgAdmin or so...). I use following steps: You should read how to start work with new Postgres server. In Linux/Debian I use "peer" authentication for user "postgres", i.e. I have in /etc/postgresql/9.4/main/pg_hba.conf the line

[web2py] web2py dynamic search form

2016-05-18 Thread Ghada Chabbouh
pleasse i need a web2py dynamic search form -- 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 Go

[web2py] Re: Mercurial and Windows 10

2016-05-18 Thread Roberto Betancur
same problem here! El sábado, 14 de mayo de 2016, 4:36:17 (UTC-3), mweissen escribió: > > I have tried to use the Mercurial Version Control System. > > There is the same web2py version (2.14.6) on a Linux Ubuntu server and on > a Windows 10 server. > No problem on the Linux server. But the Window

[web2py] Lengthy thread.lock.acquire() on ajax calls?

2016-05-18 Thread mattjn
When making consecutive ajax calls, we've noticed very lengthy TTFB (time-to-first-byte) values in the Chrome devtools for any request that goes through a web2py controller. When called individually, they do not appear to take nearly as long, but when fired off simultaneously as XHR, they see

[web2py] Re: smartgrid internals: where to find parent table id in oncreate?

2016-05-18 Thread Mirek Zvolský
Something like: place: id place (string) campaign id place_id (db.place) from (date) to (date) In smartgird, in oncreate for campaign, form.vars has fileds [id, from, to] only, but hasn't [place_id]. But I can find it as form.custom.inpval.place_id. I'm just curious if form.custom.i

[web2py] Re: Redirect after profile update

2016-05-18 Thread Ron Chatterjee
I thank you for your help villas and much appreciated. I guess the only two difference between your approach and mine is: (1) profile[0].id = consumer_rec = db(query).select().first() I believe they works the same. (2) But I may be wrong in doing. You have: form2 = SQLFORM(db.consumer

[web2py] how to develop ATC?

2016-05-18 Thread hafte agebash
how to develop ATC(agument trafic control simulation tool) using the python-django? figure example with sound and text and its code how to write and run in python-django IDLE..? like...and other similar .. -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://gi

[web2py] Empty cells while inserting module output into the database

2016-05-18 Thread Oguz Erkman
Hello everyone, I am a novice programmer so please forgive me if my question is too simple. I created a module which finds lemmas of tokens in pretokenized text and writes them into a file and into the database. I got what I wanted in the output file but I had a problem while inserting the outp

[web2py] posgresql connexion

2016-05-18 Thread Ghada Chabbouh
Hi every one acctually i'm binginner in web2py , and i'm trying to develope a web app i wrote this syntaxe: db = DAL('postgres://postgres:123@localhost:5432/Gestion_maintenance', pool_size=0,migrate=False) but i can't connect my postgresql database to my app ... any one could help me or is th

[web2py] Re: search_widget error: 'str' object has no attribute 'get'

2016-05-18 Thread Adam Drzewiecki
Thanks Anthony for your reply. Greetings Adam W dniu środa, 18 maja 2016 14:15:00 UTC+2 użytkownik Anthony napisał: > > On Wednesday, May 18, 2016 at 6:22:50 AM UTC-4, Adam Drzewiecki wrote: >> >> Hi everybody, >> >> I have some problem with my search_widget. >> I would like to create search_widg

[web2py] Re: MY auth mailer not wprking please check code and send me changes?

2016-05-18 Thread villas
It seems to me that Google SMTP server service is not so friendly. I gave up trying to work with it some time ago. I recommend that either you use your own ISP's server, or search for a professional solution. We have been very happy with fastmail.fm but there are many other low-cost or free s

[web2py] Re: search_widget error: 'str' object has no attribute 'get'

2016-05-18 Thread Anthony
On Wednesday, May 18, 2016 at 6:22:50 AM UTC-4, Adam Drzewiecki wrote: > > Hi everybody, > > I have some problem with my search_widget. > I would like to create search_widget with less fields, but i get > error: 'str' object has no attribute > 'get' > > My code: > search_options = {'string': ['=

[web2py] Re: search_widget error: 'str' object has no attribute 'get'

2016-05-18 Thread Adam Drzewiecki
I think, that this line makes troubles: File "C:\prg\src\tools\vmman\gluon\sqlhtml.py", line 1889, in search_menu W dniu środa, 18 maja 2016 13:37:09 UTC+2 użytkownik villas napisał: > > I wonder whether this is causing the problem: > > sqyhtml.py line 2513 > form = search_widget a

[web2py] Re: unique=True not working

2016-05-18 Thread villas
I think that if you add *unique *after the table has been created, DAL will not create the index on migration. I would suggest therefore that you create a unique index manually. BTW if you are discussing anything which happens at the DB level, please mention which DB you are using. -- Resou

[web2py] Re: search_widget error: 'str' object has no attribute 'get'

2016-05-18 Thread villas
I wonder whether this is causing the problem: sqyhtml.py line 2513 form = search_widget and search_widget(sfields, url()) or '' Does that line make any sense? -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code)

[web2py] Re: Redirect after profile update

2016-05-18 Thread villas
Hi Ron Whilst I am still not totally clear in what you are trying to do, it seems that your code to create your form2 is not written correctly. Maybe you can change it a little and simply redirect to this similar function ... def consumer_update(): if auth.user.user_type != 'Seller':

[web2py] unique=True not working

2016-05-18 Thread Pierre
Hi, I have this table : *db.define_table('trux',Field('tuser', 'reference auth_user', unique=True))* and this controller/function : *def testh():r=db.trux.insert(tuser=1)return locals()* I can insert as many duplicates as I want calling testh very strange?

[web2py] search_widget error: 'str' object has no attribute 'get'

2016-05-18 Thread Adam Drzewiecki
Hi everybody, I have some problem with my search_widget. I would like to create search_widget with less fields, but i get error: 'str' object has no attribute 'get' My code: search_options = {'string': ['=', '!=', '<', '>', '<=', '>=', 'starts with', 'contains', 'in', 'not in']} fields = [db

[web2py] Re: Problem running GAE SDK with web2py 2.14.5

2016-05-18 Thread Tommi Lahtonen
On Tuesday, May 10, 2016 at 8:35:56 PM UTC+3, Jacinto Parga wrote: > > Deploying GAE-applications with web2py 2.14.5 linux, GAE SDK 1.9.37 seems > ok > > I just tried web2py 2.14.6 on windows with appengine launcher 1.9.37 and it does not work without adding the appengine_config.py -- Resourc

[web2py] Re: Problem running GAE SDK with web2py 2.14.5

2016-05-18 Thread Tommi Lahtonen
On Tuesday, May 10, 2016 at 8:35:56 PM UTC+3, Jacinto Parga wrote: > > Deploying GAE-applications with web2py 2.14.5 linux, GAE SDK 1.9.37 seems > ok > > I just tried web2py 2.14.6 on windows with appengine launcher 1.9.37 and it does not work without adding the appengine_config.py -- Resourc

[web2py] Re: Problem running GAE SDK with web2py 2.14.5

2016-05-18 Thread Tommi Lahtonen
On Monday, April 18, 2016 at 2:09:27 PM UTC+3, Tommi Lahtonen wrote: > > > I have reported the defect to google but so far no help from them: > > https://code.google.com/p/googleappengine/issues/detail?id=12852&can=4&colspec=ID%20Type%20Component%20Status%20Stars%20Summary%20Language%20Priority%20O