Swapping existing Umbraco Dropdown List with Data List? #173
-
I tried to replace an existing umb core dropdown with contentment datalist/dropdown assuming that the value stored in the database would just be the set value, but then got errors in the dtge about type conversions.. Is there an easy way to update from the umb core dropdown to datalist/dropdown without having to revisit all the content? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 7 replies
-
Hi @mistyn8 👋 From what I recall the Umbraco dropdown uses the Prevalue option's ID as the value - but I'm unsure how you'd go able finding out what that value is - it's usually an This has got me thinking whether we could have an "Umbraco DataType Prevalues" data-source for Data List? e.g. keep the old (Umbraco core) dropdown DataType, and use that as the source to populate the new Data List? Reasons for doing that could be to swap out the list-editor, or as a stepping stone for further manipulation (as in, in code, etc). (Just an idea 💡) |
Beta Was this translation helpful? Give feedback.
Hi @mistyn8 👋
From what I recall the Umbraco dropdown uses the Prevalue option's ID as the value - but I'm unsure how you'd go able finding out what that value is - it's usually an
int
(well maybe as astring
). I think they might be stored in theumbracoDataType
database table.This has got me thinking whether we could have an "Umbraco DataType Prevalues" data-source for Data List? e.g. keep the old (Umbraco core) dropdown DataType, and use that as the source to populate the new Data List? Reasons for doing that could be to swap out the list-editor, or as a stepping stone for further manipulation (as in, in code, etc). (Just an idea 💡)