Add preference for disabling the protection against navigation away from partially changed forms

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@34865 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 7368ce22
......@@ -33,7 +33,7 @@ class HtmlStylePreference:
_properties = (
{ 'id' : 'preferred_html_style_developper_mode',
'description' : 'When true, usefull links for developpers are shown in '\
'description' : 'When true, useful links for developers are shown in '\
'the interface.',
'type' : 'boolean',
'preference' : 1,
......@@ -50,7 +50,7 @@ class HtmlStylePreference:
'preference' : 1,
'mode' : 'w' },
{ 'id' : 'preferred_html_style_access_tab',
'description' : 'When true, access tab will used in front page.',
'description' : 'When true, access tab will be used in front page.',
'type' : 'boolean',
'preference' : 1,
'mode' : 'w' },
......@@ -66,6 +66,14 @@ class HtmlStylePreference:
'preference' : 1,
'default' : 'http://www.erp5.com/erp5_help/',
'mode' : 'w' },
{ 'id' : 'preferred_html_style_unsaved_form_warning',
'description' : 'When true, display a javascript confirmation box if '\
'the user tries to navigate away from a form that was '\
'partially changed but is unsaved.',
'type' : 'boolean',
'preference' : 1,
'default' : True,
'mode' : 'w' },
{ 'id' : 'preferred_string_field_width',
'description' : 'The default width of string fields',
'type' : 'int',
......
<?xml version="1.0"?>
<repository>
<template id="erp5_core">
<copyright>Copyright (c) 2001-2007 Nexedi SA</copyright>
<dependency>erp5_catalog (&gt;= 1.1)</dependency>
<description>ERP5 Core is the basic template for ERP5.</description>
<license>GPL</license>
<revision>1570</revision>
<title>erp5_core</title>
<version>5.4.6</version>
</template>
<template id="erp5_mysql_innodb_catalog">
<copyright>Copyright (c) 2001-2006 Nexedi SARL</copyright>
<description>MySQL InnoDB
Contains all the scripts &amp; configuration required to use MySQL InnoDB tables as a catalog storage backend.</description>
<license>GPL</license>
<provision>erp5_catalog</provision>
<revision>190</revision>
<title>erp5_mysql_innodb_catalog</title>
<version>5.4.6</version>
</template>
<template id="erp5_mysql_ndb_catalog">
<copyright>Copyright (c) 2001-2006 Nexedi SARL</copyright>
<description>MySQL NDB
Contains all the scripts &amp; configuration required to use MySQL NDB (Network DataBase) tables as a catalog storage backend.</description>
<license>GPL</license>
<provision>erp5_catalog</provision>
<revision>33
</revision>
<title>erp5_mysql_ndb_catalog</title>
<version>0.1</version>
</template>
<template id="erp5_xhtml_style">
<copyright>Copyright (c) 2006-2007 Nexedi SA</copyright>
<dependency>erp5_core</dependency>
<description>This style is a rewrite of erp5_html_style more CSS and semantic html oriented.
Handles page parameters dynamically.</description>
<license>GPL</license>
<provision>erp5_view_style</provision>
<revision>930</revision>
<title>erp5_xhtml_style</title>
<version>5.4.6</version>
</template>
</repository>
......@@ -80,6 +80,7 @@
<value>
<list>
<string>my_preferred_date_order</string>
<string>my_prefered_html_style_unsaved_form_warning</string>
<string>my_preferred_html_style_developper_mode</string>
<string>my_preferred_html_style_contextual_help</string>
<string>my_preferred_html_style_translator_mode</string>
......@@ -96,7 +97,6 @@
<string>my_preferred_money_quantity_style</string>
<string>my_preferred_quantity_field_width</string>
<string>my_preferred_float_number_style</string>
<string>my_preferred_max_user_inactivity_duration</string>
</list>
</value>
</item>
......@@ -104,6 +104,7 @@
<key> <string>right</string> </key>
<value>
<list>
<string>my_preferred_max_user_inactivity_duration</string>
<string>my_preferred_report_style</string>
<string>my_preferred_report_format</string>
<string>my_preferred_nano_image_height</string>
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<tuple>
<global name="CheckBoxField" module="Products.Formulator.StandardFields"/>
<tuple/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>id</string> </key>
<value> <string>my_prefered_html_style_unsaved_form_warning</string> </value>
</item>
<item>
<key> <string>message_values</string> </key>
<value>
<dictionary>
<item>
<key> <string>external_validator_failed</string> </key>
<value> <string>The input failed the external validator.</string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>overrides</string> </key>
<value>
<dictionary>
<item>
<key> <string>alternate_name</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>css_class</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>default</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>description</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>editable</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>enabled</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>external_validator</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>extra</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>hidden</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>tales</string> </key>
<value>
<dictionary>
<item>
<key> <string>alternate_name</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>css_class</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>default</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>description</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>editable</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>enabled</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>external_validator</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>extra</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>hidden</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>values</string> </key>
<value>
<dictionary>
<item>
<key> <string>alternate_name</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>css_class</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>default</string> </key>
<value> <int>1</int> </value>
</item>
<item>
<key> <string>description</string> </key>
<value> <string>Indicates if a confirmation dialog should be displayed when the user tries to navigate from a form that was partially changed</string> </value>
</item>
<item>
<key> <string>editable</string> </key>
<value> <int>1</int> </value>
</item>
<item>
<key> <string>enabled</string> </key>
<value> <int>1</int> </value>
</item>
<item>
<key> <string>external_validator</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>extra</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>hidden</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Unsaved Form Warning</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
1574
\ No newline at end of file
1575
\ No newline at end of file
......@@ -60,6 +60,7 @@
</tal:block>\n
<tal:block metal:fill-slot="main">\n
<script type="text/javascript"\n
tal:condition="portal/portal_preferences/getPreferredHtmlStyleUnsavedFormWarning"\n
tal:define="message python:context.Base_translateString(\'You have unsaved changes\').replace(\'\\\'\', \'\\\\\\\'\')"\n
tal:content="string:installUnsavedChangesWarning(\'$message\')">\n
</script>\n
......
935
\ No newline at end of file
936
\ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment