Re: [web2py] Re: Unable to send email on server in web2py.....

2014-01-06 Thread Akash Agrawall
{} (534, '5.7.14 < https://accounts.google.com/ContinueSignIn?sarp=1&scc=1&plt=AKgnsbtQh\n5.7.14wnWg7iNJ76cQ-TNYHbtQ4Ow5zf3X78ZYd_hWCz-uLz6p26qOHkaLNwiHYAacQbCgpsTo8N\n5.7.14 jovPqLm6zPKwliPF7LV0Ods2eHGtAOyMq6tvuceciSmNFYaNaMF6ZmW3zhB5u4us_dAx0I\n5.7.14 NHzBmG5CGtHpEWBgLHx3NOC35I2gLQUppirDJCz1Eb71V

Re: [web2py] routes.py Problem

2014-01-06 Thread Rockiger
Hi Jonathan, many thanks for the answer: Here ist mit request object: http://pastie.org/8605943 The URL ist http://rockiger.com/de/domainfactory/kontoeroeffnung . It seems there is a variable *request.uri_language: de *in that case. It w

Re: [web2py] Re: Where should I put my application logic code?

2014-01-06 Thread Alex
thanks! that's a good tip. Unfortunately the error still exists: ImportError: No module named myapp.modules.myapp_room the file modules/myapp_room.py exists on the server. what else could be missing? Alex Am Montag, 6. Januar 2014 01:32:09 UTC+1 schrieb 黄祥: > > i think it related with module

[web2py] Re: web2py running en AppFog

2014-01-06 Thread José Antonio López Lorenzo
1.- Create an appfog acount in https://www.appfog.com/ 2.- Login in 3,- create a python app. 4.- the name of application is, for example, 'NAME_APP' (url: http://NAME_APP.eu01.aws.af.cm/) 5.- in local install 'af' (gem install af) 6.- af login 7.- modify wsgi.py: Introducir código aquí...#!/usr/b

Re: [web2py] Re: Where should I put my application logic code?

2014-01-06 Thread 黄祥
it's hard to help you track the error. please try to create the module from simple like in the book. e.g. */test/modules/justforlearn.py* from gluon import * def ip(): return current.request.client */test/controllers/default.py* from gluon.custom_import import track_changes; track_changes(True) i

Re: [web2py] Re: Unable to send email on server in web2py.....

2014-01-06 Thread Tim Richardson
Gmail probably requires a secure connection so your tls setting may be wrong -- 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 bec

Re: [web2py] Re: Unable to send email on server in web2py.....

2014-01-06 Thread 黄祥
please try this on your models. mail = auth.settings.mailer mail.settings.server = 'smtp.gmail.com:587' or 'logging' mail.settings.sender = 'em...@gmail.com' mail.settings.login = 'em...@gmail.com:password' best regards, stifan -- Resources: - http://web2py.com - http://web2py.com/book (Documen

Re: [web2py] Re: Inserting to db from module. Why do I need to keep restarting Web2py?

2014-01-06 Thread Richard Vézina
There is chance that it still broken... If you have put the track changes line in your model, it should work if you don't have access to the mods you have made to your module, it because it still broken... There is many post on the list about this issue. Since I am still using 2.4.7 and can't sa

Re: [web2py] Re: Unable to send email on server in web2py.....

2014-01-06 Thread Akash Agrawall
Still same error. it's too urgent for me you didn't mention anything about mail.settings.tls... I tried all three combinations 1. commenting it out 2. keeping it false 3. keeping it true still same output (a flash message showing "unable to send mail") On Mon, Jan 6, 2014 at 7:55 PM, 黄祥

Re: [web2py] routes.py Problem

2014-01-06 Thread Jonathan Lundell
On 6 Jan 2014, at 1:17 AM, Rockiger wrote: > Hi Jonathan, > > many thanks for the answer: > > Here ist mit request object: http://pastie.org/8605943 > > The URL ist http://rockiger.com/de/domainfactory/kontoeroeffnung. > > It seems there is a variable request.uri_language: de in that case. >

[web2py] How to format rows in a grid in SQLFORM.grid?

2014-01-06 Thread Omar Meat Boy Gutiérrez
I am using SQLFORM.grid. I'd like to classify data with colors, for example: | If data in first row is type A| I'd apply the green color to row. | -

[web2py] widget=lambda k,v: SQLFORM.widgets.radio.widget(k, v, _style='ul')

2014-01-06 Thread Annet
In my table definition I have the following field: Field('title', length=3, requires=IS_IN_SET(['Mr', 'Mrs', 'Ms'], error_message='Selecta title'), widget=lambda k,v: SQLFORM.widgets.radio.widget(k, v, _style='ul')), In a form the radio buttons are still rendered in a table, why? Kind regar

[web2py] Re: Change auth.wiki _create form

2014-01-06 Thread Dave S
On Sunday, January 5, 2014 7:57:54 AM UTC-8, Ezer Silva wrote: > > Well, the solution was much simpler, just put these lines in db.py: > > auth.wiki(resolve=False) > db.wiki_page.body.widget = advanced_editor > :-) /dps -- Resources: - http://web2py.com - http://web2py.com/book (Documentation

