Dear all,

There is an error when use SQLFORM.grid in LOAD function.
This are steps to reproduce the problem?

*Step 0*
# in models/db.py
db.define_table('product',
                Field('code', length = '50', notnull = True, unique = True),
                Field('name',  notnull = True),
)

*Step 1*
#in controller/default.py
def test_sqlform():
    return dict()

def sqlform_grid():
    sqlform_grid=SQLFORM.grid(db.product)
    return dict(sqlform_grid=sqlform_grid)

# in view => /views/default/ test_sqlform.html
{{extend 'layout.html'}}
{{=LOAD('default', 'sqlform_grid', ajax=True)}}

*Step 2*
2.0 open => 127.0.0.1/welcome/test_sqlform
2.1 try to search some product let say = 'glass' 
2.2 go to 2nd page and search again = 'dish'
2.3 in the search box you will see ['glass', 'dish']

2.4 clear and search again does not help
2.5 just press button search you will see ['glass', ['glass', 'dish'[] 
(something like this)

I using web2py version is 2.9.5 - 2.8.9

Any recommend, what I do wrong? 
Thank you in advance.

Ariya

<https://lh4.googleusercontent.com/-fyCI57DuZbo/VA_PBpE-gPI/AAAAAAAAALM/HhCVFSY4cj8/s1600/Screen%2BShot%2B2557-09-10%2Bat%2B11.09.07%2BAM.png>

-- 
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.

Reply via email to