(Calendar) Add owner in attendees editor

This commit is contained in:
Francis Lachapelle
2017-07-27 16:50:03 -04:00
parent 217525cf10
commit 8221a8de66
5 changed files with 97 additions and 8 deletions
@@ -33,7 +33,8 @@
<!-- calendar -->
<md-input-container flex="50" flex-xs="100">
<label><var:string label:value="Calendar"/></label>
<md-select ng-model="editor.component.destinationCalendar">
<md-select ng-model="editor.component.destinationCalendar"
ng-change="editor.changeCalendar()">
<md-option ng-repeat="calendar in editor.service.$findAll(null, true)"
ng-value="calendar.id">{{calendar.name}}</md-option>
</md-select>
@@ -16,6 +16,21 @@
<md-list-item>
<div class="md-tile-left"><!-- empty --></div>
</md-list-item>
<!-- organizer -->
<md-list-item>
<div class="md-button md-icon-button">
<md-icon>person</md-icon>
</div>
<sg-avatar-image class="md-avatar"
sg-email="editor.component.organizer.email"
size="40">person</sg-avatar-image>
<div class="sg-tile-content">
<div class="sg-md-subhead"><div>{{editor.component.organizer.name}}</div></div>
<div class="sg-md-body"><div>{{editor.component.organizer.email}}</div></div>
</div>
<md-divider><!-- divider --></md-divider>
</md-list-item>
<!-- attendees -->
<md-list-item ng-repeat="currentAttendee in editor.component.attendees track by currentAttendee.email">
<md-button class="md-icon-button"
label:aria-label="Delete"
@@ -35,6 +50,7 @@
<!-- freebusy -->
<md-list class="day"
ng-repeat="day in editor.attendeesEditor.days">
<!-- timeline -->
<md-list-item layout-align="start end">
<div layout="column" layout-align="end start">
<div>{{day.stringWithSeparator}}</div>
@@ -43,6 +59,27 @@
</div>
</div>
</md-list-item>
<!-- organizer freebusy -->
<md-list-item>
<div class="hour"
ng-class="{'sg-no-freebusy': !editor.component.organizer.uid}"
ng-repeat="hour in ::editor.attendeesEditor.hours">
<div class="quarter" ng-class="{event: editor.component.coversFreeBusy(day.getDayString, hour, 0)}">
<div class="busy" ng-show="editor.component.organizer.freebusy[day.getDayString][hour][0]"><!-- 15 minutes --></div>
</div>
<div class="quarter" ng-class="{event: editor.component.coversFreeBusy(day.getDayString, hour, 1)}">
<div class="busy" ng-show="editor.component.organizer.freebusy[day.getDayString][hour][1]"><!-- 15 minutes --></div>
</div>
<div class="quarter" ng-class="{event: editor.component.coversFreeBusy(day.getDayString, hour, 2)}">
<div class="busy" ng-show="editor.component.organizer.freebusy[day.getDayString][hour][2]"><!-- 15 minutes --></div>
</div>
<div class="quarter" ng-class="{event: editor.component.coversFreeBusy(day.getDayString, hour, 3)}">
<div class="busy" ng-show="editor.component.organizer.freebusy[day.getDayString][hour][3]"><!-- 15 minutes --></div>
</div>
</div>
<md-divider><!-- divider --></md-divider>
</md-list-item>
<!-- attendees freebusy -->
<md-list-item ng-repeat="currentAttendee in editor.component.attendees track by currentAttendee.email">
<div class="hour"
ng-class="{'sg-no-freebusy': !currentAttendee.uid}"