From eec3c301bc7b0f29d7a7fcfcf59d330ceb604985 Mon Sep 17 00:00:00 2001 From: Thuan Pham Quoc Date: Mon, 20 Nov 2017 22:26:31 +0700 Subject: Add card spent time to log time what can be overtime or not (will support filtering in future) --- client/components/cards/cardTime.jade | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 client/components/cards/cardTime.jade (limited to 'client/components/cards/cardTime.jade') diff --git a/client/components/cards/cardTime.jade b/client/components/cards/cardTime.jade new file mode 100644 index 00000000..dcfc92f0 --- /dev/null +++ b/client/components/cards/cardTime.jade @@ -0,0 +1,22 @@ +template(name="editCardSpentTime") + .edit-card-time + form.edit-time + .fields + label(for="time") {{_ 'time'}} + input.js-time-field#time(type="number" step="0.01" name="time" value="{{card.spentTime}}" placeholder=timeFormat autofocus) + label(for="overtime") {{_ 'overtime'}} + a.js-toggle-overtime + .materialCheckBox#overtime(class="{{#if card.isOvertime}}is-checked{{/if}}" name="overtime") + + if error.get + .warning {{_ error.get}} + button.primary.wide.left.js-submit-time(type="submit") {{_ 'save'}} + button.js-delete-time.negate.wide.right {{_ 'delete'}} + +template(name="timeBadge") + if canModifyCard + a.js-edit-time.card-time(title="{{showTitle}}" class="{{#if isOvertime}}card-label-red{{else}}card-label-green{{/if}}") + | {{showTime}} + else + a.card-time(title="{{showTitle}}" class="{{#if isOvertime}}card-label-red{{else}}card-label-green{{/if}}") + | {{showTime}} -- cgit v1.2.3-1-g7c22