In project_report.py the Task Summary field is defined as:
_columns = {
'name': fields.char('Task Summary', size=128, readonly=True),
...
}
Already, I have entered data into this field. Recently I convert it to a dropdown list, like this:
_columns = {
'name': fields.selection([('do_this_task_first','Do This Task First'),
('do_this_task_next','Do This Task Next'),
('do_this_task_last', 'Do This Task Last')],
'Task Summary', help="What the task is."),
}
But the previous data now shows as undefined. Is there an elegant way to keep the old data and assign it to one of the dropdown list options, or will all the previous tasks have to be re-entered?
I wonder if there's a way to specify that anything could be typed in, or pick one from the list.
Do you have to accept from the fields.selection then in your module.py class move that data into the fields.char in the DB?
How would you coordinate reading the fields.char into the fields.selection when you get a different record?