Re: [web2py] Re: Restful API with HTTPS and authentication

2016-10-11 Thread Keith Phillips
YES! This was the solution for me as well. Thanks! On Tuesday, September 17, 2013 at 3:31:14 AM UTC-7, Fredrik wrote: > > It turns out I needed to add this to the Apache config: > *WSGIPassAuthorization > On* > > With the line added everything works well. I couldn't find any > documentation o

Re: [web2py] Re: How to use AJAX within a SQLFORM.grid 'add' form

2014-03-31 Thread Keith Edmunds
Really helpful, thanks Anthony. One suggestion: Chapter 11 of the book, heading "The ajax function", has exactly the code I used (that's where I got it from): May I suggest that your comment about URLs be included in that documentation? Appreciate the help, thanks. Keith

Re: [web2py] Re: How to use AJAX within a SQLFORM.grid 'add' form

2014-03-31 Thread Keith Edmunds
Thanks Anthony. > First, take grid out of BEAUTIFY -- not necessary. Thanks, done. > Does db.t_dogs happen to have a field called "name"? If so, change the > name of your extra input element to something other than "name". No, it doesn't. > Also, when typing in your input field, open the brows

Re: [web2py] Re: Can I/how would I create a self-signed certificate using IIS?

2014-01-17 Thread Keith Planer
can also buy a CA for LAN here, but it is not going to continue for > very long, Goddady stop recently to emit new certificate for LAN : > http://www.instantssl.com/ssl-certificate-products/ssl/ssl-certificate-intranetssl.html?ap=ce046 > Ref.: > http://support.godaddy.com/help/art

[web2py] I want to pre-populate a custom form with values from the db

2014-01-17 Thread Keith Planer
So here's my method as-is right now: def diagnosis_lookup(): ... var=request.args(0) ... if var is not None: query=db((db.diagnosis.consumer_id==request.args(0))).select(orderby =~db.diagnosis.id) form = FORM( TABLE( TR(

[web2py] Re: Can I/how would I create a self-signed certificate using IIS?

2014-01-16 Thread Keith Planer
I understand this link might have some guidance for me, but the link is down: http://www.web2py.com/AlterEgo/default/show/140 -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list

[web2py] Can I/how would I create a self-signed certificate using IIS?

2014-01-16 Thread Keith Planer
I'm trying to get remote admin working for my web2py server. I followed instructions from here which didn't work for me, I got "Error opening metabse: 0x80040154" when I tr

[web2py] 2nd page of results don't show up on my SQLFORM.grid

2013-12-31 Thread Keith Planer
def patient_lookup(): db.consumer.id.readable=False var = request.args(0) grid = [] links=[lambda row: A('Note',_href=URL('default', 'notes',args=[row.id ])), lambda row: A('Diagnosis',_href=URL('default', 'diagnosis_lookup' ,args=[row.id])), lambda row: A('Ord

[web2py] Re: Passing form input to a query.

2013-12-31 Thread Keith Planer
And that did, thank you. On Tuesday, December 31, 2013 6:10:02 AM UTC-6, Niphlod wrote: > > use form.vars holds a dict with the values matched with the _name keys, so > something like form.vars.lname should definitely work > > On Tuesday, December 31, 2013 11:10:00 AM UTC+1, Kei

[web2py] Re: I don't want 'Login Successful' or 'Success' popping up on the screen in my app.

2013-12-31 Thread Keith Planer
eing done), so you can also do something like: > > response.flash = session.flash = None > > any time after the SQLFORM or Auth code has run (but before the function > returns and the view is executed). > > Anthony > > On Monday, December 30, 2013 3:31:51 AM UTC-5, Keith Planer wrot

[web2py] Passing form input to a query.

2013-12-31 Thread Keith Planer
This is probably a beyond-simple problem but I can't figure it out. var = request.args(0) query=db.consumer.lname grid = '' form = FORM("Last Name: ",INPUT(_name='lname'),INPUT(_type='submit')) if form.accepts(request.vars, session): query=(db.consumer.lname=???)

[web2py] Re: ValueError: invalid literal for int() with base 10: ''

2013-12-30 Thread Keith Planer
I'm having the same problem, but I'm struggling with saving the database. The corrupted field is a 'date' type. On Wednesday, May 27, 2009 1:15:36 AM UTC-5, ニコノコ wrote: > > I found the source of my problem. I have records with null values. And > since sqlite don't enforce data typing, I assume t

[web2py] Re: Calendar widget in a custom form?

2013-12-30 Thread Keith Planer
Nevermind, found it. requires=IS_EMPTY_OR(IS_DATE()) On Monday, December 30, 2013 11:31:36 AM UTC-6, Keith Planer wrote: > > One other small problem, the field doesn't allow for nothing to be entered > now. How do I make it optional? > > On Monday, December 30, 2013 8:3

[web2py] Re: Calendar widget in a custom form?

2013-12-30 Thread Keith Planer
ssion Date: ",INPUT(_class='date',_name= > 'adm_date',widget=SQLFORM.widgets.date.widget,requires=IS_DATE()))... > > > > Il giorno lunedì 30 dicembre 2013 09:48:06 UTC+1, Keith Planer ha scritto: >> >> After adding some input validation I've re

Re: [web2py] Re: Calendar widget in a custom form?

2013-12-30 Thread Keith Planer
dgets.date.widget,requires=IS_DATE()))... > > > > Il giorno lunedì 30 dicembre 2013 09:48:06 UTC+1, Keith Planer ha scritto: > >> After adding some input validation I've realized that the calendar widget >> is not popping up. Is there anything I need to add to the co

