I was just in a situation where I needed to find the field name and had to do this:
field_name = schema.field_name(ref_type, "")
if not field_name:
field_name = schema.field_model_name(
ref_type
)
I think there should be some schema method that just finds the name using all the methods, either find_field_name, field_find_name, or something like that.
I was just in a situation where I needed to find the field name and had to do this:
I think there should be some schema method that just finds the name using all the methods, either
find_field_name
,field_find_name
, or something like that.