소스 검색

Update spent time title to indicate Overtime or normal Spent time

Thuan Pham Quoc 7 년 전
부모
커밋
d38071457c
1개의 변경된 파일5개의 추가작업 그리고 1개의 파일을 삭제
  1. 5 1
      client/components/cards/cardTime.js

+ 5 - 1
client/components/cards/cardTime.js

@@ -55,7 +55,11 @@ BlazeComponent.extendComponent({
     self.time = ReactiveVar();
   },
   showTitle() {
-    return `${TAPi18n.__('card-spent')} ${this.data().spentTime}`;
+    if (this.data().isOvertime) {
+      return `${TAPi18n.__('overtime')} ${this.data().spentTime} ${TAPi18n.__('hours')}`;
+    } else {
+      return `${TAPi18n.__('card-spent')} ${this.data().spentTime} ${TAPi18n.__('hours')}`;
+    }
   },
   showTime() {
     return this.data().spentTime;