@@ -99,6 +99,9 @@ import {
99
99
import { NcModal as Modal } from '@nextcloud/vue'
100
100
import ChevronRightIcon from 'vue-material-design-icons/ChevronRight.vue'
101
101
import ChevronLeftIcon from 'vue-material-design-icons/ChevronLeft.vue'
102
+ import Vue from 'vue'
103
+ import OrganizerListItem from '../Invitees/OrganizerListItem.vue'
104
+ import InviteesListItem from '../Invitees/InviteesListItem.vue'
102
105
103
106
import { getColorForFBType } from '../../../utils/freebusy.js'
104
107
@@ -287,6 +290,13 @@ export default {
287
290
height: 'auto',
288
291
loading: this.loading,
289
292
headerToolbar: false,
293
+ // resourceLabelContent: this.customResourceRender,
294
+ resourceAreaColumns: [
295
+ {
296
+ field: 'title',
297
+ headerContent: 'Attendees',
298
+ },
299
+ ],
290
300
// Timezones:
291
301
timeZone: this.timezoneId,
292
302
// Formatting of the title
@@ -326,6 +336,28 @@ export default {
326
336
break
327
337
}
328
338
},
339
+ customResourceRender(arg) {
340
+ const attendee = [this.organizer, ...this.attendees].find((a) => a.uri === arg.resource.id)
341
+ let component = null
342
+ if (attendee === this.organizer) {
343
+ component = new Vue({
344
+ render: h => h(OrganizerListItem, { props: { organizer: attendee, isReadOnly: false } }),
345
+ }).$mount()
346
+ } else {
347
+ component = new Vue({
348
+ render: h => h(InviteesListItem, { props: { attendee, organizerDisplayName: this.organizer.commonName, isReadOnly: false } }),
349
+ }).$mount()
350
+
351
+ }
352
+
353
+ const html = document.createElement('div')
354
+ html.style.position = 'absolute'
355
+ html.innerText(component.$el.outerHTML)
356
+
357
+ return {
358
+ html,
359
+ }
360
+ },
329
361
},
330
362
}
331
363
</script>
0 commit comments