On Tuesday, April 5, 2016 at 3:26:12 PM UTC-7, Leonel Câmara wrote:
>
> So I'm trying to use SQLFORM with a custom widget I made to pick icons for 
> categories. I'm getting this weird error I can't understand, where the form 
> always says it has errors:
>
> print request.post_vars # before form.process().accepted
>
> <Storage {'category_name_en': 'test', 'category_name_pt': 'teste', 
> '_formkey': '8c8e2501-d5d5-458e-aed6-0f775076061a', 'icon': 'fa-adjust', 
> '_formname': 'category/create', 'name': '{"en":"test","pt":"teste"}'}>
>
> Then if form.errors (which always happens right now) I print form.vars
>
> <Storage {'published': None, 'category_name_en': 'test', 
> 'category_name_pt': 'teste', 'name': {u'en': u'test', u'pt': u'teste'}}>
>
> and form.errors:
>
> <Storage {'icon': 'no data'}>
>
>
> What's weird about this, to me, is that 'icon' is clearly there in 
> request.post_vars but it's somehow being eliminated during process. Anyone 
> have any ideas?
>

Maybe when _formkey and _formname are removed?

/dps
 

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