Use editname (kolab folder name) for calendar edit form
This commit is contained in:
parent
34346bce45
commit
2e0b6536d5
2 changed files with 12 additions and 0 deletions
|
@ -72,6 +72,17 @@ class kolab_calendar
|
||||||
return strlen($dispname) ? $dispname : $this->imap_folder;
|
return strlen($dispname) ? $dispname : $this->imap_folder;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Getter for the top-end calendar folder name (not the entire path)
|
||||||
|
*
|
||||||
|
* @return string Name of this calendar
|
||||||
|
*/
|
||||||
|
public function get_foldername()
|
||||||
|
{
|
||||||
|
$parts = explode('/', $this->imap_folder);
|
||||||
|
return end($parts);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Return color to display this calendar
|
* Return color to display this calendar
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -70,6 +70,7 @@ class kolab_driver extends calendar_driver
|
||||||
$this->calendars[$calendar->id] = array(
|
$this->calendars[$calendar->id] = array(
|
||||||
'id' => $calendar->id,
|
'id' => $calendar->id,
|
||||||
'name' => $calendar->get_name(),
|
'name' => $calendar->get_name(),
|
||||||
|
'editname' => $calendar->get_foldername(),
|
||||||
'color' => $calendar->get_color(),
|
'color' => $calendar->get_color(),
|
||||||
'readonly' => $c_folder->_owner != $_SESSION['username'],
|
'readonly' => $c_folder->_owner != $_SESSION['username'],
|
||||||
);
|
);
|
||||||
|
|
Loading…
Add table
Reference in a new issue