@core_helper
def list_dict_filter(list_, search_field, output_field, value):
 for item in list_:
  if (item.get(search_field) == value):
   return item.get(output_field, value)
 return value

@ core_helper def list_dict_filter ( list_ , search_field , output_field , value ) : for item in list_ : if ( item . get ( search_field ) == value ) : return item . get ( output_field , value ) return value
takes a list of dicts and returns the value of a given key if the item has a matching value for a supplied key .