mirror of
https://github.com/TracksApp/tracks.git
synced 2025-12-24 19:20:13 +01:00
39 lines
1.5 KiB
Text
39 lines
1.5 KiB
Text
<% project = project_listing
|
|
suppress_drag_handle ||= false
|
|
suppress_edit_button ||= false
|
|
-%>
|
|
<div id="<%= dom_id(project, "container") %>" class="list">
|
|
<div id="<%= dom_id(project) %>" class="project sortable_row" style="display:''">
|
|
<% unless suppress_drag_handle -%>
|
|
<div class="position">
|
|
<span class="handle">DRAG</span>
|
|
</div>
|
|
<% end -%>
|
|
<div class="data">
|
|
<%= link_to_project( project ) %><%= " (" + count_undone_todos_and_notes_phrase(project,"actions") + ")" %>
|
|
</div>
|
|
<div class="buttons">
|
|
<span class="grey"><%= project.current_state.to_s.upcase %></span>
|
|
<a class="delete_project_button"
|
|
href="<%= formatted_project_path(project, :js) %>"
|
|
title="delete the project '<%= project.name %>'"><%= image_tag( "blank.png",
|
|
:title => "Delete project",
|
|
:class=>"delete_item") %></a>
|
|
|
|
<% unless suppress_edit_button -%>
|
|
<%= link_to_remote(
|
|
image_tag( "blank.png", :title => "Edit project", :class=>"edit_item"),
|
|
:url => {:controller => 'projects', :action => 'edit', :id => project.id},
|
|
:method => 'get',
|
|
:with => "'_source_view=#{@source_view}'",
|
|
:before => "$('#{dom_id(project)}').block({message:null});",
|
|
:complete => "$('#{dom_id(project)}').unblock();enable_rich_interaction();"
|
|
) %>
|
|
|
|
<% end -%>
|
|
</div>
|
|
</div>
|
|
|
|
<div id="<%= dom_id(project, 'edit') %>" class="edit-form" style="display:none;">
|
|
</div>
|
|
</div>
|