|
|
|
@ -9,16 +9,16 @@ angular.module('openproject.timelines.directives') |
|
|
|
|
localePrefix: '@' |
|
|
|
|
}, |
|
|
|
|
link: function(scope, element) { |
|
|
|
|
scope.$watch('customFields', function(){ |
|
|
|
|
if (CustomFieldHelper.isCustomFieldKey(scope.columnName)) { |
|
|
|
|
if (CustomFieldHelper.isCustomFieldKey(scope.columnName)) { |
|
|
|
|
scope.$watch('customFields', function(){ |
|
|
|
|
var customFieldId = CustomFieldHelper.getCustomFieldId(scope.columnName); |
|
|
|
|
if (scope.customFields && scope.customFields[customFieldId]) { |
|
|
|
|
element.html(scope.customFields[customFieldId].name); |
|
|
|
|
} |
|
|
|
|
} else { |
|
|
|
|
element.html(I18n.t(scope.localePrefix + '.' + scope.columnName)); |
|
|
|
|
} |
|
|
|
|
}); |
|
|
|
|
}); |
|
|
|
|
} else { |
|
|
|
|
element.html(I18n.t(scope.localePrefix + '.' + scope.columnName)); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
} |
|
|
|
|
}; |
|
|
|
|