Thanks for the answer 
I haven't tried the latest version and I hope this behavior doesn't change 
from version to version..
but. I thought / hoped a web2py developer could explain why this 
important/central feature was changed and how to deal with it best.
Jim S schrieb am Samstag, 2. Oktober 2021 um 16:26:42 UTC+2:

> Have you tried with the latest web2py?
>
> I'm assuming the behavior is the same as with 2.18.5. 
>
> Have you been able to pinpoint a commit that would have changed this 
> behavior?
>
> -Jim
>
> On Thursday, September 30, 2021 at 4:04:28 AM UTC-5 Awe wrote:
>
>> Is anybody out there facing the same problem, wondering about getting no 
>> answers...
>>
>> Awe schrieb am Mittwoch, 4. August 2021 um 18:16:40 UTC+2:
>>
>>> we are using sqlform.factory a lot, but the way fields are shown/behave 
>>> was changed from
>>> 2.15.4
>>> fields = [f.name for f in table if  (ignore_rw or f.writable or f.readable) 
>>> and (readonly or not f.compute)]
>>> to
>>> 2.18.5
>>> fields = [f.name for f in table if (ignore_rw or f.writable or 
>>> (f.readable and f.default)) and not f.compute]
>>>
>>> so in 2.15.4 it was no problem to have an edit form with fields like
>>> readable=True, writable=False, default=""
>>> this field having an empty string was shown disabled, great as expected.
>>>
>>> in 2.18.5
>>> this field will not be shown anymore, we need to set default=" " like 
>>> this, which is
>>> not very useful.
>>>
>>> Is this a bug or feature, or is there a NEW common way to have empty 
>>> readonly fields in an
>>> edit form
>>>
>>> Many thanks for any help!
>>>
>>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/web2py/8f24f5bb-8608-4d72-8cca-a38dca5e6cc7n%40googlegroups.com.

Reply via email to