Code

Allow to edit templates.
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Mon, 26 Oct 2009 11:19:22 +0000 (11:19 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Mon, 26 Oct 2009 11:19:22 +0000 (11:19 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@14635 594d385d-05f5-0310-b6e9-bd551577e9d8

gosa-core/plugins/admin/users/class_userManagement.inc
gosa-core/plugins/admin/users/user-list.xml

index f380690f7d6d3813dd175b5c0a4f06ae8b7de68e..318919df7d78388621caf54594eddbe8fd487d9f 100644 (file)
@@ -57,6 +57,14 @@ class userManagement extends management
     $this->registerAction("copy",   "copyPasteHandler");
     $this->registerAction("cut",    "copyPasteHandler");
     $this->registerAction("paste",  "copyPasteHandler");
+
+    $this->registerAction("new_template", "newTemplate");
+  }
+
+  function newTemplate($action,$entry)
+  {
+    $this->newEntry();
+    $this->tabObject->set_template_mode ();
   }
 } 
 // vim:tabstop=2:expandtab:shiftwidth=2:filetype=php:syntax:ruler:
index 5111f87bb63636c58180d35c945596d8d7672a35..c7d5423a640aa8cc4e858d1455ba3bb717f39b30 100644 (file)
     <defaultSortColumn>1</defaultSortColumn>
 
     <objectType>
-      <label>Users</label>
-      <objectClass>person</objectClass>
+      <label>Template</label>
+      <objectClass>gosaUserTemplate</objectClass>
+      <category>users</category>
+      <class>user</class>
+      <image>plugins/users/images/select_template.png</image>
+    </objectType>
+
+    <objectType>
+      <label>User</label>
+      <objectClass>gosaAccount</objectClass>
       <category>users</category>
       <class>user</class>
       <image>plugins/users/images/select_user.png</image>
       <label>New person</label>
     </action>
 
+    <action>
+      <name>new_template</name>
+      <type>entry</type>
+      <image>plugins/users/images/select_template.png</image>
+      <label>New template</label>
+    </action>
+
     <action>
       <type>separator</type>
     </action>
       <type>copypaste</type>
     </action>
 
+    <action>
+      <type>separator</type>
+    </action>
+
+    <action>
+      <name>templatize</name>
+      <type>entry</type>
+      <image>plugins/users/images/wizard.png</image>
+      <label>Apply template</label>
+    </action>
+
     <action>
       <type>exporter</type>
     </action>