index 53d50519d5507bfc91c0059c862e5243582844f3..d4f972d3da2c5357fdb2f11ed6fe0c502125e3f3 100644 (file)
function setFilter($filter)
{
+ $filter->setCategories($this->categories);
$this->filter= &$filter;
if ($this->departmentBrowser){
$this->departments= $this->getDepartments();
$link= "href='?plug=".$_GET['plug']."&PID=".$this->pid."&act=SORT_$index'";
if (isset($config['label'])) {
if ($sortable) {
- $this->header[$index]= "<td class='listheader' ".$this->colprops[$index]."><a $link>"._($config['label'])."$sorter</a></td>";
+ $this->header[$index]= "<td class='listheader' ".$this->colprops[$index]."><a $link>"._($config['label'])."</a>$sorter</td>";
} else {
$this->header[$index]= "<td class='listheader' ".$this->colprops[$index].">"._($config['label'])."</td>";
}
$this->plainHeader[]= _($config['label']);
} else {
if ($sortable) {
- $this->header[$index]= "<td class='listheader' ".$this->colprops[$index]."><a $link> $sorter</a></td>";
+ $this->header[$index]= "<td class='listheader' ".$this->colprops[$index]."><a $link> </a>$sorter</td>";
} else {
$this->header[$index]= "<td class='listheader' ".$this->colprops[$index]."> </td>";
}
// Go thru all actions
$result= "";
$actions= $this->xmlData['actiontriggers']['action'];
+
+ // Ensure we've a valid actions array, if there is only one action in the actiontriggers col
+ // then we've to create a valid array here.
+ if(isset($actions['name'])) $actions = array($actions);
+
foreach($actions as $action) {
// Skip the entry completely if there's no permission to execute it
if (!$this->hasActionPermission($action, $dn, $classes)) {
if($restore){
$result.= "<li$separator><a href='#' onClick='document.getElementById(\"actionmenu\").value= \"restore\";document.getElementById(\"exec_act\").click();'>".image('images/lists/restore.png')." "._("Restore snapshots")."</a></li>";
}else{
- $result.= "<li$separator><a href='#'>".image('images/lists/restore_grey.png')." "._("Restore snapshots")."</a></li>";
+ $result.= "<li$separator><a href='#'>".image('images/lists/restore-grey.png')." "._("Restore snapshots")."</a></li>";
}
}
if($this->snapshotHandler->hasSnapshots($dn)){
$result.= image('images/lists/restore.png', "listing_restore_$row", _("Restore snapshot"));
} else {
- $result.= image('images/lists/restore_grey.png');
+ $result.= image('images/lists/restore-grey.png');
}
}