%def name="show_row(row, margin, filter=None)">
% if not ((row['type'] == 'template' and str(config['show_xs_templates']) == str(False)) or \
(row['type'] == 'custom_template' and str(config['show_custom_templates']) == str(False)) or \
(row['type'] == 'storage' and str(config['show_local_storage']) == str(False) and row['state'] != 'shared') or \
(row['type'] == 'vm' and str(config['show_hidden_vms']) == str(False) and str(row['HideFromXenCenter']).lower() != "false")):
% if not filter or row['children'] or row['name'].lower().count(filter):
% if row['type'] == "server" and row["state"] == "Disconnected":
% if config_hosts[row['host']][1]:
% else:
% endif
% else:
% endif

${row['name']}
% endif
% endif
%def>
-
${show_row(treestore["home"], "5")}
% if treestore["home"]["children"]:
% for row in treestore["home"]['children']:
-
${show_row(treestore[row], "20")}
% if treestore[row]["children"]:
% for row in treestore[row]['children']:
-
${show_row(treestore[row], "35", filter)}
% if treestore[row]["children"]:
% for row in treestore[row]['children']:
${show_row(treestore[row], "60", filter)}
% endfor
% endif
% endfor
% endif
% endfor
% endif