use new et2 config

This commit is contained in:
Ralf Becker 2016-04-24 13:41:36 +00:00
parent a9eba441d7
commit 1742ebf6f1
5 changed files with 124 additions and 154 deletions

View File

@ -4,7 +4,7 @@
<overlay>
<template id="admin.site-config" template="" lang="" group="0" version="16.1">
<description value="Site configuration" class="subHeader"/>
<template id="template" template="@template" width="100%"/>
<template template="@template" width="100%"/>
<hbox class="dialogFooterToolbar">
<button id="save" label="Save"/>
<button id="apply" label="Apply"/>

View File

@ -5,7 +5,7 @@
* @link http://www.egroupware.org
* @package calendar
* @author Ralf Becker <RalfBecker-AT-outdoor-training.de>
* @copyright (c) 2004-14 by RalfBecker-At-outdoor-training.de
* @copyright (c) 2004-16 by RalfBecker-At-outdoor-training.de
* @license http://opensource.org/licenses/gpl-license.php GPL - GNU General Public License
* @version $Id$
*/
@ -79,7 +79,7 @@ class calendar_hooks
static function admin()
{
$file = Array(
'Site Configuration' => egw::link('/index.php','menuaction=admin.uiconfig.index&appname=calendar'),
'Site Configuration' => egw::link('/index.php','menuaction=admin.admin_config.index&appname=calendar&ajax=true'),
'Custom fields' => egw::link('/index.php','menuaction=admin.customfields.index&appname=calendar'),
'Calendar Holiday Management' => egw::link('/index.php','menuaction=calendar.uiholiday.admin'),
'Global Categories' => egw::link('/index.php','menuaction=admin.admin_categories.index&appname=calendar'),

View File

@ -370,7 +370,7 @@ class calendar_ui
}
$this->view_menuaction = $this->view == 'listview' ? 'calendar.calendar_uilist.listview' : 'calendar.calendar_uiviews.index';
if ($this->debug > 0 || $this->debug == 'manage_states') $this->bo->debug_message('uical::manage_states(%1) session was %2, states now %3',True,$set_states,$states_session,$states);
if ($this->debug > 0 || $this->debug == 'manage_states') $this->bo->debug_message('uical::manage_states(%1), states now %3',True,$set_states,$states);
// save the states in the session only when we are in calendar
if ($GLOBALS['egw_info']['flags']['currentapp']=='calendar')
{
@ -480,7 +480,6 @@ class calendar_ui
*/
function sidebox_menu()
{
$link_vars = array();
// Magic etemplate2 favorites menu (from framework)
display_sidebox('calendar', lang('Favorites'), egw_framework::favorite_list('calendar'));
@ -520,7 +519,7 @@ class calendar_ui
if ($GLOBALS['egw_info']['user']['apps']['admin'])
{
$file = Array(
'Configuration'=>egw::link('/index.php','menuaction=admin.uiconfig.index&appname=calendar'),
'Configuration'=>egw::link('/index.php','menuaction=admin.admin_config.index&appname=calendar&ajax=true'),
'Custom Fields'=>egw::link('/index.php','menuaction=admin.customfields.index&appname=calendar'),
'Holiday Management'=>egw::link('/index.php','menuaction=calendar.uiholiday.admin'),
'Global Categories' =>egw::link('/index.php','menuaction=admin.admin_categories.index&appname=calendar'),
@ -688,6 +687,7 @@ class calendar_ui
}
$event['non_blocking'] = (bool)$event['non_blocking'];
$matches = null;
if(!(int)$event['id'] && preg_match('/^([a-z_-]+)([0-9]+)$/i',$event['id'],$matches))
{
$app = $matches[1];

View File

@ -1,148 +0,0 @@
<!-- BEGIN header -->
<p style="text-align: center; color: red; font-weight: bold;">{error}</p>
<form method="POST" action="{action_url}">
{hidden_vars}
<table border="0" align="center">
<tr class="th">
<td colspan="2"><font color="{th_text}">&nbsp;<b>{title}</b></font></td>
</tr>
<!-- END header -->
<!-- BEGIN body -->
<tr class="row_on">
<td>&nbsp;{lang_Do_you_wish_to_autoload_calendar_holidays_files_dynamically?}</td>
<td>
<select name="newsettings[auto_load_holidays]">
<option value=""{selected_auto_load_holidays_False}>{lang_No}</option>
<option value="True"{selected_auto_load_holidays_True}>{lang_Yes}</option>
</select>
</td>
</tr>
<tr class="row_off">
<td>&nbsp;{lang_Location_to_autoload_from}:</td>
<td>
<select name="newsettings[holidays_url_path]">
<option value="localhost"{selected_holidays_url_path_localhost}>localhost</option>
<option value="http://www.egroupware.org/cal"{selected_holidays_url_path_http://www.egroupware.org/cal}>www.egroupware.org</option>
</select>
</td>
</tr>
<!-- lock setting -->
<tr class="row_on">
<td>&nbsp;{lang_setting_lock_time_calender}:</td>
<td><input name="newsettings[Lock_Time_Calender]" value="{value_Lock_Time_Calender}" size="40"></td>
</tr>
<tr class="row_off">
<td>&nbsp;{lang_Deny_Ressources_reservation_for_private_events}:</td>
<td>
<select name="newsettings[no_ressources_private]">
<option value="">{lang_No}</option>
<option value="yes"{selected_no_ressources_private_yes}>{lang_Yes}</option>
</select>
</td>
</tr>
<tr class="row_on">
<td>&nbsp;{lang_Require_an_ACL_grant_to_invite_other_users_and_groups}:</td>
<td>
<select name="newsettings[require_acl_invite]">
<option value="">{lang_No}: {lang_Every_user_can_invite_other_users_and_groups}</option>
<option value="groups"{selected_require_acl_invite_groups}>{lang_Groups:_other_users_can_allways_be_invited,_only_groups_require_an_invite_grant}</option>
<option value="all"{selected_require_acl_invite_all}>{lang_Users_+_groups:_inviting_both_allways_requires_an_invite_grant}</option>
</select>
</td>
</tr>
<tr class="row_on">
<td>&nbsp;{lang_Allow_users_to_prevent_change_notifications_('Do_not_notify')}:</td>
<td>
<select name="newsettings[calendar_allow_no_notification]">
<option value=""{selected_calendar_allow_no_notification_False}>{lang_No}</option>
<option value="True"{selected_calendar_allow_no_notification_True}>{lang_Yes}</option>
</select>
</td>
</tr>
<tr class="row_off">
<td>&nbsp;{lang_Use_range-views_to_optimise_calendar_queries?}</td>
<td>
<select name="newsettings[no_timerange_views]">
<option value="">{lang_Yes}</option>
<option value="true"{selected_no_timerange_views_true}>{lang_No}</option>
</select>
</td>
</tr>
<tr class="row_on">
<td>&nbsp;<b>{lang_Security}</b>: {lang_How_many_appointments_should_non-admins_be_able_to_export}
{lang_(empty_=_use_global_limit,_no_=_no_export_at_all)}:</td>
<td><input name="newsettings[calendar_export_limit]" value="{value_calendar_export_limit}" size="5"></td>
</tr>
<tr class="th">
<td colspan="2">&nbsp;<b>{lang_History_logging}</b></td>
</tr>
<tr class="row_on">
<td>&nbsp;{lang_Prevent_deleting_of_entries}</td>
<td>
<select name="newsettings[calendar_delete_history]">
<option value="">{lang_No}</option>
<option value="history"{selected_calendar_delete_history_history}>{lang_Yes,_only_admins_can_purge_deleted_items}</option>
<option value="userpurge"{selected_calendar_delete_history_userpurge}>{lang_Yes,_users_can_purge_their_deleted_items}</option>
</select>
</td>
</tr>
<tr class="row_off">
<td>&nbsp;{lang_Automatically_purge_old_events_after}</td>
<td>
<select name="newsettings[calendar_purge_old]">
<option value="0ff">{lang_No_automatic_purging}</option>
<option value=".5"{selected_calendar_purge_old_.5}>0.5 {lang_years}</option>
<option value="1"{selected_calendar_purge_old_1}>1 {lang_year}</option>
<option value="2"{selected_calendar_purge_old_2}>2 {lang_years}</option>
<option value="3"{selected_calendar_purge_old_3}>3 {lang_years}</option>
<option value="4"{selected_calendar_purge_old_4}>4 {lang_years}</option>
<option value="5"{selected_calendar_purge_old_5}>5 {lang_years}</option>
<option value="10"{selected_calendar_purge_old_10}>10 {lang_years}</option>
</select>
</td>
</tr>
<tr class="th">
<td colspan="2">&nbsp;<b>{lang_Birthdays}</b></td>
</tr>
<tr class="row_off">
<td>&nbsp;{lang_Show_birthdays_from_addressbook}:</td>
<td>
<select name="newsettings[hide_birthdays]">
<option value="">{lang_Yes}</option>
<option value="dateonly"{selected_hide_birthdays_dateonly}>{lang_Show_only_the_date,_not_the_year}</option>
<option value="yes"{selected_hide_birthdays_yes}>{lang_No}</option>
</select>
</td>
</tr>
<tr class="row_on">
<td>&nbsp;{lang_Calendar_recurrence_horizont_in_days_(default_1000)}:</td>
<td><input size="5" name="newsettings[calendar_horizont]" value="{value_calendar_horizont}"></td>
</tr>
<tr class="row_off">
<td>&nbsp;{lang_Create_links_for_participants_from_addressbook}:</td>
<td>
<select name="newsettings[link_contacts]">
<option value="">{lang_No}</option>
<option value="yes"{selected_link_contacts_yes}>{lang_Yes}</option>
</select>
</td>
</tr>
<!-- END body -->
<!-- BEGIN footer -->
<tr class="th">
<td colspan="2">
&nbsp;
</td>
</tr>
<tr>
<td colspan="2" align="center">
<input type="submit" name="submit" value="{lang_submit}">
<input type="submit" name="cancel" value="{lang_cancel}">
</td>
</tr>
</table>
</form>
<!-- END footer -->

View File

@ -0,0 +1,118 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE overlay PUBLIC "-//Stylite AG//eTemplate 2//EN" "http://www.egroupware.org/etemplate2.dtd">
<!-- $Id$ -->
<overlay>
<template id="calendar.config" template="" lang="" group="0" version="16.1">
<grid width="100%" class="admin-config egwGridView_grid">
<columns>
<column width="60%"/>
<column/>
</columns>
<rows>
<row>
<description value="Do you wish to autoload calendar holidays files dynamically?"/>
<select id="newsettings[auto_load_holidays]">
<option value="">No</option>
<option value="True">Yes</option>
</select>
</row>
<row>
<description value="Location to autoload from" label="%s:"/>
<select id="newsettings[holidays_url_path]">
<option value="localhost">localhost</option>
<option value="http://www.egroupware.org/cal">www.egroupware.org</option>
</select>
</row>
<row>
<description value="setting lock time calender" label="%s:"/>
<textbox id="newsettings[Lock_Time_Calender]" size="40"/>
</row>
<row>
<description value="Deny Ressources reservation for private events" label="%s:"/>
<select id="newsettings[no_ressources_private]">
<option value="">No</option>
<option value="yes">Yes</option>
</select>
</row>
<row>
<description value="Require an ACL grant to invite other users and groups" label="%s:"/>
<select id="newsettings[require_acl_invite]">
<option value="">{No}: {Every user can invite other users and groups}</option>
<option value="groups">Groups: other users can allways be invited, only groups require an invite grant</option>
<option value="all">Users + groups: inviting both allways requires an invite grant</option>
</select>
</row>
<row>
<description value="Allow users to prevent change notifications ('Do not notify')" label="%s:"/>
<select id="newsettings[calendar_allow_no_notification]">
<option value="">No</option>
<option value="True">Yes</option>
</select>
</row>
<row>
<description value="Use range-views to optimise calendar queries?"/>
<select id="newsettings[no_timerange_views]">
<option value="">Yes</option>
<option value="true">No</option>
</select>
</row>
<row>
<description value="Security" span="all" class="subHeader"/>
</row>
<row>
<vbox>
<description value="How many appointments should non-admins be able to export"/>
<description value="(empty = use global limit, no = no export at all)"/>
</vbox>
<textbox id="newsettings[calendar_export_limit]" size="5"/>
</row>
<row>
<description value="History logging" span="all" class="subHeader"/>
</row>
<row>
<description value="Prevent deleting of entries"/>
<select id="newsettings[calendar_delete_history]">
<option value="">No</option>
<option value="history">Yes, only admins can purge deleted items</option>
<option value="userpurge">Yes, users can purge their deleted items</option>
</select>
</row>
<row>
<description value="Automatically purge old events after"/>
<select id="newsettings[calendar_purge_old]">
<option value="0ff">No automatic purging</option>
<option value=".5">0.5 {years}</option>
<option value="1">1 {year}</option>
<option value="2">2 {years}</option>
<option value="3">3 {years}</option>
<option value="4">4 {years}</option>
<option value="5">5 {years}</option>
<option value="10">10 {years}</option>
</select>
</row>
<row>
<description value="Birthdays" span="all" class="subHeader"/>
</row>
<row>
<description value="Show birthdays from addressbook" label="%s:"/>
<select id="newsettings[hide_birthdays]">
<option value="">Yes</option>
<option value="dateonly">Show only the date, not the year</option>
<option value="yes">No</option>
</select>
</row>
<row>
<description value="Calendar recurrence horizont in days (default 1000)" label="%s:"/>
<textbox id="newsettings[calendar_horizont]" size="5"/>
</row>
<row>
<description value="Create links for participants from addressbook" label="%s:"/>
<select id="newsettings[link_contacts]">
<option value="">No</option>
<option value="yes">Yes</option>
</select>
</row>
</rows>
</grid>
</template>
</overlay>