[web2py] Re: web2py 2.5.1 is OUT

2013-06-07 Thread 黄祥
great work, btw, for new features, is it already documented in http://web2py.com/book? thanks and best regards On Thursday, June 6, 2013 10:59:30 PM UTC+7, Massimo Di Pierro wrote: CHANGELOG - New style virtual fields in grid - Conditional fields (experimental) ``db.table.field.show_id =

[web2py] Re: redirect after registration issue

2013-06-07 Thread lesssugar
That's my concern also. I simply would like to make a transparent registration for 2 groups separately. In order to do so I have two different forms generating depending on URL argument: default/register/[group1] or [group2]. Checking request.args(0) on onaccept seemed obvious but it needs

Re: [web2py] Re: Python 3 compatibility?

2013-06-07 Thread LightDot
On Friday, June 7, 2013 3:36:49 AM UTC+2, Anthony wrote: For example, I need web2py to provide python 2.6 compatibility for at least another 5 years. I'm going to need python 2.7 compatibility for at least another 10 years if not longer. I don't know if your particular application(s) make

[web2py] Re: redirect after registration issue

2013-06-07 Thread Anthony
How do users get to their respective registration URLs to begin with? If they are sent a link via email, you could use a digital signaturehttp://web2py.com/books/default/chapter/29/04#Digitally-signed-urls. If they are allowed to choose the group themselves by making a selection, then your

[web2py] Off Topic - Open source BPM tool?

2013-06-07 Thread António Ramos
hello, just like to know if there is some kind of open source IDE/GUI for Business Process Management We have a budget of 0 Thank you António -- --- You received this message because you are subscribed to the Google Groups web2py-users group. To unsubscribe from this group and stop receiving

[web2py] Re: current.session

2013-06-07 Thread Matt
Can anyone speak to this issue? I'm not sure if I misunderstand the intent of current.session, or if this indeed a bug I could help fix. Thanks, Matt On Tuesday, June 4, 2013 8:35:06 AM UTC-4, Matt wrote: Hi, In one of my modules I'm trying to create a local socket connection that

[web2py] Re: Problem with smartgrid linked tables: 'Row' object has no attribute 'f_name'

