sogo/UI/Templates/SchedulerUI/UIxAttendeesEditor.wox
2017-07-27 16:50:03 -04:00

112 lines
5.6 KiB
XML

<?xml version='1.0' standalone='yes'?>
<container
xmlns="http://www.w3.org/1999/xhtml"
xmlns:var="http://www.skyrix.com/od/binding"
xmlns:const="http://www.skyrix.com/od/constant"
xmlns:label="OGo:label"
>
<script type="text/javascript">
var dayStartHour = <var:string value="dayStartHour"/>;
var dayEndHour = <var:string value="dayEndHour"/>;
var timeFormat = '<var:string value="userDefaults.timeFormat" const:escapeHTML="NO"/>';
</script>
<md-content>
<!-- attendees -->
<md-list>
<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"
ng-click="editor.removeAttendee(currentAttendee, eventForm)">
<md-icon>remove_circle</md-icon>
</md-button>
<sg-avatar-image class="md-avatar"
sg-email="currentAttendee.email"
size="40">person</sg-avatar-image>
<div class="sg-tile-content">
<div class="sg-md-subhead"><div>{{currentAttendee.name}}</div></div>
<div class="sg-md-body"><div>{{currentAttendee.email}}</div></div>
</div>
<md-divider><!-- divider --></md-divider>
</md-list-item>
</md-list>
<!-- 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>
<div class="hours" layout="row" layout-align="space-between center">
<div class="hour" ng-repeat="hour in ::editor.attendeesEditor.hours">{{hour}}</div>
</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}"
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="currentAttendee.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="currentAttendee.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="currentAttendee.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="currentAttendee.freebusy[day.getDayString][hour][3]"><!-- 15 minutes --></div>
</div>
</div>
<md-divider><!-- divider --></md-divider>
</md-list-item>
</md-list>
</md-content>
<!-- freebusy caption -->
<div layout="row" layout-align="end center">
<div class="quarter"><div class="busy sg-color-chip"><!-- busy --></div></div>
<label class="md-caption"><var:string label:value="Busy"/></label>
<div class="quarter"><div class="sg-no-freebusy sg-color-sample"><!-- no fb --></div></div>
<label class="md-caption"><var:string label:value="No free-busy information"/></label>
</div>
</container>