<div class="tabnav"> <ul tabs="<%= tabsetname %>"> <% tabs.forEach(function(item){ %> <li tabid="<%= item.id %>"><a href="#"><%= item.name %></a></li> <% }); %> </ul> <% tabs.forEach(function(item){ %> <div class="tab-content" fortabs="<%= tabsetname %>" tabid="<%= item.id %>"> <div class="simple-padding"> <% if (item.hasOwnProperty("addevent")){ %> <button class="pure-button" emit="modal-open" emit-args='{"id":"<%= item.addevent %>"}'> <i class="fa fa-plus-circle"></i> </button> <% } %> <% if (item.hasOwnProperty("remevent")){ %> <button class="pure-button" emit="<%= item.remevent %>"> <i class="fa fa-trash-alt"></i> </button> <% } %> </div> <div class="list-container"> <% if(item.hasOwnProperty("tmpl")){ %> <%- include(item.tmpl) %> <% } %> </div> </div> <% }); %> </div>