SQLFORM, add field with button

17 views
Skip to first unread message

KevC

unread,
Apr 17, 2015, 10:50:37 PM4/17/15
to web...@googlegroups.com
Hi community.
I want to know if you could help me. I started to use web2py, but I don't know some things. I want to create fields with a button on SQLFORM and HTML.
For example, I have author table and book table, but a book can get several authors and I need to create differents "INPUT" on the FORM for save them with book and his fields.
I have a relation many to many between book and author. Also I combine both FORM´s (author and book).

I wanna this FORM

Title:       |______________
Author:    |______________ + -       (Where '+' I wanna use it to add more authors in the same FORM and '-' to remove fields if I mistake.
Languaje:|______________
ISBN:     |______________
Etc.




Greetings.

黄祥

unread,
Apr 18, 2015, 3:48:12 AM4/18/15
to web...@googlegroups.com
i think you can use list:reference field type for author field in table book.

ref:

best regards,
stifan
Reply all
Reply to author
Forward
0 new messages