[web2py] Calendar widget in a custom form?

2013-12-30 Thread Keith Planer
After adding some input validation I've realized that the calendar widget is not popping up. Is there anything I need to add to the controller or elsewhere? form=FORM(TABLE(...TR("Admission Date: ",INPUT(_name='adm_date',widget= SQLFORM.widgets.date.widget,requires=IS_DATE()))... -- Resources

[web2py] I don't want 'Login Successful' or 'Success' popping up on the screen in my app.

2013-12-30 Thread Keith Planer
How do I keep session.flash and response.flash from doing their things when I don't want to? Specifically I don't want the messages popping up after a user logs in or when they make a new entry to the DB. -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github

[web2py] Help me understand how to create a search

2013-12-23 Thread Keith Planer
I'm new to web2py, and Python. I created a database, and I want to create a page where I can return records from a table of people, using their first and last names as search terms. What I have so far is: def patient_lookup(): #form = SQLFORM.grid(db.consumer, deletable = True) form=SQL

Re: [web2py] Re: Detect change in sqlform.grid

2013-01-28 Thread Keith Edmunds
Sorry to bump: can anyone give me a pointer on this? Thanks. On Sun, 27 Jan 2013 09:02:45 +, k...@midnighthax.com said: > On Sat, 26 Jan 2013 13:05:50 -0800 (PST), niph...@gmail.com said: > > > grid takes formargs={}, createargs={}, editargs={} > > Thanks. I'm sorry if I'm being a bit slow

Re: [web2py] web2py cookbook

2013-01-27 Thread Keith Edmunds
On Sun, 27 Jan 2013 09:07:50 -0800 (PST), pythonn...@gmail.com said: > for learn more about web2py. That appears to be the Web2py Cookbook, Copyright Packt Publishing. Is this legitimate to share in this way? It would appear not, given that the link on the Web2py pages is to purchase this bo

Re: [web2py] Re: Detect change in sqlform.grid

2013-01-27 Thread Keith Edmunds
On Sat, 26 Jan 2013 13:05:50 -0800 (PST), niph...@gmail.com said: > grid takes formargs={}, createargs={}, editargs={} Thanks. I'm sorry if I'm being a bit slow here, but I *still* can't get what I want to work. I've tried:

Re: [web2py] Re: Detect change in sqlform.grid

