always circumvented the "issue" with showid=False, but really don't know
what happens with multiple pkeys or non integer ones.
On Wednesday, April 2, 2014 9:04:17 PM UTC+2, Omi Chiba wrote:
>
> Right, Key have to be Writable.
>
> I ended up doing this my option 1 (Hide the value with CSS and display the
> value for the field separately using Custom Form.... very frustrated.
>
>
> On Wednesday, April 2, 2014 9:40:46 AM UTC-5, Niphlod wrote:
>>
>> I seem to recall that the same thing happens setting db.table.id.writable
>> = False
>>
>> On Wednesday, April 2, 2014 4:07:38 PM UTC+2, Omi Chiba wrote:
>>>
>>> This is the error I got. The form looks fine by doing Writable = False
>>> (See attachment) but None is set when it's submit.
>>>
>>>> <type 'exceptions.SyntaxError'> user is tampering with form's
>>>> record_id: {'EMTKSC': None, 'EMTKCD': None} != {'EMTKSC': 'J11', 'EMTKCD':
>>>> 'J2620008'}
>>>>
>>>
>>> I also tried Writable = True, and Disable the dropdown with jQuery but
>>> the same result.
>>>
>>> There are two option I can think of.
>>>
>>> 1. Writable = True, then hide the value from the form (Then I need to
>>> use the custom layout... which is time consuming)
>>> 2. Writable = True, then use db.executesql for updating without built-in
>>> update function.
>>>
>>> It's pretty normal to read-only the key field. I don't know how you guys
>>> dealing with this problem.
>>>
>>>
>>>
>>
--
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.