| 14 | module.exports = (ChatSearchView = (function () { |
| 15 | ChatSearchView = class ChatSearchView extends SearchView { |
| 16 | static initClass () { |
| 17 | this.prototype.id = 'editor-chat-home-view' |
| 18 | this.prototype.modelLabel = 'Chat' |
| 19 | this.prototype.model = require('models/ChatMessage') |
| 20 | this.prototype.modelURL = '/db/chat_message' |
| 21 | this.prototype.tableTemplate = require('app/templates/editor/chat/table') |
| 22 | this.prototype.projection = ['message.startDate', 'message.endDate', 'kind', 'example', 'releasePhase', 'context.levelName', 'message.sender.name', 'message.text'] |
| 23 | this.prototype.page = 'chat' |
| 24 | this.prototype.canMakeNew = false |
| 25 | this.prototype.limit = 1000 |
| 26 | |
| 27 | this.prototype.events = |
| 28 | { 'click #delete-button': 'deleteChatMessage' } |
| 29 | } |
| 30 | |
| 31 | getRenderData () { |
| 32 | const context = super.getRenderData() |