2013-01-26 Thread Keith Edmunds
Thanks Massimo, but I'm struggling with how to apply this as I don't ever process the form. I'm doing: grid = SQLFORM.grid(...) return dict(grid=grid, ...) How would I hook into the grid's process() function? > SQLFORM(...).process(...) > > takes two callback functions > > process(onvalidatio

[web2py] Detect change in sqlform.grid

2013-01-25 Thread Keith Edmunds
I have a SQLFORM.grid, and I hook into edits with 'onupdate'. Is there an easy way to tell which field(s) have been edited? It seems that by the time onupdate is called, the database has already been updated, so comparing the form record with the db shows no differences. Thanks. -- We're looking

Re: [web2py] Re: please help us test web2py

2012-07-08 Thread Keith Edmunds
On Sun, 8 Jul 2012 23:31:31 -0700 (PDT), too...@gmail.com said: > +1 on removing it... > The internet is covered with too many meaningless share buttons already. Surely the whole point of the 'welcome' application is to be a scaffolding to be modified as required? It is much easier for someone ne

Re: [web2py] Re: How much python is needed to learn web2py

2012-07-03 Thread Keith Edmunds
On Tue, 3 Jul 2012 15:17:59 -0700, bruce.w...@gmail.com said: > The good news is development is becoming a lot faster as we learned from > a lot of mistakes. That's nice. I realise you won't have the time right now, but an article summarising what you've learned would be good one day. -- We're l

Re: [web2py] Re: How much python is needed to learn web2py

2012-07-03 Thread Keith Edmunds
On Tue, 3 Jul 2012 15:11:10 -0700, bruce.w...@gmail.com said: > So sorry if I find it a little humorous when you think it is still in > development mode FWIW, I thought the same when I saw, "We welcome all the new commers to join this incredible site, Please full-fill the following form." Maybe

[web2py] How does keepvalues work?

2012-07-01 Thread Keith Edmunds
valid. Thanks, Keith -- We're looking for good Linux people: http://www.tiger-computing.co.uk/jobs

[web2py] Need DISTINCT query for combo box

2012-06-22 Thread Keith Edmunds
works, but the query may return more than one row for any given company, and thus the combo repeats the company name, once for each row. I need to make the query DISTINCT, but can't see how to do that. Can anyone help? Thanks, Keith -- We're looking for good Linux people: http://www.tiger-computing.co.uk/jobs --

Re: [web2py] Advice on building a search form

2012-06-14 Thread Keith Edmunds
s week thru Monday. I can help if > Tuesday is soon enough. Next Tuesday is great: I look forward to learning more then. Thanks, Keith -- We're looking for good Linux people: http://www.tiger-computing.co.uk/jobs

[web2py] Advice on building a search form

2012-06-14 Thread Keith Edmunds
27; (populated from the customer table). The resulting query will be fed into a SQLFORM.grid, if that's important. Any pointers to a good way of doing this? Thanks, Keith -- We're looking for good Linux people: http://www.tiger-computing.co.uk/jobs

Re: [web2py] SQLFORM.grid: sorting

2012-05-21 Thread Keith Edmunds
determine the sort order when I click on a SQLFORM.grid header? Thanks, Keith -- "You can have everything in life you want if you help enough other people get what they want" - Zig Ziglar. Who did you help today?

[web2py] SQLFORM.grid: sorting

2012-05-21 Thread Keith Edmunds
y the displayed field? Thanks, Keith -- "You can have everything in life you want if you help enough other people get what they want" - Zig Ziglar. Who did you help today?

[web2py] cpdb errors

2012-05-17 Thread Keith Edmunds
I'm trying to copy a database from Sqlite to MySQL using the cpdb.py script. In the manual, it states: cd web2py python scripts/cpdb.py \ -f applications/app/databases \ -y 'sqlite://storage.sqlite' \ -Y 'postgresql://username:password@hocalhost/mydb' However, if I do that I get "gluon p

Re: [web2py] [noob]html not properly rendered, class="ten columns" has no effect on where the elements are positioned.

2012-05-16 Thread Keith Edmunds
On Tue, 15 May 2012 14:28:04 -0700 (PDT), shortempe...@gmail.com said: > all I get is a page with elements placed on default location I would start by looking in the browser at the page source, and see what is wrong, and I'd check that the CSS file is being loaded. Once you know how the HTML diff

Re: [web2py] Web-framework+db with the widest scalability?

2012-05-13 Thread Keith Edmunds
On Sun, 13 May 2012 06:21:17 -0700 (PDT), abasta...@gmail.com said: > I suspect there wouldn't be much difference in performance > between the two frameworks (similarly and properly configured). So long as this is broadly true (which I suspect it is), there are other considerations to take into

Re: [web2py] Anyone using flake8 / pyflakes?

2012-05-06 Thread Keith Edmunds
In case anyone's interested, I've posted a quick and dirty hack to fix this problem at https://bitbucket.org/tarek/flake8/issue/14/flake8-fails-to-ignore-errors-warning-from#comment-1385353 -- "You can have everything in life you want if you help enough other people get what they want" - Zig Zigl

[web2py] Anyone using flake8 / pyflakes?

2012-05-06 Thread Keith Edmunds
I've just started using flake8 from within vim. Flake8 checks code for PEP8 conformance and general errors, including undefined names. That means that running it when editing, say, a web2py controller, lots of warnings are given: /path/to/file.py|16| W802 undefined name 'session' There is an opti

Re: [web2py] request.intargs RFC

2012-04-30 Thread Keith Edmunds
On Sun, 29 Apr 2012 16:54:11 -0700 (PDT), massimo.dipie...@gmail.com said: > It also takes the optional parameter url_onerror which allows redirect > instead of raise HTTP(404). I kept reading that as "url one error", and struggled to understand the logic. I realise now that it is me that is bro

[web2py] SQLFORM.grid edit form

2012-04-30 Thread Keith Edmunds
I have a SQLFORM.grid, and I want to add a button to the form used to edit records (as called from the grid). Is that possible? -- "You can have everything in life you want if you help enough other people get what they want" - Zig Ziglar. Who did you help today?

[web2py] Admin of list:string

2012-04-30 Thread Keith Edmunds
In the database admin application, when editing a record from table with a list:string field, the field is not pre-populated with the current value. Test model: db.define_table('t_colours', Field('f_colour', type='list:string', label=T('Colour'))) db.t_colours.f_colour.requires = IS_IN_SET(('

Re: [web2py] How to merge more than one template in web2py

2012-04-26 Thread Keith Edmunds
On Thu, 26 Apr 2012 23:23:06 -0700 (PDT), vibhor.purand...@zero-group.com said: > How to merge more than one template in web2py? http://web2py.com/books/default/chapter/29/5#Page-layout -- "You can have everything in life you want if you help enough other people get what they want" - Zig Ziglar

Re: [web2py] Cookies and Sessions

2012-04-26 Thread Keith Edmunds
On Wed, 25 Apr 2012 15:49:23 -0700 (PDT), varelay...@gmail.com said: > I'm quite new to web2py and a noob at it. I've been struggling with the > difference between cookies and sessions...But I have plenty of questions > about them and how to use them(in web2py) I think you should approach them f

Re: [web2py] shared host deployment of my web2py site

2012-04-15 Thread Keith Edmunds
On Sun, 15 Apr 2012 07:36:19 +0100, doncoleon...@gmail.com said: > So you mean I should just click the 'configure' file? You need to do this from the command line. > And how do I add > the parameters, are u saying It's "you", not "u". You need a open a terminal window and type in the commands

Re: [web2py] Vertical lines around database string values

2012-04-14 Thread Keith Edmunds
Are you using Fields of type list:string? -- "You can have everything in life you want if you help enough other people get what they want" - Zig Ziglar. Who did you help today?

Re: [web2py] shared host deployment of my web2py site

2012-04-14 Thread Keith Edmunds
On Sat, 14 Apr 2012 05:08:01 -0700 (PDT), doncoleon...@gmail.com said: > but i dont > know what the next line of instruction says It says run this command: ./configure --prefix=$HOME ...from the Python-2.6.5 directory under your home directory. The './configure' is the command that will be run

Re: [web2py] Overlapping periods

2012-04-14 Thread Keith Edmunds
On Sat, 14 Apr 2012 09:44:28 +0100, k...@midnighthax.com said: > q = ((db.period.begindatestart)) > if db(query).count(): Argh. Typos. 'q' and 'query' should refer to the same thing, so change the second line to 'if db(q).count():' (that change needs to take place twice). -- "You can

Re: [web2py] Overlapping periods

2012-04-14 Thread Keith Edmunds
On Fri, 13 Apr 2012 11:38:25 -0700 (PDT), sababa.sab...@gmail.com said: > The > function should only add periods that doesn't overlap any of the > already registered ones. Let me try to help (I owe this group a lot of help). I've ignored your code, and I don't know what schema you're using, bu

Re: [web2py] Overlapping periods

2012-04-14 Thread Keith Edmunds
On Fri, 13 Apr 2012 11:38:25 -0700 (PDT), sababa.sab...@gmail.com said: > But the function does not work, and I can't see what's wrong. Any idea? You don't make it very easy for others to help. "The function does not work" - which function doesn't work, and in what way does it not work? What inpu

Re: [web2py] Re: SQLFORM.grid pagination

2012-04-11 Thread Keith Edmunds
On Tue, 10 Apr 2012 21:38:15 -0700 (PDT), massimo.dipie...@gmail.com said: > Please open a ticket about this in google code. Added: http://code.google.com/p/web2py/issues/detail?id=758 -- "You can have everything in life you want if you help enough other people get what they want" - Zig Ziglar.

Re: [web2py] Re: creating a shopping cart using session

2012-04-11 Thread Keith Edmunds
On Wed, 11 Apr 2012 00:11:18 -0700 (PDT), halna...@gardeniatelco.com said: > i am trying to work with session like you showed me but still when i add > somthing it just changes the last element in the session to the element > i added Show us the code. -- "You can have everything in life you wan

[web2py] SQLFORM.grid pagination

2012-04-10 Thread Keith Edmunds
I have a SQLFORM.grid that says "67 records found", and shows the first 20 (as I would expect). At the bottom, there are four buttons for the pages (1-4). If I click on any of 2, 3 or 4, I get "No records found". Looking deeper, the URL of the first page is http://127.0.0.1:8000/app/repor

Re: [web2py] Multiple target by using the Ajax

2012-04-09 Thread Keith Edmunds
On Mon, 9 Apr 2012 12:28:23 +0100, k...@midnighthax.com said: > def echo(): > return "jQuery('#target1').html(%s);jQuery('#target1').html(%s);" \ > % > (repr(request.vars.name.upper()),repr(request.vars.name.lower())) Sorry, the second '#target1' above should be '#target2' -- "You can

Re: [web2py] Multiple target by using the Ajax

2012-04-09 Thread Keith Edmunds
On Sun, 8 Apr 2012 23:32:31 -0700 (PDT), sanjeet.ro...@gmail.com said: > How to call the multiple function or set the multiple target via Ajax In the view: Start of target1 End of target1 Start of target2 End of target2 In the controller: def echo(): return "jQuery('#target1').ht

[web2py] Stopping a timer from an Ajax call (Clienttools)

2012-04-07 Thread Keith Edmunds
I'm using clienttools.py to put a timer on a page; the timer calls a controller function (imaginatively called 'tick') every second, which in turn updates a div on the page via Ajax. So far, so good. I want the 'tick' controller function to be able to stop/disable the timer under certain circumsta

Re: [web2py] Re: Hiding columns in SQLFORM.grid

2012-04-07 Thread Keith Edmunds
On Sat, 7 Apr 2012 07:41:16 -0700 (PDT), abasta...@gmail.com said: > Before constructing the grid, try db.mytable.myfield.readable = False. Anthony, very neat, and it works: thank you. -- "You can have everything in life you want if you help enough other people get what they want" - Zig Ziglar.

[web2py] Hiding columns in SQLFORM.grid

2012-04-07 Thread Keith Edmunds
Is it possible to hide columns in a SQLFORM.grid? I need to retrieve some columns in the query to build some custom links, but I don't want those columns displayed. I've tried setting maxtextlength for those columns to zero, but they still display. Thanks. -- "You can have everything in life you

[web2py] Unit testing and faking authentication

2012-04-07 Thread Keith Edmunds
I've been looking that the unit testing page (http://www.web2py.com/AlterEgo/default/show/260), which is very helpful. However, most of my controller functions are decorated with '@auth.requires_login()', and thus if I call them from the test suite, they fail (issuing a redirect): File "/home/ka

Re: [web2py] Re: DAL or SQL?

2012-03-27 Thread Keith Edmunds
On Sun, 25 Mar 2012 16:41:09 -0700 (PDT), niph...@gmail.com said: > Doh, you're right. All the "datetime" api on fields are extracting, not > converting the actual value Yes, and I've also found that, with Sqlite at least, web2py doesn't carry out datetime arithmetic correctly within the DAL

Re: [web2py] Re: DAL or SQL?

2012-03-25 Thread Keith Edmunds
On Mon, 19 Mar 2012 14:45:51 -0700 (PDT), niph...@gmail.com said: > for every "period", duration is calculated as: > duration = db.periods.end_time.seconds() - > db.periods.start_time.seconds() This is wrong. I reworked my data model so that the period start and stop fields were of type datetime

[web2py] Documentation suggestion

2012-03-25 Thread Keith Edmunds
If something like this has already been suggested, please point me at the earlier discussion. I've read the Web2py manual (and bought three of them) since v1, and the quality of both web2py and the manual has improved hugely. To my mind, however, the manual tries to fulfil two roles currently: it

Re: [web2py] Re: DAL or SQL?

2012-03-22 Thread Keith Edmunds
> Perhaps you could add the seconds as a virtual lazy field. That sounds worth investigating, thanks. > We shall come to an agreement when you explain plainly what is your real > model... it seems that your start and end columns are "time" and not > "datetime"... Time fields don't have a "seconds

Re: [web2py] Re: DAL or SQL?

2012-03-21 Thread Keith Edmunds
On Mon, 19 Mar 2012 14:45:51 -0700 (PDT), niph...@gmail.com said: > for every "period", duration is calculated as: > duration = db.periods.end_time.seconds() - > db.periods.start_time.seconds() > > now, get a list of all "durations"... > > result = db(db.periods.id>0).select(db.periods.id, durat

Re: [web2py] Re: DAL or SQL?

2012-03-21 Thread Keith Edmunds
On Wed, 21 Mar 2012 14:43:42 -0700 (PDT), niph...@gmail.com said: > rows = db(db.t_periods.id==40).select(db.t_periods.f_period_end) > for row in rows: > print row.f_period_end.seconds() No, that gives an error: >>> rows = db(db.t_periods.id==40).select(db.t_periods.f_period_end) >>> for row

Re: [web2py] Re: DAL or SQL?

2012-03-21 Thread Keith Edmunds
I'm having problems getting a valid value for seconds() from a time field under Sqlite. I can extract a time: >>> for row in db(db.t_periods.id==40).select(db.t_periods.f_period_end): ... print row ... However, if I try to get the seconds(), it returns None: >>> for row in >>> db(db.t_periods

[web2py] Bug(?) using list:string in 1.99.7

2012-03-21 Thread Keith Edmunds
My application has broken moving from 1.99.4 to 1.99.7. I have a field of type list:string (using Sqlite). In 1.99.7, dal.py breaks at line 1405 (marked with >>>): return str(obj) if fieldtype.startswith('list:'): if not obj: obj = [] el

Re: [web2py] Re: DAL or SQL?

2012-03-20 Thread Keith Edmunds
I'm using sqlite, and I'm embarrassed about my errors. Thanks for your help. -- "You can have everything in life you want if you help enough other people get what they want" - Zig Ziglar. Who did you help today?

Re: [web2py] Re: DAL or SQL?

2012-03-20 Thread Keith Edmunds
I've hit an error (web2py bug?) in Niphlod's well-explained example. I *was* running web2py.1.99.4, which gave this: >>> duration=(db.t_periods.f_period_end.seconds() - >>> db.t_periods.f_period_start.seconds()).sum() >>> result=db(db.t_periods>0).select(db.t_periods.id,duration,groupby=db.t_per

Re: [web2py] Re: DAL or SQL?

2012-03-20 Thread Keith Edmunds
Thanks Niphlod, that looks good and I will try it soon. -- "You can have everything in life you want if you help enough other people get what they want" - Zig Ziglar. Who did you help today?

[web2py] DAL or SQL?

2012-03-19 Thread Keith Edmunds
I need to run a reasonably complex query, and I'm wondering whether it would be better to code it in SQL, or should I try to get the DAL to provide the data (or maybe there's another way). There's no right or wrong answer, but I'd welcome opinion on the best approach. Simply put, consider two tabl

Re: [web2py] Re: Odd auth problem

2012-03-18 Thread Keith Edmunds
On Sat, 17 Mar 2012 15:03:39 -0700 (PDT), abasta...@gmail.com said: > Instead, you can use auth.user_id, which > will simply return None when the user isn't logged in rather than an > error. Thanks, that's fixed the problem. -- "You can have everything in life you want if you help enough other

[web2py] Odd auth problem

2012-03-17 Thread Keith Edmunds
/logout. Can anyone offer any suggestions as to what is going on here? Thanks, Keith

Re: [web2py] Re: Representing foreign field with image (format/represent)

2012-02-12 Thread Keith Edmunds
Thanks Alan, that has enabled me to do what I want. -- "You can have everything in life you want if you help enough other people get what they want" - Zig Ziglar. Who did you help today?

[web2py] Representing foreign field with image (format/represent)

2012-02-12 Thread Keith Edmunds
I have a form based on a table which includes foreign fields. By default, the foreign fields are displayed as the name from the foreign table as expected. I want to have an image displayed rather than the name from the foreign table. Not having used 'format' before, I changed the format of the fo

Re: [web2py] Howto create parent and children at same time?

2011-04-20 Thread Keith Pettit
I would prefer to do that in the controller and not depend on javascript. It would be a big problem if javascript was turned off. Thanks for the suggestion though. -Keith

[web2py] Howto create parent and children at same time?

2011-04-20 Thread Keith Pettit
oad', Field('ticket', db.ticket), Field('container_id'), Field('entered', 'datetime'), Field('updated', 'datetime'), Field('product', db.product) ) Thanks for any help, -Keith

[web2py] Re: Access Control not in db.py?? How to modify?

2011-04-19 Thread Keith Pettit
c but has a nice single ajax page for adding user/group and modifying the basics. Thanks, -Keith

[web2py] Re: Access Control not in db.py?? How to modify?

2011-04-19 Thread Keith Pettit
I appreciate the help. I'll give the plugin a try and read through the docs you suggested. One note. auth_user was in db.py if I created a "New simple application" or went through the "New Application Wizard". Which I is part of what was confusing me. Thanks, -Keith

[web2py] Access Control not in db.py?? How to modify?

2011-04-19 Thread Keith Pettit
I'm still learning web2py, I'm working on access control and was confused by a few things I was hoping to understand better. 1 - Why is auth_user in db.py, but none of the other auth_ tables are? 2 - If I wanted to add or modify any of the auth tables, how would I do that? auth_user is in db.p

[web2py] Wizard comments/suggestions

2011-04-11 Thread Keith Pettit
First of all, I love it. This gives me a huge start on creating an application. It may not be perfect but it gives a great start. I had some comments/questions about some of the different parts of the wizard that I put below. *Step 1: Setting Parameters* Plugins: Where does it get it's plugi

[web2py] Re: Wizard bug when creating a table auth_group

2011-04-11 Thread Keith Pettit
Ah, got it. Thanks for the help. I didn't know auth_user created those tables along with it. In case anybody is wondering it looks like it creates the following tables: auth_event auth_group auth_membership auth_permission auth_user Thanks again, -Keith

[web2py] Wizard bug when creating a table auth_group

2011-04-11 Thread Keith Pettit
was the table name, me adding that field to auth_user or if it was something else that caused the problem. Either way it was a minor annoyance and regardless the wizard saved me allot of work in creating all the CRUD stuff. Thanks, Keith

[web2py] Re: Best way to have dynamic user created Questionnaire?

2011-04-06 Thread Keith Pettit
Ah, thanks. I'll take a look. I did find a PHP app that does most of what I need http://www.limesurvey.org/ I'm trying to take it apart to see how it works.

[web2py] Best way to have dynamic user created Questionnaire?

2011-04-06 Thread Keith Pettit
ucture the model. Any ideas on how to do the model or this type of app in general? Thanks, Keith

[web2py] Re: video about new RESTful APIs

2011-03-22 Thread Keith Pettit
eb2py book and now I'm trying RESTful API's and it seems like the same thing. At least from what I've tried so far. What is the difference and why would I want to use one method over another? Thanks, -Keith

Re: [web2py] Re: web2py default application suggestion

2011-03-22 Thread Keith Pettit
Thanks that helps me understand a bit better. Being a newbie I'd suggest just having the one example. When looking I didn't really know what the files were or that they are competing methods to do the same thing. Even if the naming is better like you suggest, it would still make me wonder

Re: [web2py] Re: web2py default application suggestion

2011-03-22 Thread Keith Pettit
One other note. For both apache and web2py's built in webserver I had to restart them for the change to take effect. Just thought I'd mention that in case someone wonders why there change isn't showing. -Keith On Tue, Mar 22, 2011 at 1:30 PM, Ross Peoples wrote: > I'm

Re: [web2py] Re: web2py default application suggestion

2011-03-22 Thread Keith Pettit
file like you suggested called routes.py which did work. It's kind of confusing with the two examples that don't quite work so I thought I'd mention it. Thanks for the help, -Keith On Tue, Mar 22, 2011 at 1:14 PM, Ross Peoples wrote: > I had a similar question as you a few we

[web2py] How do I set web2py applications as separate virtualhosts?

2011-03-22 Thread Keith Pettit
Web2py works great for me through Apache and mod_wsgi. All seems fast and clean. But now that I'm creating multiple web2py applications. How can I deploy multiple web2py applications as separate virtualhosts? Basically I want to do something like: app1.mydomain.com goes to App1 app2.mydomain

[web2py] web2py default application suggestion

2011-03-22 Thread Keith Pettit
I'm fairly new to web2py and had a question early on. How could I make a app I created in web2py show up by default. Not that I didn't like the "welcome" app but I wanted to set my own as default. Somebody in IRC #web2py told me to rename my app to "init" which worked. There wasn't a way I s

[web2py] Re: FORM without db, how to get field name?

2010-09-22 Thread Keith
{{if fieldname is not 'id':}} {{=form.custom.label[fieldname]}} {{=form.custom.widget[fieldname]}} {{pass}} {{pass}} {{=form.custom.submit}} {{=form.custom.end}} Thanks again for the help! -Keith On Sep 22, 10:22 am, mdipierro wrote: > that messes up ord

[web2py] Re: FORM without db, how to get field name?

2010-09-22 Thread Keith
om the above: Moderator Pw Room Name Id Attendee Pw I'm not sure if the first or second example is the better way to go but it's nice working through the features of web2py. Thanks again for the help, -Keith On Sep 21, 5:29 pm, mdipierro wrote

[web2py] FORM without db, how to get field name?

2010-09-21 Thread Keith
ut that doesn't give me the end result HTML I need. I really need to be able to call the field itself and field name as separate variables in the view. I know worst case I can manually create the HTML for the whole form but I'm trying to learn and figure out if this is possible first before I do that. Thanks for any help or pointers. -Keith

[web2py] convert field to multiple view values?

2010-06-04 Thread Keith
I'm new to web2py and the I did this previously was with javascript but I was hoping to avoid that this go around. In my database table I have a single field something like this below: db.define_table('foo', Field('height', 'double'), In the controller/view I need to be able to translate that

Re: [web2py] Re: Using LOAD from a controller?

2010-05-13 Thread Keith Edmunds
. I'm going to monitor the list more and see if I can help others. Keith

Re: [web2py] Re: Using LOAD from a controller?

2010-05-11 Thread Keith Edmunds
Sorry, Iceburg, I appreciate your attempt to help, but you've lost me completely! Can you explain? Thanks

Re: [web2py] Using LOAD from a controller?

2010-05-11 Thread Keith Edmunds
On Tue, 11 May 2010 21:16:45 +0100, k...@midnighthax.com said: > return = LOAD('todo','todo_form',ajax=True) Typo in my mail: that is actually return LOAD('todo','todo_form',ajax=True)

[web2py] Using LOAD from a controller?

2010-05-11 Thread Keith Edmunds
I was to display a form using Ajax in response to a click on a link on the page. I have tried putting this in the view: New todo with this in the controller: def new(): return = LOAD('todo','todo_form',ajax=True) def todo_form(): form = SQLFORM(db.tasks,fields=['priority','subject','d

Re: [web2py] Debugging with GAE and Eclipse/Aptana?

2010-05-01 Thread Keith Edmunds
I don't run web2py.py under the debugger. I just put the following where I want the first breakpoint: import pydb pydb.debugger() ...which drops into the debugger when encountered. No GUI, but I believe you can hook up DDD to pydb if you are so inclined. Whether that works on GAE or not, I don't

Re: [web2py] Re: Application logging

2010-04-29 Thread Keith Edmunds
g files (which are logrotated independently). Massimo: I would have thought that application logging was an integral part of an enterprise application, much as authentication is, and should be in the scaffolding. It really isn't very big. Keith

[web2py] Silent errors

2010-04-27 Thread Keith Edmunds
I've just found a stupid programming error of mine. Code: task_rows = db(db.tasks.ref==request.vars.number).select() if len(task_rows): rows[0].update_record(status = request.vars.new)

  1   2   >