/* -*- Mode: javascript; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
(function() {
'use strict';
/*
* sgCalendarMonthEvent - An event block to be displayed in a month
* @memberof SOGo.Common
* @restrict element
* @param {object} sgBlock - the event block definition
* @ngInject
* @example:
*/
function sgCalendarMonthEvent() {
return {
restrict: 'E',
scope: {
block: '=sgBlock',
clickBlock: '&sgClick'
},
replace: true,
template: [
'
',
' {{ block.starthour }}',
' {{ block.component.summary }}',
' ',
// Component is reccurent
' ',
// Component has an alarm
' ',
// Component is confidential
' ',
// Component is private
' ',
' ',
'
'
].join(''),
link: link
};
function link(scope, iElement, attrs) {
if (scope.block.component)
iElement.addClass('bg-folder' + scope.block.component.pid);
}
}
angular
.module('SOGo.SchedulerUI')
.directive('sgCalendarMonthEvent', sgCalendarMonthEvent);
})();