Hi,
I have a Dynamic DropDown menu created in Studio, I need to convert it to MultiSelect without loose data. How can I do, editing some files by hand? Which?
Thanks!
Hi,
I have a Dynamic DropDown menu created in Studio, I need to convert it to MultiSelect without loose data. How can I do, editing some files by hand? Which?
Thanks!
Hi
I donât know the full process for you, but to get you started, look for PHP files under custom which contain strings from your dropdown items.
I would start by searching in custom/include/language/en_us.lang.php
This post will gives you a sample:
Thanks,
BrozTechnologies
Hi,
for fields created with studio the field definitions are not saved in vardefs, but in the database table fields_meta_data.
To convert your field, assuming your field has the name âfieldname_câ and was created for the module âContactsâ you would:
update fields_meta_data set type='multienum', ext2=NULL where name='fieldname_c' and custom_module='Contacts';
update contacts_cstm set fieldname_c = concat('^', concat(fieldname_c, '^'));
Please note that this multiselect is no longer dynamic: its values do no longer depend on a parent dropdown field.
Thanks jansiero!
Is it really necessary to âRemove the field from all layouts using Studioâ? I remember that in my case it is a âDynamic DropDownâ which will be converted to MultiSelect (it doesnât matter if I lose âdepend on a parent dropdown fieldâ).
Hi @harry84, yes, because the field type is also saved in the view definitions, so to make sure that it is displayed as a multiselect, you will have to remove it and add it again.
You could also edit the custom/modules/<module>/metadata/*viewdefs.php files to change the field type, but removing and adding them through studio is less error prone.
I just had time to make the changes, I just wanted to say that after getting to point 4) In SuiteCRM, I give to Admin -> Repair -> Quick Repair and Rebuild, I realized that in listviewdefs.php there was the field that I was converting set as dynamicenum, and then either edited that word in multienum and did a Quick Repair and Rebuild again, performed step 5, Quick Repair and Rebuild and everything seems OK.
I wanted to know if I was right to edit listviewdefs.php by hand.