My first post in the group:
I think if web2py have something like this or can be implemented:
db.define_table('puppy',
SQLField('name',label='A puppy'),
SQLField('image','upload', label='Photo'))
Would be grat, this is for Not having to write:
db.puppy.name.label = "A puppy"
db.puppy.im
name"),
4 SQLField(’image’,’upload’,label="Photo"))
5 db.puppy.name.requires=IS_NOT_EMPTY()
Mauricio
On 13 ene, 18:16, mfolmos wrote:
> My first post in the group:
>
> I think if web2py have something like this or can be implemented:
> db.define_table('puppy'
I need to add fields to t2 tables, like t2_person and t2_group, and
have seen prior posts to do this and I have done that, but it would be
desirable a function that do an alter table to add fields to already
created tables that comes hard coded in plugins like t2 and t3
Ej.
You have db.t2_person t
the table is altered and field
> two is dropped
> d) go back to c).
>
> You do not want this to happen to the database. The only way to avoid
> would be a complicated mechanism to tell web2py to delay migrations.
>
> Massimo
>
> On Jan 14, 1:11 pm, mfolmos wrote:
>
>
In my db.py I have a table definition with this field:
SQLField("foto","upload",label="Foto")
I can insert and edit the table with the generated t2 forms, but when
I try to delete a record that have an empty upload field, it fails
#edit function
def editar_hacker():
form=t2.update(db.hackers,n
5 matches
Mail list logo