initial commit of file from CVS for e-smith-turba on Wed 12 Jul 09:11:40 BST 2023

This commit is contained in:
Brian Read
2023-07-12 09:11:40 +01:00
parent e4f24e34e7
commit 420341c17f
67 changed files with 3168 additions and 2 deletions

View File

@@ -0,0 +1,3 @@
#! /bin/sh
#test -f /var/lib/mysql/horde/turba_objects.frm && exit 0
exec mysql horde < /home/httpd/html/horde/smeserver/turba.sql

View File

@@ -0,0 +1,2 @@
#! /bin/sh
exec /etc/e-smith/events/actions/turba_upgrade

View File

@@ -0,0 +1,2 @@
#! /bin/sh
exec mysql < /home/httpd/html/horde/smeserver/turba_mysql_reset_addressbook_pref.sql

View File

@@ -0,0 +1,3 @@
#! /bin/sh
test -f /var/lib/mysql/horde/imp_addr.frm && exit 0
exec /etc/e-smith/events/actions/migrate-imp-to-turba

View File

@@ -0,0 +1,29 @@
{
my $status = $imp{status} || 'disabled';
if ($status eq 'enabled')
{
$OUT .= qq(
# IMP specific access configuration
<Directory /home/httpd/html/horde/turba/config>
order deny,allow
deny from all
</Directory>
<Directory /home/httpd/html/horde/turba/lib>
order deny,allow
deny from all
</Directory>
<Directory /home/httpd/html/horde/turba/locale>
order deny,allow
deny from all
</Directory>
<Directory /home/httpd/html/horde/turba/templates>
order deny,allow
deny from all
</Directory>
);
}
}

View File

@@ -0,0 +1,5 @@
{
my $TurbaMenu = $turba{MenuArray} || "enabled"; return "" unless ($TurbaMenu eq "enabled");
$apps{turba} = 1;
$OUT = '';
}

View File

@@ -0,0 +1,17 @@
// 210AppRegistryTurba
$this->applications['turba'] = array(
'fileroot' => dirname(__FILE__) . '/../turba',
'webroot' => $this->applications['horde']['webroot'] . '/turba',
'name' => _("Address Book"),
'status' => 'active',
'provides' => array('contacts', 'clients/getClientSource', 'clients/clientFields', 'clients/getClient', 'clients/getClients', 'clients/addClient', 'clients/updateClient', 'clients/deleteClient', 'clients/searchClients'),
'menu_parent' => 'organizing'
);
$this->applications['turba-menu'] = array(
'status' => 'block',
'app' => 'turba',
'blockname' => 'tree_menu',
'menu_parent' => 'turba',
);

View File

