1 <div class="modal modal-with-loading-spinner">
2 <div class="modal-dialog">
3 <div class="modal-content">
5 <div class="modal-header">
6 <button type="button" class="close" onClick="reset_form()" data-dismiss="modal" aria-hidden="true">×</button>
8 <div class="col-sm-6"> <h4 class="modal-title"><%= params[:title] || 'Choose project' %></h4> </div>
9 <div class="spinner spinner-32px spinner-h-center col-sm-1" hidden="true"></div>
14 <div class="modal-body">
15 <div class="selectable-container" style="height: 15em; overflow-y: scroll">
16 <% [my_project_tree, shared_project_tree].each do |tree| %>
17 <% tree.each do |projectnode| %>
18 <% if projectnode[:object].is_a? String %>
19 <div class="row" style="padding-left: <%= 1 + projectnode[:depth] %>em; margin-right: 0px">
20 <i class="fa fa-fw fa-folder-open-o"></i>
21 <%= projectnode[:object] %>
24 row_selectable = !params[:editable] || projectnode[:object].editable?
25 folder_class = "fa-folder-o"
26 if projectnode[:object].uuid == current_user.uuid
27 row_name = "My Projects"
28 row_selectable &&= params[:my_root_selectable]
29 folder_class = "fa-folder-open-o" if not row_selectable
31 row_name = projectnode[:object].friendly_link_name || 'New project'
33 <div class="<%= 'selectable project' if row_selectable %> row"
34 style="padding-left: <%= 1 + projectnode[:depth] %>em; margin-right: 0px" data-object-uuid="<%= projectnode[:object].uuid %>">
35 <i class="fa fa-fw <%= folder_class %>"></i> <%= row_name %>
43 <div class="modal-footer">
44 <button class="btn btn-default" data-dismiss="modal" aria-hidden="true">Cancel</button>
45 <button class="btn btn-primary" aria-hidden="true" data-enable-if-selection disabled><%= params[:action_name] || 'Select' %></button>
46 <div class="modal-error hide" style="text-align: left; margin-top: 1em;">