Importing "Booleans" from ClearQuest to Jazz
![](http://jazz.net/_images/myphoto/c2799916a3eac4aab69061fc0918d57f.jpg)
Hi,
I have some checkboxes in ClearQuest whose underlying values are 0 and 1. I'd like to get them displayed as checkboxes on my imported work items as well.
My Boolean Editor Presentation correctly displays a checkbox, but the values are being placed in the discussion presentation instead of the showing up as a checkmark (or lack thereof) on the checkbox. The text in the discussion field is "FieldX was: 0" or "FieldX was : 1".
My custom attribute looks like:
<customAttributes category="com.ibm.team.workitem.workItemType">
...
<customAttribute id="fieldx" name="Field X" type="boolean"/>
...
</customAttributes>
My presentation attribute looks like:
<presentation attributeId="fieldx" kind="com.ibm.team.workitem.kind.boolean" label="Field X"/>
And my mapping file looks like:
<attribute sourceId="fieldx_chkbox targetId="fieldx" />
Can anyone tell me if I'm on the wrong track for displaying data in checkboxes or if I've just done something wrong here?
Thanks,
David
I have some checkboxes in ClearQuest whose underlying values are 0 and 1. I'd like to get them displayed as checkboxes on my imported work items as well.
My Boolean Editor Presentation correctly displays a checkbox, but the values are being placed in the discussion presentation instead of the showing up as a checkmark (or lack thereof) on the checkbox. The text in the discussion field is "FieldX was: 0" or "FieldX was : 1".
My custom attribute looks like:
<customAttributes category="com.ibm.team.workitem.workItemType">
...
<customAttribute id="fieldx" name="Field X" type="boolean"/>
...
</customAttributes>
My presentation attribute looks like:
<presentation attributeId="fieldx" kind="com.ibm.team.workitem.kind.boolean" label="Field X"/>
And my mapping file looks like:
<attribute sourceId="fieldx_chkbox targetId="fieldx" />
Can anyone tell me if I'm on the wrong track for displaying data in checkboxes or if I've just done something wrong here?
Thanks,
David
3 answers
![](http://jazz.net/_images/myphoto/c2799916a3eac4aab69061fc0918d57f.jpg)
I think your presentation configuration is fine. The problem is with the boolean mapping. The importer expects values of true or false, not 1 or 0, for boolean values. Add value mappings to the boolean value property mapping to convert the 1's and 0's to true and false. For example, your mapping should look like the following:
<attribute sourceId="fieldx_chkbox targetId="fieldx">
<value sourceId="1" targetId="true"/>
<value sourceId="0" targetId="false"/>
</attribute>
<attribute sourceId="fieldx_chkbox targetId="fieldx">
<value sourceId="1" targetId="true"/>
<value sourceId="0" targetId="false"/>
</attribute>