mirror of
https://github.com/discourse/discourse.git
synced 2024-11-23 12:40:40 +08:00
FIX: formats topic report only if we have one (#6231)
This commit is contained in:
parent
14bbd5d167
commit
1ca999fdb5
|
@ -324,12 +324,16 @@ const Report = Discourse.Model.extend({
|
|||
|
||||
_topicLabel(properties, row) {
|
||||
const topicTitle = row[properties.title];
|
||||
const topicId = row[properties.id];
|
||||
const href = `/t/-/${topicId}`;
|
||||
|
||||
const formatedValue = () => {
|
||||
const topicId = row[properties.id];
|
||||
const href = `/t/-/${topicId}`;
|
||||
return `<a href='${href}'>${topicTitle}</a>`;
|
||||
};
|
||||
|
||||
return {
|
||||
value: topicTitle,
|
||||
formatedValue: `<a href='${href}'>${topicTitle}</a>`
|
||||
formatedValue: topicTitle ? formatedValue() : "-"
|
||||
};
|
||||
},
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user