[web2py] Data in database as translated...

2012-06-01 Thread Jason Brower
I have some states of an row in the database. read and unread There will be more states later. To do the translations I made this in the the template {{=T("read")}} {{=T("unread")}} {{=T("message.state")}} Do you see a better way for something like this to happen? BR, Jason Brower

Re: [web2py] Re: failures

2012-06-01 Thread G. Clifford Williams
As I used to have a (zope) hosting business I have spare capacity on my servers (actual hardware that I own) where I host mirrors for cherokee, linuxmint, and pc-bsd. I'd be more than happy to host or mirror web2py.com. My servers are currently in CA, FL, and CO but CA will likely be migrated t

Re: [web2py] Hebrew encoding

2012-06-01 Thread Martin Weissenboeck
Hi Udi, I have tried it once again. I had to change from to and from to . "unescape" works now! But it would be interesting to learn about more this problem. Could you please answer Massimos questions? 2012/6/2 Massimo Di Pierro > I am not sure there is an error here. Is the problem that t

Re: [web2py] Re: Thinking of building a bug tracker...

2012-06-01 Thread Bruce Wade
i-track is the winner I already have it integrated into my project and will build off of it. On Fri, Jun 1, 2012 at 7:01 AM, Bruce Wade wrote: > issue tracker there is an error when you click on projects on the demo not > a good example :D > i-track looks like a very good starting point if we wa

Re: [web2py] Set the permission on the selectable in SQLFORM.grid

