1 |
|
2 | var NoteComment = function(data) {
|
3 | this.id = data.comment_id;
|
4 | this.userID = data.user_id;
|
5 | this.action = data.comment_action;
|
6 | this.timestamp = data.comment_timestamp;
|
7 | this.comment = data.comment;
|
8 | this.userName = data.user_name;
|
9 | };
|
10 |
|
11 | NoteComment.prototype.getJSON = function() {
|
12 | return {
|
13 | 'id': this.id,
|
14 | 'userID': this.userID,
|
15 | 'userName': this.userName,
|
16 | 'action': this.action,
|
17 | 'timestamp': this.timestamp,
|
18 | 'comment': this.comment
|
19 | };
|
20 | };
|
21 |
|
22 | module.exports = NoteComment; |
\ | No newline at end of file |