if(issue.getTimeEntries()!=null) {
taskAttribute.setValue(""+issue.getTimeEntries().getSum()); //$NON-NLS-1$
for (TimeEntry timeEntry : issue.getTimeEntries().getAll()) {
RedmineTaskTimeEntryMapper mapper = new RedmineTaskTimeEntryMapper();
mapper.setTimeEntryId(timeEntry.getId());
mapper.setUser(repository.createPerson(""+timeEntry.getUserId())); //$NON-NLS-1$
mapper.setActivityId(timeEntry.getActivityId());
mapper.setHours(timeEntry.getHours());
mapper.setSpentOn(timeEntry.getSpentOn());
mapper.setComments(timeEntry.getComments());
mapper.setCustomValues(timeEntry.getCustomValues().getAll());
taskAttribute = taskData.getRoot().createAttribute(IRedmineConstants.TASK_ATTRIBUTE_TIMEENTRY_PREFIX + mapper.getTimeEntryId());
mapper.applyTo(taskAttribute, cfg);
}
}
}