bsw@276: local units = Unit:get_flattened_tree{ active = true } bsw@276: bsw@462: ui.container{ attr = { class = "box" }, content = function() bsw@462: bsw@462: ui.list{ bsw@462: attr = { class = "unit_list" }, bsw@462: records = units, bsw@462: columns = { bsw@462: { bsw@462: content = function(unit) bsw@462: for i = 1, unit.depth - 1 do bsw@462: slot.put("     ") bsw@462: end bsw@462: ui.link{ text = unit.name, module = "unit", view = "show", id = unit.id } bsw@462: end bsw@462: } bsw@276: } bsw@276: } bsw@462: bsw@462: end }