[web2py] Retrieving values

2011-11-29 Thread Saurabh S
Hi , I have two controllers namely REGISTRATIONS and EVENTS , i have calender in my application. values and the data are printed on the calender via EVENTS controller. I have come across a requirement where i need to have a variable who's value is determined in the REGISTRATION controller is to b

[web2py] web2py shell

2011-11-29 Thread chandrakant kumar
how can i do from gluon.sql import *, in a normal python shell.

[web2py] SQLFORM, DAL and Hidden Fields - a way or a better way?

2011-11-29 Thread lyn2py
Hello guys, I am looking for a DRY way to do this while keeping the file code maintainable. I appreciate your replies. Thank you. ### I have already defined my tables in the model file, and now I would like to have a form created for it. So I have: #model db.define_table('mytable', Field('titl

[web2py] Re: SQLFORM, DAL and Hidden Fields - a way or a better way?

2011-11-29 Thread lyn2py
After I write a very long email, I found my answer. It left me speechless. writable=False readable=False A hard kick in the butt.

[web2py] Re: SQLForm.grid - How do I use it properly?

2011-11-29 Thread Rahul
All, How do I view SQLForm.grid View, Edit or Delete forms without using auth? I have implemented my own custom authorization mechanism which does not use web2py auth in any way. Now the problem is in SQLForm grid that is serialized in my view It say "not authorised" when I click on View button.

[web2py] referenced auth.user_id type string

2011-11-29 Thread thodoris
Hello, Simple question: auth.user.id returns an integer but if i define a field in a table: Field('author_id', default=auth.user_id) author_id is a string and if i want in a later step to compare these values it doesn't seem good tactic to do str(auth.user.id)

Re: [web2py] referenced auth.user_id type string

2011-11-29 Thread Bruno Rocha
Field('user_id', 'integer', default=auth.user_id) or Field('user_id', 'reference auth_user', default=auth.user_id) http://zerp.ly/rochacbruno Em 29/11/2011 09:23, "thodoris" escreveu: > Hello, > > Simple question: > > auth.user.id returns an integer > > but if i define a field in a table: > > F

Re: [web2py] Error using LOAD in custom module

2011-11-29 Thread Nik Go
Nice! Are you planning to release the plugin? Let me know if you need any help testing it. :) On Saturday, November 26, 2011, monotasker wrote: > I'm adapting the select_or_add widget from web2py slices so that it can be > packaged as a plugin. In that process I'm moving the business logic from

[web2py] cannot login or register, missing links: login|register|lost password

2011-11-29 Thread Nik Go
I've been deleting tables and playing around with various settings, so I don't know what I've done exactly but now my app lost the links for logging in, registering or resetting passwords. If I try to access the links manually (i.e. http://127.0.0.1:8000/s1/default/user/register) or do the same fo

[web2py] Fwd: How disable date widget?

2011-11-29 Thread Vinicius Assef
Anybody there? -- Forwarded message -- From: viniciusban Date: Mon, Nov 28, 2011 at 3:39 PM Subject: [web2py] Fwd: How disable date widget? To: web2py@googlegroups.com I found this thread in archives and I have some thoughts about this theme. 1) I need only one date field in j

Re: [web2py] web2py shell

2011-11-29 Thread Vinicius Assef
I think you must import DAL. Now it's decoupled from web2py. On Tue, Nov 29, 2011 at 7:28 AM, chandrakant kumar wrote: > how can i do from gluon.sql import *, in a normal python shell. >

Re: [web2py] web2py shell

2011-11-29 Thread Ross Peoples
You typically have to use the web2py shell: python web2py.py -S appname -M If you are trying to use gluon libraries by themselves in some other application (without using web2py at all), then you either need to put web2py on your PYTHONPATH or copy the needed libraries where you want to use th

[web2py] Re: fedora, pip, web2py, virtualenv, and mysql

2011-11-29 Thread David Watson
I don't believe that's true. For instance, in the aforementioned example my code has a mysql db uri specified in db.py, but the mysql driver is never loaded, despite its obvious presence in the virtualenv. Only the sqlite3 driver gets loaded. The different behavior can clearly be observed after r

