db.define_table("patient",
Field('first_name'),
Field('last_name'),
Field('date_of_birth', 'date'),
)
db.patient.first_name.widget=SQLFORM.widgets.autocomplete(request, db.patient.first_name, limitby=(0,10), min_length=1)
db.patient.last_name.widget=SQLFORM.widgets.autocomplete(request, db.patient.last_name, limitby=(0,10), min_length=1)
db.patient.date_of_birth.widget=SQLFORM.widgets.autocomplete(request, db.patient.date_of_birth, limitby=(0,10), min_length=1)
I want it to be that, after I type inside the first_name form field, when I type inside the last_name form field, the autocomplete results for last_name should be limited to rows where db.patient.first_name == <whatever was typed in first_name field>. Is there any way to customize the Autocomplete widget to do this? Thanks!