Commit b3f8bde7 authored by Ivan Tyagov's avatar Ivan Tyagov

Do not use hard coded permission names.

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@32941 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 1b96167a
...@@ -26,6 +26,7 @@ ...@@ -26,6 +26,7 @@
# #
############################################################################## ##############################################################################
from Products.ERP5Type import Permissions
class DocumentPreference: class DocumentPreference:
""" """
...@@ -37,49 +38,49 @@ class DocumentPreference: ...@@ -37,49 +38,49 @@ class DocumentPreference:
'description' : 'Address of a server for converting docs (ip or domain)', 'description' : 'Address of a server for converting docs (ip or domain)',
'type' : 'string', 'type' : 'string',
'preference' : 1, 'preference' : 1,
'write_permission': 'Manage properties', 'write_permission': Permissions.ManageProperties,
'mode' : '' }, 'mode' : '' },
{ 'id' : 'preferred_ooodoc_server_port_number', { 'id' : 'preferred_ooodoc_server_port_number',
'description' : 'Port number of a server for converting docs', 'description' : 'Port number of a server for converting docs',
'type' : 'int', 'type' : 'int',
'preference' : 1, 'preference' : 1,
'write_permission': 'Manage properties', 'write_permission': Permissions.ManageProperties,
'mode' : '' }, 'mode' : '' },
{ 'id' : 'preferred_document_reference_regular_expression', { 'id' : 'preferred_document_reference_regular_expression',
'description' : 'A regular expression to find and verify doc references', 'description' : 'A regular expression to find and verify doc references',
'type' : 'string', 'type' : 'string',
'preference' : 1, 'preference' : 1,
'write_permission': 'Manage properties', 'write_permission': Permissions.ManageProperties,
'mode' : '' }, 'mode' : '' },
{ 'id' : 'preferred_document_file_name_regular_expression', { 'id' : 'preferred_document_file_name_regular_expression',
'description' : 'A regular expression to parse file names', 'description' : 'A regular expression to parse file names',
'type' : 'string', 'type' : 'string',
'preference' : 1, 'preference' : 1,
'write_permission': 'Manage properties', 'write_permission': Permissions.ManageProperties,
'mode' : '' }, 'mode' : '' },
{ 'id' : 'preferred_document_reference_method_id', { 'id' : 'preferred_document_reference_method_id',
'description' : 'Function for parsing, finding and verifying doc reference', 'description' : 'Function for parsing, finding and verifying doc reference',
'type' : 'string', 'type' : 'string',
'preference' : 1, 'preference' : 1,
'write_permission': 'Manage properties', 'write_permission': Permissions.ManageProperties,
'mode' : '' }, 'mode' : '' },
{ 'id' : 'preferred_document_ingestion_email_notification', { 'id' : 'preferred_document_ingestion_email_notification',
'description' : 'None - always, "always", "problem (only if problem), "never"', # XXX-JPS this is not a description 'description' : 'None - always, "always", "problem (only if problem), "never"', # XXX-JPS this is not a description
'type' : 'selection', 'type' : 'selection',
'select_variable' : 'getPreferredDocumentIngestionEmailNotificationSelectionList', 'select_variable' : 'getPreferredDocumentIngestionEmailNotificationSelectionList',
'write_permission': 'Manage properties', 'write_permission': Permissions.ManageProperties,
'preference' : 1, 'preference' : 1,
'mode' : '' }, 'mode' : '' },
{ 'id' : 'preferred_document_email_ingestion_address', { 'id' : 'preferred_document_email_ingestion_address',
'description' : 'Email ingestion address', 'description' : 'Email ingestion address',
'type' : 'string', 'type' : 'string',
'write_permission': 'Manage properties', 'write_permission': Permissions.ManageProperties,
'preference' : 1, 'preference' : 1,
'mode' : '' }, 'mode' : '' },
{ 'id' : 'preferred_document_classification', { 'id' : 'preferred_document_classification',
'description' : 'Preffered classification policy for newly created documents', 'description' : 'Preffered classification policy for newly created documents',
'type' : 'string', 'type' : 'string',
'write_permission': 'Manage properties', 'write_permission': Permissions.ManageProperties,
'preference' : 1, 'preference' : 1,
'mode' : '' }, 'mode' : '' },
# XXX-JPS. This is not a real property - it is somehow a hack. # XXX-JPS. This is not a real property - it is somehow a hack.
...@@ -88,18 +89,18 @@ class DocumentPreference: ...@@ -88,18 +89,18 @@ class DocumentPreference:
'description' : 'List of possible values for preferred_document_ingestion_email_notification', 'description' : 'List of possible values for preferred_document_ingestion_email_notification',
'type' : 'tokens', 'type' : 'tokens',
'default' : ['always','problem','never'], 'default' : ['always','problem','never'],
'write_permission': 'Manage properties', 'write_permission': Permissions.ManageProperties,
'mode' : 'w'}, 'mode' : 'w'},
{ 'id' : 'preferred_conversion_cache_factory', { 'id' : 'preferred_conversion_cache_factory',
'description' : 'Preferred Conversion Cache', 'description' : 'Preferred Conversion Cache',
'type' : 'string', 'type' : 'string',
'write_permission': 'Manage properties', 'write_permission': Permissions.ManageProperties,
'preference' : 1, 'preference' : 1,
'mode' : '' }, 'mode' : '' },
{ 'id' : 'preferred_synchronous_metadata_discovery', { 'id' : 'preferred_synchronous_metadata_discovery',
'description' : 'Is preferred synchronous metadata discovery', 'description' : 'Is preferred synchronous metadata discovery',
'type' : 'boolean', 'type' : 'boolean',
'write_permission': 'Manage properties', 'write_permission': Permissions.ManageProperties,
'default' : False, 'default' : False,
'preference' : 1, 'preference' : 1,
'mode' : '' }, 'mode' : '' },
......
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