--- app/controllers/IssueApp.java
+++ app/controllers/IssueApp.java
... | ... | @@ -432,7 +432,7 @@ |
432 | 432 |
IssueLabel label = IssueLabel.finder.byId(labelId); |
433 | 433 |
issue.labels.add(label); |
434 | 434 |
isLabelChanged = true; |
435 |
- addedLabels.append(label.category.name).append(" - ").append(label.name); |
|
435 |
+ addedLabels.append(label.category.name).append(" - ").append(label.name).append(" ").append(label.color); |
|
436 | 436 |
} |
437 | 437 |
} |
438 | 438 |
|
... | ... | @@ -441,7 +441,7 @@ |
441 | 441 |
IssueLabel label = IssueLabel.finder.byId(labelId); |
442 | 442 |
issue.labels.remove(label); |
443 | 443 |
isLabelChanged = true; |
444 |
- deletedLabels.append(label.category.name).append(" - ").append(label.name); |
|
444 |
+ deletedLabels.append(label.category.name).append(" - ").append(label.name).append(" ").append(label.color); |
|
445 | 445 |
} |
446 | 446 |
} |
447 | 447 |
|
--- app/controllers/api/IssueApi.java
+++ app/controllers/api/IssueApi.java
... | ... | @@ -107,12 +107,14 @@ |
107 | 107 |
if (issue.events.size() > 0) { |
108 | 108 |
for (IssueEvent event: issue.events) { |
109 | 109 |
ObjectNode result = Json.newObject(); |
110 |
+ User sender = User.findByLoginId(event.senderLoginId); |
|
110 | 111 |
result.put("id", event.id); |
111 | 112 |
result.put("createdDate", JodaDateUtil.getDateString(event.created, JodaDateUtil.ISO_FORMAT)); |
112 | 113 |
result.put("eventType", event.eventType.toString()); |
113 | 114 |
result.put("eventDescription", event.eventType.getDescr()); |
114 | 115 |
result.put("oldValue", event.oldValue); |
115 | 116 |
result.put("newValue", event.newValue); |
117 |
+ result.put("actor", getActorJson(sender)); |
|
116 | 118 |
array.add(result); |
117 | 119 |
} |
118 | 120 |
} |
... | ... | @@ -120,6 +122,14 @@ |
120 | 122 |
return array; |
121 | 123 |
} |
122 | 124 |
|
125 |
+ private static JsonNode getActorJson(User user) { |
|
126 |
+ ObjectNode result = Json.newObject(); |
|
127 |
+ result.put("name", user.getPureNameOnly()); |
|
128 |
+ result.put("loginId", user.loginId); |
|
129 |
+ result.put("englishName", user.englishName); |
|
130 |
+ return result; |
|
131 |
+ } |
|
132 |
+ |
|
123 | 133 |
@Transactional |
124 | 134 |
@IsCreatable(ResourceType.ISSUE_POST) |
125 | 135 |
public static Result newIssues(String owner, String projectName) { |
--- app/views/issue/partial_event_timeline.scala.html
+++ app/views/issue/partial_event_timeline.scala.html
... | ... | @@ -58,7 +58,7 @@ |
58 | 58 |
categoryAndName |
59 | 59 |
} else { |
60 | 60 |
var categoryName = splitedCategoryAndName(0).trim |
61 |
- var labelName = splitedCategoryAndName(1).trim |
|
61 |
+ var labelName = splitedCategoryAndName(1).split(" #")(0).trim |
|
62 | 62 |
val issueLabel = IssueLabel.findByName(labelName, categoryName, project) |
63 | 63 |
if(issueLabel != null) { |
64 | 64 |
val labelColor = issueLabel.color |
Add a comment
Delete comment
Once you delete this comment, you won't be able to recover it. Are you sure you want to delete this comment?