[web2py] Re: SQLFORM, DAL and Hidden Fields - a way or a better way?

2011-11-29 Thread lyn2py
Clarification Needed! If I use default=some_value, writable=False, readable=False, the field does not appear on the form at all, and does not autofill with the default value either, is that the correct behavior? To have a value for this field, I must manually assign a value in controller? I ask

[web2py] Re: Problems with forms and firefox

2011-11-29 Thread DenesL
Note that in my previous test the P tags were not encoded: Content-Disposition: form-data; name="comment_text" test by Denes using Firefox 8.0.1 on Win XP If you type for example: TEST the comment will be encoded as: TEST Again note that the P tags are not encoded. If

[web2py] Re: How place the standard Register form in my front page?

2011-11-29 Thread Massimo Di Pierro
The reason I asked is that I see at least two problems: 1) auth.settings.register_next = '/myapp/default/myinfo' should be auth.settings.register_next = URL('default','myinfo') or it breaks with routes 2) you mention form.process(formname='myinfo').accepted but you says form is an auth form. Th

[web2py] Re: Retrieving values

2011-11-29 Thread Massimo Di Pierro
Controllers are separate. Each request runs one or the other. You have two options: - compute the variable in a model (so it will be visible to both) - have one controller store the variable in a session and retrieve it in another http request by the other controller. On Nov 29, 2:54 am, Saurabh

[web2py] Re: cannot login or register, missing links: login|register|lost password

2011-11-29 Thread Massimo Di Pierro
Somewhere you are passing None where it expects a table object. Not sure where without seeing the code. fields = [f.name for f in table if (ignore_rw or f.writable or f.readable) and not f.compute] TypeError: 'NoneType' object is not iterable On Nov 29, 6:29 am, Nik Go wrote: > I've been deletin

[web2py] Re: SQLForm.grid - How do I use it properly?

2011-11-29 Thread Massimo Di Pierro
gird(,...user_sigature=fFalse) than do your own authentication outside the function. On Nov 29, 5:10 am, Rahul wrote: > All, >    How do I view SQLForm.grid View, Edit or Delete forms without using > auth? I have implemented my own custom authorization mechanism which > does not use web2py auth

[web2py] Re: SQLFORM, DAL and Hidden Fields - a way or a better way?

2011-11-29 Thread Massimo Di Pierro
On Nov 29, 7:58 am, lyn2py wrote: > Clarification Needed! > > If I use default=some_value, writable=False, readable=False, the field > does not appear on the form at all, and does not autofill with the > default value either, is that the correct behavior? If a field value is not provided it is

Re: [web2py] web2py shell

