Skip to content
Snippets Groups Projects
Commit f389405b authored by Robert Latta's avatar Robert Latta
Browse files

corrected filtering of customers RE DBOARD3-526

parent 0ebdb508
Branches
No related tags found
No related merge requests found
......@@ -526,7 +526,15 @@ def _get_dashboard_data(ifc, possible_names):
name = _get_customer_name(description)
names = [name]
if BRIAN_DASHBOARDS.L2_CIRCUIT.name in dashboards:
names = names + possible_names
# DBOARD3-524
# Uncomment this line and comment the next if they want all
# customers from IMS
# names = names + possible_names
# Uncomment this line and comment previous if they only want
# customers from IMS that appear in the interface description
names = names + [n for n in possible_names
if n in description.upper().split(' ')]
return {
**ifc,
......@@ -534,19 +542,10 @@ def _get_dashboard_data(ifc, possible_names):
'name': name,
'interface_type': interface_type.name
},
# DBOARD3-524
# Uncomment this section if they want all customers from IMS
'dashboards_info': [{
'name': name,
'interface_type': interface_type.name
} for name in set(names)]
# Uncomment this section if they only want customers from IMS that
# appear in the interface description
# 'dashboards_info': [{
# 'name': name,
# 'interface_type': interface_type.name
# } for name in set(names) if name in description.upper().split(' ')]
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment