From fc54c5162c86f4d0222242ef7a98b59cafdb5900 Mon Sep 17 00:00:00 2001 From: bsatarnejad Date: Thu, 23 Apr 2020 14:17:49 +0200 Subject: [PATCH] add the spent time logo to wp details --- .../field-types/wp-spent-time-display-field.module.ts | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/frontend/src/app/modules/fields/display/field-types/wp-spent-time-display-field.module.ts b/frontend/src/app/modules/fields/display/field-types/wp-spent-time-display-field.module.ts index d10ae38951..59db5cbaa2 100644 --- a/frontend/src/app/modules/fields/display/field-types/wp-spent-time-display-field.module.ts +++ b/frontend/src/app/modules/fields/display/field-types/wp-spent-time-display-field.module.ts @@ -35,7 +35,8 @@ import * as URI from 'urijs'; export class WorkPackageSpentTimeDisplayField extends DurationDisplayField { public text = { - linkTitle: this.I18n.t('js.work_packages.message_view_spent_time') + linkTitle: this.I18n.t('js.work_packages.message_view_spent_time'), + logTime: this.I18n.t('js.button_log_time') }; @InjectField() PathHelper:PathHelperService; @@ -63,7 +64,13 @@ export class WorkPackageSpentTimeDisplayField extends DurationDisplayField { }); } + + const timelogLogo= document.createElement('a'); + timelogLogo.setAttribute('class','icon icon-time'); + timelogLogo.textContent = this.text.logTime; + element.innerHTML = ''; element.appendChild(link); + element.appendChild(timelogLogo); } }