diff --git a/UI/Templates/SchedulerUI/UIxAppointmentEditorTemplate.wox b/UI/Templates/SchedulerUI/UIxAppointmentEditorTemplate.wox
index 86453c1e6..be7094cbd 100644
--- a/UI/Templates/SchedulerUI/UIxAppointmentEditorTemplate.wox
+++ b/UI/Templates/SchedulerUI/UIxAppointmentEditorTemplate.wox
@@ -208,12 +208,12 @@
+ ng-if="editor.showRecurrenceEditor">
+ ng-if="editor.component.repeat.frequency != 'never'">
+ ng-if="editor.component.$hasAlarm">
diff --git a/UI/WebServerResources/js/Scheduler/ComponentController.js b/UI/WebServerResources/js/Scheduler/ComponentController.js
index d5c4a690e..5ab35f1c5 100644
--- a/UI/WebServerResources/js/Scheduler/ComponentController.js
+++ b/UI/WebServerResources/js/Scheduler/ComponentController.js
@@ -388,14 +388,16 @@
};
this.changeAlarmRelation = function (form) {
- if (this.component.type == 'task' && this.component.$hasAlarm &&
- (this.component.start || this.component.due) &&
- ((!this.component.start && this.component.alarm.relation == 'START') ||
- (!this.component.due && this.component.alarm.relation == 'END'))) {
- form.alarmRelation.$setValidity('alarm', false);
- }
- else {
- form.alarmRelation.$setValidity('alarm', true);
+ if (form.alarmRelation) {
+ if (this.component.type == 'task' && this.component.$hasAlarm &&
+ (this.component.start || this.component.due) &&
+ ((!this.component.start && this.component.alarm.relation == 'START') ||
+ (!this.component.due && this.component.alarm.relation == 'END'))) {
+ form.alarmRelation.$setValidity('alarm', false);
+ }
+ else {
+ form.alarmRelation.$setValidity('alarm', true);
+ }
}
};