Has anyone had success with creating a custom (Dexterity) contenttype, and then after data has been entered for a field, changing its type from Choice to List?
For example, here is the original custom field, created as a single select Choice field, using a vocabulary that populates the dropdown choices:
personRole = schema.Choice(
title=(u"Role"),
description=(u"Role of person in the Technical Standards Program"),
vocabulary=('TSP.Type.PersonRole'),
required = True
)
Now, it needs to change to a multi-select checkbox field. Here is what I changed it to:
form.widget(personRole=CheckBoxFieldWidget)
personRole = schema.List(
title=(u"Role"),
description=(u"Role of person in the Technical Standards Program"),
value_type=schema.Choice(vocabulary='TSP.Type.PersonRole'),
required = True
)
The Problem: now the edit form will not populate the existing data into the checkboxes.