<% _.each(data, function(obj){ %>
<% _.each(obj.children, function(d){ %>
<% if (!_.includes(["utilities_cost", "line_cost"], d.id)) { %>
<% } %>
<% }) %>
<% }) %>
TIER 2
<% let order_list = ["utilities_cost", "usle", "line_cost", "yields"] %>
<% data = _.find(data, e => {return e.id == 'manuf'})['children'] %>
<% let sorted_data = _.sortBy(data, (v) => order_list.indexOf(v.id)) %>
<% _.each(sorted_data, function(parent){ %>
<% if(_.size(parent.children) > 0){ %>
<%= parent.name %>
<% _.each(parent.children, function(d){ %>
<% console.log("Tier2", d) %>
<% }) %>
<%- _.includes(['utilities_cost', 'usle', 'line_cost', 'yields'], parent.id)?'Please Note: This is absolute cost / percentage':'' %>
<% } %>
<% }) %>
TIER 3
<% _.each(data, function(parent){ %>
<% _.each(parent.children, function(teir2){ %>
<% if(_.size(teir2.children) > 0){ %>
<%= parent.name %>
<% _.each(teir2.children, function(d){ %>
<% }) %>
<%- _.includes(['yields'], parent.id)?'Please Note: This is absolute cost / percentage':'' %>
<% } %>
<% }) %>
<% }) %>