Mike Mabey wrote:
> On Fri, Aug 22, 2008 at 1:10 PM, Paul McNett <[EMAIL PROTECTED]> wrote:
>>
>> In the radio list's afterInit(), tell me the return values of:
>>
>> print [(v, type(v)) for v in self.Choices]
>> print self.Value, type(self.Value)
>>
>> Paul
>>
>
>>From start to finish, this is what is printed to the console:
>
> Dabo Error Log: Fri Aug 22 13:14:40 2008: No radio button matching '1' was
> found.
> [('1', <type 'str'>), ('2', <type 'str'>), ('3', <type 'str'>), ('4', <type
> 'str'>)]
> 1 <type 'str'>
> Dabo Error Log: Fri Aug 22 13:14:41 2008: No radio button matching '0' was
> found.
> Dabo Error Log: Fri Aug 22 13:14:41 2008: No radio button matching '0' was
> found.
Edit dabo/dabo/ui/uiwx/dRadioList.py, and insert lines 493 and 494 as
follows:
491 if val is not None:
492 # No such string.
493 print val, type(val)
494 print [(v, type(v)) for v in self.Choices]
495 dabo.errorLog.write(_("No radio button matching '%s'
was found.") % val)
The '0' is likely coming from your default value for the field in the
bizobj. If '0' is a valid value in the database, the add it as a choice
in the Choices. If it is not a valid value, then keep your bizobj from
assigning the value of 0 by setting the field's DefaultValue.
Test to see by asking the bizobj:
print biz.getFieldVal(fieldname)
Paul
_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/[EMAIL PROTECTED]