break;
}
message = m.alarm.title.escapeHTML();
- if (!Object.isUndefined(m.alarm.url)) {
+ if (!Object.isUndefined(m.alarm.ajax)) {
+ message = new Element('a')
+ .insert(message)
+ .observe('click', function() { this.go(m.alarm.ajax); }.bind(this));
+ } else if (!Object.isUndefined(m.alarm.url)) {
message = new Element('a', { 'href': m.alarm.url })
.insert(message);
}
$methods['notify']['show'] = array(
'__app' => $GLOBALS['registry']->getApp(),
'task' => $this->id,
- 'tasklist' => $this->tasklist,
- 'ajax' => 'task:' . $this->tasklist . ':' . $this->id);
+ 'tasklist' => $this->tasklist);
+ $methods['notify']['ajax'] = 'task:' . $this->tasklist . ':' . $this->id;
if (!empty($methods['notify']['sound'])) {
if ($methods['notify']['sound'] == 'on') {
// Handle boolean sound preferences;