2012-06-01 Thread Sanjeet Roy
Thanks Johann On Fri, Jun 1, 2012 at 2:53 PM, Johann Spies wrote: > On 1 June 2012 10:18, Sanjeet Roy wrote: > >> HIi i am useng the following codes :- >> >> def test(): >> table = >> SQLFORM.grid(db.abc,create=(auth.has_permission('CRUD','auth_user') or >> auth.has_permission('Admin','auth

[web2py] Re: Trouble migrating databases

2012-06-01 Thread Massimo Di Pierro
Hello David, Do you have a backup of the databases/ folder that worked with a previous version? If so..., delete everything in databases. Than do: db = DAL('sqlite://storage.sqlite', migrate_enabled=True) Do you get an error? If you do not get any error, check which table files different from

[web2py] Re: DAL list:integer and postgresql integer array type

2012-06-01 Thread Massimo Di Pierro
The search by content should be faster using native postgresql array type. Everything else should be the same. We could change it and should be easy. The problem is backward compatibility. I need to give some thought about this. Please open a ticket to google code. On Friday, 1 June 2012 16:49:

Re: [web2py] pyfilesystem support (store uploads in S3)

2012-06-01 Thread Massimo Di Pierro
For production, your solution is better than using web2py+pyfilesystem. Yet, if you can help us test it would be great. On Friday, 1 June 2012 16:32:04 UTC-5, Nils Olofsson wrote: > > Hi, > I use s3 for storing images, I was looking a creating something like this > ages ago but my python Fu and

Re: [web2py] Re: failures

2012-06-01 Thread Massimo Di Pierro
I am for it, as long as we have a policy and scripts do make sure the VERSION and the web2py*.zip are in sync. There are many apps on web2py.com. Some of them cannot easily be mirrored but can be given subdomains and do not need to be up 100%. On Friday, 1 June 2012 15:52:55 UTC-5, mcm wrote: >

[web2py] Re: Removing a row from a list

2012-06-01 Thread Cliff Kachinske
Based on this thread and an earlier one on the same topic, I think I'm going to rework my index list pages something like this. The link to the delete function will include the record id, index row number of the record and number of rows on the page. When the user clicks the delete button, the

[web2py] Trouble migrating databases

2012-06-01 Thread david.waldrop
I just downloaded the nightly build form Trunk to test the new web2py 2.0 with some of my web2py based solutions. I now have a very weird eroor I think due to migrating the database form postgress (production) to sqllite (development). Here is one of the errors I get: Traceback (most recent c

[web2py] DAL list:integer and postgresql integer array type

2012-06-01 Thread Lewis
By any chance is the DAL list:integer type implemented as a postgresql array? The web2py book would say no--the list:integer is a big text field as '1 | 2 | 3', etc. Could it be implemented using postgresql's native array types in the DAL driver for postgresql? I'd assume that optimized db

Re: [web2py] Re: web2py.com/book generating an internal error

2012-06-01 Thread pbreit
I wonder if Cloudflare would help out? It basically offers a free service to help improve site performance (CDN, etc) as well as mitigate malicious/nonmalicious bots. On Friday, June 1, 2012 11:13:48 AM UTC-7, rochacbruno wrote: > > may be robots scanning? I had some problem in slices site. > >

Re: [web2py] pyfilesystem support (store uploads in S3)

2012-06-01 Thread nils
Hi, I use s3 for storing images, I was looking a creating something like this ages ago but my python Fu and web2py Fu were not up to scratch... I will test this, just wondering if I can change my DB model over,currently I have s3 mounted as a filesystem, so web2py is just writing to a directory.

Re: [web2py] Re: failures

2012-06-01 Thread Bruno Rocha
I think it is a good idea. I also have web2py.com.br which I am pointing to slices website and it could be pointed to the main mirror for Brazil. On Fri, Jun 1, 2012 at 5:52 PM, Michele Comitini wrote: > Should we have global mirrors of web2py.com? > IMHO we should and we should also have a geo

Re: [web2py] Re: failures

2012-06-01 Thread Michele Comitini
Should we have global mirrors of web2py.com? IMHO we should and we should also have a geo dns service with a server like http://geoipdns.org/ mic 2012/6/1 LightDot : > If you need a mirror quickly, I can give you a full VPS on a 100 Mbit line. > I have space on a new hardware we recently put into

[web2py] Re: How to check if attribute exists

2012-06-01 Thread Omi Chiba
It works great. Thanks !! On Friday, June 1, 2012 2:56:58 PM UTC-5, Anthony wrote: > > if hasattr(request.vars.csvfile, 'file'): > > Anthony > > On Friday, June 1, 2012 3:51:09 PM UTC-4, Omi Chiba wrote: >> >> I have a simple upload form. It works fine but it shows the following >> error when use

Re: [web2py] Suggestions for multiple files upload in form

2012-06-01 Thread Richard Vézina
No problem, I don't have time neither maybe for a couples of days too :) Richard On Fri, Jun 1, 2012 at 3:24 PM, Paolo Caruccio wrote: > Richard, > > I made some reflections on what you want to do and it's not easy, since > the use of control for simultaneous upload of multiple files was aimed t

[web2py] Re: [OT] Pycharm 2 is out

2012-06-01 Thread Omi Chiba
Voted ! I just missed #100. I was #101 : ) On Thursday, December 15, 2011 1:08:07 PM UTC-6, mikech wrote: > > Still no web2py love, but some nice features. > > http://www.jetbrains.com/pycharm/whatsnew/ > > and here is the link for voting for web2py support. > > http://youtrack.jetbrains.net/is

[web2py] Re: How to check if attribute exists

2012-06-01 Thread Anthony
if hasattr(request.vars.csvfile, 'file'): Anthony On Friday, June 1, 2012 3:51:09 PM UTC-4, Omi Chiba wrote: > > I have a simple upload form. It works fine but it shows the following > error when user submit it without selecting file. How can I check > if request.vars.csvfile.file attribute exi

[web2py] How to check if attribute exists

2012-06-01 Thread Omi Chiba
I have a simple upload form. It works fine but it shows the following error when user submit it without selecting file. How can I check if request.vars.csvfile.file attribute exists ? File "C:/trunk/web2py/applications/tedi/controllers/default.py", line 110, in customer_upload if request.v

Re: [web2py] Suggestions for multiple files upload in form

2012-06-01 Thread Paolo Caruccio
Richard, I made some reflections on what you want to do and it's not easy, since the use of control for simultaneous upload of multiple files was aimed to replace the standard control. As an example of use, you can seehttp://ochiba77.blogspot.it/2012/01/web2py-slices-sending-email-from-form.htm

[web2py] Re: using ajax and load for modular applications

2012-06-01 Thread Andrew
Also, I don't see a div with an Id = patient. That's your target. Is it in the code but not in your post?

[web2py] Re: using ajax and load for modular applications

2012-06-01 Thread Anthony
On Friday, June 1, 2012 2:03:23 PM UTC-4, angle wrote: > > Thanks for your response, I've answered your points below: > >> >> > #response.ajax = \ >>> 'web2py_component("%s","patient",ajax=True,vars=vars1)' % URL >>> ('patient') >> >> I think this should be response.js rather than respo

[web2py] Re: failures

2012-06-01 Thread LightDot
If you need a mirror quickly, I can give you a full VPS on a 100 Mbit line. I have space on a new hardware we recently put into service (EU colocation). On Friday, June 1, 2012 4:53:03 PM UTC+2, Massimo Di Pierro wrote: > > Today the VPS that hosts web2py.com failed (not sure what but I can no >

[web2py] Re: Problem with basic_login actually logging in (maybe not a bug)

2012-06-01 Thread Anthony
OK, I updated the book again. On Friday, June 1, 2012 10:43:42 AM UTC-4, Massimo Di Pierro wrote: > > There is a major problem with the VPS that hosts the book. It is down and > can no longer login into it. I am forced to restore it as May 29. This > change will be lost. Sorry Anthony. > > Massi

Re: [web2py] Re: web2py.com/book generating an internal error

2012-06-01 Thread Bruno Rocha
may be robots scanning? I had some problem in slices site. On Fri, Jun 1, 2012 at 3:01 PM, Massimo Di Pierro < massimo.dipie...@gmail.com> wrote: > The VPS is slow like a dog. Even if I turn off the web server. I do not > know what is going on but I submitted a ticket. That is causing all kind of

[web2py] Re: using ajax and load for modular applications

2012-06-01 Thread angle
Thanks for your response, I've answered your points below: > > #response.ajax = \ >> 'web2py_component("%s","patient",ajax=True,vars=vars1)' % URL >> ('patient') > > I think this should be response.js rather than response.ajax. > This code is copied from the example 'Designing Modula

[web2py] Re: web2py.com/book generating an internal error

2012-06-01 Thread Massimo Di Pierro
The VPS is slow like a dog. Even if I turn off the web server. I do not know what is going on but I submitted a ticket. That is causing all kind of issues. I managed to login into it, clearn cache, etc. but still slow. On Friday, 1 June 2012 12:16:34 UTC-5, Anthony wrote: > > It was working a

[web2py] Re: [OT] Pycharm 2 is out

2012-06-01 Thread Fumiki Shinohara
voted!

[web2py] Modular Applications and the use of Load / Ajax

2012-06-01 Thread angle
Hi web2py, I am a fairly experienced coder, but am new to web-programming and web2py. Ihave read the documentation, bought the book, and done quite a few of the examples which have run OK. I am coding on Windows7 OS - using Firefox browser. I am trying to modularise my current demo web2py web-a

[web2py] Re: Removing a row from a list

2012-06-01 Thread monotasker
ΟΚ, that's very helpful. Thanks once again. On Friday, June 1, 2012 1:14:08 PM UTC-4, Anthony wrote: > > X >> > > That would have to be _onclick, not _href, and you'd want to add something > like "; return false" at the end to prevent the usual link behavior. > Anyway, I suggested an alternative

[web2py] web2py.com/book generating an internal error

2012-06-01 Thread Anthony
It was working a minute ago.

[web2py] Re: Removing a row from a list

2012-06-01 Thread Anthony
> > X > That would have to be _onclick, not _href, and you'd want to add something like "; return false" at the end to prevent the usual link behavior. Anyway, I suggested an alternative (in a separate post) that's a little simpler. I'm just not quite sure what you mean that "response.js is o

[web2py] Re: Removing a row from a list

2012-06-01 Thread monotasker
Thanks, Anthony, and sorry for spreading misinformation. I just re-read the book section and found where I'd been confused. So it looks like Johann simply needs something like this for each row in his view: X Then to refresh the component after the controller runs, he would just return "web2py

[web2py] Re: Removing a row from a list

2012-06-01 Thread Anthony
You might consider building the links in the grid using the A() helper -- if you specify the cid argument, it will trap the link and load it as a component: A('Remove', _href=URL('default', 'grid.load', args=['delete', item.uuid]),cid =request.cid) Each link should include the uuid of the item

Re: [web2py] failures

2012-06-01 Thread Michele Comitini
Massimo, what is happening to you is on or more Murphy Law: http://www.murphys-laws.com/murphy/murphy-office.html 2012/6/1 Bruno Rocha : > Hi Massimo, > > If you need I can host a web2py mirror on the same linode where slices is > hosted. > > Let me know if you need some help on this. > > http:/

Re: [web2py] failures

2012-06-01 Thread Massimo Di Pierro
Sure. Just tell what you need from me On Friday, 1 June 2012 10:35:41 UTC-5, rochacbruno wrote: > > Hi Massimo, > > If you need I can host a web2py mirror on the same linode where slices is > hosted. > > Let me know if you need some help on this. > > http://zerp.ly/rochacbruno > Em 01/06/2012 11:

[web2py] Re: Removing a row from a list

2012-06-01 Thread Anthony
> > The :eval method of the ajax() function requires that there is a form > field holding the value to be sent by ajax. > When calling ajax(), it is not necessary to send any data via a form field (the value of the second parameter can simply be an empty list). > So in your view you could ju

[web2py] Re: Removing a row from a list

2012-06-01 Thread monotasker
The :eval method of the ajax() function requires that there is a form field holding the value to be sent by ajax. So in your view you could just include in INPUT() helper somewhere on the page and hide it via css. Then when the "remove row" link is clicked, your could use js to: - set the input

[web2py] Re: From ul to bootstrap row

2012-06-01 Thread Anthony
Maybe something like: {{for i, s in enumerate(socialmedia):}} {{if not i % 2:}}{{pass}} {{=s}} {{if i % 2:}}{{pass}} {{pass}} Anthony On Friday, June 1, 2012 3:05:00 AM UTC-4, Annet wrote: > > In a view I have the following code to generate an ul: > > > {{for s in socialmedia:}} >

[web2py] Re: really dumb question

2012-06-01 Thread pbreit
In finder you can right-click web2py.app and "show package contents".

[web2py] From ul to bootstrap row

2012-06-01 Thread pbreit
Sounds like you should be using a table.

[web2py] Re: using ajax and load for modular applications

2012-06-01 Thread Anthony
> > LOAD('default','post.load',ajax=True,target='patient',vars={'scanId':( > request.args[2] or 1)}) > LOAD is an HTML helper that generates a div and a script element, so it should be inserted in a view, not simply called in the controller. > #response.ajax = \ > 'web2py_component

[web2py] Regex problem in custom validator

2012-06-01 Thread monotasker
I have a db field that holds a regular expression (one unique regex for each row in the table). Another row in the table (db.steps.readable_response) lists sample strings that should satisfy the regex. I'm trying to create a custom validator that tests the regular expression against the sample

Re: [web2py] failures

2012-06-01 Thread Bruno Rocha
Hi Massimo, If you need I can host a web2py mirror on the same linode where slices is hosted. Let me know if you need some help on this. http://zerp.ly/rochacbruno Em 01/06/2012 11:53, "Massimo Di Pierro" escreveu: > Today the VPS that hosts web2py.com failed (not sure what but I can no > long

[web2py] Re: Removing a row from a list

2012-06-01 Thread Cliff Kachinske
This looks like a job for ajax. Make a callback to the controller to delete the row using :eval. The callback function returns a jquery code to delete the row from the page. I would give you a link to the book, but I'm having problems going to web2py.com. On Friday, June 1, 2012 6:43:37 AM UT

[web2py] failures

2012-06-01 Thread Massimo Di Pierro
Today the VPS that hosts web2py.com failed (not sure what but I can no longer ssh into it). Is to happens that yesterday the HD of my laptop failed. My office mac is no longer syncing emails with outlook and gmail. A few other random and independent things have been failing on me in the last fe

[web2py] Re: Filter select options

2012-06-01 Thread Rod Watkins
Thanks Anthony, that's good to know. On Wednesday, 30 May 2012 19:55:09 UTC-7, Anthony wrote: > > Note, the default IS_IN_DB validator for a reference field also sets the > label argument of the validator to be the _format attribute of the > referenced table (so the select will show a more descr

[web2py] Re: Problem with basic_login actually logging in (maybe not a bug)

2012-06-01 Thread Massimo Di Pierro
There is a major problem with the VPS that hosts the book. It is down and can no longer login into it. I am forced to restore it as May 29. This change will be lost. Sorry Anthony. Massimo On Thursday, 31 May 2012 23:05:09 UTC-5, Anthony wrote: > > Just updated the book: > http://web2py.com/bo

Re: [web2py] Re: Future of Web2py in India/Asia

2012-06-01 Thread RKumar Its mee
Hahah good one.. I have read this article long days back. Yes this happens too. To tell you, even SAP got Java libraries as well ehehehehe. Its great that Web2py is doing good changes. I wish it keep up something different "Think Different" and attract more people to this community Regards, Rohit

Re: [web2py] Re: Thinking of building a bug tracker...

2012-06-01 Thread Bruce Wade
issue tracker there is an error when you click on projects on the demo not a good example :D i-track looks like a very good starting point if we want to build of an existing product. On Fri, Jun 1, 2012 at 12:37 AM, Jason (spot) Brower wrote: > issue tracker I know of... > I am looking at itracke

[web2py] using ajax and load for modular applications

2012-06-01 Thread angle
Hi web2py, I am a fairly experienced coder, but am new to web-programming and web2py. Ihave read the documentation, bought the book, and done quite a few of the examples which have run OK. I am coding on Windows7 OS - using Firefox browser. I am trying to modularise my current demo web2py web-a

[web2py] Using web2py+mod_wsgi for SVN/DAV Auth and Authz

2012-06-01 Thread demetrio
Hi everyone, i've seen this entry on the book: http://web2py.com/books/default/chapter/29/9?search=wsgi#Using-web2py-to-authorize-non-web2py-apps but i think that it needs to have an active session on the web application, and I need something a little more complex I need to ask from a wsgi scr

Re: [web2py] cool new wysiwyg editor

2012-06-01 Thread villas
Then it must be compatible with this guy!! The Refridgerator Remember him - he was a sensation at the time? On Thursday, 31 May 2012 15:50:23 UTC+1, encompass wrote: > > Oh, and it's compatible with refrigerators. :P > Says it right in the front page. :O > On 05/31/2

[web2py] Removing a row from a list

2012-06-01 Thread Johann Spies
I have a screen with a simple search form in the top halve and a grid at the bottom part showing the items found in the search a session variable. The grid part is a component. I want to be able to remove individual items from the grid without leaving the page - just reloading the component part.

Re: [web2py] Re: Future of Web2py in India/Asia

2012-06-01 Thread Michele Comitini
None of the java programmers that I worked with ->*once they*<- used web2py ever looked back for web application development, ever. Once you go python you never go back to java unless forced. mic 2012/6/1 Michele Comitini : > Massimo, >> >> >> I talk to many employers and entrepreneurs. There is

Re: [web2py] Re: Future of Web2py in India/Asia

2012-06-01 Thread Michele Comitini
Massimo, > > > I talk to many employers and entrepreneurs. There is a perception that Java > programmers are the please finish the phrase it was getting interesting ;-). @RKumar This is old but even more true today so pls read it: http://www.paulgraham.com/pypar.html I do work with Java often

Re: [web2py] Set the permission on the selectable in SQLFORM.grid

2012-06-01 Thread Johann Spies
On 1 June 2012 10:18, Sanjeet Roy wrote: > HIi i am useng the following codes :- > > def test(): > table = > SQLFORM.grid(db.abc,create=(auth.has_permission('CRUD','auth_user') or > auth.has_permission('Admin','auth_user')), maxtextlength=100, selectable = > (lambda ids: del_abc(ids) and (aut

[web2py] Re: Anyone using BootSwatch with new web2py layout

2012-06-01 Thread Paolo Caruccio
I was hasty. I posted a dev file. I'm testing responsive layout of welcome app. Andrew, you have several solutions: 1. to leave everything as it is; 2. to find and delete the detected row in layout.html 3. to download bootstrap-responsive.css from web and put it in "static/css" folder Il giorn

[web2py] Set the permission on the selectable in SQLFORM.grid

2012-06-01 Thread Sanjeet Roy
HIi i am useng the following codes :- def test(): table = SQLFORM.grid(db.abc,create=(auth.has_permission('CRUD','auth_user') or auth.has_permission('Admin','auth_user')), maxtextlength=100, selectable = (lambda ids: del_abc(ids) and (auth.has_permission('Admin','auth_user' return

[web2py] Re: What do you think of this service? Pagodabox

2012-06-01 Thread stefaan
> > > They pull from your git repository to deploy an application. Do you see > a demand for something like this in Web2py? Would it be a feature you > would want to use? > > Doesn't fluxflex also do this already?

Re: [web2py] Re: Thinking of building a bug tracker...

2012-06-01 Thread Jason (spot) Brower
issue tracker I know of... I am looking at itracker now Thanks. :) On Fri, Jun 1, 2012 at 10:31 AM, stefaan wrote: > > > > I have noticed one other tracker in web2py, but I couldn't demo it. >> >> Have you seen these? > > http://code.google.com/p/web2py-issuetracker/ > http://www.i-track.org/ >

Re: [web2py] pyfilesystem support (store uploads in S3)

2012-06-01 Thread Jason (spot) Brower
Sounds fun! On Thu, May 31, 2012 at 8:56 PM, Massimo Di Pierro < massimo.dipie...@gmail.com> wrote: > Here is an example: > > easy_install pyfilesystem > > >>> import fs.s3fs > >>> myfs = fs.s3fs.S3FS(bucket, prefix, aws_access_ke, aws_secret_key) > >>> db.define_table('test',Field('file','upload

[web2py] Re: Thinking of building a bug tracker...

2012-06-01 Thread stefaan
I have noticed one other tracker in web2py, but I couldn't demo it. > > Have you seen these? http://code.google.com/p/web2py-issuetracker/ http://www.i-track.org/

[web2py] From ul to bootstrap row

2012-06-01 Thread Annet
In a view I have the following code to generate an ul: {{for s in socialmedia:}} {{pass}} I use css to display two list items next to each other. To drop this css I'd like to replace this with bootstrap rows: I think the solution lies in doing

Re: [web2py] Thinking of building a bug tracker...

2012-06-01 Thread Jason (spot) Brower
Perhaps a bug tracker like this should give access to outsiders so that they can be aware of the situations. This could be done with some role management. BR, Jason On Fri, Jun 1, 2012 at 6:25 AM, Cliff Kachinske wrote: > +1 for git. > > It seems so much simpler. > > > On Thursday, May 31, 2012