2016-12-26 21:49:01 -05:00
|
|
|
%li{ class: "todo todo-#{todo.done? ? 'done' : 'pending'}", id: dom_id(todo), data: { url: todo_target_path(todo) } }
|
2017-02-20 08:13:37 -05:00
|
|
|
.todo-avatar
|
|
|
|
= author_avatar(todo, size: 40)
|
2016-07-20 08:01:29 -04:00
|
|
|
|
2016-02-27 05:39:33 -05:00
|
|
|
.todo-item.todo-block
|
2016-03-18 14:02:08 -04:00
|
|
|
.todo-title.title
|
2016-12-14 09:37:31 -05:00
|
|
|
- unless todo.build_failed? || todo.unmergeable?
|
2016-05-23 20:34:55 -04:00
|
|
|
= todo_target_state_pill(todo)
|
2016-04-28 16:43:18 -04:00
|
|
|
|
2017-02-20 08:13:37 -05:00
|
|
|
.title-item.author-name
|
2016-03-08 13:22:50 -05:00
|
|
|
- if todo.author
|
2017-04-10 11:51:15 -04:00
|
|
|
= link_to_author(todo, self_added: todo.self_added?)
|
2016-03-08 13:22:50 -05:00
|
|
|
- else
|
|
|
|
(removed)
|
2017-01-26 07:16:26 -05:00
|
|
|
|
2017-02-20 08:13:37 -05:00
|
|
|
.title-item.action-name
|
2016-02-20 15:01:50 -05:00
|
|
|
= todo_action_name(todo)
|
2017-01-26 07:16:26 -05:00
|
|
|
|
2017-02-20 08:13:37 -05:00
|
|
|
.title-item.todo-label
|
2016-03-23 21:52:16 -04:00
|
|
|
- if todo.target
|
|
|
|
= todo_target_link(todo)
|
|
|
|
- else
|
|
|
|
(removed)
|
2016-02-20 08:59:59 -05:00
|
|
|
|
2017-04-10 11:51:15 -04:00
|
|
|
- if todo.self_assigned?
|
|
|
|
.title-item.action-name
|
|
|
|
to yourself
|
|
|
|
|
2017-02-20 08:13:37 -05:00
|
|
|
.title-item
|
|
|
|
·
|
|
|
|
|
|
|
|
.title-item
|
|
|
|
#{time_ago_with_tooltip(todo.created_at)}
|
|
|
|
= todo_due_date(todo)
|
2016-09-14 14:16:13 -04:00
|
|
|
|
2016-02-20 08:59:59 -05:00
|
|
|
.todo-body
|
|
|
|
.todo-note
|
|
|
|
.md
|
2017-11-06 11:52:56 -05:00
|
|
|
= first_line_in_markdown(todo, :body, 150, project: todo.project)
|
2016-07-20 08:01:29 -04:00
|
|
|
|
|
|
|
- if todo.pending?
|
|
|
|
.todo-actions
|
2017-01-29 04:44:30 -05:00
|
|
|
= link_to dashboard_todo_path(todo), method: :delete, class: 'btn btn-loading js-done-todo', data: { href: dashboard_todo_path(todo) } do
|
2016-07-20 08:01:29 -04:00
|
|
|
Done
|
|
|
|
= icon('spinner spin')
|
2017-01-29 04:44:30 -05:00
|
|
|
= link_to restore_dashboard_todo_path(todo), method: :patch, class: 'btn btn-loading js-undo-todo hidden', data: { href: restore_dashboard_todo_path(todo) } do
|
2017-01-16 08:11:08 -05:00
|
|
|
Undo
|
|
|
|
= icon('spinner spin')
|
2017-03-10 07:31:30 -05:00
|
|
|
- else
|
|
|
|
.todo-actions
|
2017-01-29 04:44:30 -05:00
|
|
|
= link_to restore_dashboard_todo_path(todo), method: :patch, class: 'btn btn-loading js-add-todo', data: { href: restore_dashboard_todo_path(todo) } do
|
2017-03-10 07:31:30 -05:00
|
|
|
Add todo
|
|
|
|
= icon('spinner spin')
|