Thank you Massimo, It seems that will only work with string. But for an example of file upload validator, this wouldn't work. Or if I have a DAL validator like is URL(). In other words... Let's say I want someone to create a profile of his work by adding multiple url links to their portfolio using a same table. Or add couple of primary emails as a validator IS_EMAIL(). It wouldn't.
db.define_table('news', Field('title', notnull=True), Field('link','list:string', requires=IS_URL()), #This is wrong Field('body', 'text'), Field('files','list:string','upload'), #This is wrong Field('posted_on', 'datetime', readable=False, writable=False), Field('posted_by', 'reference auth_user', readable=False,writable=False), format='%(title)s') On Sunday, January 17, 2016 at 5:08:55 PM UTC-8, Massimo Di Pierro wrote: > > Field('something','list:string') ? > > On Sunday, 17 January 2016 12:28:06 UTC-6, Ron Chatterjee wrote: >> >> Hello, >> >> I saw a similar post on this once but don't quite recall. Basically >> looking for a similar feature like django admin. Let's say I have a table >> below, I want to be able to add/appends fields to "link" or "files" using a >> plus sign next to my field (see attached picture). Or minus to subtract. >> Anyone knows of a widget or plugin that does that? Don't want to reinvent a >> wheel if its already available. I would imagine its a very useful features >> that others can use. >> >> db.define_table('news', >> Field('title', notnull=True), >> Field('link', requires=IS_URL()), >> Field('body', 'text'), >> Field('files','upload'), >> Field('votes', 'integer',default=0, readable=False, >> writable=False), >> Field('posted_on', 'datetime', readable=False, >> writable=False), >> Field('posted_by', 'reference auth_user', >> readable=False,writable=False), >> format='%(title)s') >> > -- 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 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 options, visit https://groups.google.com/d/optout.