Skip to content

Commit

Permalink
Merge pull request #830 from caktus/TM-837-expose-active-entry-comment
Browse files Browse the repository at this point in the history
[TM-837] Better UX for exposing the active entry's comment, if one exists
  • Loading branch information
daaray committed Dec 7, 2015
2 parents e1acdce + 6d786bb commit 85defce
Showing 1 changed file with 16 additions and 1 deletion.
17 changes: 16 additions & 1 deletion timepiece/templates/timepiece/dashboard.html
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,11 @@
</script>
<script charset="utf-8" src="{% static "timepiece/js/dashboard.js" %}"></script>
<script charset="utf-8" src="{% static "timepiece/js/prevent_double_click.js" %}"></script>
<script>
$(document).ready(function(){
$('[data-toggle="popover"]').popover();
});
</script>
{% endblock extrajs %}

{% block content %}
Expand Down Expand Up @@ -68,7 +73,17 @@ <h2>{{ week_start|date:'M j' }} to {{ week_end|date:'M j' }}</h2>
{% endif %}
{% endifnotequal %}
({{ active_entry.get_total_seconds|humanize_seconds }} time clocked{% if active_entry.seconds_paused or active_entry.is_paused %} and {{ active_entry.get_paused_seconds|humanize_seconds }} paused{% endif %}).
{% if active_entry.comments %}<blockquote>{{ active_entry.comments }}</blockquote>{% endif %}
{% if active_entry.comments %}
<a class="btn btn-primary btn-mini" data-toggle="popover"
data-html="true"
title="Active Entry Comment"
data-content="{{ active_entry.comments|linebreaks }}"
data-placement="bottom"
data-container="body">
<i class="icon-white icon-comment"></i>
</a>
{% endif %}

{% else %}
You are not currently clocked into a project.
{% endif %}
Expand Down

0 comments on commit 85defce

Please sign in to comment.