summaryrefslogtreecommitdiff
path: root/doc/sample-insert-user_types.php
diff options
context:
space:
mode:
authorJeroen van Meeuwen (Kolab Systems) <vanmeeuwen@kolabsys.com>2013-05-29 10:47:19 (GMT)
committerJeroen van Meeuwen (Kolab Systems) <vanmeeuwen@kolabsys.com>2013-05-29 10:47:42 (GMT)
commit4fbb0d9354d69e18b4677e46d93f75c986ea5a45 (patch)
treead95561fccae46d0b99ed1d907c8af9dbcee3e81 /doc/sample-insert-user_types.php
parente2054aa50bd5ca07b6cc95e045d9178862ca511f (diff)
downloadkolab-wap-4fbb0d9354d69e18b4677e46d93f75c986ea5a45.tar.gz
Add a contact entry to the default list of user types
Diffstat (limited to 'doc/sample-insert-user_types.php')
-rw-r--r--doc/sample-insert-user_types.php91
1 files changed, 91 insertions, 0 deletions
diff --git a/doc/sample-insert-user_types.php b/doc/sample-insert-user_types.php
index 8932744..be2d37d 100644
--- a/doc/sample-insert-user_types.php
+++ b/doc/sample-insert-user_types.php
@@ -390,4 +390,95 @@
"VALUES ('kolab_posix','Mail-enabled POSIX User', 'A mail-enabled POSIX User'," .
"'" . json_encode($attributes) . "')");
+ $attributes = Array(
+ "auto_form_fields" => Array(
+ "cn" => Array(
+ "data" => Array(
+ "givenname",
+ "sn",
+ ),
+ ),
+ "displayname" => Array(
+ "data" => Array(
+ "givenname",
+ "sn",
+ ),
+ ),
+ "uid" => Array(
+ "data" => Array(
+ "givenname",
+ "preferredlanguage",
+ "sn",
+ ),
+ ),
+ "userpassword" => Array(
+ "optional" => true,
+ ),
+ ),
+ "form_fields" => Array(
+ "cn" => Array(
+ "optional" => true,
+ ),
+ "displayname" => Array(
+ "optional" => true,
+ ),
+ "givenname" => Array(),
+ "initials" => Array(
+ "optional" => true,
+ ),
+ "l" => Array(
+ "optional" => true,
+ ),
+ "mail" => Array(
+ "type" => "list",
+ "optional" => true,
+ ),
+ "mailalternateaddress" => Array(
+ "type" => "list",
+ "optional" => true,
+ ),
+ "mobile" => Array(
+ "optional" => true,
+ ),
+ "o" => Array(
+ "optional" => true,
+ ),
+ "ou" => Array(
+ "type" => "select",
+ ),
+ "pager" => Array(
+ "optional" => true,
+ ),
+ "postalcode" => Array(
+ "optional" => true,
+ ),
+ "sn" => Array(),
+ "street" => Array(
+ "optional" => true,
+ ),
+ "telephonenumber" => Array(
+ "optional" => true,
+ ),
+ "title" => Array(
+ "optional" => true,
+ ),
+ "userpassword" => Array(
+ "optional" => true,
+ ),
+ ),
+ "fields" => Array(
+ "objectclass" => Array(
+ "top",
+ "inetorgperson",
+ "mailrecipient",
+ "organizationalperson",
+ "person",
+ ),
+ ),
+ );
+
+ $result = $db->query("INSERT INTO `user_types` (`key`, `name`, `description`, `attributes`) " .
+ "VALUES ('contact','Contact', 'A global address book contact'," .
+ "'" . json_encode($attributes) . "')");
+
?>