Constructor
new Comment(data)
Parameters:
Name | Type | Description |
---|---|---|
data |
(Object} key/value pairs of information, must at least contain "id", can basically just pass in response from Trello API |
- Source:
Example
var notif = new Notification(posted);
if(new RegExp("Remove.*").test(notif.addedComment().text()))
notif.card().removeMember(notif.member());
Methods
(static) this.card()
Return the Card on which this comment was added
- Source:
Example
var card = new Notification(posted).addedComment().card();
(static) this.del()
Delete this comment, works only if you have more permissions than the person who made the comment, you made the comment or the person who made the comment has deleted their account Returns the containing card
- Source:
Example
card.comments().first().del();
(static) this.id()
Return the id of this comment
- Source:
Example
card.comments().first().id();
(static) this.member()
Return the member who made a comment
- Source:
Example
card.comments().first().member();
(static) this.mentionedMembers()
Return an IterableCollection of mentioned members
- Source:
Example
card.comments().first().mentionedMembers();
(static) this.name()
A name() function used in name comparisons in the IterableCollection findByName method
- Source:
Example
card.comments().findByName(new RegExp(".*search.*")).first().text();
(static) this.setText()
Edit this comment, works only if you have more permissions than the person who made the comment, you made the comment or the person who made the comment has deleted their account Returns the containing card
- Source:
Example
card.comments().first().del();
(static) this.text()
Return the text of the comment
- Source:
Example
card.comments().first().text();
(static) this.when()
Return a Date when this comment was made
- Source:
Example
card.comments().first().when().toString();