Hello All,
I'm new to web2py. I'm on mac os x.
I managed to:
1. Install web2py.
2. Run it.
3. Create new application, similar to welcome.
4. Create table. (It started working when I added config related code).
I want to create a form to view - add - update - delete data from my table.
How do I d
I am having a strange problem.
I'm am running a my application in webfaction server with the following
configuration:
Apache/2.4.16 (Unix) mod_wsgi/4.4.13 Python/2.7.11, Python 2.7.11
And my restful return
method not allowed
However the same application is running without problem with the
from the console, it seems that if you have signature=True on auth it does
not create groups when you are not logged in, if I make an user it works.
On 17 April 2014 17:16, Anthony wrote:
> Where/how are you calling auth.add_group?
>
>
> On Thursday, April 17, 2014 4:08:27 PM UT
Hey!
When I try to create a new group with auth.add_group('Administrators',
'Administrators of the system') it return the id of the new group but the
group is not created on the database.
but when I create an user and web2py create their group it got the next id,
so I supposed that add_group is
Thanks :)
On Thursday, April 17, 2014 1:57:57 PM UTC-4, Anthony wrote:
>
> password=db.auth_user.password.validate('mypassword')[0]
>
> Anthony
>
>
> On Thursday, April 17, 2014 11:58:23 AM UTC-4, Eduardo Cruz wrote:
>
>> Thanks but how can I crypt the p
Thanks but how can I crypt the password?
On 17 April 2014 11:47, Anthony wrote:
> There is
>
> auth.get_or_create_user(keys=dict(first_name='Eduardo', ...), login=False)
>
> Anthony
>
>
> On Thursday, April 17, 2014 11:25:07 AM UTC-4, Eduardo Cruz w
How can I create a user progmatically? I'm trying to make a custom form for
login/register/etc
--
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
---
You receiv
You can get all the many to many relationship with
table.many_to_many_.select() but is there a way to insert the relationship
when you create the row? like
db.table.insert(dict(field1=1, field2=2, manytomanytable={x_id}) ?
--
Resources:
- http://web2py.com
- http://web2py.com/book (Documentatio
You are using 'animals' in the for loop not livestock_animals,
instead of livestock_animals use animals like {{=animals.eartag_number}}
On Sat, 2013-11-23 at 06:18 -0800, raferbop wrote:
> # Model
>
>
> db.define_table('livestock_animals',
> Field('eartag_number'),
>
'Row' object has no attribute 'unknown'
Version web2py™ Version 2.7.4-stable+timestamp.2013.10.14.15.16.29
Traceback
Traceback (most recent call last):
File "/home/eduardo/PycharmProjects/gblog/web2py/gluon/restricted.py", line
217, in restricted
exec ccode
I does not work, sadly.
On Wednesday, November 20, 2013 6:52:56 PM UTC-4, Tim Richardson wrote:
>
> Also, my experience with virtual fields is limited to returning
> non-iterable types, not lists.
>
> On Thursday, November 21, 2013 9:48:57 AM UTC+11, Tim Richardson wrote:
>>
>> I can't see what'
def posts():
grid = SQLFORM.grid(db.Post)
return dict(grid=grid)Ingresar el código aquí...
Sure.
El miércoles, 20 de noviembre de 2013 17:49:33 UTC-4, Tim Richardson
escribió:
>
> can you show how you make the grid?
>>
>>
--
Resources:
- http://web2py.com
- http://web2py.com/book (
Web2py Version 2.7.4-stable+timestamp.2013.10.14.15.16.29
On 20 November 2013 16:26, Tim Richardson wrote:
> What version of web2py?
>
>
> On Thursday, November 21, 2013 5:26:23 AM UTC+11, Eduardo Cruz wrote:
>>
>> Whe I use a table that has some a virtual field sqlfor
Whe I use a table that has some a virtual field sqlform.grid does not works
'Row' object has no attribute 'unknown'
and that happens only when the virtual field is uncommented
def get_category_list(post):
category_id_list = db(db.Post_in_category.post_id == post.id).select(db
.Post_in_cate
db(db.auth_user.id == auth.user.id).update(pagesize=100)
it will update the database.
El martes, 19 de noviembre de 2013 03:38:40 UTC-4, User escribió:
>
> I want to store user page size preference for when there is a list view of
> items that needs pagination and have that preference persist
it's working now but the code it's exactly the same, woah.
On 12 August 2013 18:44, Anthony wrote:
> Should work. I guess we need to see some more code. Also, make sure you're
> checking the right records in the right database.
>
>
> On Monday, August 12, 2013
2, 2013 1:28:48 PM UTC-4, Eduardo Cruz wrote:
>>
>> I'm trying to update a record:
>>>
>>> for station in stations:
>>> voice = "something"
>>> station.update_record(voice=**voice)
>>>
>>> but for some reason
I'm trying to update a record:
>
> for station in stations:
> voice = "something"
> station.update_record(voice=voice)
>
> but for some reason it's not in the db when I check with MySQL Workbench,
any suggestions?
--
---
You received this message because you are subscribed to
I need to upload a file that I will create on the fly, is there a way to do
that without using a form?
--
---
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 it, send an email
to web
Hi, I have this table
db.define_table('station',
dates,
Field('name', 'string', unique=True),
Field('average_time', 'integer'),
Field('area_id', 'reference area', requires=IS_IN_DB(db,
'area.id', '%(name)s') ,label="Area", represent=
How can I get in the view the ip of the web2py server?
--
---
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 it, send an email
to web2py+unsubscr...@googlegroups.com.
For more option
Is there a way to send data to a websocket from javascript
using web2py_websocket ?
--
---
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 it, send an email
to web2py+unsubscr...@goo
Hello, I want to use the templating engine as a module so I can use it
with weasyprint as a barebones reporting engine, with mako I can do:
from mako.template import Template
print Template("hello ${data}!").render(data="world")
How could I do that in the web2py templating engine?
--
---
Y
Why you want to do this?
El jueves, 18 de julio de 2013 10:49:42 UTC-4, Richard escribió:
>
> Hello,
>
> Is it safe to do :
>
> from gluon import current
> current.db = db
>
> And if so, why is db not already available in current by default?
>
> Thanks
>
> Richard
>
--
---
You received this me
I have a function like this
@request.restful()
def api():
def GET(*args,**vars):
return dict()
def POST(*args,**vars):
return dict()
def PUT(*args,**vars):
return dict()
def DELETE(*args,**vars):
return dict()
return locals()
then I try to use
#x27;,
> > _and=IS_NOT_IN_DB(subset,'person.id'))
> >
> >
> > -Jim
> >
> > On Tuesday, July 16, 2013 8:12:46 AM UTC-5, Eduardo Cruz wrote:
> >>
> >> is there a way that I can make
erson.id', '%(name)s',
> > _and=IS_NOT_IN_DB(subset,'person.id'))
> >
> >
> > -Jim
> >
> > On Tuesday, July 16, 2013 8:12:46 AM UTC-5, Eduardo Cruz wrote:
> >>
> >> is there a way that I
Chrome Logger: http://craig.is/writing/chrome-logger
Chrome Logger for web2py:
https://github.com/ccampbell/chromelogger-python/pull/5
Hi, I made a little decorator to use chrome logger with web2py.
So if you do this
import chromelogger as console
@console.ChromeLoggerWeb2Py(response=response)
Oh I forgot, this is a complete example:
<https://lh6.googleusercontent.com/-Ty-kti6vLXg/UeVTV5kFjhI/A-A/Z6KjViHeRMg/s1600/Captura.PNG>
import chromelogger as console
def index():
console.log(auth.user)
return dict()
El martes, 16 de julio de 2013 09:57:39 UTC-4, E
Nope, but I just try it and it works pretty well.
console.log("test log")
headers_console = console.get_header()
response.headers[headers_console[0]] = headers_console[1]
El martes, 16 de julio de 2013 07:15:49 UTC-4, David Marko escribió:
>
> Anyone having experience with web2py and ChromeLogg
is there a way that I can make the IS_IN_DB validator to show all the
records in an select in the form but not the ones that have the field
active set to False?
--
---
You received this message because you are subscribed to the Google Groups
"web2py-users" group.
To unsubscribe from this gro
You can use response.write and pass escape=False as parameter.
{{response.write("text", escape=False)}}
El lunes, 15 de julio de 2013 08:43:49 UTC-4, wdtnh escribió:
>
> I've used XML() to escape some very basic html tags (e.g., bold, italic) I
> have embedded in a string that comes from a dat
Thanks!
On 13 July 2013 19:33, Anthony wrote:
> requires=IS_EMPTY_OR(IS_IN_DB(db, 'area.id', '%(nombre)s'))
>
>
> On Saturday, July 13, 2013 6:08:26 PM UTC-4, Eduardo Cruz wrote:
>>
>> is there a way to have something like << requires=IS_IN_
is there a way to have something like << requires=IS_IN_DB(db, 'area.id',
'%(nombre)s') >> but that the field is not actually required? I want
SQLFORM to make a html select with that field but I want to have the option
to just not select any value.
--
---
You received this message because y
else []
>
> change it to
>
> response.generic_patterns = ['*']
>
>
> Paolo
>
> On Monday, June 17, 2013 9:50:58 PM UTC+2, Michele Comitini wrote:
>>
>> send example code to reproduce the error please! model, controller and
>> iff you have m
I have made an restful api and it works perfectly on localhost but when I
try to use it from another machine all the api endpoints give me an 404, Im
running web2py with the built-in server on 0.0.0.0
--
---
You received this message because you are subscribed to the Google Groups
"web2py-us
I have made an api using @request.restful() decorator but when I try to use
the api from another machine it gives me an 404, Im running web2py with the
built-in server at 0.0.0.0
--
---
You received this message because you are subscribed to the Google Groups
"web2py-users" group.
To unsubsc
lue it seems to be wrong.
Any ideas?
Thanks,
Eduardo Lopes.
--
Parabéns Bruno,
Ficou muito show!
Tenho um motorola xoom com android 4.02 e tá rodando perfeito!!!
Em segunda-feira, 3 de setembro de 2012 20h46min12s UTC-3, rochacbruno
escreveu:
>
> Hi, I just published a beta version of web2pyslices reader for Android:
> https://play.google.com/store/app
Thanks Massimo,
*Ticket http://code.google.com/p/web2py/issues/detail?id=794
*
In our work we migrate from version of Web2py from 1.96.4 to 1.99.7, but we
have the following problem: SQLFORM not print the ID values less and
equal than zero, the referenced table (ex. table "a"). any security reason for
this change?
# controller: debug.py
def index():
db.define_table(
any functionality with: http://cloudsilverlining.org/
>
> Cheers
>
> On Mar 22, 8:43 am, Eduardo Bergavera wrote:
>> Hi Everyone!
>>
>> I would like to ask some guidance regarding anyone who may be
>> interested in developing web-based python app for systems manag
r help and guidance.
--
Eduardo B.
tool.
Thanks.
Eduardo D. Bergavera, Jr.
Hello,
When I'm trying to use Versioning (mercurial) but I get an a ticket error:
Traceback (most recent call last):
File "/var/www/web2py/gluon/restricted.py", line 181, in restricted
exec ccode in environment
File "/var/www/web2py/applications/admin/controllers/mercurial.py", line
75, i
o be in view if the coding would be
simpler in the controller - I am looking for the simplest solution to
grasp the idea!
Eduardo
uot;? I am
trying to find the usage of "represent" on the book; could you give me
a link?
Thanks,
Eduardo
On 11 mar, 11:17, Massimo Di Pierro
wrote:
> appadmin is for the administrator so it ignores "represent" and allows
> you to distinguish None from ''. It
When I leave a field empty, it shows nothing on the SQLTABLE generated
by appadmin. If, however, the empty field was validated with
IS_EMPTY_OR(...), its value is displayed as "None"
Is it possible to make it show no value at all?
Thanks,
Eduardo
apter 3 also says that "In the SQLite case, if the database does
not exist, it is created. You can change the name of the file."
Please let me know anyone if there are concrete cases where I really
should avoid doing as above (no need to mention PEP08 nor renaming
internal components!).
('Pais', 'string'),
Field('Nascimento', 'date'),
Field('Sexo', 'string'),
Field('Email', 'string'))
Well, now every time I try to insert a new entry via appadmin, I get
an Operational Error message
Thank you, DenesL.
Eduardo
On Mar 10, 4:14 pm, DenesL wrote:
> ...requires=IS_EMPTY_OR(IS_EMAIL(...))
>
> Seehttp://web2py.com/book/default/chapter/07#Validators
>
> On Mar 10, 1:21 pm, Eduardo wrote:
>
> > Hello,
>
> > I need to validate a field as e-mai
I fix that?
Thanks,
Eduardo
Alright, neither opening in NotePad and resaving with different
encodings nor copying from one editor to another worked.
Opening on NotePad++, however, and copying/pasting to a new file on
the same editor, then saving as UTF-8 solved the problem.
Eduardo
On 10 mar, 13:23, Massimo Di Pierro
h the
framework's editor. I even 'corrected' the characters through the
framework - just to see them messed up on NotePad++ this time.
Thanks,
Eduardo
On 10 mar, 13:23, Massimo Di Pierro
wrote:
> How did you edit using utf8 or did you insert latin-1 chars?
>
> On Mar 10, 9:44
ields(form.vars))
Eduardo
On 10 mar, 11:18, Ross Peoples wrote:
> Let's not forget about SQLFORM.factory either. This lets you create a
> SQLFORM based on a virtual table that you create as an argument to
> SQLFORM.factory. For example, I used this code to provide edit capabilities
. Note that both appadmin.py and layout.html are
declared as utf-8, and those two, together with appadmin.html, were
saved as utf-8.
Also note that a dict passed to SQLTABLE within appadmin.html is being
correctly displayed, which makes me confuse.
Any suggestions?
Eduardo
Thank you, DenesL; I know that. I don't see how that would help me. I
do need to insert the data on the DB.
Eduardo
On 10 mar, 11:11, DenesL wrote:
> FYI you can turn off the automatic DB functions when using SQLFORM
> specifying dbio=False as a parameter in the form.accepts(...), se
hanks,
Eduardo
On 10 mar, 10:51, Kenneth Lundström
wrote:
> Please explain what kind of control you need. It's much easier to help.
>
> Kenneth
>
> > Hello,
>
> > I understand database inserts with SQLFORM( ) and accepts( ) are
> > automatic when input is v
FORM( ) and accepts( )
to then insert the values on a database?
Thanks,
Eduardo
Thank you very much, Anthony. Your explanation and solution was
exactly what I needed.
Eduardo
On 4 mar, 00:23, Anthony wrote:
> On Thursday, March 3, 2011 1:19:14 PM UTC-5, Eduardo wrote:
>
> > Thank you all. Editing appadmin will do. I am, however, having a hard
> >
time,
Eduardo
On 3 mar, 13:49, Massimo Di Pierro wrote:
> You cannot change the default bahavior. You need to call these
> functions yourself in your code with the delimiter argument.
> You can also edit the appadmin.py in your app.
>
> On Mar 3, 10:33 am, Eduardo wrote:
>
Hi,
What function in what file should I modify to change the default
behaviour of both import_from_csv( ) and export_to_csv( )? I need to
make delimiter="\t" the default behaviour.
I modified those functions within dal.py with no success.
Thanks,
Eduardo
rement field declared. Besides
"migrate=False" and properly declaring the tables' schema with
define_table(), what else do I need to use that database?
Thanks,
Eduardo
Thank you all. That solves the matter.
Eduardo
On Feb 24, 8:31 pm, Vasile Ermicioi wrote:
> > Please note I would like to use sqlite, not mysql.
>
> if you have many tables use mysql just to generate you models, then you can
> use generated models with your sqlite database
Please note I would like to use sqlite, not mysql.
Eduardo
On Feb 24, 7:18 pm, Eduardo wrote:
> Alright, clarifying the question: I understand I can edit db.py and
> add the sqlite file form there; my question is: will an already
> populated db be affected (reset) when I define the t
Alright, clarifying the question: I understand I can edit db.py and
add the sqlite file form there; my question is: will an already
populated db be affected (reset) when I define the table with
db.define_table()?
Eduardo
On Feb 24, 6:51 pm, Eduardo wrote:
> Hello,
>
> How can I crea
at option either.
Thanks,
Eduardo
Thanks, Vukelic; I completely forgot the editor which comes with
web2py already edits HTML in the views!
Now I have to check if I'm able to configure it to open fields in the
db, edit them and then save them back.
Eduardo
On Nov 8, 10:12 pm, Branko Vukelic wrote:
> This is the editor
h the browser.
Well, if it's not asking too much, being able to edit the entry on my
favorite text editor would be an excellent alternative!
What strategy do you people recommend in case there are no such
options?
Thanks,
Eduardo
Thanks, Massimo. I got it now. I guess I'll just avoid ('/$anything',
'/myapplic/default/$anything') before deployment, as it makes my app
the default view for the base address.
Eduardo
On Nov 8, 8:17 pm, mdipierro wrote:
> instead of
>
> http:///a
for (y, x) in routes_in]
# ===== #
made the rewrites work fine, except that now admin and appadmin return
"invalid function". What should I do?
Eduardo
x27;, '/'))
# == #
I'm afraid of getting too many tuples to add to routes.py in the
future. Is there a single-command way of always turning ""myapplic/
default/whatever" into "/whatever"?
Eduardo
I found the problem: restarting the appserver fixes it.
Thanks,
Eduardo
On Nov 8, 2:50 pm, mdipierro wrote:
> '/' is the correct thing. It should work on appserver too. Anybody
> else having this problem?
>
> On Nov 8, 10:29 am, Eduardo wrote:
>
> > Is a URL
=#
Or should I at least use '/' instead of ''?
Neither '' nor '/' is working from http://127.0.0.1:8000. Does it work
only after deployment (viewed by visitors, not through the admin
server)?
Thanks,
Eduardo
analytical and synthetic
thinking.
Eduardo
uest.args(1)))
body = db.executesql('SELECT body FROM articles WHERE id=%s AND
main_tag=%s' % (request.args(0), request.args(1)))
return dict(title=title, body=body)
Thanks,
Eduardo
Hi,
I've been trying for the past weeks to access web2py@googlegroups.com but
failed to connect when I clicked Groups at Google.com. The error displayed is
Network Timeout. I googled but didn't find any solution. Tried searching email
address of Google groups to address this concern but never fo
Hi,
I have problem accessing web2py google groups. When i click web2py link it
issues message "timeout".
Cheers,
Ed
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"web2py-users" group.
To post to this gr
78 matches
Mail list logo