index 7d8138348388885a26eeb771b6259af2ca87dbc7..e0ca916ef09189fa7e64a337fc6435643e90a057 100644 (file)
}
$this->categories= array();
if (isset($this->xmlData['definition']['objectType'])) {
}
$this->categories= array();
if (isset($this->xmlData['definition']['objectType'])) {
+ if(isset($this->xmlData['definition']['objectType']['label'])) {
+ $this->xmlData['definition']['objectType']= array($this->xmlData['definition']['objectType']);
+ }
foreach ($this->xmlData['definition']['objectType'] as $index => $otype) {
$this->objectTypes[]= $this->xmlData['definition']['objectType'][$index];
if (isset($this->xmlData['definition']['objectType'][$index]['category'])){
foreach ($this->xmlData['definition']['objectType'] as $index => $otype) {
$this->objectTypes[]= $this->xmlData['definition']['objectType'][$index];
if (isset($this->xmlData['definition']['objectType'][$index]['category'])){
}
// Need to fill the list if it's not full (nobody knows why this is 22 ;-))
}
// Need to fill the list if it's not full (nobody knows why this is 22 ;-))
- $emptyListStyle= (count($this->entries) + count($deps) == 0)?"border:0;":"";
- if (count($this->entries) + count($deps) < 22) {
+ $emptyListStyle= (count($this->entries) + $deps == 0)?"border:0;":"";
+ if ((count($this->entries) + $deps) < 22) {
$result.= "<tr>";
for ($i= 0; $i<$this->numColumns; $i++) {
if ($i == 0) {
$result.= "<tr>";
for ($i= 0; $i<$this->numColumns; $i++) {
if ($i == 0) {
global $config;
$ui= get_userinfo();
global $config;
$ui= get_userinfo();
+ // Reset object counter
+ $this->objectTypeCount= array();
+
// Do not do anything if this is not our PID
if(isset($_REQUEST['PID']) && $_REQUEST['PID'] != $this->pid) {
return;
// Do not do anything if this is not our PID
if(isset($_REQUEST['PID']) && $_REQUEST['PID'] != $this->pid) {
return;
// Watch out for filters and prepare to execute them
$data= $this->processElementFilter($data, $config, $row);
// Watch out for filters and prepare to execute them
$data= $this->processElementFilter($data, $config, $row);
+ // Replace all non replaced %{...} instances because they
+ // are non resolved attributes or filters
+ $data= preg_replace('/%{[^}]+}/', ' ', $data);
+
return $data;
}
return $data;
}
$actions= &$this->xmlData['actionmenu']['action'];
$result= "<input type='hidden' name='act' id='actionmenu' value=''>".
"<ul class='level1' id='root'><li><a href='#'>Aktionen <img ".
$actions= &$this->xmlData['actionmenu']['action'];
$result= "<input type='hidden' name='act' id='actionmenu' value=''>".
"<ul class='level1' id='root'><li><a href='#'>Aktionen <img ".
- "border=0 src='images/lists/sort-down.png'></a>";
+ "border=0 class='center' src='images/lists/sort-down.png'></a>";
// Build ul/li list
$result.= $this->recurseActions($actions);
// Build ul/li list
$result.= $this->recurseActions($actions);
// Fill image if set
$img= "";
if (isset($action['image'])){
// Fill image if set
$img= "";
if (isset($action['image'])){
- $img= "<img border=0 src='".$action['image']."'> ";
+ $img= "<img border='0' class='center' src='".$action['image']."'> ";
}
if ($action['type'] == "separator"){
}
if ($action['type'] == "separator"){
// Every ACL has to pass
foreach ($acls as $acl) {
$module= $this->module;
// Every ACL has to pass
foreach ($acls as $acl) {
$module= $this->module;
- $acllist= array();
+ $aclList= array();
// Split for category and plugins if needed
// match for "[rw]" style entries
// Split for category and plugins if needed
// match for "[rw]" style entries
// If there is a daemon registered, draw the menu entries
if(class_available("DaemonEvent")){
$events= DaemonEvent::get_event_types_by_category($this->categories);
// If there is a daemon registered, draw the menu entries
if(class_available("DaemonEvent")){
$events= DaemonEvent::get_event_types_by_category($this->categories);
- if(count($events['BY_CLASS'])){
+ if(isset($events['BY_CLASS']) && count($events['BY_CLASS'])){
foreach($events['BY_CLASS'] as $name => $event){
foreach($events['BY_CLASS'] as $name => $event){
- $result.= "<li$separator><a href='#' onClick='document.getElementById(\"actionmenu\").value= \"$name\";mainform.submit();'><img src='".$event['MenuImage']."' alt='' border='0' class='center'> ".$event['s_Menu_Name']."</a></li>";
+ $result.= "<li$separator><a href='#' onClick='document.getElementById(\"actionmenu\").value=\"$name\";mainform.submit();'>".$event['MenuImage']." ".$event['s_Menu_Name']."</a></li>";
$separator= "";
}
}
$separator= "";
}
}