|
@ -2,30 +2,42 @@ |
|
|
%span{ class:"icon-home"} |
|
|
%span{ class:"icon-home"} |
|
|
%h2 Your Timesheet |
|
|
%h2 Your Timesheet |
|
|
|
|
|
|
|
|
%p Total Hours Worked: #{@hours_worked} |
|
|
%dl.dl-horizontal |
|
|
%p Total Credits Available: #{@credits_available} |
|
|
%dd |
|
|
|
|
|
%span.badge #{@hours_worked} |
|
|
|
|
|
Total Hours Worked |
|
|
|
|
|
%dd |
|
|
|
|
|
%span.badge #{@credits_available} |
|
|
|
|
|
Total Credits Available |
|
|
|
|
|
|
|
|
%table.table |
|
|
%table.table |
|
|
%tbody |
|
|
%tbody |
|
|
- @user_time_entries.each do |entry| |
|
|
- @user_time_entries.each do |entry| |
|
|
%tr |
|
|
%tr{ "data-id" => entry.id, "data-description" => entry.description, |
|
|
|
|
|
"data-duration" => entry.duration_in_hours, |
|
|
|
|
|
"data-start_date" => entry.start_date.to_date.to_formatted_s(:rfc822)} |
|
|
%td #{entry.start_date.to_date.to_formatted_s(:rfc822)} |
|
|
%td #{entry.start_date.to_date.to_formatted_s(:rfc822)} |
|
|
%td #{entry.duration_in_hours} |
|
|
%td #{entry.duration_in_hours} |
|
|
%td #{truncate(entry.description)} |
|
|
%td #{truncate(entry.description)} |
|
|
%td |
|
|
%td |
|
|
%button{ class: "btn icon-remove btn-danger", role: "button", "data-toggle" => "modal", "data-target" => "#confirmation" } |
|
|
%button{ class: "btn icon-remove btn-danger work_entry-delete-btn", role: "button", "data-toggle" => "modal", "data-target" => "#confirmation" } |
|
|
|
|
|
|
|
|
%a{class: "btn btn-lg btn-block btn-primary", href: new_time_entry_path } Add Time Entry |
|
|
%a{class: "btn btn-lg btn-block btn-primary", href: new_time_entry_path } Add Time Entry |
|
|
|
|
|
|
|
|
.modal{ id: "confirmation", class: "hide", role: "dialog", "aria-labelledby" => "confirmation_title", "aria-hidden" => "true", tabindex: -1 } |
|
|
.modal{ id: "confirmation", class: "hide", role: "dialog", "aria-labelledby" => "confirmation_title", "aria-hidden" => "true", tabindex: -1 } |
|
|
.modal-header |
|
|
.modal-header |
|
|
%button{ class: "close", "data-dismiss" => "modal", "aria-hidden" => "true"}x |
|
|
%button{ class: "close", "data-dismiss" => "modal", "aria-hidden" => "true"}x |
|
|
%h4{ id: "confirmation_title" } header |
|
|
%h4{ id: "confirmation_title" } Are you sure you want to delete? |
|
|
.modal-body |
|
|
.modal-body |
|
|
Are you sure? |
|
|
%div{ id: "work_entry_start_date" } |
|
|
|
|
|
Start Date |
|
|
|
|
|
%div{ id: "work_entry_duration" } |
|
|
|
|
|
Duration |
|
|
|
|
|
%div{ id: "work_entry_description" } |
|
|
|
|
|
Description |
|
|
.modal-footer |
|
|
.modal-footer |
|
|
%button{ class: "btn", "data-dismiss" => "modal", "aria-hidden" => "true"} Close |
|
|
%button{ class: "btn", "data-dismiss" => "modal", "aria-hidden" => "true"} Close |
|
|
%button{ class: "btn btn-primary" } Delete |
|
|
%button{ id: "confirmation_delete", class: "btn btn-primary" } Delete |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|