need a hint on web2py built-in autocomplete widget.

in controller: db.otc_products.counterparty.widget = 
SQLFORM.widgets.autocomplete(request, db.counterparty.Long_Name, 
limitby=(0,10), min_length=2)

in model:

db.define_table('otc_products', Field('counterparty','reference 
counterparty', widget = SQLFORM.widgets.autocomplete(request, 
db.counterparty.Long_Name, id_field=db.counterparty.id, limitby=(0,20), 
min_length=2 )), ...

db.define_table('counterparty', Field('Long_Name'), ...

The resulted sqlform.grid returns a grid which features the counterparty 
field to be a regular table field instead of a widget, let alone 
autocompelete widget.

What is the configuration that needs to modify here to get a autocomplete 
widget shown and work.

thanks in advance <http://i.stack.imgur.com/Gr1Rt.png>! check link above 
for a snapshot of the grid.

-- 
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 [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to