nopaque.resource_lists.JobList = class JobList extends nopaque.resource_lists.ResourceList { static htmlClass = 'job-list'; constructor(listContainerElement, options = {}) { super(listContainerElement, options); this.documentJobArea = document.querySelector('#jobs'); this.listjs.list.addEventListener('click', (event) => {this.onClick(event)}); document.querySelectorAll('.job-list-selection-action-trigger[data-selection-action]').forEach((element) => { element.addEventListener('click', (event) => {this.onSelectionAction(event)}); }); this.isInitialized = false; this.selectedItemIds = new Set(); this.userId = listContainerElement.dataset.userId; if (this.userId === undefined) {return;} app.subscribeUser(this.userId).then((response) => { app.socket.on('patch_user', (patch) => { if (this.isInitialized) {this.onPatch(patch);} }); }); app.getUser(this.userId).then((user) => { this.add(Object.values(user.jobs)); this.isInitialized = true; }); } get item() { return `
Service | Title and Description | Status |
---|