2013-06-07 Thread CrC Nommack
Hi, I have the same problem. I defined the following tables: db.define_table('t_questions', Field('f_question', type='text', label=T('Question')), Field('f_question_number', type='integer', label=T('Question number')), Field('f_lecture', type='reference t_activities',

[web2py] Re: current.session

2013-06-07 Thread Anthony
current.session is just the session object, which is in the web2py global environment -- it contains the user's session for the current request. The session itself does not include its own ID. If you want the session ID, it is in response.session_id (also, current.response.session_id). For file

[web2py] Re: redirect after registration issue

2013-06-07 Thread lesssugar
It's pretty straightforward - there are 2 registration links in the menu and each of them links to default/register/[group_type]. Then, in the view, request.args(0) value is being checked to generate respective form. Guess, I'll go for the request.args(0) limitation, as you wrote. By the way,

[web2py] Re: Nested groups/roles for authorization

2013-06-07 Thread Alfonso E.M.
Reading my post I think I did not explained clearly. I want to substitute AD, not for login, just as storage for user apps profiles and policies. The tool I have in my mind is something like puppet, chef, or saltstack, but with a powerful web interface. AD Is needed at the begining, in order

[web2py] Re: redirect after registration issue

2013-06-07 Thread Anthony
Don't check the validity of request.args(0) in the onaccept callback -- that's too late. Instead, check it before you even call auth.register(). Anthony On Friday, June 7, 2013 9:58:09 AM UTC-4, lesssugar wrote: It's pretty straightforward - there are 2 registration links in the menu and

[web2py] web2py in education

2013-06-07 Thread Massimo Di Pierro
Can you please help me Do you use web2py in a class? What is your name? What is your position (teacher, student, etc.)? What is the instructor name (if not you)? How was web2py uses (to do a project, as teaching tool, etc.)? Where is the class taught? When was is taught (can be a date in the

Re: [web2py] web2py in education

2013-06-07 Thread joseph simpson
I have used Web2py in two classes where I was a student. The classes were Web Technology Solutions and Professional Open Source Web Development at the University of Washington in the Professional and Continuing Education Department. The instructors vary ... Web2py was used in my class projects I

[web2py] where is the json data when using GWT's RequestBuilder() ?

2013-06-07 Thread Carl
From a GWT app I'm calling my Web2py server app. String jsonData = {'example' : 'example data'}; builder.setHeader(Accept, application/json); builder.setHeader(Content-type, application/json); builder.setHeader(Content-length, Integer.toString(jsonData.length())); builder.sendRequest(jsonData,

[web2py] Re: current.session

2013-06-07 Thread Matt
On Friday, June 7, 2013 9:53:42 AM UTC-4, Anthony wrote: current.session is just the session object, which is in the web2py global environment -- it contains the user's session for the current request. The session itself does not include its own ID. If you want the session ID, it is in

[web2py] Re: current.session

2013-06-07 Thread Matt
On Friday, June 7, 2013 11:28:48 AM UTC-4, Matt wrote: On Friday, June 7, 2013 9:53:42 AM UTC-4, Anthony wrote: current.session is just the session object, which is in the web2py global environment -- it contains the user's session for the current request. The session itself does not

[web2py] What is the best (or correct) way to show a reference value

2013-06-07 Thread Relsi Hur Maron
Hi guys, I have a doubt here about he best way of show a *reference* value. I'll use a simple example to illustrate, I have the following tables: db.define_table('city', Field('name', type='string') ) db.define_table('state', Field('name', type='string') )

[web2py] Error when modifying auth_user table

2013-06-07 Thread Andre Kozaczka
I'm trying to modify the auth_user table and I keep either getting a Table 'auth_user' already exist error (when migrate=True) OR a 'Column not found' (when migrate=False). Not sure what I need to do. I've also tried experimenting with fake_migrate but I'm still getting either one of those

[web2py] Passing Smartgrid vars to Factory

2013-06-07 Thread Alex Glaros
Is it good programming, and is there a way to pass parameters from Smartgrid to Factory? I often need a way to have user locate an already-existing record, which works great in Smartgrid, then add children to that one record, which works great in Factory. Can anyone please offer code samples

[web2py] Re: redirect after registration issue

2013-06-07 Thread lesssugar
Instead, check it before you even call auth.register(). Not sure how to achieve this. It's goes the following way now: 1. The registration view renders. request.args(0) is checked (group1 or group2) and respective form generates. At this point the URL argument is OK (as user came to

[web2py] Re: Scheduler task in GAE

2013-06-07 Thread Christian Foster Howes
you may use the taskqueue from inside your controllers or modules. here's a sample invocation that i used recently: taskqueue.add( url=URL(r=request, f=function_to_run), params={ 'created_on':start, 'end':chunk_end,

[web2py] Re: current.session

2013-06-07 Thread Cliff Kachinske
You can learn a lot about what's inside the session by adding {{=BEAUTIFY(session)}} to the bottom of your main template. As a rule of thumb, anything that can be pickled can go into the session and it does persist from request to request. If anyone new to this stuff reads this post, you only

[web2py] Re: Problem running web2py with Google Appengine - invalid controller (default/index)

2013-06-07 Thread Christian Foster Howes
if some pages/apps load but some pages give you invalid controller i bet there is an error in your routing. check both app.yaml (the GAE specific routing) and your web2py routing config. remember that it's best to restart the GAE SDK each time you change app.yaml or a web2py route. cfh On

[web2py] SmartGrid acting like SQLFORM.grid

2013-06-07 Thread greenpoise
So yesterday I added a smart grid. It was working fine, today I switched it to just grid and it worked..but when I tried to go back to the smartgrid, it wont show up the Add button etc..it just shows the search..I deleted the cache, restarted web2py, deleted the function, created it under

[web2py] Re: Web2py Restful api authentication for android app

2013-06-07 Thread Christian Foster Howes
for my resful APIs i use an oauth library to sign the requests. i then use oauth as my authentication mechanism. On Wednesday, June 5, 2013 5:29:23 PM UTC-7, Saurabh Kumar wrote: Hi, I am writing an android app which has web2py as the server side backend. What are the authentication

Re: [web2py] Re: Web2py Restful api authentication for android app

2013-06-07 Thread Saurabh Kumar
Can you give pointers to the library you are using? On Fri, Jun 7, 2013 at 11:40 PM, Christian Foster Howes cfho...@gmail.comwrote: for my resful APIs i use an oauth library to sign the requests. i then use oauth as my authentication mechanism. On Wednesday, June 5, 2013 5:29:23 PM UTC-7,

[web2py] Re: current.session

2013-06-07 Thread Matt
On Friday, June 7, 2013 2:03:14 PM UTC-4, Cliff Kachinske wrote: You can learn a lot about what's inside the session by adding {{=BEAUTIFY(session)}} to the bottom of your main template. As a rule of thumb, anything that can be pickled can go into the session and it does persist from

Re: [web2py] Re: Web2py Restful api authentication for android app

2013-06-07 Thread Christian Foster Howes
we are using a modified form of https://github.com/simplegeo/python-oauth2 modified to make it run on GAE and also some tweaks in usage to handle some special-case requirements. cfh On 6/7/13 11:26 , Saurabh Kumar wrote: Can you give pointers to the library you are using? On Fri, Jun 7,

[web2py] Re: Error when modifying auth_user table

2013-06-07 Thread Niphlod
The column not found is your eft one ? You code seems legit (setting migrate=True on the define_tables() function). We need to see the errors and the definition that causes them. On Friday, June 7, 2013 7:29:12 PM UTC+2, Andre Kozaczka wrote: I'm trying to modify the auth_user table and I keep

Re: [web2py] Re: Web2py Restful api authentication for android app

2013-06-07 Thread Saurabh Kumar
Thanks :) On Sat, Jun 8, 2013 at 12:36 AM, Christian Foster Howes cfho...@gmail.comwrote: we are using a modified form of https://github.com/simplegeo/** python-oauth2 https://github.com/simplegeo/python-oauth2 modified to make it run on GAE and also some tweaks in usage to handle some

[web2py] Re: What is the best (or correct) way to show a reference value

2013-06-07 Thread Niphlod
the first is more efficient, cause it does a single query. web2py allows to fetch connected records for each row, but is forced to fetch them one at a time. Inspect with response.toolbar queries and timings and choose your own poison (hefty query vs speedier to code) On Friday, June 7, 2013

[web2py] Re: where is the json data when using GWT's RequestBuilder() ?

2013-06-07 Thread Niphlod
if you're using recent web2py releases, that are able to parse POST vars encoded in json, you should have them in request.vars as usual. Otherwise, see response.body.read() On Friday, June 7, 2013 5:24:44 PM UTC+2, Carl wrote: From a GWT app I'm calling my Web2py server app. String

[web2py] Re: web2py_component with helper A(cid=request.cid) and LOAD()

2013-06-07 Thread Niphlod
as soon as the profile page is accessed, TypeError: $(...).mask is not a function http://127.0.0.1:8000/phone/static/js/jquery.js/eval/seq/7 Line 2 remove the line calling the mask plugin that you don't have, it works all fine (seems to, at least)! On Friday, June 7, 2013 4:46:51 PM UTC+2,

[web2py] Re: current.session

2013-06-07 Thread Anthony
If the session changes during the request, it gets pickled at the end of every request and stored in the session file (or db or cookie if using db or cookie based sessions). At the beginning of each request, the session is read from the file (or db or cookie) and unpickled. Anything that can't

[web2py] Re: What is the best (or correct) way to show a reference value

2013-06-07 Thread Anthony
{{for data in list:}} tr td{{=data.user_name}}/td td{{=(%(name)s %data.user_city)}}/td td{{=(%(name)s %data.user_state)}}/td Above, '%(name)s' % data.user_city results in data.user_city.name being filled into the string. data.user_city is a DAL Reference object -- it stores

[web2py] Re: current.session

2013-06-07 Thread Matt
On Friday, June 7, 2013 3:23:02 PM UTC-4, Anthony wrote: If the session changes during the request, it gets pickled at the end of every request and stored in the session file (or db or cookie if using db or cookie based sessions). At the beginning of each request, the session is read

[web2py] Re: redirect after registration issue

2013-06-07 Thread Anthony
def register(): if not request.args(0) in [list, of, valid, groups]: [redirect somewhere or return an error message] [rest of your registration code] Anthony On Friday, June 7, 2013 1:52:57 PM UTC-4, lesssugar wrote: Instead, check it before you even call auth.register().

[web2py] Re: What is the best (or correct) way to show a reference value

2013-06-07 Thread Relsi Hur Maron
Great! Thank you very much guys. =) Em sexta-feira, 7 de junho de 2013 16h29min55s UTC-3, Anthony escreveu: {{for data in list:}} tr td{{=data.user_name}}/td td{{=(%(name)s %data.user_city)}}/td td{{=(%(name)s %data.user_state)}}/td Above, '%(name)s' % data.user_city

[web2py] Re: current.session

2013-06-07 Thread LightDot
On Friday, June 7, 2013 8:58:46 PM UTC+2, Matt wrote: Either way, it appears that Request, Response and Session are all just sort of variable dumping grounds of thread local storage. None of these classes seem to give me a way to callback (and delete my object) when the session itself has

[web2py] Re: current.session

2013-06-07 Thread Anthony
Indeed, you have no way of knowing when the session has ended on the server because the session ends only when the user no longer has a session cookie to keep sending back from the browser (so, typically when the browser closes or the user manually deletes the session cookie). So yes, you

[web2py] changing class of a custom form not working

2013-06-07 Thread André Kablu
Hi all, I am trying to change a class of a field using form.element on my user.html view: {{=form.custom.begin}} Name: {{ form.element('input',_name='first_name')['_class']='input-medium' =form.custom.widget.first_name }} {{=form.custom.end}} It changes the HTML on the source

Re: [web2py] is there a dicateded request something to verify if a function get call by a browser?

2013-06-07 Thread Richard Vézina
Wasn't know about sheme=True, that's exactly what was the problem Thank you Anthony, it is really appreciate. Richard On Thu, Jun 6, 2013 at 5:31 PM, Anthony abasta...@gmail.com wrote: What is the problem with the A() helper? Is it that the URL is a relative URL rather than an absolute URL?

Re: [web2py] boolean_widget

2013-06-07 Thread Tim Richardson
Note that the validator to enforce selection (perhaps it is a accept terms and conditions field) is requires=IS_IN_SET(['on']) -- --- You received this message because you are subscribed to the Google Groups web2py-users group. To unsubscribe from this group and stop receiving emails from

[web2py] Re: changing class of a custom form not working

2013-06-07 Thread André Kablu
one more information... if I put on my html file a html code like this: input id=test class=input-small type=text value= name=test it also does not change the css effect to the correct class input-small Em sexta-feira, 7 de junho de 2013 16h51min36s UTC-3, André Kablu escreveu: Hi all, I am

[web2py] Re: changing class of a custom form not working

2013-06-07 Thread André Kablu
found, in web2py.css there is a code: input[type=text], input[type=password], select { margin-right: 5px; width: 300px; } now the question is: if we want to customize fields size do we need to remove this from web2py.css. Is it a bug or the correct behavior of web2py.css? Thanks!

[web2py] Re: web2py_component with helper A(cid=request.cid) and LOAD()

2013-06-07 Thread Charles Levesque
It's working on your side? I'll be damned =P. I'll download another web2py and reinstall my app on it, hopping that it'll work. It must be when I updated web2py before playing with components. Thanks for your time and support. Much appreciated. -- --- You received this message because you

[web2py] Re: redirect after registration issue

2013-06-07 Thread lesssugar
Yep. This was embarrassingly simple. Thanks for help and patience. On Friday, June 7, 2013 9:34:28 PM UTC+2, Anthony wrote: def register(): if not request.args(0) in [list, of, valid, groups]: [redirect somewhere or return an error message] [rest of your registration code]

[web2py] Re: Eclipse and autocomplete

2013-06-07 Thread Tim Richardson
This is what I'm doing with eclipse and pydev 2.7.5 this code snippet at the top of files: if False: #this block helps eclipse import gluon from gluon import * from db import * #repeat for all models from menu import * and added the web2py directory to PyDev System

[web2py] EuroPython

2013-06-07 Thread Massimo DiPierro
Anybody here going to EuroPython? I may be able to make it for a day or two and if other people are going we can organize an Open Space meeting. -- --- You received this message because you are subscribed to the Google Groups web2py-users group. To unsubscribe from this group and stop

[web2py] custom registration fields (no form.custom)

2013-06-07 Thread lesssugar
auth_user stores many fields. For registration, I would like to use only some of them. Is there a simple way to specify fields for registration form - except form.custom? It would be great to just set the form register_form = auth.register() and then list the fields of auth_user to be used,

[web2py] Re: custom registration fields (no form.custom)

2013-06-07 Thread Anthony
Just set the readable and writable attributes of the fields you don't want to show to False. Anthony On Friday, June 7, 2013 7:40:07 PM UTC-4, lesssugar wrote: auth_user stores many fields. For registration, I would like to use only some of them. Is there a simple way to specify fields for

[web2py] Re: Off Topic - Open source BPM tool?

2013-06-07 Thread 黄祥
had you already checked? http://en.wikipedia.org/wiki/Business_process_management http://en.wikipedia.org/wiki/Comparison_of_business_integration_software best regards On Friday, June 7, 2013 8:23:39 PM UTC+7, Ramos wrote: hello, just like to know if there is some kind of open source IDE/GUI

[web2py] Re: custom registration fields (no form.custom)

2013-06-07 Thread lesssugar
What if (as you probably already know) I have two registrations forms. In one case I need fields A, B, C, D, in the other case - C, D, E. Do I set this in the model also? On Saturday, June 8, 2013 2:01:28 AM UTC+2, Anthony wrote: Just set the readable and writable attributes of the fields you

[web2py] Re: custom registration fields (no form.custom)

2013-06-07 Thread Anthony
You can set the readable and writable attributes of fields wherever you want -- so set them conditionally based on the particular registration form being served. You might even write a helper function that takes a list of fields and sets their readable and writable attributes to True or False

[web2py] Re: custom registration fields (no form.custom)

2013-06-07 Thread lesssugar
Thanks, I'll dig through it. On Saturday, June 8, 2013 2:35:59 AM UTC+2, Anthony wrote: You can set the readable and writable attributes of fields wherever you want -- so set them conditionally based on the particular registration form being served. You might even write a helper function

Re: [web2py] web2py in education

2013-06-07 Thread Ovidio Marinho
Hello Massimo, Use web2py to teach users use the frame and develop their applications. My name is Ovidio Marinho I am a web developer Have academic and professional projects I will make a new class on 01/07/2013 http://stoodos.com/c/web2py/478?s_v=2utm_expid=43885913-12 language course Portuguese

Re: [web2py] Re: where is the json data when using GWT's RequestBuilder() ?

2013-06-07 Thread Carl Roach
thanks. both request.vars and response.body.read() are empty. I'm calling my function: http://127.0.0.1:8000/init/default/call.jsp I think it must be something in my Java GWT app that's not setting something for Web2py to identify that there is json data. On 7 June 2013 20:16, Niphlod