Create function

Function creates a list of filtered elements for input model.
We need an element with "is_current==True" (if it exists), otherwise we take the first one.
If list is empty, return None. Finally, function creates a list of dictionaries for further display in template.