Skip to content

Commit

Permalink
Merge pull request #5237 from dimagi/update-reminder-wording
Browse files Browse the repository at this point in the history
Update wording on offset-based events
  • Loading branch information
czue committed Jan 8, 2015
2 parents c947fc3 + c993a42 commit 51149a9
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 4 deletions.
5 changes: 5 additions & 0 deletions corehq/apps/reminders/static/reminders/ko/reminders.manage.js
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,11 @@ var ManageRemindersViewModel = function (
return self.areTimeoutsVisible() && self.ui_type === self.choices.UI_SIMPLE_FIXED;
});

self.isOffsetTimingUsed = ko.computed(function () {
var timing = $.parseJSON(self.event_timing());
return timing.event_interpretation === "OFFSET";
});

self.submit_partial_forms = ko.observable(initial.submit_partial_forms);
self.isPartialSubmissionsVisible = ko.computed(function () {
return (self.method() === self.choices.METHOD_IVR_SURVEY ||
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,26 +2,30 @@
<table class="table table-bordered">
<thead data-bind="with: eventObjects()[0]">
<th class="span2">
{% trans 'Day' %}
<span data-bind="visible: !$parent.isOffsetTimingUsed()">{% trans 'Day' %}</span>
<span data-bind="visible: $parent.isOffsetTimingUsed()">{% trans 'Days to Delay' %}</span>
<a href="#" class="hq-help no-click event-help-text" style="font-weight: normal;">
<i class="icon-question-sign"
data-title="{% trans 'Day' %}"
data-content="{% blocktrans %}
The day on which each event in the reminder comes due.
Day 0 indicates the day that the reminder was triggered.
If Delay After Start is chosen, this is the number of days
to wait after the previous event.
{% endblocktrans %}"
data-trigger="hover"></i>
</a>
</th>
<th class="span2">
{% trans 'Time' %}
<span data-bind="visible: !$parent.isOffsetTimingUsed()">{% trans 'Time' %}</span>
<span data-bind="visible: $parent.isOffsetTimingUsed()">{% trans 'Time to Delay' %}</span>
<a href="#" class="hq-help no-click event-help-text" style="font-weight: normal;">
<i class="icon-question-sign"
data-title="{% trans 'Time' %}"
data-content="{% blocktrans %}
Specify the time at which the specific message will be sent out.
Specify the time at which the reminder will be sent out.
If Delay After Start is chosen, this is the number of
minutes after which the reminder will go out.
hours and minutes to wait after the previous event.
{% endblocktrans %}"
data-trigger="hover"></i>
</a>
Expand Down

0 comments on commit 51149a9

Please sign in to comment.