Df property not working

i want to change field property from SELECT to DATA type but using this
frm.set_df_property(‘description’, ‘fieldtype’, ‘Text’);
not working for me?
any idea?
how to change df property from select to data?

  1. Do you want to change from Select to Data or to Type?
  2. I try to change from browser console
cur_frm.set_df_property('description', 'fieldtype', 'Data');

the field doesn’t seem to change (by it’s look). But when exploring the field on the browser console using cur_frm.fields I can see the fieldtype has changed.
3. Why do you want to change the fieldtype?

i have two scenarios in which when transporter detail available then they have to select but if doesnt available then they should enter manually .
that’s why i want to change df property.

Is there is a bug in version-13 (frappe v 13.19) that affect this set_df_property behaviour?

I tried setting a field to be readonly on onload and refresh. Both changes are not displayed on the browser.
But via browser console looking at the df property of the field, yes it changes.
Other change of set_df_property also not displayed on browser, but changed in the df property itself.

@nabinhait sorry to tag you as I don’t know the owner of this part of code.

EDIT: the set_df_property for hidden works.
EDIT2: if I run the command in browser console, I can change anything in the df.