2011-11-29 Thread Jim Steil
Here is what I use in my scripts to access DAL from a regular Python script using MySQL database: import sys sys.path.append('path_to_web2py') from gluon import DAL db = DAL('mysql://username:password@servername/databasename',folder='path_to_the_databases_folder_of_my_application', auto_import

[web2py] Re: SQLFORM, DAL and Hidden Fields - a way or a better way?

2011-11-29 Thread lyn2py
Here's the code: #model db.define_table('discussion', Field('title', 'string', length=255, required=True), Field('description', 'text', required=True), Field('created_by', 'reference auth_user', default=auth.user_id, writable=False, readable=False), Field('modified_by', 'reference auth_use

[web2py] Re: How to implement the simpler possible Sign Up system: email address/password?

2011-11-29 Thread DenesL
On Nov 28, 11:51 pm, Constantine Vasil wrote: > Hi Anthony, > > Yes I don't want to mess it up - the most important - > I don't want 'username'. I want the email to be the username. > > How to do that? from gluon.tools import Auth auth = Auth(db) auth.define_tables(username=False) # book chapt

Re: [web2py] Re: SQLFORM, DAL and Hidden Fields - a way or a better way?

2011-11-29 Thread Bruno Rocha
is the user logged in? http://zerp.ly/rochacbruno Em 29/11/2011 12:51, "lyn2py" escreveu: > Here's the code: > > #model > db.define_table('discussion', > Field('title', 'string', length=255, required=True), > Field('description', 'text', required=True), > Field('created_by', 'reference auth_u

Re: [web2py] Re: Problems with forms and firefox

2011-11-29 Thread Bruno Rocha
I am sure it is not ckeditor because I tested without it. may be it is a problem in current or in custom_importer. note that my form is built in a module. I will try to build the form in controller for test. thanks again. http://zerp.ly/rochacbruno Em 29/11/2011 12:02, "DenesL" escreveu: > >

[web2py] Re: SQLFORM, DAL and Hidden Fields - a way or a better way?

2011-11-29 Thread Anthony
auth.user_id returns None if the user isn't logged in. On Tuesday, November 29, 2011 9:51:21 AM UTC-5, lyn2py wrote: > > Here's the code: > > #model > db.define_table('discussion', > Field('title', 'string', length=255, required=True), > Field('description', 'text', required=True), > Field('

[web2py] clean upload notnull field after being set

2011-11-29 Thread thodoris
Hello, I have this Field Field('cover','upload',notnull=False,autodelete=True), When the form is displayed you click on browse you can select the file. But once a file is selected you cannot undo your choice. There is always the choice to reload the page that holds the form and clean the field b

[web2py] Re: clean upload notnull field after being set

2011-11-29 Thread Anthony
Unless you're using a special widget, once you select a file for upload, the browser should simply put the filename in the string field next to the browse button. You should be able to put the cursor in that string field and delete the filename. As an alternative, I suppose you could add a butt

[web2py] Re: How to implement the simpler possible Sign Up system: email address/password?

2011-11-29 Thread Constantine Vasil
How you would exclude First Name and Last Name?

[web2py] Re: Fwd: How disable date widget?

2011-11-29 Thread Massimo Di Pierro
sorry it took me a while SQLFORM.widgets.string.widget and SQLFORM.widgets.date.widget are the same. what you want is to eliminate the datepicker popup. Technically that is not part of the widget but handled by the JS in the page. try this, immediately after you insert the form or field: j

[web2py] Re: How to implement the simpler possible Sign Up system: email address/password?

2011-11-29 Thread Massimo Di Pierro
I would recommend you simply do db.auth_user.first_name.writable = db.auth_user.first_name.readable = False db.auth_user.last_name.writable = db.auth_user.last_name.readable = False and leave everything else alone. On Nov 29, 9:36 am, Constantine Vasil wrote: > How you would exclude First Name

[web2py] Re: How to rewrite reset_password link in the Email send for password retrieval?

2011-11-29 Thread Anthony
You should always use the URL() function to construct your URLs (especially if you are using routes.py). Anthony On Tuesday, November 29, 2011 1:28:11 AM UTC-5, Constantine Vasil wrote: > > > The email I receive has this link: > /**default/user/reset_password/**1322547476-0ee03b96-5410-4a61-** >

[web2py] Unable to define the right query to get the first matching record of each category in a group by expression

2011-11-29 Thread Manakel
Hello, I'm writing my first app with Web2py. So far, i'm very impressed. But i'm facing a problem of query design: I have the following model for "operations" DATE BUDGET TITLE AMOUNT where the possible values for budget are defined in a "budget_types" table (budget is a reference field) I need

[web2py] Re: How to implement the simpler possible Sign Up system: email address/password?

2011-11-29 Thread Constantine Vasil
Hi Massimo - that was a great recommendation, thank you!

[web2py] Re: How to rewrite reset_password link in the Email send for password retrieval?

2011-11-29 Thread Constantine Vasil
so URL() will work on generating the email link too?

Re: [web2py] Error using LOAD in custom module

2011-11-29 Thread monotasker
Thanks. Yes, I'll release the plugin as soon as I'm happy with how it works. I'll announce it on the list here when the time comes (hopefully in the next couple of weeks).

[web2py] Re: Error using LOAD in custom module

2011-11-29 Thread monotasker
Thanks Massimo. I'm continually amazed at how responsive you and the other devs are. Maybe that's possible in part because web2py is still (in comparison to Django or Drupal) a small community, but it's much appreciated.

[web2py] Re: How place the standard Register form in my front page?

2011-11-29 Thread Constantine Vasil
Here is a better description for what I want to accomplish. Basically the business logic is this: I need a quick registration and then redirection to a form with option to enter more information. 1) Register with the minimum requirements - email address/password 2) Redirect to My Info form at /m

[web2py] Re: Unable to define the right query to get the first matching record of each category in a group by expression

2011-11-29 Thread monotasker
If you just need the last row from your (ordered) select object, you can just add ".last()" to the end of your query: db(db.operations.date.month() == current_month).select(db. operations.date,db.operations.budget,db.operations.title,db.operations.amount,groupby=db.operations.budget,orderby= ~db

[web2py] Re: some ideas on built-in emphasis on client-side processing for web2py

2011-11-29 Thread Constantine Vasil
On mobile browser is slow. This is better to be made on the server which is fast.

[web2py] Re: Refresh select widget via Ajax before form submission

2011-11-29 Thread monotasker
Ah, great. At first glance those look like they might do the trick.

[web2py] Re: How to rewrite reset_password link in the Email send for password retrieval?

2011-11-29 Thread Anthony
Yes, but in emails you need absolute URLs, including the host, so use URL(..., host=True). That will add the current host (you can also specify the host explicitly). There is also a 'scheme' argument, so you could specify scheme='https', for example. Anthony On Tuesday, November 29, 2011 11:29

[web2py] How to implement a function to choose from a really long list of categories?

2011-11-29 Thread Constantine Vasil
I have a long list of categories which the user has to add to his My Info. The issue is the list is very long - about 500 categories and counting. How it would be the best approach to make this list to load in the HTML really quick? Loading this long list takes considerable time especially on mo

[web2py] Re: Create a simple drop down list

2011-11-29 Thread Constantine Vasil
Hi Anthony, how can I link a virtual tables from a factory? Regards, --Constantine

[web2py] Re: How to rewrite reset_password link in the Email send for password retrieval?

2011-11-29 Thread Constantine Vasil
Hi Anthony, Thank you, absolute URLs explains how it will work. Regards, --Constantine

Re: [web2py] How to implement a function to choose from a really long list of categories?

2011-11-29 Thread Bruno Rocha
http://dev.s-cubism.com/plugin_suggest_widget http://dev.s-cubism.com/plugin_lazy_options_widget On Tue, Nov 29, 2011 at 3:02 PM, Constantine Vasil wrote: > I have a long list of categories which the user has to add to his My Info. > > The issue is the list is very long - about 500 categories an

[web2py] Re: How to implement a function to choose from a really long list of categories?

2011-11-29 Thread Anthony
How about using the autocomplet widget: http://web2py.com/book/default/chapter/07#Autocomplete-Widget. It makes Ajax calls as you type to retrieve matching items, so the whole list doesn't have to load with the page (or at all). I've had problems with the UI display in IE, so an alternative is

[web2py] Re: Create a simple drop down list

2011-11-29 Thread Anthony
Not sure what you mean. On Tuesday, November 29, 2011 12:06:16 PM UTC-5, Constantine Vasil wrote: > > Hi Anthony, > > how can I link a virtual tables from a factory? > > Regards, > --Constantine >

[web2py] Re: Unable to define the right query to get the first matching record of each category in a group by expression

2011-11-29 Thread Manakel
Mistakes from my side. It should be read But i would like to get the line with "Mensualité No..." instead of the line with "AGIO PRETS" for the LOGEMENT_PRET budget because the last operation by date is the ID BUDGET AMOUNT DATE TITLE 1 LOGEMENT_PRET 990.0 2011-11-29 Mensualité No... 980.0 an

[web2py] Re: Unable to define the right query to get the first matching record of each category in a group by expression

2011-11-29 Thread Manakel
Hello, Simply adding the last() at the end does not work. It gives me the last operation of the full request (whatever the budget) But i need each last operation for each budget. On 29 nov, 17:43, monotasker wrote: > If you just need the last row from your (ordered) select object, you can > ju

Re: [web2py] How to implement a function to choose from a really long list of categories?

2011-11-29 Thread Jim Steil
+1 for the suggest widget. I too have had display issues with the web2py autocomplete widget. -Jim On 11/29/2011 11:10 AM, Bruno Rocha wrote: http://dev.s-cubism.com/plugin_suggest_widget http://dev.s-cubism.com/plugin_lazy_options_widget On Tue, Nov 29, 2011 at 3:02 PM, Constantine Vas

Re: [web2py] web2py shell

2011-11-29 Thread chandrakant kumar
This solved the problem, actually i was trying to test the code before using it in app, kind of like dbshell in Rails. On Tue, Nov 29, 2011 at 6:49 PM, Ross Peoples wrote: > You typically have to use the web2py shell: > > python web2py.py -S appname -M > > If you are trying to use gluon libraries

[web2py] Re: Error using LOAD in custom module

2011-11-29 Thread Massimo Di Pierro
Yes but this list gets almost 50% more traffic than the django google group and the rails google group. ;-) On Nov 29, 10:34 am, monotasker wrote: > Thanks Massimo. I'm continually amazed at how responsive you and the other > devs are. Maybe that's possible in part because web2py is still (in > c

[web2py] Re: How to implement a function to choose from a really long list of categories?

2011-11-29 Thread Constantine Vasil
Autocomplete is useful if the users know what they are looking for, usually they don't. So they have to browse. I am using jQuery Mobile and had an issues with Ajax solution before - when the list is fetched it is not displayed correctly - it does not renders in the same way as rest of the pag

[web2py] Re: Create a simple drop down list

2011-11-29 Thread Constantine Vasil
I am using SQLFORM.factory not a read database for different reasons. The question is can I link two SQLFORM.factory tables (virtual tables so to say) to achieve the same effect?

[web2py] Re: How place the standard Register form in my front page?

2011-11-29 Thread Massimo Di Pierro
You are asking to make a guess about your code. Coding from scratch I would do this: auth=Auth(db) auth.settings.extra_field['auth_user']=[Field('phone_number',default=None)] auth.define_tables() if auth.user and not auth.user.phone_number: session.flash='we need your phone number' redir

[web2py] deploying with uWSGI

2011-11-29 Thread peter
A very simple and light way of deploying web2py is to use uwsgi both to handle the uwsgi communication and also act as a server. Once one has installed uwsgi it is as simple as uwsgi --pythonpath /opt/web-apps/web2py --module wsgihandler --http : 80 -s /tmp/we2py.sock One should ensure that /tmp

[web2py] Re: clean upload notnull field after being set

2011-11-29 Thread thodoris
Thanx for the reply, Well, whenever i put the cursor on the text area a popup window opens to choose the file, so i can't edit the text. About the solution with Javascript, how can i reference the field that i want to clear? I could do something like: form.append(INPUT(_type="button", _value="C

[web2py] Re: GAE Caching and Views

2011-11-29 Thread Constantine Vasil
>not picklable there is a way to serialize with protocol buffers. I am using it in my code but it better be implemented in the web2py core as a 'gae' dependency.

[web2py] Re: Create a simple drop down list

2011-11-29 Thread Anthony
What do you mean by linking factory tables? Is it one factory or two? What would the linking do? Can you detail an example? On Tuesday, November 29, 2011 12:48:15 PM UTC-5, Constantine Vasil wrote: > > I am using SQLFORM.factory not a read database for different reasons. > > The question is can I

[web2py] Re: How place the standard Register form in my front page?

2011-11-29 Thread Constantine Vasil
Hi Massimo, >You are asking to make a guess about your code. It is a lot of code and the main point is I use GAE datatable. In order to use web2py I use SQLFORM.factory, then in form.process(formname='myinfo').accepted I get the values, assign to GAE table instance and use GAE .put() to store

[web2py] Re: clean upload notnull field after being set

2011-11-29 Thread Anthony
On Tuesday, November 29, 2011 12:54:45 PM UTC-5, thodoris wrote: > > Thanx for the reply, > > Well, whenever i put the cursor on the text area a popup window opens > to choose the file, so i can't edit the text. > You're right -- I guess it depends on the browser. In IE, you can delete the filenam

[web2py] Re: Create a simple drop down list

2011-11-29 Thread Constantine Vasil
= Instead, though, you might want to explicitly link the two tables: db.define_table('t_ab_distribution', Field('f_distributionname'), format='%(f_distributionname)') db.define_table('t_ab_recipient', Field('f_distribution', db.t

[web2py] Re: How to implement a function to choose from a really long list of categories?

2011-11-29 Thread Constantine Vasil
>I've had problems with the UI display in IE And yes IE is a big issue. I had issues witch clicking on Buttons and Submit - does web2py has these issues?

[web2py] Re: How to implement the simpler possible Sign Up system: email address/password?

2011-11-29 Thread Constantine Vasil
Basically the solution is like this: from gluon.tools import Auth auth = Auth(db) auth.define_tables(username=False) db.auth_user.first_name.writable = db.auth_user.first_name.readable = False db.auth_user.last_name.writable = db.auth_user.last_name.readable =False This will leave only email addr

[web2py] Re: Create a simple drop down list

2011-11-29 Thread Anthony
I'm not sure, but what's the use case? SQLFORM.factory is for creating forms, not database tables. What would be the result of any linking? On Tuesday, November 29, 2011 1:14:18 PM UTC-5, Constantine Vasil wrote: > > = > Instead, though, you

Re: [web2py] How to implement a function to choose from a really long list of categories?

2011-11-29 Thread Constantine Vasil
I looked at it and it is .js code. I am developing for mobile with jQuery Mobile and am not sure it will play nicely with jQuery Mobile. I believe a pure Ajax is more appropriate but I have this rendering issue with injected HTML after the page is already build. jQuery Mobile does not fires at t

[web2py] Re: How to implement the simpler possible Sign Up system: email address/password?

2011-11-29 Thread Anthony
On Tuesday, November 29, 2011 1:28:33 PM UTC-5, Constantine Vasil wrote: > > Basically the solution is like this: > > from gluon.tools import Auth > auth = Auth(db) > auth.define_tables(username=False) > db.auth_user.first_name.writable = db.auth_user.first_name.readable = > False > db.auth_user.l

Re: [web2py] Re: Web2py based STARTUP: Linkfindr.com

2011-11-29 Thread Kuba Kucharski
@anthony for now Linkfindr IE compatibility is not my prio ;) @lyn2py it took 3 months @massimo I thanked Yarko because he helped me a lot more than 3 years ago when I was a beginner with web2py, I wasn't aware about current top 10, I wrote this email really fast, looks like I haven't given i

[web2py] Re: How to implement the simpler possible Sign Up system: email address/password?

2011-11-29 Thread Constantine Vasil
Yes, this was just brainstorming - the user usually have one or two email addresses and usually they remember them ;) Bottom line email address/password is the simpler and quicker way to Sign Up users - he need to enter just three lines. Could not be more simpler.

[web2py] Re: GAE and 'cannot set memcache' error

2011-11-29 Thread howesc
nothing is mentioned here on detecting the service status: http://code.google.com/appengine/docs/python/memcache/clientclass.html perhaps it's just a matter of catching the exception. i have not been paying close enough attention to know how often there might be service disruptions, but none o

[web2py]

2011-11-29 Thread Richard
Hello, Here my configuration : Apache2, wsgi, web2py, ubuntu 10.04.3, postgres I just made a load test and my app was slow to death... I look into CPU usage, process, memory, disk acces and I found that only the CPU can be incriminated... Total CPU usage never exceed 45%, but the apache2 process

[web2py] app slow to death (sorry double post because empyt object)

2011-11-29 Thread Richard
Hello, Here my configuration : Apache2, wsgi, web2py, ubuntu 10.04.3, postgres I just made a load test and my app was slow to death... I look into CPU usage, process, memory, disk acces and I found that only the CPU can be incriminated... Total CPU usage never exceed 45%, but the apache2 process

[web2py] Re: GAE Caching and Views

2011-11-29 Thread howesc
Constantine, do you mind sharing what and how you are serializing things with protocol buffers? perhaps we can adapt what you are doing into the web2py GAE caching core. JT - thanks for the nice writeup. i'm working on optimizing some web2py apps for customers now, and should be using your te

Re: [web2py] deploying with uWSGI

2011-11-29 Thread Vasile Ermicioi
compared to rocket, and apache+mod_wsgi, uwsgi uses less memory and is more recommended for production as many use it either with web2py or django, you can google to find out is also have much more options to use to make it run at is best for your case I use version 0.9.8.6 on webfaction using thi

[web2py] Wizard builder

2011-11-29 Thread bluemoth
Hi all, I'm involved with a project that requires many wizards to collect information. I could build these wizards by hand or develop a module to generate them. It needs to be slick i.e. loads each step using AJAX, given certain answers show or hide questions, client-side and server-side validatio

[web2py] Re: GAE and 'cannot set memcache' error

2011-11-29 Thread Constantine Vasil
>a fall-back plan How you would do it in web2py?

[web2py] Re: How to implement the simpler possible Sign Up system: email address/password?

2011-11-29 Thread Constantine Vasil
In db.py I have implemented it. Still when the Register form shows up there is a username present, note I added this: auth.define_tables(username=False) db.define_table('auth_user', Field('username', type='string', label=T('Username')), Field('first_name', type='string',

Re: [web2py] Re: Problems with forms and firefox

2011-11-29 Thread Bruno Rocha
I found that the problem is somewhere in the new welcome layout. some lib there is changing the form encoding. If I try with .load http://labs.blouweb.com/movuca/article/show.load/2/vegetarian-cheese The comments works ok with any browser. Now I have to find what lib or html tag is doing that,

[web2py] Re: How to implement the simpler possible Sign Up system: email address/password?

2011-11-29 Thread Constantine Vasil
do I have to add: settings.login_userfield = 'email' or delete 'username' field?

Re: [web2py] Re: Problems with forms and firefox

2011-11-29 Thread Bruno Rocha
Finally the problem is solved, and it has not to be with web2py. I am using jqm (Jquery Modal Plugin) The sample code has {{=T("Close")}} where the src attr for img is filled dynamically by the plugin modal. Firefox was raising v

[web2py] Re: How to implement the simpler possible Sign Up system: email address/password?

2011-11-29 Thread Constantine Vasil
It seems that commenting out 'username' is the only option #Field('username', type='string', # label=T('Username')),

[web2py] Re: How to implement the simpler possible Sign Up system: email address/password?

2011-11-29 Thread Anthony
Why are you defining your own auth_user table? auth.define_tables() will do that for you automatically. You only need to define your own if you want to customize it, and in that case, you can simply exclude the username field from your custom definition. On Tuesday, November 29, 2011 4:45:33 PM

Re: [web2py] Re: could use some help ... mobile admin

2011-11-29 Thread Angelo Compagnucci
I'm astonished, I'm trying to use admin from my rly old htc g1 with android and it's totally usable and responsive! Great! I want mobile admin as soon as possible! There is a way to know the current porting status? What files left to be edited? I'll look myself and if I find the respons

[web2py] Re: How to implement the simpler possible Sign Up system: email address/password?

2011-11-29 Thread Constantine Vasil
OK - if I simply comment out the username field it is OK now?

[web2py] Re: autocomplete widget a disaster on Internet Explorer

2011-11-29 Thread Constantine Vasil
Hi guys I mentioned this post because I want to use autocomplete. How is the status of autocomplete with IE? Can I still implement my own and it to work in IE?

[web2py] Re: autocomplete widget a disaster on Internet Explorer

2011-11-29 Thread Anthony
I assume if you implement you're own, it should work fine. There's something wrong with the JS in the default autocomplete widget that causes problems with the UI in IE (i.e., it's a client-side problem, not a server-side problem). An alternative is http://dev.s-cubism.com/plugin_suggest_widget

[web2py] Re: How to implement the simpler possible Sign Up system: email address/password?

2011-11-29 Thread Anthony
Sure. On Tuesday, November 29, 2011 5:56:17 PM UTC-5, Constantine Vasil wrote: > > OK - if I simply comment out the username field it is OK now?

[web2py] Will jQuery Mobile keyup handler and Auto-completion work with web2py?

2011-11-29 Thread Constantine Vasil
I am using jQuery Mobile and here is a code for a keyup handler directly from the source. The question is would it work under web2py? What about IE? http://jquerymobile.com/demos/1.0a2/#experiments/api-viewer/docs/keyup/index.html Show the event object for the keyup handler when a key is releas

[web2py] Re: How to implement the simpler possible Sign Up system: email address/password?

2011-11-29 Thread Constantine Vasil
Great! I have to move on with this Sign Up now ;) Need to work on ajax auto-complete - could you please see my new posting?

Re: [web2py] Re: could use some help ... mobile admin

2011-11-29 Thread Angelo Compagnucci
I almost done the admin mobilization! I have to get rid of an error on design.html, when done, I'll send you patches! Thanks! 2011/11/29 Angelo Compagnucci : > I'm astonished, > > I'm trying to use admin from my rly old htc g1 with android > and it's totally usable and responsive! Great!

[web2py] Re: How to implement the simpler possible Sign Up system: email address/password?

2011-11-29 Thread pbreit
The Web2py default is to *not* use username for login. I think your problem is creating your own auth_user table instead of using the default table. To suppress first/last name collection, set readable/writable in a model or in user() function: db.auth_user.first_name.writable = db.auth_user.fi

Re: [web2py]

2011-11-29 Thread pbreit
You might look in to Nginx.

Re: [web2py] Re: could use some help ... mobile admin

2011-11-29 Thread Javier Quarite
On Tue, Nov 29, 2011 at 6:40 PM, Angelo Compagnucci < angelo.compagnu...@gmail.com> wrote: > I almost done the admin mobilization! > > I have to get rid of an error on design.html, when done, I'll send you > patches! > > Thanks! > > Is there a way to see an example? it sounds interesting and it co

[web2py] Re: Unable to define the right query to get the first matching record of each category in a group by expression

2011-11-29 Thread pbreit
I'm not sure there's an easy way to do that in one query. I don't think grouping and ordering is going to work how you are expecting. Are you able to see what SQL gets generated for this query? Is running separate queries for each budget OK?

[web2py] Re: How to rewrite reset_password link in the Email send for password retrieval?

2011-11-29 Thread pbreit
I would suggest just leaving the default. The only way to get to a reset_password page is by clicking on a link so there's no benefit to "pretty-fying" it.

[web2py] Re: simulate a sub-domain from localhost?

2011-11-29 Thread pbreit
That's what I do on my Mac. In /etc/hosts I have: 127.0.0.1 pb-dev.pricetack.com Since I run web2py on port 8001 I access my dev site with "http://pb-dev.pricetack.com:8001/";

[web2py] Re: computed field: update and images

2011-11-29 Thread pbreit
I'd be curious as well. That looks like my resize_image function. For now I've just been letting old images clutter up. Somehow you'd need to know the original filename to be able to delete it either in the resize_image function or perhaps a second computed function.

Re: [web2py] Re: Problems with forms and firefox

2011-11-29 Thread Bruno Rocha
This was the issue: http://www.nczonline.net/blog/2009/11/30/empty-image-src-can-destroy-your-site/ and http://www.nczonline.net/blog/2010/03/16/empty-string-urls-in-html-a-followup/

[web2py] Re: How to rewrite reset_password link in the Email send for password retrieval?

2011-11-29 Thread Constantine Vasil
OK here is my setup: routes.py: === routers = dict( BASE = dict( default_application = 'myapp', default_controller='default' ), ) routes_in = ( ('/myinfo', '/default/myinfo'), ) routes_out = (

  1   2   >