From 4a5c8e92a390dba483a9ff58d6b7a3005014f0b6 Mon Sep 17 00:00:00 2001 From: "Jeroen van Meeuwen (Kolab Systems)" Date: Thu, 3 May 2012 13:23:58 +0100 Subject: Add Roundcube templates --- share/Makefile.am | 18 ++ share/templates/roundcubemail/acl.inc.php.tpl | 8 + share/templates/roundcubemail/calendar.inc.php.tpl | 10 + .../roundcubemail/compose_addressbook.inc.php.tpl | 4 + share/templates/roundcubemail/db.inc.php.tpl | 25 ++ share/templates/roundcubemail/kolab.inc.php.tpl | 17 ++ .../templates/roundcubemail/kolab_auth.inc.php.tpl | 66 +++++ .../roundcubemail/kolab_folders.inc.php.tpl | 14 ++ share/templates/roundcubemail/main.inc.php.tpl | 269 +++++++++++++++++++++ .../roundcubemail/managesieve.inc.php.tpl | 13 + share/templates/roundcubemail/mimetypes.php.tpl | 49 ++++ share/templates/roundcubemail/owncloud.inc.php.tpl | 4 + share/templates/roundcubemail/password.inc.php.tpl | 151 ++++++++++++ .../roundcubemail/recipient_to_contact.inc.php.tpl | 4 + share/templates/roundcubemail/terms.html.tpl | 10 + share/templates/roundcubemail/terms.inc.php.tpl | 18 ++ 16 files changed, 680 insertions(+) create mode 100644 share/Makefile.am create mode 100644 share/templates/roundcubemail/acl.inc.php.tpl create mode 100644 share/templates/roundcubemail/calendar.inc.php.tpl create mode 100644 share/templates/roundcubemail/compose_addressbook.inc.php.tpl create mode 100644 share/templates/roundcubemail/db.inc.php.tpl create mode 100644 share/templates/roundcubemail/kolab.inc.php.tpl create mode 100644 share/templates/roundcubemail/kolab_auth.inc.php.tpl create mode 100644 share/templates/roundcubemail/kolab_folders.inc.php.tpl create mode 100644 share/templates/roundcubemail/main.inc.php.tpl create mode 100644 share/templates/roundcubemail/managesieve.inc.php.tpl create mode 100644 share/templates/roundcubemail/mimetypes.php.tpl create mode 100644 share/templates/roundcubemail/owncloud.inc.php.tpl create mode 100644 share/templates/roundcubemail/password.inc.php.tpl create mode 100644 share/templates/roundcubemail/recipient_to_contact.inc.php.tpl create mode 100644 share/templates/roundcubemail/terms.html.tpl create mode 100644 share/templates/roundcubemail/terms.inc.php.tpl (limited to 'share') diff --git a/share/Makefile.am b/share/Makefile.am new file mode 100644 index 0000000..047b5c2 --- /dev/null +++ b/share/Makefile.am @@ -0,0 +1,18 @@ +templatedir = $(datadir)/kolab/templates + +template_DATA = \ + $(wildcard templates/*.tpl) + +rctemplatedir = $(datadir)/kolab/templates/roundcubemail +rctemplate_DATA = \ + $(wildcard templates/roundcubemail/*.tpl) + +EXTRA_DIST = \ + $(template_DATA) \ + $(rctemplate_DATA) + +install-exec-local: + mkdir -p \ + $(DESTDIR)/$(sysconfdir)/kolab/templates \ + $(DESTDIR)/$(sysconfdir)/kolab/templates/roundcubemail + diff --git a/share/templates/roundcubemail/acl.inc.php.tpl b/share/templates/roundcubemail/acl.inc.php.tpl new file mode 100644 index 0000000..e056660 --- /dev/null +++ b/share/templates/roundcubemail/acl.inc.php.tpl @@ -0,0 +1,8 @@ + diff --git a/share/templates/roundcubemail/calendar.inc.php.tpl b/share/templates/roundcubemail/calendar.inc.php.tpl new file mode 100644 index 0000000..bc871ce --- /dev/null +++ b/share/templates/roundcubemail/calendar.inc.php.tpl @@ -0,0 +1,10 @@ + diff --git a/share/templates/roundcubemail/compose_addressbook.inc.php.tpl b/share/templates/roundcubemail/compose_addressbook.inc.php.tpl new file mode 100644 index 0000000..31702ac --- /dev/null +++ b/share/templates/roundcubemail/compose_addressbook.inc.php.tpl @@ -0,0 +1,4 @@ + diff --git a/share/templates/roundcubemail/db.inc.php.tpl b/share/templates/roundcubemail/db.inc.php.tpl new file mode 100644 index 0000000..8b8db48 --- /dev/null +++ b/share/templates/roundcubemail/db.inc.php.tpl @@ -0,0 +1,25 @@ + diff --git a/share/templates/roundcubemail/kolab.inc.php.tpl b/share/templates/roundcubemail/kolab.inc.php.tpl new file mode 100644 index 0000000..c7f81a6 --- /dev/null +++ b/share/templates/roundcubemail/kolab.inc.php.tpl @@ -0,0 +1,17 @@ + 'personal', 'name' => '', 'delimiter' => '/'), + array('type' => 'other', 'name' => 'Other Users', 'delimiter' => '/'), + array('type' => 'shared', 'name' => 'Shared Folders', 'delimiter' => '/'), +); + +?> diff --git a/share/templates/roundcubemail/kolab_auth.inc.php.tpl b/share/templates/roundcubemail/kolab_auth.inc.php.tpl new file mode 100644 index 0000000..41e0bc8 --- /dev/null +++ b/share/templates/roundcubemail/kolab_auth.inc.php.tpl @@ -0,0 +1,66 @@ + 'Kolab Auth', + 'hosts' => Array('localhost'), + 'port' => 389, + 'use_tls' => false, + 'user_specific' => false, + 'base_dn' => '$ldap_user_base_dn', + 'bind_dn' => '$ldap_service_bind_dn', + 'bind_pass' => '$ldap_service_bind_pw', + 'writable' => false, + 'ldap_version' => 3, // using LDAPv3 + 'fieldmap' => Array( + 'name' => 'displayname', + 'email' => 'mail', + 'email:alias' => 'alias', + 'role' => 'nsroledn', + ), + 'sort' => 'displayname', + 'scope' => 'sub', + 'filter' => '(objectClass=*)', + 'fuzzy_search' => true, + 'sizelimit' => '0', + 'timelimit' => '0', + 'groups' => Array( + 'base_dn' => '$ldap_group_base_dn', + 'filter' => '$ldap_group_filter', + 'object_classes' => Array('top', 'groupOfUniqueNames'), + 'member_attr' => 'uniqueMember', + ), +); + + +// This will overwrite defined filter +\$rcmail_config['kolab_auth_filter'] = '(&' . '$ldap_user_filter' . '(|(uid=%u)(mail=%fu)(alias=%fu)))'; + +// Use this fields (from fieldmap configuration) to get authentication ID +\$rcmail_config['kolab_auth_login'] = 'email'; + +// Use this fields (from fieldmap configuration) for default identity +\$rcmail_config['kolab_auth_name'] = 'name'; +\$rcmail_config['kolab_auth_alias'] = 'alias'; +\$rcmail_config['kolab_auth_email'] = 'email'; + +if (preg_match('/\/helpdesk-login\//', \$_SERVER["REQUEST_URI"]) ) { + + // Login and password of the admin user. Enables "Login As" feature. + \$rcmail_config['kolab_auth_admin_login'] = '$imap_admin_login'; + \$rcmail_config['kolab_auth_admin_password'] = '$imap_admin_password'; + + \$rcmail_config['kolab_auth_auditlog'] = true; +} + +// Administrative role field (from fieldmap configuration) which must be filled with +// specified value which adds privilege to login as another user. +\$rcmail_config['kolab_auth_role'] = 'role'; +\$rcmail_config['kolab_auth_role_value'] = 'cn=kolab-admin,$ldap_base_dn'; + +// Administrative group name to which user must be assigned to +// which adds privilege to login as another user. +\$rcmail_config['kolab_auth_group'] = 'Kolab Helpdesk'; + +?> diff --git a/share/templates/roundcubemail/kolab_folders.inc.php.tpl b/share/templates/roundcubemail/kolab_folders.inc.php.tpl new file mode 100644 index 0000000..b0c7ea1 --- /dev/null +++ b/share/templates/roundcubemail/kolab_folders.inc.php.tpl @@ -0,0 +1,14 @@ + diff --git a/share/templates/roundcubemail/main.inc.php.tpl b/share/templates/roundcubemail/main.inc.php.tpl new file mode 100644 index 0000000..030e239 --- /dev/null +++ b/share/templates/roundcubemail/main.inc.php.tpl @@ -0,0 +1,269 @@ +{locality} {zipcode}
{country} {region}'; + \$rcmail_config['default_charset'] = 'ISO-8859-1'; + \$rcmail_config['pagesize'] = 40; + \$rcmail_config['timezone'] = 'auto'; + \$rcmail_config['dst_active'] = (bool)date('I'); + \$rcmail_config['prefer_html'] = true; + \$rcmail_config['show_images'] = 0; + \$rcmail_config['prettydate'] = true; + \$rcmail_config['draft_autosave'] = 300; + \$rcmail_config['preview_pane'] = true; + \$rcmail_config['preview_pane_mark_read'] = 0; + \$rcmail_config['logout_purge'] = false; + \$rcmail_config['logout_expunge'] = false; + \$rcmail_config['inline_images'] = true; + \$rcmail_config['mime_param_folding'] = 1; + \$rcmail_config['skip_deleted'] = true; + \$rcmail_config['read_when_deleted'] = true; + \$rcmail_config['flag_for_deletion'] = true; + \$rcmail_config['keep_alive'] = 300; + \$rcmail_config['check_all_folders'] = false; + \$rcmail_config['display_next'] = true; + \$rcmail_config['autoexpand_threads'] = 2; + \$rcmail_config['top_posting'] = false; + \$rcmail_config['strip_existing_sig'] = true; + \$rcmail_config['show_sig'] = 1; + \$rcmail_config['sig_above'] = false; + \$rcmail_config['force_7bit'] = false; + \$rcmail_config['search_mods'] = null; + \$rcmail_config['delete_always'] = true; + \$rcmail_config['mdn_requests'] = 0; + \$rcmail_config['mdn_default'] = false; + \$rcmail_config['dsn_default'] = false; + \$rcmail_config['reply_same_folder'] = false; + + \$rcmail_config['plugins'] = array( + 'acl', + 'archive', + 'calendar', + 'compose_addressbook', + 'http_authentication', + 'jqueryui', + 'kolab_addressbook', + 'kolab_auth', + 'kolab_core', + 'kolab_config', + 'kolab_folders', + 'kolab_zpush', + 'listcommands', + 'managesieve', + 'newmail_notifier', +// 'owncloud', + 'password', + + // Depends on sieverules + // 'quickrules', + + 'redundant_attachments', + 'terms', + 'threading_as_default', + // contextmenu must be after kolab_addressbook (#444) + 'contextmenu', + ); + + + if (file_exists(RCMAIL_CONFIG_DIR . '/' . \$_SERVER["HTTP_HOST"] . '/main.inc.php')) { + include_once(RCMAIL_CONFIG_DIR . '/' . \$_SERVER["HTTP_HOST"] . '/main.inc.php'); + } + + // Re-apply mandatory settings here. + + \$rcmail_config['debug_level'] = 0; + \$rcmail_config['devel_mode'] = false; + \$rcmail_config['log_driver'] = 'file'; + \$rcmail_config['log_date_format'] = 'd-M-Y H:i:s,u O'; + \$rcmail_config['syslog_id'] = 'roundcube'; + \$rcmail_config['syslog_facility'] = LOG_USER; + \$rcmail_config['smtp_log'] = true; + \$rcmail_config['log_logins'] = true; + \$rcmail_config['log_session'] = true; + \$rcmail_config['sql_debug'] = true; + \$rcmail_config['memcache_debug'] = true; + \$rcmail_config['imap_debug'] = true; + \$rcmail_config['ldap_debug'] = true; + \$rcmail_config['smtp_debug'] = true; + + \$rcmail_config['product_name'] = 'Kolab Groupware'; + + \$rcmail_config['skin'] = 'kolab'; + \$rcmail_config['skin_logo'] = 'skins/kolab/images/kolab_logo.png'; + \$rcmail_config['skin_include_php'] = false; + \$rcmail_config['mime_magic'] = '/usr/share/misc/magic'; + \$rcmail_config['im_identify_path'] = '/usr/bin/identify'; + \$rcmail_config['im_convert_path'] = '/usr/bin/convert'; + \$rcmail_config['login_lc'] = true; + \$rcmail_config['auto_create_user'] = true; + \$rcmail_config['enable_installer'] = false; + \$rcmail_config['session_storage'] = 'db'; + \$rcmail_config['default_port'] = 143; + \$rcmail_config['imap_auth_type'] = ''; + \$rcmail_config['imap_delimiter'] = '/'; + \$rcmail_config['imap_ns_personal'] = null; + \$rcmail_config['imap_ns_other'] = null; + \$rcmail_config['imap_ns_shared'] = null; + \$rcmail_config['imap_force_caps'] = false; + \$rcmail_config['imap_force_lsub'] = true; + \$rcmail_config['imap_timeout'] = 0; + \$rcmail_config['imap_auth_cid'] = null; + \$rcmail_config['imap_auth_pw'] = null; + \$rcmail_config['smtp_port'] = 587; + \$rcmail_config['smtp_user'] = '%u'; + \$rcmail_config['smtp_pass'] = '%p'; + \$rcmail_config['smtp_auth_type'] = ''; + \$rcmail_config['smtp_auth_cid'] = null; + \$rcmail_config['smtp_auth_pw'] = null; + \$rcmail_config['smtp_helo_host'] = \$_SERVER["HTTP_HOST"]; + \$rcmail_config['smtp_timeout'] = 0; + \$rcmail_config['log_dir'] = '/var/log/roundcubemail/'; + \$rcmail_config['temp_dir'] = '\${_tmppath}'; + \$rcmail_config['message_cache_lifetime'] = '10d'; + + \$rcmail_config['archive_mbox'] = 'Archive'; + \$rcmail_config['drafts_mbox'] = 'Drafts'; + \$rcmail_config['junk_mbox'] = 'Spam'; + \$rcmail_config['sent_mbox'] = 'Sent'; + \$rcmail_config['trash_mbox'] = 'Trash'; + \$rcmail_config['default_imap_folders'] = array('INBOX', 'Drafts', 'Sent', 'Spam', 'Trash'); + \$rcmail_config['create_default_folders'] = true; + \$rcmail_config['protect_default_folders'] = true; + + \$mandatory_plugins = Array( + 'calendar', + 'kolab_addressbook', + 'kolab_auth', + 'kolab_core', + 'kolab_config', + 'kolab_folders', + 'password', + 'terms' + ); + + foreach ( \$mandatory_plugins as \$num => \$plugin ) { + if (!in_array(\$plugin, \$rcmail_config['plugins'])) { + \$rcmail_config['plugins'][] = \$plugin; + } + } + + \$rcmail_config['default_host'] = 'tls://localhost'; + \$rcmail_config['smtp_server'] = 'tls://localhost'; + \$rcmail_config['session_domain'] = ''; + \$rcmail_config['des_key'] = 'aTMVSq6lNHg1YbcV6t59uGeZ'; + \$rcmail_config['username_domain'] = ''; + + \$rcmail_config['mail_domain'] = ''; + + \$rcmail_config['ldap_public'] = array( + 'kolab_addressbook' => array( + 'name' => 'Global Address Book', + 'hosts' => Array('localhost'), + 'port' => 389, + 'use_tls' => false, + 'base_dn' => '$ldap_user_base_dn', + 'user_specific' => true, + 'bind_dn' => '%dn', + 'bind_pass' => '', + 'search_base_dn' => '$ldap_user_base_dn', + 'search_bind_dn' => '$ldap_service_bind_dn', + 'search_bind_pw' => '$ldap_service_bind_pw', + 'search_filter' => '(&(objectClass=inetOrgPerson)(mail=%fu))', + 'writable' => false, + 'LDAP_Object_Classes' => array("top", "inetOrgPerson"), + 'required_fields' => array("cn", "sn", "mail"), + 'LDAP_rdn' => 'uid', + 'ldap_version' => 3, // using LDAPv3 + 'search_fields' => array('displayname', 'mail'), + 'sort' => array('displayname', 'sn', 'givenname', 'cn'), + 'scope' => 'sub', + 'filter' => '(objectClass=inetOrgPerson)', + 'vlv' => false, + 'fuzzy_search' => true, + 'sizelimit' => '0', + 'timelimit' => '0', + 'fieldmap' => Array( + // Roundcube => LDAP + 'name' => 'displayName', + 'surname' => 'sn', + 'firstname' => 'givenName', + 'middlename' => 'initials', + 'prefix' => 'title', + 'email:primary' => 'mail', + 'email:alias' => 'alias', + 'phone:main' => 'telephoneNumber', + 'phone:work' => 'alternateTelephoneNumber', + 'phone:mobile' => 'mobile', + 'phone:work2' => 'blackberry', + 'jobtitle' => 'title', + 'manager' => 'manager', + 'assistant' => 'secretary', + 'photo' => 'jpegphoto' + ), + 'groups' => Array( + 'base_dn' => '$ldap_group_base_dn', + 'filter' => '(&' . '$ldap_group_filter' . '(mail=*))', + 'object_classes' => Array("top", "groupOfUniqueNames"), + 'member_attr' => 'uniqueMember', + ), + ), + ); + + \$rcmail_config['autocomplete_addressbooks'] = Array( + 'kolab_addressbook' + ); + + \$rcmail_config['htmleditor'] = 0; + +?> diff --git a/share/templates/roundcubemail/managesieve.inc.php.tpl b/share/templates/roundcubemail/managesieve.inc.php.tpl new file mode 100644 index 0000000..c1a9fa3 --- /dev/null +++ b/share/templates/roundcubemail/managesieve.inc.php.tpl @@ -0,0 +1,13 @@ + diff --git a/share/templates/roundcubemail/mimetypes.php.tpl b/share/templates/roundcubemail/mimetypes.php.tpl new file mode 100644 index 0000000..d404c1f --- /dev/null +++ b/share/templates/roundcubemail/mimetypes.php.tpl @@ -0,0 +1,49 @@ + 'application/vnd.ms-excel', + 'xlm' => 'application/vnd.ms-excel', + 'xla' => 'application/vnd.ms-excel', + 'xlc' => 'application/vnd.ms-excel', + 'xlt' => 'application/vnd.ms-excel', + 'xlw' => 'application/vnd.ms-excel', + 'pdf' => 'application/pdf', + 'ppt' => 'application/vnd.ms-powerpoint', + 'pps' => 'application/vnd.ms-powerpoint', + 'pot' => 'application/vnd.ms-powerpoint', + 'doc' => 'application/msword', + 'dot' => 'application/msword', + 'odc' => 'application/vnd.oasis.opendocument.chart', + 'otc' => 'application/vnd.oasis.opendocument.chart-template', + 'odf' => 'application/vnd.oasis.opendocument.formula', + 'otf' => 'application/vnd.oasis.opendocument.formula-template', + 'odg' => 'application/vnd.oasis.opendocument.graphics', + 'otg' => 'application/vnd.oasis.opendocument.graphics-template', + 'odi' => 'application/vnd.oasis.opendocument.image', + 'oti' => 'application/vnd.oasis.opendocument.image-template', + 'odp' => 'application/vnd.oasis.opendocument.presentation', + 'otp' => 'application/vnd.oasis.opendocument.presentation-template', + 'ods' => 'application/vnd.oasis.opendocument.spreadsheet', + 'ots' => 'application/vnd.oasis.opendocument.spreadsheet-template', + 'odt' => 'application/vnd.oasis.opendocument.text', + 'otm' => 'application/vnd.oasis.opendocument.text-master', + 'ott' => 'application/vnd.oasis.opendocument.text-template', + 'oth' => 'application/vnd.oasis.opendocument.text-web', + 'docm' => 'application/vnd.ms-word.document.macroEnabled.12', + 'docx' => 'application/vnd.openxmlformats-officedocument.wordprocessingml.document', + 'dotm' => 'application/vnd.ms-word.template.macroEnabled.12', + 'dotx' => 'application/vnd.openxmlformats-officedocument.wordprocessingml.template', + 'ppsm' => 'application/vnd.ms-powerpoint.slideshow.macroEnabled.12', + 'ppsx' => 'application/vnd.openxmlformats-officedocument.presentationml.slideshow', + 'pptm' => 'application/vnd.ms-powerpoint.presentation.macroEnabled.12', + 'pptx' => 'application/vnd.openxmlformats-officedocument.presentationml.presentation', + 'xlsb' => 'application/vnd.ms-excel.sheet.binary.macroEnabled.12', + 'xlsm' => 'application/vnd.ms-excel.sheet.macroEnabled.12', + 'xlsx' => 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet', + 'xps' => 'application/vnd.ms-xpsdocument', + 'rar' => 'application/x-rar-compressed', + 'vcf' => 'text/vcard', + 'ics' => 'text/calendar', +); + +?> \ No newline at end of file diff --git a/share/templates/roundcubemail/owncloud.inc.php.tpl b/share/templates/roundcubemail/owncloud.inc.php.tpl new file mode 100644 index 0000000..7410a53 --- /dev/null +++ b/share/templates/roundcubemail/owncloud.inc.php.tpl @@ -0,0 +1,4 @@ + \ No newline at end of file diff --git a/share/templates/roundcubemail/password.inc.php.tpl b/share/templates/roundcubemail/password.inc.php.tpl new file mode 100644 index 0000000..992ccc6 --- /dev/null +++ b/share/templates/roundcubemail/password.inc.php.tpl @@ -0,0 +1,151 @@ + diff --git a/share/templates/roundcubemail/recipient_to_contact.inc.php.tpl b/share/templates/roundcubemail/recipient_to_contact.inc.php.tpl new file mode 100644 index 0000000..f3b8d2f --- /dev/null +++ b/share/templates/roundcubemail/recipient_to_contact.inc.php.tpl @@ -0,0 +1,4 @@ + \ No newline at end of file diff --git a/share/templates/roundcubemail/terms.html.tpl b/share/templates/roundcubemail/terms.html.tpl new file mode 100644 index 0000000..4fcabc7 --- /dev/null +++ b/share/templates/roundcubemail/terms.html.tpl @@ -0,0 +1,10 @@ + + + + +

Welcome to Kolab Groupware

+

+ Here could be your Message of the Day. +

+ + diff --git a/share/templates/roundcubemail/terms.inc.php.tpl b/share/templates/roundcubemail/terms.inc.php.tpl new file mode 100644 index 0000000..5faa888 --- /dev/null +++ b/share/templates/roundcubemail/terms.inc.php.tpl @@ -0,0 +1,18 @@ + -- cgit v1.1