/** Treeview. A wrapper for FuelUX treeview element. It's just a wrapper so you still need to include FuelUX treeview script first. */ (function($ , undefined) { var $options = { 'open-icon' : ace.vars['icon'] + 'fa fa-folder-open', 'close-icon' : ace.vars['icon'] + 'fa fa-folder', 'selectable' : true, 'selected-icon' : ace.vars['icon'] + 'fa fa-check', 'unselected-icon' : ace.vars['icon'] + 'fa fa-times' } $.fn.ace_tree = function(options) { $options = $.extend({}, $options, options) this.each(function() { var $this = $(this); $this.html('\ '); $this.addClass($options['selectable'] == true ? 'tree-selectable' : 'tree-unselectable'); $this.tree($options); }); return this; } })(window.jQuery);