@@ -0,0 +1,611 @@
/**
* Turba Attributes File.
*
* This file contains examples of attributes that Turba understands, and their
* types. It may be safely edited by hand. Use attributes.php.dist as a
* reference.
*
* The syntax of this array is as follows:<pre>
* label - The text that the user will see attached to this
* field.
* type - One of the following:
* - spacer - header
* - description - html
* - number - int
* - intlist - text
* - longtext - countedtext
* - address - file
* - boolean - link
* - email - emailconfirm
* - password - passwordconfirm
* - enum - multienum
* - radio - set
* - date - time
* - monthyear - monthdayyear
* - colorpicker - sorter
* - creditcard - invalid
* - stringlist - addresslink (requires Horde-3.2)
* required - Boolean whether this field is mandatory.
* readonly - Boolean whether this field is editable.
* desc - Any help text attached to the field.
* time_object_label - The text to describe the time object category.
* Only valid for monthdayyear types and removing this
* from a monthdayyear type will hide it from the
* listTimeObjects api.
* params - Any other parameters that need to be passed to the
* field. For a documentation of available field
* paramaters see
* http://wiki.horde.org/Doc/Dev/FormTypes.
* </pre>
*
* $Horde: turba/config/attributes.php.dist,v 1.36.6.18 2008-11-12 06:29:26 wrobel Exp $
*/
/* Personal stuff. */
$attributes['name'] = array(
'label' => _("Name"),
'type' => 'text',
'required' => true,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['firstname'] = array(
'label' => _("First Name"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['lastname'] = array(
'label' => _("Last Name"),
'type' => 'text',
'required' => true,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['middlenames'] = array(
'label' => _("Middle Names"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['namePrefix'] = array(
'label' => _("Name Prefixes"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 32, 'maxlength' => 32)
);
$attributes['nameSuffix'] = array(
'label' => _("Name Suffixes"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 32, 'maxlength' => 32)
);
$attributes['alias'] = array(
'label' => _("Alias"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 32)
);
$attributes['nickname'] = array(
'label' => _("Nickname"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 32, 'maxlength' => 32)
);
$attributes['birthday'] = array(
'label' => _("Birthday"),
'type' => 'monthdayyear',
'required' => false,
'params' => array('start_year' => 1900, 'end_year' => null, 'picker' => true, 'format_in' => '%Y-%m-%d', 'format_out' => $GLOBALS['prefs']->getValue('date_format')),
'time_object_label' => _("Birthdays"),
);
$attributes['anniversary'] = array(
'label' => _("Anniversary"),
'type' => 'monthdayyear',
'params' => array('start_year' => 1900, 'end_year' => null, 'picker' => true, 'format_in' => '%Y-%m-%d', 'format_out' => $GLOBALS['prefs']->getValue('date_format')),
'required' => false,
'time_object_label' => _("Anniversaries"),
);
$attributes['spouse'] = array(
'label' => _("Spouse"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['children'] = array(
'label' => _("Children"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['photo'] = array(
'label' => _("Photo"),
'type' => 'image',
'required' => false,
'params' => array('show_upload' => true, 'show_keeporig' => true, 'max_filesize' => null),
);
$attributes['phototype'] = array(
'label' => _("Photo MIME Type"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
/* Locations, addresses. */
$attributes['homeAddress'] = array(
'label' => _("Home Address"),
'type' => 'address',
'required' => false,
'params' => array('rows' => 3, 'cols' => 40)
);
$attributes['homeStreet'] = array(
'label' => _("Home Street Address"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['homePOBox'] = array(
'label' => _("Home Post Office Box"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 10, 'maxlength' => 10)
);
$attributes['homeCity'] = array(
'label' => _("Home City"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['homeProvince'] = array(
'label' => _("Home State/Province"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['homePostalCode'] = array(
'label' => _("Home Postal Code"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 10, 'maxlength' => 10)
);
$attributes['homeCountry'] = array(
'label' => _("Home Country"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
/* If using Horde 3.2 or higher, you can display a drop down with a country
* list. */
// $attributes['homeCountry'] = array(
// 'label' => _("Home Country"),
// 'type' => 'country',
// 'required' => false,
// 'params' => array('prompt' => true)
// );
$attributes['workAddress'] = array(
'label' => _("Work Address"),
'type' => 'address',
'required' => false,
'params' => array('rows' => 3, 'cols' => 40)
);
$attributes['workStreet'] = array(
'label' => _("Work Street Address"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['workPOBox'] = array(
'label' => _("Work Post Office Box"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 10, 'maxlength' => 10)
);
$attributes['workCity'] = array(
'label' => _("Work City"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['workProvince'] = array(
'label' => _("Work State/Province"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['workPostalCode'] = array(
'label' => _("Work Postal Code"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 10, 'maxlength' => 10)
);
$attributes['workCountry'] = array(
'label' => _("Work Country"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
/* If using Horde 3.2 or higher, you can display a drop down with a country
* list. */
// $attributes['workCountry'] = array(
// 'label' => _("Work Country"),
// 'type' => 'country',
// 'required' => false,
// 'params' => array('prompt' => true)
// );
$attributes['companyAddress'] = array(
'label' => _("Company Address"),
'type' => 'address',
'required' => false,
'params' => array('rows' => 3, 'cols' => 40)
);
$attributes['timezone'] = array(
'label' => _("Time Zone"),
'type' => 'enum',
'params' => array('values' => $GLOBALS['tz'], 'prompt' => true),
'required' => false
);
/* Communication. */
$attributes['email'] = array(
'label' => _("Email"),
'type' => 'email',
'required' => false,
'params' => array('allow_multi' => true, 'strip_domain' => false, 'link_compose' => true)
);
$attributes['emails'] = array(
'label' => _("Emails"),
'type' => 'email',
'required' => false,
'params' => array('allow_multi' => true, 'strip_domain' => false, 'link_compose' => true)
);
$attributes['homePhone'] = array(
'label' => _("Home Phone"),
'type' => 'phone',
'required' => false
);
$attributes['workPhone'] = array(
'label' => _("Work Phone"),
'type' => 'phone',
'required' => false
);
$attributes['cellPhone'] = array(
'label' => _("Mobile Phone"),
'type' => 'cellphone',
'required' => false
);
$attributes['fax'] = array(
'label' => _("Fax"),
'type' => 'phone',
'required' => false
);
$attributes['pager'] = array(
'label' => _("Pager"),
'type' => 'phone',
'required' => false
);
/* Job, company, organization. */
$attributes['title'] = array(
'label' => _("Job Title"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['role'] = array(
'label' => _("Occupation"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['businessCategory'] = array(
'label' => _("Business Category"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['company'] = array(
'label' => _("Company"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['department'] = array(
'label' => _("Department"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['office'] = array(
'label' => _("Office"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['logo'] = array(
'label' => _("Logo"),
'type' => 'image',
'required' => false,
'params' => array('show_upload' => true, 'show_keeporig' => true, 'max_filesize' => null),
);
$attributes['logotype'] = array(
'label' => _("Logo MIME Type"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
/* Other */
$attributes['notes'] = array(
'label' => _("Notes"),
'type' => 'longtext',
'required' => false,
'params' => array('rows' => 3, 'cols' => 40)
);
$attributes['website'] = array(
'label' => _("Website URL"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['freebusyUrl'] = array(
'label' => _("Freebusy URL"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['pgpPublicKey'] = array(
'label' => _("PGP Public Key"),
'type' => 'longtext',
'required' => false,
'params' => array('rows' => 3, 'cols' => 40)
);
$attributes['smimePublicKey'] = array(
'label' => _("S/MIME Public Certificate"),
'type' => 'longtext',
'required' => false,
'params' => array('rows' => 3, 'cols' => 40)
);
/* If using Horde 3.3 or later, you can enable the following attributes to
* enable pretty rendering of PGP and S/MIME keys. */
// $attributes['pgpPublicKey'] = array(
// 'label' => _("PGP Public Key"),
// 'type' => 'pgp',
// 'required' => false,
// 'params' => array('gpg' => '/usr/bin/gpg', 'temp_dir' => Horde::getTempDir(), 'rows' => 3, 'cols' => 40)
// );
// $attributes['smimePublicKey'] = array(
// 'label' => _("S/MIME Public Certificate"),
// 'type' => 'smime',
// 'required' => false,
// 'params' => array('temp_dir' => Horde::getTempDir(), 'rows' => 3, 'cols' => 40)
// );
/* This attribute uses Horde's categories and is an example how to use an enum
* field. Don't forget to add a 'map' entry to config/sources.php if you want
* to use this attribute. */
require_once 'Horde/Prefs/CategoryManager.php';
require_once 'Horde/Array.php';
$cManager = new Prefs_CategoryManager();
$attributes['category'] = array(
'label' => _("Category"),
'type' => 'enum',
'params' => array(
'values' => array_merge(array('' => _("Unfiled")), Horde_Array::valuesToKeys($cManager->get())),
'prompt' => false),
'required' => false
);
/* If using Horde 3.2 or later, you can use the following category attribute
* instead which shows category colors and allows to add new categories. */
// $attributes['category'] = array(
// 'label' => _("Category"),
// 'type' => 'category',
// 'params' => array(),
// 'required' => false
// );
/* Additional attributes supported by Kolab */
$attributes['kolabHomeServer'] = array(
'label' => _("Kolab Home Server"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['initials'] = array(
'label' => _("Initials"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['instantMessenger'] = array(
'label' => _("Instant Messenger"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['manager'] = array(
'label' => _("Manager"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['assistant'] = array(
'label' => _("Assistant"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['gender'] = array(
'label' => _("Gender"),
'type' => 'enum',
'required' => false,
'params' => array('values' => array(_("male"), _("female")), 'prompt' => true),
);
$attributes['language'] = array(
'label' => _("Language"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['latitude'] = array(
'label' => _("Latitude"),
'type' => 'number',
'required' => false,
);
$attributes['longitude'] = array(
'label' => _("Longitude"),
'type' => 'number',
'required' => false,
);
/* Additional attributes supported by some SyncML clients */
$attributes['workEmail'] = array(
'label' => _("Work Email"),
'type' => 'email',
'required' => false,
'params' => array('allow_multi' => false, 'strip_domain' => false, 'link_compose' => true)
);
$attributes['homeEmail'] = array(
'label' => _("Home Email"),
'type' => 'email',
'required' => false,
'params' => array('allow_multi' => false, 'strip_domain' => false, 'link_compose' => true)
);
$attributes['phone'] = array(
'label' => _("Common Phone"),
'type' => 'phone',
'required' => false
);
$attributes['workFax'] = array(
'label' => _("Work Fax"),
'type' => 'phone',
'required' => false
);
$attributes['homeFax'] = array(
'label' => _("Home Fax"),
'type' => 'phone',
'required' => false
);
$attributes['workCellPhone'] = array(
'label' => _("Work Mobile Phone"),
'type' => 'cellphone',
'required' => false
);
$attributes['homeCellPhone'] = array(
'label' => _("Home Mobile Phone"),
'type' => 'cellphone',
'required' => false
);
$attributes['videoCall'] = array(
'label' => _("Common Video Call"),
'type' => 'phone',
'required' => false
);
$attributes['workVideoCall'] = array(
'label' => _("Work Video Call"),
'type' => 'phone',
'required' => false
);
$attributes['homeVideoCall'] = array(
'label' => _("Home Video Call"),
'type' => 'phone',
'required' => false
);
$attributes['voip'] = array(
'label' => _("VoIP"),
'type' => 'phone',
'required' => false
);
$attributes['sip'] = array(
'label' => _("SIP"),
'type' => 'email',
'required' => false,
'params' => array('allow_multi' => true, 'strip_domain' => false, 'link_compose' => true)
);
$attributes['ptt'] = array(
'label' => _("PTT"),
'type' => 'phone',
'required' => false
);
$attributes['commonExtended'] = array(
'label' => _("Common Address Extended"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['commonStreet'] = array(
'label' => _("Common Street"),
'type' => 'address',
'required' => false,
'params' => array('rows' => 3, 'cols' => 40)
);
$attributes['commonPOBox'] = array(
'label' => _("Common Post Office Box"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 10, 'maxlength' => 10)
);
$attributes['commonCity'] = array(
'label' => _("Common City"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['commonProvince'] = array(
'label' => _("Common State/Province"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['commonPostalCode'] = array(
'label' => _("Common Postal Code"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 10, 'maxlength' => 10)
);
$attributes['commonCountry'] = array(
'label' => _("Common Country"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['workWebsite'] = array(
'label' => _("Work Website URL"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['workExtended'] = array(
'label' => _("Work Address Extended"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['workLatitude'] = array(
'label' => _("Work Latitude"),
'type' => 'number',
'required' => false,
);
$attributes['workLongitude'] = array(
'label' => _("Work Longitude"),
'type' => 'number',
'required' => false,
);
$attributes['homeWebsite'] = array(
'label' => _("Home Website URL"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['homeExtended'] = array(
'label' => _("Home Address Extended"),
'type' => 'text',
'required' => false,
'params' => array('regex' => '', 'size' => 40, 'maxlength' => 255)
);
$attributes['homeLatitude'] = array(
'label' => _("Home Latitude"),
'type' => 'number',
'required' => false,
);
$attributes['homeLongitude'] = array(
'label' => _("Home Longitude"),
'type' => 'number',
'required' => false,
);

View File

@@ -0,0 +1,13 @@
/* SME Server attributes */
$attributes['groupdescription'] = array(
'label' => _("Group Description"),
'type' => 'text',
'required' => false
);
$attributes['groupmembers'] = array(
'label' => _("Group Members"),
'type' => 'text',
'required' => false
);

View File

@@ -0,0 +1,3 @@
/* CONFIG START. DO NOT CHANGE ANYTHING IN OR AFTER THIS LINE. */
// $Horde: turba/config/conf.xml,v 1.6.2.6 2008/06/25 15:52:54 jan Exp $

View File

@@ -0,0 +1,7 @@
// 100Conf
$conf['menu']['import_export'] = true;
$conf['client']['addressbook'] = 'localsql';
$conf['shares']['source'] = 'localsql';
$conf['comments']['allow'] = true;
$conf['documents']['type'] = 'horde';

View File

@@ -0,0 +1,3 @@
// 120MenuSettings
include '/home/httpd/html/horde/conf.menu.apps.php';

View File

@@ -0,0 +1,2 @@
// 999Footer
/* CONFIG END. DO NOT CHANGE ANYTHING IN OR BEFORE THIS LINE. */

View File

@@ -0,0 +1,7 @@
//00header
/**
* $Horde: turba/config/prefs.php.dist,v 1.28.10.10 2008/07/10 22:52:41 jan Exp $
*
* See horde/config/prefs.php for documentation on the structure of this file.
*/

View File

@@ -0,0 +1,8 @@
//100displayoptions
$prefGroups['addressbooks'] = array(
'column' => _("Display Options"),
'label' => _("Address Books"),
'desc' => _("Choose which address books to use."),
'members' => array('default_dir', 'addressbookselect', 'sync_books'),
);

View File

@@ -0,0 +1,8 @@
//110columnoptions
$prefGroups['columns'] = array(
'column' => _("Display Options"),
'label' => _("Column Options"),
'desc' => _("Select which fields to display in the address lists."),
'members' => array('columnselect'),
);

View File

@@ -0,0 +1,8 @@
//120display
$prefGroups['display'] = array(
'column' => _("Display Options"),
'label' => _("Display"),
'desc' => _("Select view to display by default and paging options."),
'members' => array('initial_page', 'maxpage', 'perpage'),
);

View File

@@ -0,0 +1,8 @@
//130format
$prefGroups['format'] = array(
'column' => _("Display Options"),
'label' => _("Name Format"),
'desc' => _("Select which format to display names."),
'members' => array('name_format'),
);

View File

@@ -0,0 +1,7 @@
//160addressbookselect
// Address Book selection widget
$_prefs['addressbookselect'] = array(
'locked' => false,
'type' => 'special',
);

View File

@@ -0,0 +1,14 @@
//170addressbooks
// Address books to be displayed in the address book selection widget
// and in the Browse menu item. The address book name is stored using
// the source key from sources.php (e.g. "localsql"). Separate
// entries with "\n" , e. g. 'value' => "localsql\nlocalldap" (the
// double quotes are REQUIRED). If 'value' is empty (''), all address
// books that the user has permissions to will be listed.
$_prefs['addressbooks'] = array(
'value' => '',
'locked' => false,
'shared' => false,
'type' => 'implicit',
);

View File

@@ -0,0 +1,10 @@
//180syncbooks
// Address books use for synchronization
$_prefs['sync_books'] = array(
'value' => 'a:0:\{\}',
'locked' => false,
'shared' => false,
'type' => 'multienum',
'desc' => _("Select the address books that should be used for synchronization with external devices:"),
);

View File

@@ -0,0 +1,7 @@
//185columnselect
// columns selection widget
$_prefs['columnselect'] = array(
'locked' => false,
'type' => 'special',
);

View File

@@ -0,0 +1,13 @@
//190columns
// Columns to be displayed in Browse and Search results, with entries
// for the columns displayed for each address book. Separate address
// book stanzas with \n and columns with \t. The "name" column is
// currently always displayed first and so cannot be modified here.
// Double quotes MUST be used as in the example.
$_prefs['columns'] = array(
'value' => "netcenter\temail\nverisign\temail\nlocalsql\temail",
'locked' => false,
'shared' => false,
'type' => 'implicit',
);

View File

@@ -0,0 +1,10 @@
//200sortorder
// user preferred sorting column
// serialized array of hashes containing 'field' and 'ascending' keys
$_prefs['sortorder'] = array(
'value' => 'a:1:\{i:0;a:2:\{s:5:"field";s:8:"lastname";s:9:"ascending";b:1;\}\}',
'locked' => false,
'shared' => false,
'type' => 'implicit',
);

View File

@@ -0,0 +1,10 @@
//220maxpage
// number of maximum pages and items per page
$_prefs['maxpage'] = array(
'value' => 10,
'locked' => false,
'shared' => false,
'type' => 'number',
'desc' => _("Maximum number of pages"),
);

View File

@@ -0,0 +1,9 @@
//230perpage
$_prefs['perpage'] = array(
'value' => 20,
'locked' => false,
'shared' => false,
'type' => 'number',
'desc' => _("Number of items per page"),
);

View File

@@ -0,0 +1,12 @@
//240initialpage
// the page to display. Either 'browse.php' or 'search.php'
$_prefs['initial_page'] = array(
'value' => 'search.php',
'locked' => false,
'shared' => false,
'type' => 'enum',
'desc' => _("View to display by default:"),
'enum' => array('browse.php' => _("Address Book Listing"),
'search.php' => _("Search")),
);

View File

@@ -0,0 +1,13 @@
//250nameformat
// the format to display names. Either 'last_first' or 'first_last'
$_prefs['name_format'] = array(
'value' => 'last_first',
'locked' => false,
'shared' => false,
'type' => 'enum',
'desc' => _("Select the format used to display names:"),
'enum' => array('last_first' => _("\"Lastname, Firstname\" (ie. Doe, John)"),
'first_last' => _("\"Firstname Lastname\" (ie. John Doe)"),
'none' => _("no formatting")),
);

View File

@@ -0,0 +1,11 @@
//260defaultdir
// Default directory
$_prefs['default_dir'] = array(
//'value' => '',
'value' => 'localsql',
'locked' => false,
'shared' => false,
'type' => 'select',
'desc' => _("This will be the default address book when adding or importing contacts."),
);

View File

@@ -0,0 +1,9 @@
//265prefbooks
// preference for holding any preferences-based addressbooks.
$_prefs['prefbooks'] = array(
'value' => '',
'locked' => false,
'shared' => false,
'type' => 'implicit',
);

View File

@@ -0,0 +1,9 @@
//270turbamaintenancetasks
// Used to keep track of which turba maintenance tasks have been run.
$_prefs['turba_maintenance_tasks'] = array(
'value' => 'a:0:\{\}',
'locked' => false,
'shared' => false,
'type' => 'implicit'
);

View File

@@ -0,0 +1,10 @@
//275owncontact
// Personal contact.
$_prefs['own_contact'] = array(
// The format is 'source_name;contact_id'.
'value' => '',
'locked' => false,
'shared' => false,
'type' => 'implicit'
);

View File

@@ -0,0 +1,6 @@
{
use esmith::util;
$basedn = esmith::util::ldapBase ($DomainName);
$OUT = '';
}

View File

@@ -0,0 +1,4 @@
//00header
/**
* $Horde: turba/config/sources.php.dist,v 1.97.6.41 2009/08/05 21:06:10 jan Exp $
*/

View File

@@ -0,0 +1,132 @@
//40LocalSQL
/**
* A local address book in an SQL database. This implements a private
* per-user address book. Sharing of this source with other users may be
* accomplished by enabling Horde_Share for this source by setting
* 'use_shares' => true.
*
* Be sure to create a turba_objects table in your Horde database from the
* schema in turba/scripts/db/turba.sql if you use this source.
*/
$cfgSources['localsql'] = array(
'title' => _("My Address Book"),
'type' => 'sql',
// The default connection details are pulled from the Horde-wide SQL
// connection configuration.
'params' => array_merge($GLOBALS['conf']['sql'], array('table' => 'turba_objects')),
// Using two tables as datasource.
// 'params' => array_merge($GLOBALS['conf']['sql'],
// array('table' => 'leaddetails LEFT JOIN leadaddress ON leaddetails.leadid = leadaddress.leadaddressid',
// 'filter' => 'leaddetails.converted = 0')),
'map' => array(
'__key' => 'object_id',
'__owner' => 'owner_id',
'__type' => 'object_type',
'__members' => 'object_members',
'__uid' => 'object_uid',
'firstname' => 'object_firstname',
'lastname' => 'object_lastname',
'middlenames' => 'object_middlenames',
'namePrefix' => 'object_nameprefix',
'nameSuffix' => 'object_namesuffix',
'name' => array('fields' => array('namePrefix', 'firstname',
'middlenames', 'lastname',
'nameSuffix'),
'format' => '%s %s %s %s %s',
'parse' => array(
array('fields' => array('firstname', 'middlenames',
'lastname'),
'format' => '%s %s %s'),
array('fields' => array('firstname', 'lastname'),
'format' => '%s %s'))),
// This is a shorter version of a "name" composite field which only
// consists of the first name and last name.
// 'name' => array('fields' => array('firstname', 'lastname'),
// 'format' => '%s %s'),
'alias' => 'object_alias',
'birthday' => 'object_bday',
'spouse' => 'object_spouse',
'anniversary' => 'object_anniversary',
'children' => 'object_children',
// The photo field requires at least Horde 3.3 and a matching type
// field.
'photo' => 'object_photo',
'phototype' => 'object_phototype',
'homeStreet' => 'object_homestreet',
'homePOBox' => 'object_homepob',
'homeCity' => 'object_homecity',
'homeProvince' => 'object_homeprovince',
'homePostalCode' => 'object_homepostalcode',
'homeCountry' => 'object_homecountry',
// This is an example composite field for addresses, so you can display
// the various map links. If you use this, be sure to add 'homeAddress'
// to the 'tabs' parameter below.
'homeAddress' => array('fields' => array('homeStreet', 'homeCity',
'homeProvince',
'homePostalCode'),
'format' => "%s \n %s, %s %s"),
'workStreet' => 'object_workstreet',
'workPOBox' => 'object_workpob',
'workCity' => 'object_workcity',
'workProvince' => 'object_workprovince',
'workPostalCode' => 'object_workpostalcode',
'workCountry' => 'object_workcountry',
'workAddress' => array('fields' => array('workStreet', 'workCity',
'workProvince',
'workPostalCode'),
'format' => "%s \n %s, %s %s"),
'timezone' => 'object_tz',
'email' => 'object_email',
'homePhone' => 'object_homephone',
'workPhone' => 'object_workphone',
'cellPhone' => 'object_cellphone',
'fax' => 'object_fax',
'pager' => 'object_pager',
'title' => 'object_title',
'role' => 'object_role',
'company' => 'object_company',
// The logo field requires at least Horde 3.3 and a matching type
// field.
'logo' => 'object_logo',
'logotype' => 'object_logotype',
'category' => 'object_category',
'notes' => 'object_notes',
'website' => 'object_url',
'freebusyUrl' => 'object_freebusyurl',
'pgpPublicKey' => 'object_pgppublickey',
'smimePublicKey' => 'object_smimepublickey',
),
'tabs' => array(
_("Personal") => array('firstname', 'lastname', 'middlenames',
'namePrefix', 'nameSuffix', 'name', 'alias',
'birthday', 'spouse', 'anniversary', 'children' , 'photo'),
_("Location") => array('homeStreet', 'homePOBox', 'homeCity',
'homeProvince', 'homePostalCode', 'homeCountry',
'homeAddress', 'workStreet', 'workPOBox', 'workCity',
'workProvince', 'workPostalCode', 'workCountry', 'workAddress',
'timezone'),
_("Communications") => array('email', 'homePhone', 'workPhone',
'cellPhone', 'fax', 'pager'),
_("Organization") => array('title', 'role', 'company', 'logo'),
_("Other") => array('category', 'notes', 'website', 'freebusyUrl',
'pgpPublicKey', 'smimePublicKey'),
),
'search' => array(
'name',
'email'
),
'strict' => array(
'object_id',
'owner_id',
'object_type',
),
'export' => true,
'browse' => true,
{
my $sab = ($horde{SharedAddressBooks} || 'disabled') eq 'enabled' ? 'true' : 'false';
$OUT = " 'use_shares' => $sab,";
}
'list_name_field' => 'lastname',
'alternative_name' => 'company',
);

View File

@@ -0,0 +1,136 @@
//50LocalLDAP
/**
* A local address book in an LDAP directory. This implements a public
* (shared) address book.
*
* To store distribution lists in the LDAP directory, you'll need to include
* horde/scripts/ldap/horde.schema in your LDAP configuration.
*
* To store freebusy information in the LDAP directory, you'll need to include
* turba/scripts/ldap/rfc2739.schema in your LDAP configuration.
*/
$cfgSources['localldap'] = array(
'title' => _("Local LDAP"),
'type' => 'ldap',
'params' => array(
'server' => 'localhost',
'port' => 389,
'tls' => false,
{
$OUT .= qq( 'root' => '$basedn',);
}
// 'bind_dn' => 'cn=admin,ou=users,dc=example,dc=com',
// // For Active Directory:
// // 'bind_dn' => 'username@example.com',
// 'bind_password' => '********',
'sizelimit' => 200,
// // For Active Directory:
// // 'sizelimit' => 0,
'dn' => array('cn'),
'objectclass' => array('top',
'person',
'organizationalPerson',
{
if (($horde{freebusy} || "disabled") eq "enabled") {
$OUT =<<HERE;
'inetOrgPerson',
'calEntry'),
HERE
} else {
$OUT =<<HERE;
'inetOrgPerson'),
HERE
}
}
// Add 'turbaContact' to this array if using
// 'turbaType' attribute below, and 'calEntry'
// // if using 'freebusyUrl'.
// // For Active Directory:
// // 'objectclass' => array('organizationalPerson',
// // 'user',
// // 'group',
// // 'contact'),
'scope' => 'sub',
// // For Active Directory:
// // 'scope' => 'sub',
'charset' => 'UTF-8',
// // Consult the LDAP schema to verify that all required attributes for
// // an entry are set and add them if needed.
'checkrequired' => false,
// // Value used to fill in missing required attributes.
'checkrequired_string' => ' ',
// // Check LDAP schema for valid syntax. If this is false an address
// // field is assumed to have postalAddress syntax; otherwise the schema
// // is consulted for the syntax to use.
// 'checksyntax' => false,
'version' => 3,
'filter' => '&(!(mail=admin@{$DomainName}))',
//
// // For Active Directory you probably want to also set the following
// // parameters:
// // 'deref' => LDAP_DEREF_ALWAYS,
// // 'filter' => '&(SAMAccountName=*)(mail=*)',
// // 'referrals' => 0,
),
'map' => array(
'__key' => 'dn',
// // Remove this mapping if using Active Directory server:
// '__uid' => 'uid',
'__uid' => 'uid',
// // From horde.schema. Make sure you have 'turbaContact' objectClass
// // included above:
// '__type' => 'turbaType',
// '__members' => 'turbaMembers',
//
'name' => 'cn',
'email' => 'mail',
'homePhone' => 'homephone',
'workPhone' => 'telephonenumber',
'cellPhone' => 'mobiletelephonenumber',
'homeAddress' => 'street',
//
// // From rfc2739.schema:
{
if (($horde{freebusy} || "disabled") eq "enabled") {
$OUT =<<HERE;
'freebusyUrl\' => 'calFBURL',
HERE
} else {
$OUT =<<HERE;
#freebusy is currently not enabled. To enable - config setprop horde freebusy enabled
HERE
}
}
//
// // For Active Directory servers:
// // 'name' => 'displayname',
// // 'title' => 'title',
// // 'cellPhone' => 'mobile',
// // 'department' => 'department',
// // 'company' => 'company',
),
'search' => array(
'name',
'email',
'homePhone',
'workPhone',
'cellPhone',
'homeAddress'
),
'strict' => array(
'dn',
),
'approximate' => array(
'cn',
),
// // For Active Directory servers:
// // 'approximate' => array(
// // 'displayname',
// // 'samaccountname',
// // ),
'export' => true,
'browse' => true,
);

View File

@@ -0,0 +1,53 @@
//60LocalLDAPGroups
/**
* A local address book in an LDAP directory. This implements a public
* (shared) address book.
*
* To store distribution lists in the LDAP directory, you'll need to include
* horde/scripts/ldap/horde.schema in your LDAP configuration.
*
* To store freebusy information in the LDAP directory, you'll need to include
* turba/scripts/ldap/rfc2739.schema in your LDAP configuration.
*/
$cfgSources['localldapgroups'] = array(
'title' => _("Local LDAP Groups"),
'type' => 'ldap',
'params' => array(
'server' => 'localhost',
'port' => 389,
'tls' => false,
{
$OUT .= qq( 'root' => '$basedn',);
}
'sizelimit' => 200,
'dn' => array('cn'),
'objectclass' => array('posixGroup'),
'scope' => 'sub',
'charset' => 'UTF-8',
'checkrequired' => false,
'checkrequired_string' => ' ',
'version' => 3,
),
'map' => array(
'__key' => 'dn',
'__uid' => 'uid',
'name' => 'cn',
'email' => 'mail',
'groupdescription' => 'description',
'groupmembers' => 'memberUid',
),
'search' => array(
'displayName',
'groupdescription',
'groupmembers',
),
'strict' => array(
'dn',
),
'approximate' => array(
'cn',
),
'export' => true,
'browse' => true,
);