Commit d8041a76 authored by Benoit Mortier's avatar Benoit Mortier
Browse files

synchronising with simple plugin master

parent 20ee37d4
......@@ -110,11 +110,6 @@ class simpleManagement extends management
foreach ($this->objectTypes as $object) {
$i = objects::infos($object);
$objectClass = '';
if (preg_match('/objectClass=([^)]+)/', $i['filter'], $m)) {
$objectClass = $m[1];
}
if (!isset($i['icon'])) {
trigger_error('Missing icon for type '.$object);
$i['icon'] = '';
......@@ -123,10 +118,11 @@ class simpleManagement extends management
$this->headpage->objectTypes[$object] =
array(
'label' => $i['name'],
'objectClass' => $objectClass,
'category' => $i['aclCategory'],
'class' => $i['mainTab'],
'image' => $i['icon']
'image' => $i['icon'],
'filter' => ldapFilter::parse($i['filter']),
'nameAttr' => $i['nameAttr'],
);
$this->headpage->categories[] = $i['aclCategory'];
if ($this->autoActions) {
......@@ -203,6 +199,7 @@ class simpleManagement extends management
$this->filter->elementValues[$tag] = TRUE;
$attributes[] = $i['mainAttr'];
$attributes[] = $i['nameAttr'];
}
$filter .= ')';
$attributes = array_values(array_unique($attributes));
......
......@@ -32,7 +32,7 @@
<label>Name</label>
<sortAttribute>cn</sortAttribute>
<sortType>string</sortType>
<value>%{filter:link(row,dn,"%s",cn)}</value>
<value>%{filter:nameLink(row,dn)}</value>
<export>true</export>
</column>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment