summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 1ac2154)
raw | patch | inline | side by side (parent: 1ac2154)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Thu, 12 Jun 2008 14:04:12 +0000 (14:04 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Thu, 12 Jun 2008 14:04:12 +0000 (14:04 +0000) |
gosa.conf
<deptabs>
<tab class="department" name="Generic" />
</deptabs>
<organization_tabs>
<tab class="organization" name="Generic" />
</organization_tabs>
<locality_tabs>
<tab class="locality" name="Generic" />
</locality_tabs>
<country_tabs>
<tab class="country" name="Generic" />
</country_tabs>
<ogrouptabs>
<tab class="ogroup" name="Generic" />
</ogrouptabs>
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@11307 594d385d-05f5-0310-b6e9-bd551577e9d8
<deptabs>
<tab class="department" name="Generic" />
</deptabs>
<organization_tabs>
<tab class="organization" name="Generic" />
</organization_tabs>
<locality_tabs>
<tab class="locality" name="Generic" />
</locality_tabs>
<country_tabs>
<tab class="country" name="Generic" />
</country_tabs>
<ogrouptabs>
<tab class="ogroup" name="Generic" />
</ogrouptabs>
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@11307 594d385d-05f5-0310-b6e9-bd551577e9d8
gosa-core/plugins/admin/departments/class_departmentManagement.inc | patch | blob | history | |
gosa-core/plugins/admin/departments/generic.tpl | patch | blob | history |
diff --git a/gosa-core/plugins/admin/departments/class_departmentManagement.inc b/gosa-core/plugins/admin/departments/class_departmentManagement.inc
index 03cf292c68afe1185318e8e0f87d14b3299bf256..26ed101aa8c1b4bdf7b2536dfd0a2faa8d6b1b86 100644 (file)
*/
if ($s_action=="new"){
$this->dn= "new";
- if($s_entry == "c"){
- $this->deptabs= new deptabs($this->config,$this->config->data['TABS']['COUNTRY_TABS'], $this->dn,"country");
+
+ $objects['c'] ['ACL'] = "country";
+ $objects['c'] ['TAB'] = "COUNTRY_TABS";
+ $objects['ou']['ACL'] = "department";
+ $objects['ou']['TAB'] = "DEPTABS";
+ $objects['l'] ['ACL'] = "locatity";
+ $objects['l'] ['TAB'] = "LOCALITY_TABS";
+ $objects['o'] ['ACL'] = "organization";
+ $objects['o'] ['TAB'] = "ORGANIZATION_TABS";
+
+ if(isset($objects[$s_entry])){
+ $tab = $objects[$s_entry]['TAB'];
+ $acl = $objects[$s_entry]['ACL'];
+ $this->deptabs= new deptabs($this->config,$this->config->data['TABS'][$tab], $this->dn,$acl);
}else{
- $this->deptabs= new deptabs($this->config,$this->config->data['TABS']['DEPTABS'], $this->dn,"department");
+ trigger_error("Invalid / Not implemented countainer type.");
}
$this->deptabs->set_acl_base($this->DivListDepartment->selectedBase);
}
/**/
$non_ou = get_list("(&(|(c=$Regex)(description=$Regex))(objectClass=country))",
"department", $base, array("c", "description"), GL_SIZELIMIT );
+ $non_ou = array_merge($non_ou,get_list("(&(|(l=$Regex)(description=$Regex))(objectClass=locality))",
+ "department", $base, array("l", "description"), GL_SIZELIMIT ));
+ $non_ou = array_merge($non_ou,get_list("(&(|(o=$Regex)(description=$Regex))(objectClass=organization))",
+ "department", $base, array("o", "description"), GL_SIZELIMIT ));
$this->departments= array();
foreach($non_ou as $obj){
diff --git a/gosa-core/plugins/admin/departments/generic.tpl b/gosa-core/plugins/admin/departments/generic.tpl
index fa8fc8ea3b954874d3963d41773abe3c57e44e20..df3c9121f2c758a188dbea9331f6a5c9e6a4d145 100644 (file)
-{if $dep_type == "c"}
+
+{if $dep_type == "l"}
+
+<!--////////////////////
+ // LOCALITY (l)
+ //////////////////// -->
+
+<table summary="" style="width:100%; vertical-align:top; text-align:left;" cellpadding=4>
+ <tr>
+ <td style="vertical-align:top; width:50%">
+ <h2><img class="center" alt="" align="middle" src="images/rightarrow.png"> {t}Properties{/t}</h2>
+ <table summary="">
+ <tr>
+ <td><LABEL for="l">{t}Locality name{/t}</LABEL>{$must}</td>
+ <td>
+{render acl=$ouACL}
+ <input id="l" name="l" size=25 maxlength=60 value="{$l}" title="{t}Name of locality to create{/t}">
+{/render}
+ </td>
+ </tr>
+ <tr>
+ <td><LABEL for="description">{t}Description{/t}</LABEL>{$must}</td>
+ <td>
+{render acl=$descriptionACL}
+ <input id="description" name="description" size=25 maxlength=80 value="{$description}" title="{t}Descriptive text for department{/t}">
+{/render}
+ </td>
+ </tr>
+ <tr>
+ <td><LABEL for="base">{t}Base{/t}</LABEL>{$must}</td>
+ <td>
+{render acl=$baseACL}
+ <select id="base" size="1" name="base" title="{t}Choose subtree to place department in{/t}">
+ {html_options options=$bases selected=$base_select}
+ </select>
+{/render}
+
+{render acl=$baseACL disable_picture='images/lists/folder_grey.png'}
+ <input type="image" name="chooseBase" src="images/lists/folder.png" class="center" title="{t}Select a base{/t}">
+{/render}
+ </td>
+ </tr>
+ </table>
+ </td>
+ </tr>
+</table>
+<p class='seperator'> </p>
+<table summary="" style="width:100%; vertical-align:top; text-align:left;" cellpadding=4>
+ <tr>
+ <td style="vertical-align:top; width:100%">
+ <h2><img class="center" alt="" align="middle" src="images/lists/locked.png"> {t}Administrative settings{/t}</h2>
+{render acl=$gosaUnitTagACL}
+ <input id="unitTag" type=checkbox name="unitTag" value="1" {$unitTag}><label for="unitTag">{t}Tag department as an independent administrative unit{/t}</label>
+{/render}
+ </td>
+ </tr>
+</table>
+
+
+{elseif $dep_type == "o"}
+
+<!--////////////////////
+ // ORGANIZATION (o)
+ //////////////////// -->
+
+<table summary="" style="width:100%; vertical-align:top; text-align:left;" cellpadding=4>
+ <tr>
+ <td style="vertical-align:top; width:50%">
+ <h2><img class="center" alt="" align="middle" src="images/rightarrow.png"> {t}Properties{/t}</h2>
+ <table summary="">
+ <tr>
+ <td><LABEL for="o">{t}Organization name{/t}</LABEL>{$must}</td>
+ <td>
+{render acl=$ouACL}
+ <input id="o" name="o" size=25 maxlength=60 value="{$o}" title="{t}Name of organization to create{/t}">
+{/render}
+ </td>
+ </tr>
+ <tr>
+ <td><LABEL for="description">{t}Description{/t}</LABEL>{$must}</td>
+ <td>
+{render acl=$descriptionACL}
+ <input id="description" name="description" size=25 maxlength=80 value="{$description}" title="{t}Descriptive text for department{/t}">
+{/render}
+ </td>
+ </tr>
+ <tr>
+ <td><LABEL for="base">{t}Base{/t}</LABEL>{$must}</td>
+ <td>
+{render acl=$baseACL}
+ <select id="base" size="1" name="base" title="{t}Choose subtree to place department in{/t}">
+ {html_options options=$bases selected=$base_select}
+ </select>
+{/render}
+
+{render acl=$baseACL disable_picture='images/lists/folder_grey.png'}
+ <input type="image" name="chooseBase" src="images/lists/folder.png" class="center" title="{t}Select a base{/t}">
+{/render}
+ </td>
+ </tr>
+ </table>
+ </td>
+ </tr>
+</table>
+<p class='seperator'> </p>
+<table summary="" style="width:100%; vertical-align:top; text-align:left;" cellpadding=4>
+ <tr>
+ <td style="vertical-align:top; width:100%">
+ <h2><img class="center" alt="" align="middle" src="images/lists/locked.png"> {t}Administrative settings{/t}</h2>
+{render acl=$gosaUnitTagACL}
+ <input id="unitTag" type=checkbox name="unitTag" value="1" {$unitTag}><label for="unitTag">{t}Tag department as an independent administrative unit{/t}</label>
+{/render}
+ </td>
+ </tr>
+</table>
+
+
+{elseif $dep_type == "c"}
<!--////////////////////
// COUNTRY (c)
<td>
{render acl=$ouACL}
<input id="ou" name="ou" size=25 maxlength=60 value="{$ou}" title="{t}Name of subtree to create{/t}">
-{/render}
- </td>
- </tr>
- <tr>
- <td><LABEL for="c">{t}Name of department{/t}</LABEL>{$must}</td>
- <td>
-{render acl=$ouACL}
- <input id="c" name="c" size=25 maxlength=60 value="{$c}" title="{t}Name of country to create{/t}">
{/render}
</td>
</tr>