[web2py] Re: cpdb from sqlite to postgresql

2014-01-06 Thread Dave S
See below: On Sunday, January 5, 2014 12:32:26 PM UTC-8, mweissen wrote: > > > I want to change from sqlite to postgresql. > > At first I have installed postgresql and prepared everything as described > in the book. Next I have built a sample application > with a line like > > db1 = DAL("postgr

[web2py] Re: How to format rows in a grid in SQLFORM.grid?

2014-01-06 Thread Omar Meat Boy Gutiérrez
My new approach is use TABLE() helper with TR() and TD(). However I lost my header! I need this because sometimes is useful for the user order table by items. Suggestions? def myformat(rows): #import gluon #nuevo = gluon.dal.Rows() new = TABLE() for i in rows: if i.acc

Re: [web2py] widget=lambda k,v: SQLFORM.widgets.radio.widget(k, v, _style='ul')

2014-01-06 Thread Richard Vézina
Could it be possible that the keyword is not _style, but style? Richard On Mon, Jan 6, 2014 at 12:49 PM, Annet wrote: > In my table definition I have the following field: > > > Field('title', length=3, requires=IS_IN_SET(['Mr', 'Mrs', 'Ms'], > error_message='Selecta title'), widget=lambda k,v:

[web2py] styling widget divs

2014-01-06 Thread Annet
I have the following field definition in a table: Field('title', length=8, requires=IS_IN_SET(['Mr', 'Mrs'. 'Ms']), widget=lambda k,v: SQLFORM.widgets.radio.widget(k, v, style='divs')), I would like to style the radio widget, but adding _class='radio' to the widget function does not add a class

Re: [web2py] styling widget divs

2014-01-06 Thread Richard Vézina
You can try this : **{'_class': 'radio'} As a kargs... Richard On Mon, Jan 6, 2014 at 1:53 PM, Annet wrote: > I have the following field definition in a table: > > Field('title', length=8, requires=IS_IN_SET(['Mr', 'Mrs'. 'Ms']), > widget=lambda k,v: SQLFORM.widgets.radio.widget(k, v, style=

[web2py] Re: Virtual Field and sqlform.grid

2014-01-06 Thread sunny
I think, you need to delete the old session files of your application. I had the same problem. Am Mittwoch, 20. November 2013 19:26:23 UTC+1 schrieb Eduardo Cruz: > > Whe I use a table that has some a virtual field sqlform.grid does not works > > 'Row' object has no attribute 'unknown' > > and th

Re: [web2py] styling widget divs

2014-01-06 Thread Richard Vézina
Or you will have to create a custom widget... You can grab the radio.widget in /gluon/sqlhtml.py ans search for RadioWidget class... You can turn it into a method with the help of the book. But the kargs above should work as far as I can see look at the code of the RadioWidget... Richard On Mo

[web2py] Re: Virtual Field and sqlform.grid

2014-01-06 Thread sunny
Field.Virtual has a name attribute which has to be set: db.Post.category_list = Field.Virtual( 'category_list', lambda row: get_category_list(row.Post) ) Am Mittwoch, 20. November 2013 19:26:23 UTC+1 schrieb Eduardo Cruz: > > Whe I use a table that has some a virtual field sqlform.grid does not

Re: [web2py] Why web2py and AnguljarJS?

2014-01-06 Thread Richard Vézina
Angular client side programming, web2py server side programming. Angular less bandwidth, web2py more bandwidth But you can easily transform web2py to only serve the data through JSON... Richard On Sun, Jan 5, 2014 at 8:22 PM, António Ramos wrote: > I´m using angular recently and for UI Exper

Re: [web2py] widget=lambda k,v: SQLFORM.widgets.radio.widget(k, v, _style='ul')

2014-01-06 Thread Anthony
Indeed, the keyword is "style", not "_style". Anthony On Monday, January 6, 2014 1:46:28 PM UTC-5, Richard wrote: > > Could it be possible that the keyword is not _style, but style? > > Richard > > > On Mon, Jan 6, 2014 at 12:49 PM, Annet > > wrote: > >> In my table definition I have the followi

[web2py] Need more than one value to unpack

2014-01-06 Thread Akash Agrawall
I am getting this error: "Need more than one value to unpack" *db.py:* class IS_CATEGORYIT(object): def __init__(self, error_message="Zip code not allowed"): self.error_message = error def __call__(self, value): error = None print len(value) if len(value)==0

[web2py] Re: Need more than one value to unpack

2014-01-06 Thread Dave S
On Monday, January 6, 2014 12:32:01 PM UTC-8, Akash Agrawall wrote: > > I am getting this error: > "Need more than one value to unpack" > > Can you tell us which line the error message is referencing? Is there a traceback in the ticket? /dps > *db.py:* > class IS_CATEGORYIT(object): > d

Re: [web2py] styling widget divs

2014-01-06 Thread Paolo Caruccio
The radiowidget function returns https://github.com/web2py/web2py/blob/master/gluon/sqlhtml.py#L384 parent(*opts, **attr) so the kargs solution of Richard works but not when style is 'divs' because the parent is 'CAT' https://github.com/web2py/web2py/blob/master/gluon/sqlhtml.py#L364 and http

Re: [web2py] styling widget divs

2014-01-06 Thread Richard Vézina
Could the CAT just be replaced by another DIV? Richard On Mon, Jan 6, 2014 at 3:56 PM, Paolo Caruccio wrote: > The radiowidget function returns > https://github.com/web2py/web2py/blob/master/gluon/sqlhtml.py#L384 > > parent(*opts, **attr) > > so the kargs solution of Richard works but not when

[web2py] Re: Why web2py and AnguljarJS?

2014-01-06 Thread Simon Ashley
> > One point of view and YMMV. It depends on your application. You can build > very effective one page apps (typically the domain of client side tools) > with standard w2p components (.js, jquery). After all it's a framework > using a mix of tools. One can argue that w2p has broader scope, is

[web2py] !! NEW ADMIN !!

2014-01-06 Thread samuel bonill
Admin Plus(A-Plus) is a web2py plugin that provides an easy-to-use interface for managing your data link: https://github.com/pyner/admin_plus install 1. Download and install the plugin 2. go to "127.0.0.1:8000//plugin_admin_plus/install" 3. Get the permissions " plugin_admin_plus_superuser " i

Re: [web2py] styling widget divs

2014-01-06 Thread Paolo Caruccio
That was the solution I proposed. Il giorno lunedì 6 gennaio 2014 22:10:04 UTC+1, Richard ha scritto: > > Could the CAT just be replaced by another DIV? > > Richard > > > On Mon, Jan 6, 2014 at 3:56 PM, Paolo Caruccio > > > wrote: > >> The radiowidget function returns >> https://github.com/web2

Re: [web2py] styling widget divs

2014-01-06 Thread Richard Vézina
Ok, seems like a easy one, why not just commit the change on github? :) Richard On Mon, Jan 6, 2014 at 4:22 PM, Paolo Caruccio wrote: > That was the solution I proposed. > > Il giorno lunedì 6 gennaio 2014 22:10:04 UTC+1, Richard ha scritto: >> >> Could the CAT just be replaced by another DIV?

Re: [web2py] !! NEW ADMIN !!

2014-01-06 Thread Richard Vézina
Nice! Richard On Mon, Jan 6, 2014 at 4:19 PM, samuel bonill wrote: > Admin Plus(A-Plus) is a web2py plugin that provides an easy-to-use > interface for managing your data > > link: https://github.com/pyner/admin_plus > > install > > 1. Download and install the plugin > 2. go to "127.0.0.1:8000

[web2py] Re: Need more than one value to unpack

2014-01-06 Thread Anthony
Yes, please provide more detail. Also, requires=IS_CATEGORYIT should be requires=IS_CATEGORYIT(). Anthony On Monday, January 6, 2014 3:41:35 PM UTC-5, Dave S wrote: > > On Monday, January 6, 2014 12:32:01 PM UTC-8, Akash Agrawall wrote: >> >> I am getting this error: >> "Need more than one value

[web2py] outer join? i guess

2014-01-06 Thread lucas
hey everyone, ok i have a table of companies: db.define_table('companys', Field('company_name', length=128, requires=NE, comment='Legal Name of the Company or Entity.'), etc...) and the auth_user table with the added field: db.define_table( auth.settings.table_user_name, ...

[web2py] Re: need help for rewrite on routes.py

2014-01-06 Thread galoshes
Hello, I would like to revive this older thread (which also relates to this one: https://groups.google.com/forum/#!topic/web2py/ff1syTIl12o). I'm new to web2py, and so far have been finding my way around ok (thanks to the excellent docs), but the particular problem of mapping controllers and fu

[web2py] SQLFORM.grid oncreate how can I find out the ID of the record just created?

2014-01-06 Thread Jim S
Using SQLFORM.grid, created a function assigned to the oncreate callback. SQLFORM.grid(., oncreate=myfunction) def myfunction(form): redirect(URL('workorders',args=('workorder','edit',form.vars.workorderId),user_signature=True)) return But, I'm getting a value of None passed for fo

[web2py] Re: SQLFORM.grid oncreate how can I find out the ID of the record just created?

2014-01-06 Thread Jim S
Or, to re-phrase my question; How can I redirect to the edit page for a record as soon as it is added through the 'new' page using SQLFORM.grid? -Jim On Monday, January 6, 2014 4:28:02 PM UTC-6, Jim S wrote: > > Using SQLFORM.grid, created a function assigned to the oncreate callback. > > SQLFO

[web2py] Re: SQLFORM.grid oncreate how can I find out the ID of the record just created?

2014-01-06 Thread Anthony
Instead of form.vars.workorderId, use form.vars.id. Anthony On Monday, January 6, 2014 5:37:12 PM UTC-5, Jim S wrote: > > Or, to re-phrase my question; > > How can I redirect to the edit page for a record as soon as it is added > through the 'new' page using SQLFORM.grid? > > -Jim > > On Monday,

Re: [web2py] Re: Unable to send email on server in web2py.....

2014-01-06 Thread Alan Etkin
El lunes, 6 de enero de 2014 12:26:48 UTC-3, Akash Agrawall escribió: > > Still same error. it's too urgent for me > It appears gmail is using some sort of smtp service lock for your application account: http://designoservices.com/smtp-error-534-5-7-14-54-sending-mail-through-cake-or-ph

[web2py] Re: SQLFORM.grid oncreate how can I find out the ID of the record just created?

2014-01-06 Thread Jim S
Sorry Anthony, should have caught that myself. Worked like a champ. -Jim On Monday, January 6, 2014 4:43:54 PM UTC-6, Anthony wrote: > > Instead of form.vars.workorderId, use form.vars.id. > > Anthony > > On Monday, January 6, 2014 5:37:12 PM UTC-5, Jim S wrote: >> >> Or, to re-phrase my questio

[web2py] Re: SQLFORM.grid oncreate how can I find out the ID of the record just created?

2014-01-06 Thread Anthony
Wasn't obvious. I had to look at the code to confirm it. On Monday, January 6, 2014 5:47:56 PM UTC-5, Jim S wrote: > > Sorry Anthony, should have caught that myself. Worked like a champ. > > -Jim > > On Monday, January 6, 2014 4:43:54 PM UTC-6, Anthony wrote: >> >> Instead of form.vars.workorderI

[web2py] Re: Unable to send email on server in web2py.....

2014-01-06 Thread Cliff Kachinske
On webfaction you can set up an email account and access it directly from within web2py, thus eliminating the transmission to gmail. On Saturday, January 4, 2014 3:40:11 AM UTC-5, Akash Agrawall wrote: > > Hie folks.. I know this question is already been asked but I didn't get > any help from th

[web2py] Re: cpdb from sqlite to postgresql

2014-01-06 Thread Alan Etkin
> > The result is an error message: >> >> EXCEPTION: could not make a copy of the database >> Failure to connect, tried 5 times: >> Traceback (most recent call last): >> File "gluon/dal.py", line 7766, in __init__ >> self._adapter = ADAPTERS[self._dbname](**kwargs) >> File "gluon/dal.py",

[web2py] Re: outer join? i guess

2014-01-06 Thread lucas
ok, i got lucky. this seems to work perfectly: db((tUser.id==auth.user.id) | (tUser.id==None)).select(tCmp.ALL, orderby=tCmp.company_name, left=tUser.on((tCmp.id==tUser.firm_id))) but honestly, i have no idea why it works. can someone explain this to me? it is almost like the left condition,

Re: [web2py] routes.py Problem

2014-01-06 Thread Rockiger
Thanks again, this is much more than I exspectet. I will look into this, and post back. Best, Marco On Monday, January 6, 2014 4:50:17 PM UTC+1, Jonathan Lundell wrote: > > On 6 Jan 2014, at 1:17 AM, Rockiger > > wrote: > > Hi Jonathan, > > > > many thanks for the answer: > > > > Here ist

Re: [web2py] !! NEW ADMIN !!

2014-01-06 Thread Samuel Marks
Very nice! Samuel Marks http://linkedin.com/in/samuelmarks On Tue, Jan 7, 2014 at 8:29 AM, Richard Vézina wrote: > Nice! > > Richard > > > On Mon, Jan 6, 2014 at 4:19 PM, samuel bonill wrote: > >> Admin Plus(A-Plus) is a web2py plugin that provides an easy-to-use >> interface for managing your

[web2py] download file

2014-01-06 Thread sonu kumar
Hi, I have an application, which takes query in a form and after submitting this form result comes in upload folder in text file which I want to download. Please let me know how to download this. Thanks -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://git

Re: [web2py] Re: web2py app like adminer

2014-01-06 Thread samuel bonill
hi all already available A-PLUS (admin plus) in : https://groups.google.com/forum/#!topic/web2py/irlm_8dGSnQ 2014/1/2 rif > https://github.com/rif/web2admin it's something like a django admin. > Maybe it can help. > > -rif > > joi, 2 ianuarie 2014, 03:54:43 UTC+2, samuel bonill a scris: >>

Re: [web2py] Re: need help for rewrite on routes.py

2014-01-06 Thread Jonathan Lundell
On 6 Jan 2014, at 1:55 PM, galoshes wrote: > Hello, I would like to revive this older thread (which also relates to this > one:https://groups.google.com/forum/#!topic/web2py/ff1syTIl12o). > > I'm new to web2py, and so far have been finding my way around ok (thanks to > the excellent docs), but

[web2py] Re: download file

2014-01-06 Thread Anthony
Read about response.download() here: http://web2py.com/books/default/chapter/29/04/the-core#response, and here as well: http://web2py.com/books/default/chapter/29/07/forms-and-validators#SQLFORM-and-uploads. There is a download() function in the default.py controller of the scaffolding app th

Re: [web2py] !! NEW ADMIN !!

2014-01-06 Thread 黄祥
wonthefull best regards, stifan -- 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] Re: outer join? i guess

2014-01-06 Thread Tim Richardson
Not an answer, but are you using _select to see the sql generated? -- 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 yo

[web2py] Re: Possibly a problem with CAS redirection in v2.8.2

2014-01-06 Thread Tim Richardson
I noticed that I'm getting these tickets generated by the CAS provider app (welcome, in my case) during the CAS authentication. Traceback (most recent call last): File "/Users/tim/web2py/gluon/restricted.py", line 217, in restricted exec ccode in environment File "/Users/tim/web2py/appl

[web2py] Re: Possibly a problem with CAS redirection in v2.8.2

2014-01-06 Thread Tim Richardson
I've sent a PR which seems to fix this. On Tuesday, 7 January 2014 15:57:38 UTC+11, Tim Richardson wrote: > > > > I noticed that I'm getting these tickets generated by the CAS provider app > (welcome, in my case) during the CAS authentication. > > Traceback (most recent call last): > File "/Use

[web2py] Re: Possibly a problem with CAS redirection in v2.8.2

2014-01-06 Thread Mirko
Hi, some time ago I had a similar issue that I solved this way : https://groups.google.com/d/msg/web2py/FhtokyNZT7k/QEFQOdMzIP4J Hope it helps, Mirko On Friday, December 20, 2013 8:05:10 PM UTC, viniciusban wrote: > > Hi guys, > I'm playing around with CAS and faced this error: > --

[web2py] Re: Possibly a problem with CAS redirection in v2.8.2

2014-01-06 Thread Tim Richardson
this time it was throwing a ticket due to an undefined variable. -- 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 ar