Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Cédric Le Ninivin
erp5
Commits
752833d9
Commit
752833d9
authored
Jul 15, 2020
by
Jérome Perrin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
configurator: address pylint messages and enable coding style test
parent
9e95bc1d
Changes
70
Hide whitespace changes
Inline
Side-by-side
Showing
70 changed files
with
741 additions
and
300 deletions
+741
-300
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.AccountConfiguratorItem.py
...ortal_components/document.erp5.AccountConfiguratorItem.py
+3
-2
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.AccountConfiguratorItem.xml
...rtal_components/document.erp5.AccountConfiguratorItem.xml
+25
-6
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.AccountingPeriodConfiguratorItem.py
...ponents/document.erp5.AccountingPeriodConfiguratorItem.py
+3
-2
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.AccountingPeriodConfiguratorItem.xml
...onents/document.erp5.AccountingPeriodConfiguratorItem.xml
+1
-3
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.AdvancedPurchaseTradeConditionConfiguratorItem.py
...nt.erp5.AdvancedPurchaseTradeConditionConfiguratorItem.py
+4
-3
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.AdvancedPurchaseTradeConditionConfiguratorItem.xml
...t.erp5.AdvancedPurchaseTradeConditionConfiguratorItem.xml
+25
-6
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.AdvancedSaleTradeConditionConfiguratorItem.py
...cument.erp5.AdvancedSaleTradeConditionConfiguratorItem.py
+4
-3
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.AdvancedSaleTradeConditionConfiguratorItem.xml
...ument.erp5.AdvancedSaleTradeConditionConfiguratorItem.xml
+25
-6
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.AlarmConfiguratorItem.py
.../portal_components/document.erp5.AlarmConfiguratorItem.py
+3
-2
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.AlarmConfiguratorItem.xml
...portal_components/document.erp5.AlarmConfiguratorItem.xml
+1
-3
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.BankAccountConfiguratorItem.py
...l_components/document.erp5.BankAccountConfiguratorItem.py
+3
-2
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.BankAccountConfiguratorItem.xml
..._components/document.erp5.BankAccountConfiguratorItem.xml
+25
-6
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.BusinessProcessConfiguratorItem.py
...mponents/document.erp5.BusinessProcessConfiguratorItem.py
+3
-2
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.BusinessProcessConfiguratorItem.xml
...ponents/document.erp5.BusinessProcessConfiguratorItem.xml
+1
-3
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.CatalogKeywordKeyConfiguratorItem.py
...onents/document.erp5.CatalogKeywordKeyConfiguratorItem.py
+3
-2
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.CatalogKeywordKeyConfiguratorItem.xml
...nents/document.erp5.CatalogKeywordKeyConfiguratorItem.xml
+1
-3
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.CategoriesSpreadsheetConfiguratorItem.py
...ts/document.erp5.CategoriesSpreadsheetConfiguratorItem.py
+3
-2
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.CategoriesSpreadsheetConfiguratorItem.xml
...s/document.erp5.CategoriesSpreadsheetConfiguratorItem.xml
+25
-6
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.CategoryConfiguratorItem.py
...rtal_components/document.erp5.CategoryConfiguratorItem.py
+3
-3
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.CategoryConfiguratorItem.xml
...tal_components/document.erp5.CategoryConfiguratorItem.xml
+25
-6
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.CurrencyConfiguratorItem.py
...rtal_components/document.erp5.CurrencyConfiguratorItem.py
+3
-3
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.CurrencyConfiguratorItem.xml
...tal_components/document.erp5.CurrencyConfiguratorItem.xml
+25
-6
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.CustomerBT5ConfiguratorItem.py
...l_components/document.erp5.CustomerBT5ConfiguratorItem.py
+3
-4
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.CustomerBT5ConfiguratorItem.xml
..._components/document.erp5.CustomerBT5ConfiguratorItem.xml
+25
-6
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.OrganisationConfiguratorItem.py
..._components/document.erp5.OrganisationConfiguratorItem.py
+3
-2
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.OrganisationConfiguratorItem.xml
...components/document.erp5.OrganisationConfiguratorItem.xml
+25
-6
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.PermissionConfiguratorItem.py
...al_components/document.erp5.PermissionConfiguratorItem.py
+3
-3
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.PermissionConfiguratorItem.xml
...l_components/document.erp5.PermissionConfiguratorItem.xml
+25
-6
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.PersonConfiguratorItem.py
...portal_components/document.erp5.PersonConfiguratorItem.py
+3
-2
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.PersonConfiguratorItem.xml
...ortal_components/document.erp5.PersonConfiguratorItem.xml
+1
-3
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.PortalTypeConfiguratorItem.py
...al_components/document.erp5.PortalTypeConfiguratorItem.py
+3
-2
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.PortalTypeConfiguratorItem.xml
...l_components/document.erp5.PortalTypeConfiguratorItem.xml
+25
-6
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.PortalTypeRolesSpreadsheetConfiguratorItem.py
...cument.erp5.PortalTypeRolesSpreadsheetConfiguratorItem.py
+3
-2
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.PortalTypeRolesSpreadsheetConfiguratorItem.xml
...ument.erp5.PortalTypeRolesSpreadsheetConfiguratorItem.xml
+25
-6
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.PreferenceConfiguratorItem.py
...al_components/document.erp5.PreferenceConfiguratorItem.py
+3
-2
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.PreferenceConfiguratorItem.xml
...l_components/document.erp5.PreferenceConfiguratorItem.xml
+25
-6
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.PurchaseTradeConditionConfiguratorItem.py
...s/document.erp5.PurchaseTradeConditionConfiguratorItem.py
+3
-2
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.PurchaseTradeConditionConfiguratorItem.xml
.../document.erp5.PurchaseTradeConditionConfiguratorItem.xml
+25
-6
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.RoleConfiguratorItem.py
...m/portal_components/document.erp5.RoleConfiguratorItem.py
+3
-2
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.RoleConfiguratorItem.xml
.../portal_components/document.erp5.RoleConfiguratorItem.xml
+25
-6
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.RuleConfiguratorItem.py
...m/portal_components/document.erp5.RuleConfiguratorItem.py
+2
-2
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.RuleConfiguratorItem.xml
.../portal_components/document.erp5.RuleConfiguratorItem.xml
+25
-6
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.SaleTradeConditionConfiguratorItem.py
...nents/document.erp5.SaleTradeConditionConfiguratorItem.py
+3
-2
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.SaleTradeConditionConfiguratorItem.xml
...ents/document.erp5.SaleTradeConditionConfiguratorItem.xml
+25
-6
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.SecurityCategoryMappingConfiguratorItem.py
.../document.erp5.SecurityCategoryMappingConfiguratorItem.py
+3
-3
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.SecurityCategoryMappingConfiguratorItem.xml
...document.erp5.SecurityCategoryMappingConfiguratorItem.xml
+25
-7
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.ServiceConfiguratorItem.py
...ortal_components/document.erp5.ServiceConfiguratorItem.py
+3
-2
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.ServiceConfiguratorItem.xml
...rtal_components/document.erp5.ServiceConfiguratorItem.xml
+1
-3
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.SitePropertyConfiguratorItem.py
..._components/document.erp5.SitePropertyConfiguratorItem.py
+9
-8
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.SitePropertyConfiguratorItem.xml
...components/document.erp5.SitePropertyConfiguratorItem.xml
+25
-7
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.SolverConfiguratorItem.py
...portal_components/document.erp5.SolverConfiguratorItem.py
+4
-4
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.SolverConfiguratorItem.xml
...ortal_components/document.erp5.SolverConfiguratorItem.xml
+25
-7
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.StandardBT5ConfiguratorItem.py
...l_components/document.erp5.StandardBT5ConfiguratorItem.py
+3
-2
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.StandardBT5ConfiguratorItem.xml
..._components/document.erp5.StandardBT5ConfiguratorItem.xml
+25
-6
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.SystemPreferenceConfiguratorItem.py
...ponents/document.erp5.SystemPreferenceConfiguratorItem.py
+3
-2
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.SystemPreferenceConfiguratorItem.xml
...onents/document.erp5.SystemPreferenceConfiguratorItem.xml
+25
-6
bt5/erp5_configurator/MixinTemplateItem/portal_components/mixin.erp5.SkinConfiguratorItemMixin.py
...portal_components/mixin.erp5.SkinConfiguratorItemMixin.py
+2
-1
bt5/erp5_configurator/MixinTemplateItem/portal_components/mixin.erp5.SkinConfiguratorItemMixin.xml
...ortal_components/mixin.erp5.SkinConfiguratorItemMixin.xml
+25
-6
bt5/erp5_configurator/SkinTemplateItem/portal_skins/erp5_configurator/BusinessConfiguration_getISOCurrencyList.py
..._configurator/BusinessConfiguration_getISOCurrencyList.py
+1
-1
bt5/erp5_configurator/SkinTemplateItem/portal_skins/erp5_configurator/BusinessConfiguration_getISOCurrencyList.xml
...configurator/BusinessConfiguration_getISOCurrencyList.xml
+1
-1
bt5/erp5_configurator/SkinTemplateItem/portal_skins/erp5_configurator/BusinessConfiguration_getUIDescription.py
...p5_configurator/BusinessConfiguration_getUIDescription.py
+1
-1
bt5/erp5_configurator/SkinTemplateItem/portal_skins/erp5_configurator/BusinessConfiguration_validateCustomerPassword.py
...gurator/BusinessConfiguration_validateCustomerPassword.py
+2
-5
bt5/erp5_configurator/SkinTemplateItem/portal_skins/erp5_configurator/BusinessConfiguration_validateCustomerUsername.py
...gurator/BusinessConfiguration_validateCustomerUsername.py
+2
-2
bt5/erp5_configurator/SkinTemplateItem/portal_skins/erp5_configurator_wizard/ConfiguratorTool_generateJavaScript.py
...onfigurator_wizard/ConfiguratorTool_generateJavaScript.py
+0
-1
bt5/erp5_configurator/SkinTemplateItem/portal_skins/erp5_configurator_wizard/ConfiguratorTool_viewRunningInstallationMessage.py
...wizard/ConfiguratorTool_viewRunningInstallationMessage.py
+0
-2
bt5/erp5_configurator/TestTemplateItem/portal_components/test.erp5.testConfiguratorItem.py
...eItem/portal_components/test.erp5.testConfiguratorItem.py
+4
-21
bt5/erp5_configurator/TestTemplateItem/portal_components/test.erp5.testConfiguratorItem.xml
...Item/portal_components/test.erp5.testConfiguratorItem.xml
+25
-16
bt5/erp5_configurator/ToolComponentTemplateItem/portal_components/tool.erp5.ConfiguratorTool.py
...plateItem/portal_components/tool.erp5.ConfiguratorTool.py
+5
-8
bt5/erp5_configurator/ToolComponentTemplateItem/portal_components/tool.erp5.ConfiguratorTool.xml
...lateItem/portal_components/tool.erp5.ConfiguratorTool.xml
+25
-9
bt5/erp5_configurator/bt/skip_coding_style_test
bt5/erp5_configurator/bt/skip_coding_style_test
+0
-1
No files found.
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.AccountConfiguratorItem.py
View file @
752833d9
...
...
@@ -28,12 +28,13 @@
import
zope.interface
from
AccessControl
import
ClassSecurityInfo
from
Products.ERP5Type
import
Permissions
,
PropertySheet
,
interfaces
from
Products.ERP5Type
import
Permissions
,
PropertySheet
from
Products.ERP5Type.XMLObject
import
XMLObject
from
Products.ERP5Type.Message
import
translateString
from
erp5.component.mixin.ConfiguratorItemMixin
import
ConfiguratorItemMixin
from
erp5.component.interface.IConfiguratorItem
import
IConfiguratorItem
class
AccountConfiguratorItem
(
ConfiguratorItemMixin
,
XMLObject
):
""" Setup an Accounting Account. """
...
...
@@ -57,7 +58,7 @@ class AccountConfiguratorItem(ConfiguratorItemMixin, XMLObject):
,
PropertySheet
.
DublinCore
,
PropertySheet
.
Account
)
def
_checkConsistency
(
self
,
fixit
=
False
,
filter
=
None
,
**
kw
):
def
_checkConsistency
(
self
,
fixit
=
False
,
**
kw
):
account_module
=
self
.
getPortalObject
().
account_module
account
=
None
account_id
=
getattr
(
self
,
'account_id'
,
None
)
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.AccountConfiguratorItem.xml
View file @
752833d9
...
...
@@ -6,6 +6,12 @@
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_recorded_property_dict
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
AccountConfiguratorItem
</string>
</value>
...
...
@@ -43,9 +49,7 @@
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple>
<string>
W: 59, 43: Redefining built-in \'filter\' (redefined-builtin)
</string>
</tuple>
<tuple/>
</value>
</item>
<item>
...
...
@@ -55,13 +59,28 @@
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
I
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
...
...
@@ -74,7 +93,7 @@
<item>
<key>
<string>
component_validation_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
Q
=
</string>
</persistent>
</value>
</item>
</dictionary>
...
...
@@ -83,7 +102,7 @@
</dictionary>
</pickle>
</record>
<record
id=
"
3"
aka=
"AAAAAAAAAAM
="
>
<record
id=
"
4"
aka=
"AAAAAAAAAAQ
="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.AccountingPeriodConfiguratorItem.py
View file @
752833d9
...
...
@@ -28,11 +28,12 @@
import
zope.interface
from
AccessControl
import
ClassSecurityInfo
from
Products.ERP5Type
import
Permissions
,
PropertySheet
,
interfaces
from
Products.ERP5Type
import
Permissions
,
PropertySheet
from
Products.ERP5Type.XMLObject
import
XMLObject
from
erp5.component.mixin.ConfiguratorItemMixin
import
ConfiguratorItemMixin
from
erp5.component.interface.IConfiguratorItem
import
IConfiguratorItem
class
AccountingPeriodConfiguratorItem
(
ConfiguratorItemMixin
,
XMLObject
):
""" Setup an Accounting Period. """
...
...
@@ -56,7 +57,7 @@ class AccountingPeriodConfiguratorItem(ConfiguratorItemMixin, XMLObject):
,
PropertySheet
.
DublinCore
,
PropertySheet
.
Task
)
def
_checkConsistency
(
self
,
fixit
=
False
,
filter
=
None
,
**
kw
):
def
_checkConsistency
(
self
,
fixit
=
False
,
**
kw
):
portal
=
self
.
getPortalObject
()
business_configuration
=
self
.
getBusinessConfigurationValue
()
organisation_id
=
business_configuration
.
\
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.AccountingPeriodConfiguratorItem.xml
View file @
752833d9
...
...
@@ -49,9 +49,7 @@
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple>
<string>
W: 58, 43: Redefining built-in \'filter\' (redefined-builtin)
</string>
</tuple>
<tuple/>
</value>
</item>
<item>
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.AdvancedPurchaseTradeConditionConfiguratorItem.py
View file @
752833d9
...
...
@@ -28,14 +28,15 @@
import
zope.interface
from
AccessControl
import
ClassSecurityInfo
from
Products.ERP5Type
import
Permissions
,
PropertySheet
,
interfaces
from
Products.ERP5Type
import
Permissions
,
PropertySheet
from
Products.ERP5Type.XMLObject
import
XMLObject
from
Products.ERP5Type.Message
import
translateString
from
erp5.component.mixin.ConfiguratorItemMixin
import
ConfiguratorItemMixin
from
erp5.component.interface.IConfiguratorItem
import
IConfiguratorItem
class
AdvancedPurchaseTradeConditionConfiguratorItem
(
ConfiguratorItemMixin
,
XMLObject
):
""" Setup
Rule
s. """
""" Setup
Purchase Trade Condition
s. """
meta_type
=
'ERP5 Advanced Purchase Trade Condition Configurator Item'
portal_type
=
'Advanced Purchase Trade Condition Configurator Item'
...
...
@@ -58,7 +59,7 @@ class AdvancedPurchaseTradeConditionConfiguratorItem(ConfiguratorItemMixin, XMLO
,
PropertySheet
.
Reference
)
def
_checkConsistency
(
self
,
fixit
=
False
,
filter
=
None
,
**
kw
):
def
_checkConsistency
(
self
,
fixit
=
False
,
**
kw
):
if
fixit
:
portal
=
self
.
getPortalObject
()
business_configuration
=
self
.
getBusinessConfigurationValue
()
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.AdvancedPurchaseTradeConditionConfiguratorItem.xml
View file @
752833d9
...
...
@@ -6,6 +6,12 @@
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_recorded_property_dict
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
AdvancedPurchaseTradeConditionConfiguratorItem
</string>
</value>
...
...
@@ -43,9 +49,7 @@
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple>
<string>
W: 60, 43: Redefining built-in \'filter\' (redefined-builtin)
</string>
</tuple>
<tuple/>
</value>
</item>
<item>
...
...
@@ -55,13 +59,28 @@
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
I
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
...
...
@@ -74,7 +93,7 @@
<item>
<key>
<string>
component_validation_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
Q
=
</string>
</persistent>
</value>
</item>
</dictionary>
...
...
@@ -83,7 +102,7 @@
</dictionary>
</pickle>
</record>
<record
id=
"
3"
aka=
"AAAAAAAAAAM
="
>
<record
id=
"
4"
aka=
"AAAAAAAAAAQ
="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.AdvancedSaleTradeConditionConfiguratorItem.py
View file @
752833d9
...
...
@@ -28,14 +28,15 @@
import
zope.interface
from
AccessControl
import
ClassSecurityInfo
from
Products.ERP5Type
import
Permissions
,
PropertySheet
,
interfaces
from
Products.ERP5Type
import
Permissions
,
PropertySheet
from
Products.ERP5Type.XMLObject
import
XMLObject
from
Products.ERP5Type.Message
import
translateString
from
erp5.component.mixin.ConfiguratorItemMixin
import
ConfiguratorItemMixin
from
erp5.component.interface.IConfiguratorItem
import
IConfiguratorItem
class
AdvancedSaleTradeConditionConfiguratorItem
(
ConfiguratorItemMixin
,
XMLObject
):
""" Setup
Rule
s. """
""" Setup
Sale Trade Condition
s. """
meta_type
=
'ERP5 Advanced Sale Trade Condition Configurator Item'
portal_type
=
'Advanced Sale Trade Condition Configurator Item'
...
...
@@ -58,7 +59,7 @@ class AdvancedSaleTradeConditionConfiguratorItem(ConfiguratorItemMixin, XMLObjec
,
PropertySheet
.
Reference
)
def
_checkConsistency
(
self
,
fixit
=
False
,
filter
=
None
,
**
kw
):
def
_checkConsistency
(
self
,
fixit
=
False
,
**
kw
):
if
fixit
:
portal
=
self
.
getPortalObject
()
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.AdvancedSaleTradeConditionConfiguratorItem.xml
View file @
752833d9
...
...
@@ -6,6 +6,12 @@
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_recorded_property_dict
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
AdvancedSaleTradeConditionConfiguratorItem
</string>
</value>
...
...
@@ -43,9 +49,7 @@
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple>
<string>
W: 60, 43: Redefining built-in \'filter\' (redefined-builtin)
</string>
</tuple>
<tuple/>
</value>
</item>
<item>
...
...
@@ -55,13 +59,28 @@
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
I
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
...
...
@@ -74,7 +93,7 @@
<item>
<key>
<string>
component_validation_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
Q
=
</string>
</persistent>
</value>
</item>
</dictionary>
...
...
@@ -83,7 +102,7 @@
</dictionary>
</pickle>
</record>
<record
id=
"
3"
aka=
"AAAAAAAAAAM
="
>
<record
id=
"
4"
aka=
"AAAAAAAAAAQ
="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.AlarmConfiguratorItem.py
View file @
752833d9
...
...
@@ -28,12 +28,13 @@
import
zope.interface
from
AccessControl
import
ClassSecurityInfo
from
Products.ERP5Type
import
Permissions
,
PropertySheet
,
interfaces
from
Products.ERP5Type
import
Permissions
,
PropertySheet
from
Products.ERP5Type.XMLObject
import
XMLObject
from
erp5.component.mixin.ConfiguratorItemMixin
import
ConfiguratorItemMixin
from
erp5.component.interface.IConfiguratorItem
import
IConfiguratorItem
from
DateTime
import
DateTime
class
AlarmConfiguratorItem
(
ConfiguratorItemMixin
,
XMLObject
):
""" Setup an Alarm """
...
...
@@ -59,7 +60,7 @@ class AlarmConfiguratorItem(ConfiguratorItemMixin, XMLObject):
,
PropertySheet
.
Periodicity
)
def
_checkConsistency
(
self
,
fixit
=
False
,
filter
=
None
,
**
kw
):
def
_checkConsistency
(
self
,
fixit
=
False
,
**
kw
):
portal_alarms
=
self
.
getPortalObject
().
portal_alarms
error_list
=
[]
property_dict
=
{
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.AlarmConfiguratorItem.xml
View file @
752833d9
...
...
@@ -49,9 +49,7 @@
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple>
<string>
W: 61, 43: Redefining built-in \'filter\' (redefined-builtin)
</string>
</tuple>
<tuple/>
</value>
</item>
<item>
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.BankAccountConfiguratorItem.py
View file @
752833d9
...
...
@@ -29,12 +29,13 @@
import
zope.interface
from
AccessControl
import
ClassSecurityInfo
from
DateTime
import
DateTime
from
Products.ERP5Type
import
Permissions
,
PropertySheet
,
interfaces
from
Products.ERP5Type
import
Permissions
,
PropertySheet
from
Products.ERP5Type.XMLObject
import
XMLObject
from
Products.ERP5Type.Message
import
translateString
from
erp5.component.mixin.ConfiguratorItemMixin
import
ConfiguratorItemMixin
from
erp5.component.interface.IConfiguratorItem
import
IConfiguratorItem
class
BankAccountConfiguratorItem
(
ConfiguratorItemMixin
,
XMLObject
):
""" Setup bank account. """
...
...
@@ -58,7 +59,7 @@ class BankAccountConfiguratorItem(ConfiguratorItemMixin, XMLObject):
,
PropertySheet
.
DublinCore
,
PropertySheet
.
BankAccount
)
def
_checkConsistency
(
self
,
fixit
=
False
,
filter
=
None
,
**
kw
):
def
_checkConsistency
(
self
,
fixit
=
False
,
**
kw
):
organisation_module
=
self
.
getPortalObject
().
organisation_module
error_list
=
[]
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.BankAccountConfiguratorItem.xml
View file @
752833d9
...
...
@@ -6,6 +6,12 @@
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_recorded_property_dict
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
BankAccountConfiguratorItem
</string>
</value>
...
...
@@ -43,9 +49,7 @@
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple>
<string>
W: 60, 43: Redefining built-in \'filter\' (redefined-builtin)
</string>
</tuple>
<tuple/>
</value>
</item>
<item>
...
...
@@ -55,13 +59,28 @@
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
I
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
...
...
@@ -74,7 +93,7 @@
<item>
<key>
<string>
component_validation_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
Q
=
</string>
</persistent>
</value>
</item>
</dictionary>
...
...
@@ -83,7 +102,7 @@
</dictionary>
</pickle>
</record>
<record
id=
"
3"
aka=
"AAAAAAAAAAM
="
>
<record
id=
"
4"
aka=
"AAAAAAAAAAQ
="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.BusinessProcessConfiguratorItem.py
View file @
752833d9
...
...
@@ -28,12 +28,13 @@
import
zope.interface
from
AccessControl
import
ClassSecurityInfo
from
Products.ERP5Type
import
Permissions
,
PropertySheet
,
interfaces
from
Products.ERP5Type
import
Permissions
,
PropertySheet
from
Products.ERP5Type.XMLObject
import
XMLObject
from
Products.ERP5Type.Message
import
translateString
from
erp5.component.mixin.ConfiguratorItemMixin
import
ConfiguratorItemMixin
from
erp5.component.interface.IConfiguratorItem
import
IConfiguratorItem
class
BusinessProcessConfiguratorItem
(
ConfiguratorItemMixin
,
XMLObject
):
""" Setup Rules. """
...
...
@@ -59,7 +60,7 @@ class BusinessProcessConfiguratorItem(ConfiguratorItemMixin, XMLObject):
,
PropertySheet
.
Reference
)
def
_checkConsistency
(
self
,
fixit
=
False
,
filter
=
None
,
**
kw
):
def
_checkConsistency
(
self
,
fixit
=
False
,
**
kw
):
error_list
=
[
"Business Process %s should be created"
%
self
.
getReference
(),]
if
fixit
:
portal
=
self
.
getPortalObject
()
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.BusinessProcessConfiguratorItem.xml
View file @
752833d9
...
...
@@ -49,9 +49,7 @@
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple>
<string>
W: 61, 43: Redefining built-in \'filter\' (redefined-builtin)
</string>
</tuple>
<tuple/>
</value>
</item>
<item>
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.CatalogKeywordKeyConfiguratorItem.py
View file @
752833d9
...
...
@@ -28,12 +28,13 @@
import
zope.interface
from
AccessControl
import
ClassSecurityInfo
from
Products.ERP5Type
import
Permissions
,
PropertySheet
,
interfaces
from
Products.ERP5Type
import
Permissions
,
PropertySheet
from
Products.ERP5Type.XMLObject
import
XMLObject
from
erp5.component.mixin.ConfiguratorItemMixin
import
ConfiguratorItemMixin
from
erp5.component.interface.IConfiguratorItem
import
IConfiguratorItem
class
CatalogKeywordKeyConfiguratorItem
(
ConfiguratorItemMixin
,
XMLObject
):
"""Set up catalog keyword keys."""
...
...
@@ -56,7 +57,7 @@ class CatalogKeywordKeyConfiguratorItem(ConfiguratorItemMixin, XMLObject):
,
PropertySheet
.
CategoryCore
,
PropertySheet
.
DublinCore
)
def
_checkConsistency
(
self
,
fixit
=
False
,
filter
=
None
,
**
kw
):
def
_checkConsistency
(
self
,
fixit
=
False
,
**
kw
):
error_list
=
[]
portal
=
self
.
getPortalObject
()
catalog
=
portal
.
portal_catalog
.
getSQLCatalog
()
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.CatalogKeywordKeyConfiguratorItem.xml
View file @
752833d9
...
...
@@ -49,9 +49,7 @@
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple>
<string>
W: 58, 43: Redefining built-in \'filter\' (redefined-builtin)
</string>
</tuple>
<tuple/>
</value>
</item>
<item>
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.CategoriesSpreadsheetConfiguratorItem.py
View file @
752833d9
...
...
@@ -30,11 +30,12 @@ import zope.interface
from
StringIO
import
StringIO
from
Acquisition
import
aq_base
from
AccessControl
import
ClassSecurityInfo
from
Products.ERP5Type
import
Permissions
,
PropertySheet
,
interfaces
from
Products.ERP5Type
import
Permissions
,
PropertySheet
from
Products.ERP5Type.XMLObject
import
XMLObject
from
erp5.component.mixin.ConfiguratorItemMixin
import
ConfiguratorItemMixin
from
erp5.component.interface.IConfiguratorItem
import
IConfiguratorItem
class
UnrestrictedStringIO
(
StringIO
):
__allow_access_to_unprotected_subobjects__
=
1
...
...
@@ -64,7 +65,7 @@ class CategoriesSpreadsheetConfiguratorItem(ConfiguratorItemMixin, XMLObject):
,
PropertySheet
.
ConfiguratorItem
)
def
_checkConsistency
(
self
,
fixit
=
False
,
filter
=
None
,
**
kw
):
def
_checkConsistency
(
self
,
fixit
=
False
,
**
kw
):
portal
=
self
.
getPortalObject
()
ctool
=
portal
.
portal_categories
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.CategoriesSpreadsheetConfiguratorItem.xml
View file @
752833d9
...
...
@@ -6,6 +6,12 @@
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_recorded_property_dict
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
CategoriesSpreadsheetConfiguratorItem
</string>
</value>
...
...
@@ -43,9 +49,7 @@
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple>
<string>
W: 67, 43: Redefining built-in \'filter\' (redefined-builtin)
</string>
</tuple>
<tuple/>
</value>
</item>
<item>
...
...
@@ -55,13 +59,28 @@
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
I
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
...
...
@@ -74,7 +93,7 @@
<item>
<key>
<string>
component_validation_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
Q
=
</string>
</persistent>
</value>
</item>
</dictionary>
...
...
@@ -83,7 +102,7 @@
</dictionary>
</pickle>
</record>
<record
id=
"
3"
aka=
"AAAAAAAAAAM
="
>
<record
id=
"
4"
aka=
"AAAAAAAAAAQ
="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.CategoryConfiguratorItem.py
View file @
752833d9
##############################################################################
#
# Copyright (c) 2006 Nexedi SARL and Contributors. All Rights Reserved.
# Ivan Tyagov <ivan@nexedi.com>
#
...
...
@@ -29,11 +28,12 @@
import
zope.interface
from
AccessControl
import
ClassSecurityInfo
from
Products.ERP5Type
import
Permissions
,
PropertySheet
,
interfaces
from
Products.ERP5Type
import
Permissions
,
PropertySheet
from
Products.ERP5Type.XMLObject
import
XMLObject
from
erp5.component.mixin.ConfiguratorItemMixin
import
ConfiguratorItemMixin
from
erp5.component.interface.IConfiguratorItem
import
IConfiguratorItem
class
CategoryConfiguratorItem
(
ConfiguratorItemMixin
,
XMLObject
):
"""This class is meta build step for customization of ERP5 site."""
...
...
@@ -56,7 +56,7 @@ class CategoryConfiguratorItem(ConfiguratorItemMixin, XMLObject):
,
PropertySheet
.
CategoryCore
,
PropertySheet
.
DublinCore
)
def
_checkConsistency
(
self
,
fixit
=
False
,
filter
=
None
,
**
kw
):
def
_checkConsistency
(
self
,
fixit
=
False
,
**
kw
):
if
fixit
:
portal
=
self
.
getPortalObject
()
category_root
=
portal
.
portal_categories
[
self
.
category_root
]
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.CategoryConfiguratorItem.xml
View file @
752833d9
...
...
@@ -6,6 +6,12 @@
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_recorded_property_dict
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
CategoryConfiguratorItem
</string>
</value>
...
...
@@ -43,9 +49,7 @@
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple>
<string>
W: 58, 43: Redefining built-in \'filter\' (redefined-builtin)
</string>
</tuple>
<tuple/>
</value>
</item>
<item>
...
...
@@ -55,13 +59,28 @@
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
I
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
...
...
@@ -74,7 +93,7 @@
<item>
<key>
<string>
component_validation_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
Q
=
</string>
</persistent>
</value>
</item>
</dictionary>
...
...
@@ -83,7 +102,7 @@
</dictionary>
</pickle>
</record>
<record
id=
"
3"
aka=
"AAAAAAAAAAM
="
>
<record
id=
"
4"
aka=
"AAAAAAAAAAQ
="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.CurrencyConfiguratorItem.py
View file @
752833d9
##############################################################################
#
# Copyright (c) 2006 Nexedi SARL and Contributors. All Rights Reserved.
# Ivan Tyagov <ivan@nexedi.com>
#
...
...
@@ -29,12 +28,13 @@
import
zope.interface
from
AccessControl
import
ClassSecurityInfo
from
Products.ERP5Type
import
Permissions
,
PropertySheet
,
interfaces
from
Products.ERP5Type
import
Permissions
,
PropertySheet
from
Products.ERP5Type.XMLObject
import
XMLObject
from
Products.ERP5Type.Message
import
translateString
from
erp5.component.mixin.ConfiguratorItemMixin
import
ConfiguratorItemMixin
from
erp5.component.interface.IConfiguratorItem
import
IConfiguratorItem
class
CurrencyConfiguratorItem
(
ConfiguratorItemMixin
,
XMLObject
):
""" Setup currency. """
...
...
@@ -60,7 +60,7 @@ class CurrencyConfiguratorItem(ConfiguratorItemMixin, XMLObject):
,
PropertySheet
.
Resource
,
PropertySheet
.
Reference
)
def
_checkConsistency
(
self
,
fixit
=
False
,
filter
=
None
,
**
kw
):
def
_checkConsistency
(
self
,
fixit
=
False
,
**
kw
):
currency_module
=
self
.
getPortalObject
().
currency_module
error_list
=
[]
title
=
self
.
getTitle
()
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.CurrencyConfiguratorItem.xml
View file @
752833d9
...
...
@@ -6,6 +6,12 @@
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_recorded_property_dict
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
CurrencyConfiguratorItem
</string>
</value>
...
...
@@ -43,9 +49,7 @@
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple>
<string>
W: 62, 43: Redefining built-in \'filter\' (redefined-builtin)
</string>
</tuple>
<tuple/>
</value>
</item>
<item>
...
...
@@ -55,13 +59,28 @@
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
I
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
...
...
@@ -74,7 +93,7 @@
<item>
<key>
<string>
component_validation_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
Q
=
</string>
</persistent>
</value>
</item>
</dictionary>
...
...
@@ -83,7 +102,7 @@
</dictionary>
</pickle>
</record>
<record
id=
"
3"
aka=
"AAAAAAAAAAM
="
>
<record
id=
"
4"
aka=
"AAAAAAAAAAQ
="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.CustomerBT5ConfiguratorItem.py
View file @
752833d9
##############################################################################
#
# Copyright (c) 2006 Nexedi SARL and Contributors. All Rights Reserved.
# Ivan Tyagov <ivan@nexedi.com>
#
...
...
@@ -29,11 +27,12 @@
import
zope.interface
from
AccessControl
import
ClassSecurityInfo
from
Products.ERP5Type
import
Permissions
,
PropertySheet
,
interfaces
from
Products.ERP5Type
import
Permissions
,
PropertySheet
from
Products.ERP5Type.XMLObject
import
XMLObject
from
erp5.component.mixin.ConfiguratorItemMixin
import
ConfiguratorItemMixin
from
erp5.component.interface.IConfiguratorItem
import
IConfiguratorItem
class
CustomerBT5ConfiguratorItem
(
ConfiguratorItemMixin
,
XMLObject
):
""" Create a new bt5 for customer configuration.
...
...
@@ -59,7 +58,7 @@ class CustomerBT5ConfiguratorItem(ConfiguratorItemMixin, XMLObject):
,
PropertySheet
.
CategoryCore
,
PropertySheet
.
DublinCore
)
def
_checkConsistency
(
self
,
fixit
=
False
,
filter
=
None
,
**
kw
):
def
_checkConsistency
(
self
,
fixit
=
False
,
**
kw
):
template_tool
=
self
.
getPortalObject
().
portal_templates
error_list
=
[]
if
self
.
bt5_title
not
in
template_tool
.
getBuiltBusinessTemplateList
():
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.CustomerBT5ConfiguratorItem.xml
View file @
752833d9
...
...
@@ -6,6 +6,12 @@
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_recorded_property_dict
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
CustomerBT5ConfiguratorItem
</string>
</value>
...
...
@@ -43,9 +49,7 @@
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple>
<string>
W: 61, 43: Redefining built-in \'filter\' (redefined-builtin)
</string>
</tuple>
<tuple/>
</value>
</item>
<item>
...
...
@@ -55,13 +59,28 @@
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
I
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
...
...
@@ -74,7 +93,7 @@
<item>
<key>
<string>
component_validation_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
Q
=
</string>
</persistent>
</value>
</item>
</dictionary>
...
...
@@ -83,7 +102,7 @@
</dictionary>
</pickle>
</record>
<record
id=
"
3"
aka=
"AAAAAAAAAAM
="
>
<record
id=
"
4"
aka=
"AAAAAAAAAAQ
="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.OrganisationConfiguratorItem.py
View file @
752833d9
...
...
@@ -29,12 +29,13 @@
import
zope.interface
from
AccessControl
import
ClassSecurityInfo
from
Products.ERP5Type
import
Permissions
,
PropertySheet
,
interfaces
from
Products.ERP5Type
import
Permissions
,
PropertySheet
from
Products.ERP5Type.XMLObject
import
XMLObject
from
Products.ERP5Type.Message
import
translateString
from
erp5.component.mixin.ConfiguratorItemMixin
import
ConfiguratorItemMixin
from
erp5.component.interface.IConfiguratorItem
import
IConfiguratorItem
class
OrganisationConfiguratorItem
(
ConfiguratorItemMixin
,
XMLObject
):
""" This class install a Organisation."""
...
...
@@ -58,7 +59,7 @@ class OrganisationConfiguratorItem(ConfiguratorItemMixin, XMLObject):
,
PropertySheet
.
DublinCore
,
PropertySheet
.
Organisation
)
def
_checkConsistency
(
self
,
fixit
=
False
,
filter
=
None
,
**
kw
):
def
_checkConsistency
(
self
,
fixit
=
False
,
**
kw
):
""" Setup organisation. """
if
fixit
:
portal
=
self
.
getPortalObject
()
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.OrganisationConfiguratorItem.xml
View file @
752833d9
...
...
@@ -6,6 +6,12 @@
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_recorded_property_dict
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
OrganisationConfiguratorItem
</string>
</value>
...
...
@@ -43,9 +49,7 @@
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple>
<string>
W: 60, 43: Redefining built-in \'filter\' (redefined-builtin)
</string>
</tuple>
<tuple/>
</value>
</item>
<item>
...
...
@@ -55,13 +59,28 @@
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
I
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
...
...
@@ -74,7 +93,7 @@
<item>
<key>
<string>
component_validation_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
Q
=
</string>
</persistent>
</value>
</item>
</dictionary>
...
...
@@ -83,7 +102,7 @@
</dictionary>
</pickle>
</record>
<record
id=
"
3"
aka=
"AAAAAAAAAAM
="
>
<record
id=
"
4"
aka=
"AAAAAAAAAAQ
="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.PermissionConfiguratorItem.py
View file @
752833d9
##############################################################################
#
# Copyright (c) 2006 Nexedi SARL and Contributors. All Rights Reserved.
# Ivan Tyagov <ivan@nexedi.com>
#
...
...
@@ -29,11 +28,12 @@
import
zope.interface
from
AccessControl
import
ClassSecurityInfo
from
Products.ERP5Type
import
Permissions
,
PropertySheet
,
interfaces
from
Products.ERP5Type
import
Permissions
,
PropertySheet
from
Products.ERP5Type.XMLObject
import
XMLObject
from
erp5.component.mixin.ConfiguratorItemMixin
import
ConfiguratorItemMixin
from
erp5.component.interface.IConfiguratorItem
import
IConfiguratorItem
class
PermissionConfiguratorItem
(
ConfiguratorItemMixin
,
XMLObject
):
""" Set permission matrix on module."""
...
...
@@ -56,7 +56,7 @@ class PermissionConfiguratorItem(ConfiguratorItemMixin, XMLObject):
,
PropertySheet
.
CategoryCore
,
PropertySheet
.
DublinCore
)
def
_checkConsistency
(
self
,
fixit
=
False
,
filter
=
None
,
**
kw
):
def
_checkConsistency
(
self
,
fixit
=
False
,
**
kw
):
template_module_id_list
=
[]
error_list
=
[]
module_permissions_map
=
{}
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.PermissionConfiguratorItem.xml
View file @
752833d9
...
...
@@ -6,6 +6,12 @@
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_recorded_property_dict
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
PermissionConfiguratorItem
</string>
</value>
...
...
@@ -43,9 +49,7 @@
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple>
<string>
W: 58, 43: Redefining built-in \'filter\' (redefined-builtin)
</string>
</tuple>
<tuple/>
</value>
</item>
<item>
...
...
@@ -55,13 +59,28 @@
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
I
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
...
...
@@ -74,7 +93,7 @@
<item>
<key>
<string>
component_validation_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
Q
=
</string>
</persistent>
</value>
</item>
</dictionary>
...
...
@@ -83,7 +102,7 @@
</dictionary>
</pickle>
</record>
<record
id=
"
3"
aka=
"AAAAAAAAAAM
="
>
<record
id=
"
4"
aka=
"AAAAAAAAAAQ
="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.PersonConfiguratorItem.py
View file @
752833d9
...
...
@@ -29,13 +29,14 @@
import
zope.interface
from
Acquisition
import
aq_base
from
AccessControl
import
ClassSecurityInfo
from
Products.ERP5Type
import
Permissions
,
PropertySheet
,
interfaces
from
Products.ERP5Type
import
Permissions
,
PropertySheet
from
Products.ERP5Type.XMLObject
import
XMLObject
from
Products.ERP5Type.Message
import
translateString
from
DateTime
import
DateTime
from
erp5.component.mixin.ConfiguratorItemMixin
import
ConfiguratorItemMixin
from
erp5.component.interface.IConfiguratorItem
import
IConfiguratorItem
class
PersonConfiguratorItem
(
XMLObject
,
ConfiguratorItemMixin
):
""" Setup user. """
...
...
@@ -61,7 +62,7 @@ class PersonConfiguratorItem(XMLObject, ConfiguratorItemMixin):
,
PropertySheet
.
Person
,
PropertySheet
.
Login
)
def
_checkConsistency
(
self
,
fixit
=
False
,
filter
=
None
,
**
kw
):
def
_checkConsistency
(
self
,
fixit
=
False
,
**
kw
):
error_list
=
[]
person_list
=
self
.
acl_users
.
searchUsers
(
id
=
self
.
Person_getUserId
(),
exact_match
=
True
)
if
not
person_list
:
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.PersonConfiguratorItem.xml
View file @
752833d9
...
...
@@ -49,9 +49,7 @@
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple>
<string>
W: 63, 43: Redefining built-in \'filter\' (redefined-builtin)
</string>
</tuple>
<tuple/>
</value>
</item>
<item>
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.PortalTypeConfiguratorItem.py
View file @
752833d9
...
...
@@ -28,11 +28,12 @@
import
zope.interface
from
AccessControl
import
ClassSecurityInfo
from
Products.ERP5Type
import
Permissions
,
PropertySheet
,
interfaces
from
Products.ERP5Type
import
Permissions
,
PropertySheet
from
Products.ERP5Type.XMLObject
import
XMLObject
from
erp5.component.mixin.ConfiguratorItemMixin
import
ConfiguratorItemMixin
from
erp5.component.interface.IConfiguratorItem
import
IConfiguratorItem
class
PortalTypeConfiguratorItem
(
ConfiguratorItemMixin
,
XMLObject
):
"""Configure Portal Type."""
...
...
@@ -55,7 +56,7 @@ class PortalTypeConfiguratorItem(ConfiguratorItemMixin, XMLObject):
,
PropertySheet
.
CategoryCore
,
PropertySheet
.
DublinCore
)
def
_checkConsistency
(
self
,
fixit
=
False
,
filter
=
None
,
**
kw
):
def
_checkConsistency
(
self
,
fixit
=
False
,
**
kw
):
portal
=
self
.
getPortalObject
()
# Support adding new property sheet to portal type information.
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.PortalTypeConfiguratorItem.xml
View file @
752833d9
...
...
@@ -6,6 +6,12 @@
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_recorded_property_dict
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
PortalTypeConfiguratorItem
</string>
</value>
...
...
@@ -43,9 +49,7 @@
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple>
<string>
W: 57, 43: Redefining built-in \'filter\' (redefined-builtin)
</string>
</tuple>
<tuple/>
</value>
</item>
<item>
...
...
@@ -55,13 +59,28 @@
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
I
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
...
...
@@ -74,7 +93,7 @@
<item>
<key>
<string>
component_validation_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
Q
=
</string>
</persistent>
</value>
</item>
</dictionary>
...
...
@@ -83,7 +102,7 @@
</dictionary>
</pickle>
</record>
<record
id=
"
3"
aka=
"AAAAAAAAAAM
="
>
<record
id=
"
4"
aka=
"AAAAAAAAAAQ
="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.PortalTypeRolesSpreadsheetConfiguratorItem.py
View file @
752833d9
...
...
@@ -28,11 +28,12 @@
import
zope.interface
from
zLOG
import
LOG
,
INFO
from
AccessControl
import
ClassSecurityInfo
from
Products.ERP5Type
import
Permissions
,
PropertySheet
,
interfaces
from
Products.ERP5Type
import
Permissions
,
PropertySheet
from
Products.ERP5Type.XMLObject
import
XMLObject
from
erp5.component.mixin.ConfiguratorItemMixin
import
ConfiguratorItemMixin
from
erp5.component.interface.IConfiguratorItem
import
IConfiguratorItem
class
PortalTypeRolesSpreadsheetConfiguratorItem
(
ConfiguratorItemMixin
,
XMLObject
):
"""Import a portal type roles spreadsheet.
"""
...
...
@@ -57,7 +58,7 @@ class PortalTypeRolesSpreadsheetConfiguratorItem(ConfiguratorItemMixin, XMLObjec
,
PropertySheet
.
DublinCore
,
PropertySheet
.
ConfiguratorItem
)
def
_checkConsistency
(
self
,
fixit
=
False
,
filter
=
None
,
**
kw
):
def
_checkConsistency
(
self
,
fixit
=
False
,
**
kw
):
portal
=
self
.
getPortalObject
()
portal_type_role_dict
=
self
.
_getPortalTypeRoleDict
()
error_list
=
[]
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.PortalTypeRolesSpreadsheetConfiguratorItem.xml
View file @
752833d9
...
...
@@ -6,6 +6,12 @@
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_recorded_property_dict
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
PortalTypeRolesSpreadsheetConfiguratorItem
</string>
</value>
...
...
@@ -43,9 +49,7 @@
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple>
<string>
W: 61, 43: Redefining built-in \'filter\' (redefined-builtin)
</string>
</tuple>
<tuple/>
</value>
</item>
<item>
...
...
@@ -55,13 +59,28 @@
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
I
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
...
...
@@ -74,7 +93,7 @@
<item>
<key>
<string>
component_validation_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
Q
=
</string>
</persistent>
</value>
</item>
</dictionary>
...
...
@@ -83,7 +102,7 @@
</dictionary>
</pickle>
</record>
<record
id=
"
3"
aka=
"AAAAAAAAAAM
="
>
<record
id=
"
4"
aka=
"AAAAAAAAAAQ
="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.PreferenceConfiguratorItem.py
View file @
752833d9
...
...
@@ -28,11 +28,12 @@
import
zope.interface
from
AccessControl
import
ClassSecurityInfo
from
Products.ERP5Type
import
Permissions
,
PropertySheet
,
interfaces
from
Products.ERP5Type
import
Permissions
,
PropertySheet
from
Products.ERP5Type.XMLObject
import
XMLObject
from
erp5.component.mixin.ConfiguratorItemMixin
import
ConfiguratorItemMixin
from
erp5.component.interface.IConfiguratorItem
import
IConfiguratorItem
class
PreferenceConfiguratorItem
(
ConfiguratorItemMixin
,
XMLObject
):
""" Setup preference. """
...
...
@@ -72,7 +73,7 @@ class PreferenceConfiguratorItem(ConfiguratorItemMixin, XMLObject):
property_id_list
.
append
(
'%s%s'
%
(
prop
.
getReference
(),
list_prefix
))
return
property_id_list
def
_checkConsistency
(
self
,
fixit
=
False
,
filter
=
None
,
**
kw
):
def
_checkConsistency
(
self
,
fixit
=
False
,
**
kw
):
error_list
=
[]
portal
=
self
.
getPortalObject
()
preference
=
portal
.
portal_preferences
.
_getOb
(
self
.
object_id
,
None
)
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.PreferenceConfiguratorItem.xml
View file @
752833d9
...
...
@@ -6,6 +6,12 @@
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_recorded_property_dict
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
PreferenceConfiguratorItem
</string>
</value>
...
...
@@ -43,9 +49,7 @@
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple>
<string>
W: 74, 43: Redefining built-in \'filter\' (redefined-builtin)
</string>
</tuple>
<tuple/>
</value>
</item>
<item>
...
...
@@ -55,13 +59,28 @@
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
I
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
...
...
@@ -74,7 +93,7 @@
<item>
<key>
<string>
component_validation_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
Q
=
</string>
</persistent>
</value>
</item>
</dictionary>
...
...
@@ -83,7 +102,7 @@
</dictionary>
</pickle>
</record>
<record
id=
"
3"
aka=
"AAAAAAAAAAM
="
>
<record
id=
"
4"
aka=
"AAAAAAAAAAQ
="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.PurchaseTradeConditionConfiguratorItem.py
View file @
752833d9
...
...
@@ -28,12 +28,13 @@
import
zope.interface
from
AccessControl
import
ClassSecurityInfo
from
Products.ERP5Type
import
Permissions
,
PropertySheet
,
interfaces
from
Products.ERP5Type
import
Permissions
,
PropertySheet
from
Products.ERP5Type.XMLObject
import
XMLObject
from
Products.ERP5Type.Message
import
translateString
from
erp5.component.mixin.ConfiguratorItemMixin
import
ConfiguratorItemMixin
from
erp5.component.interface.IConfiguratorItem
import
IConfiguratorItem
class
PurchaseTradeConditionConfiguratorItem
(
ConfiguratorItemMixin
,
XMLObject
):
""" Setup Rules. """
...
...
@@ -58,7 +59,7 @@ class PurchaseTradeConditionConfiguratorItem(ConfiguratorItemMixin, XMLObject):
,
PropertySheet
.
Reference
)
def
_checkConsistency
(
self
,
fixit
=
False
,
filter
=
None
,
**
kw
):
def
_checkConsistency
(
self
,
fixit
=
False
,
**
kw
):
if
fixit
:
portal
=
self
.
getPortalObject
()
business_configuration
=
self
.
getBusinessConfigurationValue
()
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.PurchaseTradeConditionConfiguratorItem.xml
View file @
752833d9
...
...
@@ -6,6 +6,12 @@
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_recorded_property_dict
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
PurchaseTradeConditionConfiguratorItem
</string>
</value>
...
...
@@ -43,9 +49,7 @@
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple>
<string>
W: 60, 43: Redefining built-in \'filter\' (redefined-builtin)
</string>
</tuple>
<tuple/>
</value>
</item>
<item>
...
...
@@ -55,13 +59,28 @@
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
I
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
...
...
@@ -74,7 +93,7 @@
<item>
<key>
<string>
component_validation_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
Q
=
</string>
</persistent>
</value>
</item>
</dictionary>
...
...
@@ -83,7 +102,7 @@
</dictionary>
</pickle>
</record>
<record
id=
"
3"
aka=
"AAAAAAAAAAM
="
>
<record
id=
"
4"
aka=
"AAAAAAAAAAQ
="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.RoleConfiguratorItem.py
View file @
752833d9
...
...
@@ -29,12 +29,13 @@
import
zope.interface
from
Acquisition
import
aq_base
from
AccessControl
import
ClassSecurityInfo
from
Products.ERP5Type
import
Permissions
,
PropertySheet
,
interfaces
from
Products.ERP5Type
import
Permissions
,
PropertySheet
from
Products.ERP5Type.XMLObject
import
XMLObject
from
erp5.component.mixin.ConfiguratorItemMixin
import
ConfiguratorItemMixin
from
erp5.component.interface.IConfiguratorItem
import
IConfiguratorItem
from
zLOG
import
LOG
,
INFO
class
RoleConfiguratorItem
(
ConfiguratorItemMixin
,
XMLObject
):
""" Setup role per module basis. """
...
...
@@ -57,7 +58,7 @@ class RoleConfiguratorItem(ConfiguratorItemMixin, XMLObject):
,
PropertySheet
.
CategoryCore
,
PropertySheet
.
DublinCore
)
def
_checkConsistency
(
self
,
fixit
=
False
,
filter
=
None
,
**
kw
):
def
_checkConsistency
(
self
,
fixit
=
False
,
**
kw
):
error_list
=
[
'Roles should imported and created'
,]
if
fixit
:
business_configuration
=
self
.
getBusinessConfigurationValue
()
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.RoleConfiguratorItem.xml
View file @
752833d9
...
...
@@ -6,6 +6,12 @@
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_recorded_property_dict
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
RoleConfiguratorItem
</string>
</value>
...
...
@@ -43,9 +49,7 @@
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple>
<string>
W: 59, 43: Redefining built-in \'filter\' (redefined-builtin)
</string>
</tuple>
<tuple/>
</value>
</item>
<item>
...
...
@@ -55,13 +59,28 @@
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
I
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
...
...
@@ -74,7 +93,7 @@
<item>
<key>
<string>
component_validation_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
Q
=
</string>
</persistent>
</value>
</item>
</dictionary>
...
...
@@ -83,7 +102,7 @@
</dictionary>
</pickle>
</record>
<record
id=
"
3"
aka=
"AAAAAAAAAAM
="
>
<record
id=
"
4"
aka=
"AAAAAAAAAAQ
="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.RuleConfiguratorItem.py
View file @
752833d9
...
...
@@ -29,7 +29,7 @@
import
zope.interface
from
AccessControl
import
ClassSecurityInfo
from
Products.ERP5Type
import
Permissions
,
PropertySheet
,
interfaces
from
Products.ERP5Type
import
Permissions
,
PropertySheet
from
Products.ERP5Type.XMLObject
import
XMLObject
from
erp5.component.mixin.ConfiguratorItemMixin
import
ConfiguratorItemMixin
from
erp5.component.interface.IConfiguratorItem
import
IConfiguratorItem
...
...
@@ -57,7 +57,7 @@ class RuleConfiguratorItem(ConfiguratorItemMixin, XMLObject):
,
PropertySheet
.
DublinCore
,
PropertySheet
.
Reference
)
def
_checkConsistency
(
self
,
fixit
=
False
,
filter
=
None
,
**
kw
):
def
_checkConsistency
(
self
,
fixit
=
False
,
**
kw
):
if
fixit
:
portal
=
self
.
getPortalObject
()
template_id
=
self
.
getId
()
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.RuleConfiguratorItem.xml
View file @
752833d9
...
...
@@ -6,6 +6,12 @@
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_recorded_property_dict
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
RuleConfiguratorItem
</string>
</value>
...
...
@@ -43,9 +49,7 @@
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple>
<string>
W: 59, 43: Redefining built-in \'filter\' (redefined-builtin)
</string>
</tuple>
<tuple/>
</value>
</item>
<item>
...
...
@@ -55,13 +59,28 @@
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
I
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
...
...
@@ -74,7 +93,7 @@
<item>
<key>
<string>
component_validation_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
Q
=
</string>
</persistent>
</value>
</item>
</dictionary>
...
...
@@ -83,7 +102,7 @@
</dictionary>
</pickle>
</record>
<record
id=
"
3"
aka=
"AAAAAAAAAAM
="
>
<record
id=
"
4"
aka=
"AAAAAAAAAAQ
="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.SaleTradeConditionConfiguratorItem.py
View file @
752833d9
...
...
@@ -28,12 +28,13 @@
import
zope.interface
from
AccessControl
import
ClassSecurityInfo
from
Products.ERP5Type
import
Permissions
,
PropertySheet
,
interfaces
from
Products.ERP5Type
import
Permissions
,
PropertySheet
from
Products.ERP5Type.XMLObject
import
XMLObject
from
Products.ERP5Type.Message
import
translateString
from
erp5.component.mixin.ConfiguratorItemMixin
import
ConfiguratorItemMixin
from
erp5.component.interface.IConfiguratorItem
import
IConfiguratorItem
class
SaleTradeConditionConfiguratorItem
(
ConfiguratorItemMixin
,
XMLObject
):
""" Setup Rules. """
...
...
@@ -58,7 +59,7 @@ class SaleTradeConditionConfiguratorItem(ConfiguratorItemMixin, XMLObject):
,
PropertySheet
.
Reference
)
def
_checkConsistency
(
self
,
fixit
=
False
,
filter
=
None
,
**
kw
):
def
_checkConsistency
(
self
,
fixit
=
False
,
**
kw
):
if
fixit
:
portal
=
self
.
getPortalObject
()
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.SaleTradeConditionConfiguratorItem.xml
View file @
752833d9
...
...
@@ -6,6 +6,12 @@
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_recorded_property_dict
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
SaleTradeConditionConfiguratorItem
</string>
</value>
...
...
@@ -43,9 +49,7 @@
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple>
<string>
W: 60, 43: Redefining built-in \'filter\' (redefined-builtin)
</string>
</tuple>
<tuple/>
</value>
</item>
<item>
...
...
@@ -55,13 +59,28 @@
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
I
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
...
...
@@ -74,7 +93,7 @@
<item>
<key>
<string>
component_validation_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
Q
=
</string>
</persistent>
</value>
</item>
</dictionary>
...
...
@@ -83,7 +102,7 @@
</dictionary>
</pickle>
</record>
<record
id=
"
3"
aka=
"AAAAAAAAAAM
="
>
<record
id=
"
4"
aka=
"AAAAAAAAAAQ
="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.SecurityCategoryMappingConfiguratorItem.py
View file @
752833d9
...
...
@@ -28,12 +28,13 @@
import
zope.interface
from
AccessControl
import
ClassSecurityInfo
from
Products.ERP5Type
import
Permissions
,
PropertySheet
,
interfaces
from
Products.ERP5Type
import
Permissions
,
PropertySheet
from
Products.ERP5Type.XMLObject
import
XMLObject
from
erp5.component.mixin.SkinConfiguratorItemMixin
import
\
SkinConfiguratorItemMixin
from
erp5.component.interface.IConfiguratorItem
import
IConfiguratorItem
class
SecurityCategoryMappingConfiguratorItem
(
SkinConfiguratorItemMixin
,
XMLObject
):
""" Setup the ERP5Type_getSecurityCategoryMapping Python Script which
...
...
@@ -58,11 +59,10 @@ class SecurityCategoryMappingConfiguratorItem(SkinConfiguratorItemMixin,
,
PropertySheet
.
CategoryCore
,
PropertySheet
.
DublinCore
)
def
_checkConsistency
(
self
,
fixit
=
False
,
filter
=
None
,
**
kw
):
def
_checkConsistency
(
self
,
fixit
=
False
,
**
kw
):
script_id
=
'ERP5Type_getSecurityCategoryMapping'
error_list
=
[
'%s should be created'
%
script_id
,]
if
fixit
:
portal_alarms
=
self
.
getPortalObject
().
portal_alarms
script_content
=
"""return (
('ERP5Type_getSecurityCategoryFromAssignmentStrict', ['function']),
('ERP5Type_getSecurityCategoryFromAssignmentStrict', ['follow_up']),
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.SecurityCategoryMappingConfiguratorItem.xml
View file @
752833d9
...
...
@@ -6,6 +6,12 @@
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_recorded_property_dict
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
SecurityCategoryMappingConfiguratorItem
</string>
</value>
...
...
@@ -43,10 +49,7 @@
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple>
<string>
W: 60, 43: Redefining built-in \'filter\' (redefined-builtin)
</string>
<string>
W: 64, 6: Unused variable \'portal_alarms\' (unused-variable)
</string>
</tuple>
<tuple/>
</value>
</item>
<item>
...
...
@@ -56,13 +59,28 @@
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
I
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
...
...
@@ -75,7 +93,7 @@
<item>
<key>
<string>
component_validation_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
Q
=
</string>
</persistent>
</value>
</item>
</dictionary>
...
...
@@ -84,7 +102,7 @@
</dictionary>
</pickle>
</record>
<record
id=
"
3"
aka=
"AAAAAAAAAAM
="
>
<record
id=
"
4"
aka=
"AAAAAAAAAAQ
="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.ServiceConfiguratorItem.py
View file @
752833d9
...
...
@@ -29,12 +29,13 @@
from
warnings
import
warn
import
zope.interface
from
AccessControl
import
ClassSecurityInfo
from
Products.ERP5Type
import
Permissions
,
PropertySheet
,
interfaces
from
Products.ERP5Type
import
Permissions
,
PropertySheet
from
Products.ERP5Type.XMLObject
import
XMLObject
from
Products.ERP5Type.Message
import
translateString
from
erp5.component.mixin.ConfiguratorItemMixin
import
ConfiguratorItemMixin
from
erp5.component.interface.IConfiguratorItem
import
IConfiguratorItem
class
ServiceConfiguratorItem
(
ConfiguratorItemMixin
,
XMLObject
):
"""Create default service documents."""
...
...
@@ -58,7 +59,7 @@ class ServiceConfiguratorItem(ConfiguratorItemMixin, XMLObject):
,
PropertySheet
.
DublinCore
,
PropertySheet
.
ConfiguratorItem
)
def
_checkConsistency
(
self
,
fixit
=
False
,
filter
=
None
,
**
kw
):
def
_checkConsistency
(
self
,
fixit
=
False
,
**
kw
):
portal
=
self
.
getPortalObject
()
error_list
=
[]
for
service_id
,
service_dict
in
iter
(
self
.
getConfigurationListList
()):
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.ServiceConfiguratorItem.xml
View file @
752833d9
...
...
@@ -49,9 +49,7 @@
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple>
<string>
W: 60, 43: Redefining built-in \'filter\' (redefined-builtin)
</string>
</tuple>
<tuple/>
</value>
</item>
<item>
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.SitePropertyConfiguratorItem.py
View file @
752833d9
...
...
@@ -28,11 +28,12 @@
import
zope.interface
from
AccessControl
import
ClassSecurityInfo
from
Products.ERP5Type
import
Permissions
,
PropertySheet
,
interfaces
from
Products.ERP5Type
import
Permissions
,
PropertySheet
from
Products.ERP5Type.XMLObject
import
XMLObject
from
erp5.component.mixin.ConfiguratorItemMixin
import
ConfiguratorItemMixin
from
erp5.component.interface.IConfiguratorItem
import
IConfiguratorItem
class
SitePropertyConfiguratorItem
(
ConfiguratorItemMixin
,
XMLObject
):
"""Set up site properties."""
...
...
@@ -56,19 +57,19 @@ class SitePropertyConfiguratorItem(ConfiguratorItemMixin, XMLObject):
,
PropertySheet
.
DublinCore
,
PropertySheet
.
ConfiguratorItem
)
def
_checkConsistency
(
self
,
fixit
=
False
,
filter
=
None
,
**
kw
):
def
_checkConsistency
(
self
,
fixit
=
False
,
**
kw
):
portal
=
self
.
getPortalObject
()
id_list
=
[]
for
id
,
value
,
prop_type
in
self
.
getConfigurationList
():
for
id
_
,
value
,
prop_type
in
self
.
getConfigurationList
():
if
fixit
:
if
portal
.
hasProperty
(
id
):
portal
.
_delProperty
(
id
)
portal
.
_setProperty
(
id
,
value
,
type
=
prop_type
)
id_list
.
append
(
id
)
if
portal
.
hasProperty
(
id
_
):
portal
.
_delProperty
(
id
_
)
portal
.
_setProperty
(
id
_
,
value
,
type
=
prop_type
)
id_list
.
append
(
id
_
)
if
fixit
:
business_configuration
=
self
.
getBusinessConfigurationValue
()
bt
=
business_configuration
.
getSpecialiseValue
()
bt
.
edit
(
template_site_property_id_list
=
id_list
)
return
[
"The property %s should set on portal"
%
id
for
id
in
id_list
]
return
[
"The property %s should set on portal"
%
id
_
for
id_
in
id_list
]
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.SitePropertyConfiguratorItem.xml
View file @
752833d9
...
...
@@ -6,6 +6,12 @@
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_recorded_property_dict
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
SitePropertyConfiguratorItem
</string>
</value>
...
...
@@ -43,10 +49,7 @@
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple>
<string>
W: 58, 43: Redefining built-in \'filter\' (redefined-builtin)
</string>
<string>
W: 61, 8: Redefining built-in \'id\' (redefined-builtin)
</string>
</tuple>
<tuple/>
</value>
</item>
<item>
...
...
@@ -56,13 +59,28 @@
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
I
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
...
...
@@ -75,7 +93,7 @@
<item>
<key>
<string>
component_validation_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
Q
=
</string>
</persistent>
</value>
</item>
</dictionary>
...
...
@@ -84,7 +102,7 @@
</dictionary>
</pickle>
</record>
<record
id=
"
3"
aka=
"AAAAAAAAAAM
="
>
<record
id=
"
4"
aka=
"AAAAAAAAAAQ
="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.SolverConfiguratorItem.py
View file @
752833d9
...
...
@@ -28,11 +28,12 @@
import
zope.interface
from
AccessControl
import
ClassSecurityInfo
from
Products.ERP5Type
import
Permissions
,
PropertySheet
,
interfaces
from
Products.ERP5Type
import
Permissions
,
PropertySheet
from
Products.ERP5Type.XMLObject
import
XMLObject
from
erp5.component.mixin.ConfiguratorItemMixin
import
ConfiguratorItemMixin
from
erp5.component.interface.IConfiguratorItem
import
IConfiguratorItem
class
SolverConfiguratorItem
(
ConfiguratorItemMixin
,
XMLObject
):
""" Setup Solvers. """
...
...
@@ -55,7 +56,7 @@ class SolverConfiguratorItem(ConfiguratorItemMixin, XMLObject):
,
PropertySheet
.
CategoryCore
,
PropertySheet
.
DublinCore
)
def
_checkConsistency
(
self
,
fixit
=
False
,
filter
=
None
,
**
kw
):
def
_checkConsistency
(
self
,
fixit
=
False
,
**
kw
):
if
fixit
:
portal
=
self
.
getPortalObject
()
business_configuration
=
self
.
getBusinessConfigurationValue
()
...
...
@@ -77,8 +78,7 @@ class SolverConfiguratorItem(ConfiguratorItemMixin, XMLObject):
for
information_dict
in
self
.
content_list
:
portal_type
=
information_dict
.
pop
(
'portal_type'
)
id
=
information_dict
.
pop
(
'id'
)
action
=
solver
.
newContent
(
portal_type
=
portal_type
,
id
=
id
)
action
=
solver
.
newContent
(
portal_type
=
portal_type
,
id
=
information_dict
.
pop
(
'id'
))
action
.
edit
(
**
information_dict
)
self
.
install
(
solver
,
business_configuration
)
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.SolverConfiguratorItem.xml
View file @
752833d9
...
...
@@ -6,6 +6,12 @@
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_recorded_property_dict
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
SolverConfiguratorItem
</string>
</value>
...
...
@@ -43,10 +49,7 @@
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple>
<string>
W: 79, 10: Redefining built-in \'id\' (redefined-builtin)
</string>
<string>
W: 57, 43: Redefining built-in \'filter\' (redefined-builtin)
</string>
</tuple>
<tuple/>
</value>
</item>
<item>
...
...
@@ -56,13 +59,28 @@
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
I
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
...
...
@@ -75,7 +93,7 @@
<item>
<key>
<string>
component_validation_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
Q
=
</string>
</persistent>
</value>
</item>
</dictionary>
...
...
@@ -84,7 +102,7 @@
</dictionary>
</pickle>
</record>
<record
id=
"
3"
aka=
"AAAAAAAAAAM
="
>
<record
id=
"
4"
aka=
"AAAAAAAAAAQ
="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.StandardBT5ConfiguratorItem.py
View file @
752833d9
...
...
@@ -28,13 +28,14 @@
import
zope.interface
from
AccessControl
import
ClassSecurityInfo
from
Products.ERP5Type
import
Permissions
,
PropertySheet
,
interfaces
from
Products.ERP5Type
import
Permissions
,
PropertySheet
from
Products.ERP5Type.XMLObject
import
XMLObject
from
erp5.component.mixin.ConfiguratorItemMixin
import
ConfiguratorItemMixin
from
erp5.component.interface.IConfiguratorItem
import
IConfiguratorItem
from
Products.ERP5Type.Cache
import
CachingMethod
from
zLOG
import
LOG
,
INFO
class
StandardBT5ConfiguratorItem
(
ConfiguratorItemMixin
,
XMLObject
):
""" This class will install standard ERP5 template from a repository to
fake site. """
...
...
@@ -60,7 +61,7 @@ class StandardBT5ConfiguratorItem(ConfiguratorItemMixin, XMLObject):
,
PropertySheet
.
StandardBT5ConfiguratorItem
)
def
_checkConsistency
(
self
,
fixit
=
False
,
filter
=
None
,
**
kw
):
def
_checkConsistency
(
self
,
fixit
=
False
,
**
kw
):
template_tool
=
self
.
getPortalObject
().
portal_templates
bt5_id
=
self
.
getBt5Id
().
split
(
'.'
)[
0
]
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.StandardBT5ConfiguratorItem.xml
View file @
752833d9
...
...
@@ -6,6 +6,12 @@
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_recorded_property_dict
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
StandardBT5ConfiguratorItem
</string>
</value>
...
...
@@ -43,9 +49,7 @@
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple>
<string>
W: 62, 43: Redefining built-in \'filter\' (redefined-builtin)
</string>
</tuple>
<tuple/>
</value>
</item>
<item>
...
...
@@ -55,13 +59,28 @@
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
I
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
...
...
@@ -74,7 +93,7 @@
<item>
<key>
<string>
component_validation_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
Q
=
</string>
</persistent>
</value>
</item>
</dictionary>
...
...
@@ -83,7 +102,7 @@
</dictionary>
</pickle>
</record>
<record
id=
"
3"
aka=
"AAAAAAAAAAM
="
>
<record
id=
"
4"
aka=
"AAAAAAAAAAQ
="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.SystemPreferenceConfiguratorItem.py
View file @
752833d9
...
...
@@ -28,11 +28,12 @@
import
zope.interface
from
AccessControl
import
ClassSecurityInfo
from
Products.ERP5Type
import
Permissions
,
PropertySheet
,
interfaces
from
Products.ERP5Type
import
Permissions
,
PropertySheet
from
Products.ERP5Type.XMLObject
import
XMLObject
from
erp5.component.mixin.ConfiguratorItemMixin
import
ConfiguratorItemMixin
from
erp5.component.interface.IConfiguratorItem
import
IConfiguratorItem
class
SystemPreferenceConfiguratorItem
(
ConfiguratorItemMixin
,
XMLObject
):
""" Setup System preference. """
...
...
@@ -73,7 +74,7 @@ class SystemPreferenceConfiguratorItem(ConfiguratorItemMixin, XMLObject):
property_id_list
.
append
(
'%s%s'
%
(
prop
.
getReference
(),
list_prefix
))
return
property_id_list
def
_checkConsistency
(
self
,
fixit
=
False
,
filter
=
None
,
**
kw
):
def
_checkConsistency
(
self
,
fixit
=
False
,
**
kw
):
error_list
=
[]
portal
=
self
.
getPortalObject
()
preference
=
portal
.
portal_preferences
.
_getOb
(
self
.
object_id
,
None
)
...
...
bt5/erp5_configurator/DocumentTemplateItem/portal_components/document.erp5.SystemPreferenceConfiguratorItem.xml
View file @
752833d9
...
...
@@ -6,6 +6,12 @@
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_recorded_property_dict
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
SystemPreferenceConfiguratorItem
</string>
</value>
...
...
@@ -43,9 +49,7 @@
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple>
<string>
W: 75, 43: Redefining built-in \'filter\' (redefined-builtin)
</string>
</tuple>
<tuple/>
</value>
</item>
<item>
...
...
@@ -55,13 +59,28 @@
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
I
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
...
...
@@ -74,7 +93,7 @@
<item>
<key>
<string>
component_validation_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
Q
=
</string>
</persistent>
</value>
</item>
</dictionary>
...
...
@@ -83,7 +102,7 @@
</dictionary>
</pickle>
</record>
<record
id=
"
3"
aka=
"AAAAAAAAAAM
="
>
<record
id=
"
4"
aka=
"AAAAAAAAAAQ
="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
...
...
bt5/erp5_configurator/MixinTemplateItem/portal_components/mixin.erp5.SkinConfiguratorItemMixin.py
View file @
752833d9
...
...
@@ -31,12 +31,13 @@
from
zLOG
import
LOG
,
INFO
from
erp5.component.mixin.ConfiguratorItemMixin
import
ConfiguratorItemMixin
class
SkinConfiguratorItemMixin
(
ConfiguratorItemMixin
):
""" Mixin which allows to create python scripts and/or skin
elements during the configuration.
"""
def
install
(
self
,
skinfolder
,
business_configuration
):
def
install
(
self
,
skinfolder
,
business_configuration
,
prefix
=
''
):
"""
"""
bt5_obj
=
business_configuration
.
getSpecialiseValue
()
...
...
bt5/erp5_configurator/MixinTemplateItem/portal_components/mixin.erp5.SkinConfiguratorItemMixin.xml
View file @
752833d9
...
...
@@ -6,6 +6,12 @@
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_recorded_property_dict
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
SkinConfiguratorItemMixin
</string>
</value>
...
...
@@ -43,9 +49,7 @@
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple>
<string>
W: 39, 2: Arguments number differs from overridden \'install\' method (arguments-differ)
</string>
</tuple>
<tuple/>
</value>
</item>
<item>
...
...
@@ -55,13 +59,28 @@
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
I
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
...
...
@@ -74,7 +93,7 @@
<item>
<key>
<string>
component_validation_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
Q
=
</string>
</persistent>
</value>
</item>
</dictionary>
...
...
@@ -83,7 +102,7 @@
</dictionary>
</pickle>
</record>
<record
id=
"
3"
aka=
"AAAAAAAAAAM
="
>
<record
id=
"
4"
aka=
"AAAAAAAAAAQ
="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
...
...
bt5/erp5_configurator/SkinTemplateItem/portal_skins/erp5_configurator/BusinessConfiguration_getISOCurrencyList.py
View file @
752833d9
from
Products.ERP5Type.Cache
import
CachingMethod
result
=
[]
if
empty_first_element
==
True
:
if
empty_first_element
:
result
=
[[
''
,
''
],]
filename
=
"standard_currency_list.ods"
...
...
bt5/erp5_configurator/SkinTemplateItem/portal_skins/erp5_configurator/BusinessConfiguration_getISOCurrencyList.xml
View file @
752833d9
...
...
@@ -50,7 +50,7 @@
</item>
<item>
<key>
<string>
_params
</string>
</key>
<value>
<string>
empty_first_element
= True, filter="world"
</string>
</value>
<value>
<string>
empty_first_element
=True
</string>
</value>
</item>
<item>
<key>
<string>
id
</string>
</key>
...
...
bt5/erp5_configurator/SkinTemplateItem/portal_skins/erp5_configurator/BusinessConfiguration_getUIDescription.py
View file @
752833d9
...
...
@@ -19,7 +19,7 @@ while state not in previous_state_list:
break
if
transition
.
getTransitionFormId
()
not
in
(
None
,
""
):
result
.
append
({
'state'
:
state
.
getTitle
(),
result
.
append
({
'state'
:
state
.
getTitle
(),
'description'
:
state
.
getDescription
(),
'title'
:
state
.
getTitle
()})
...
...
bt5/erp5_configurator/SkinTemplateItem/portal_skins/erp5_configurator/BusinessConfiguration_validateCustomerPassword.py
View file @
752833d9
password_confirm
=
request
.
get
(
'field_your_password_confirm'
,
None
)
try
:
if
editor
.
encode
(
'ascii'
,
'ignore'
)
!=
editor
:
return
0
except
:
return
0
if
editor
.
encode
(
'ascii'
,
'ignore'
)
!=
editor
:
return
False
return
password_confirm
==
editor
bt5/erp5_configurator/SkinTemplateItem/portal_skins/erp5_configurator/BusinessConfiguration_validateCustomerUsername.py
View file @
752833d9
...
...
@@ -8,9 +8,9 @@ for reference in reference_list:
portal
=
context
.
getPortalObject
()
reference
=
editor
# check this is a not a reference from acl_user
# check this is a not a reference from acl_user
s
if
portal
.
acl_users
.
searchUsers
(
login
=
reference
,
exact_match
=
True
):
return
0
return
0
# first check if a Business Configuration has not already "reserved" it
# through a Person Configuration Item which when build will create a real
...
...
bt5/erp5_configurator/SkinTemplateItem/portal_skins/erp5_configurator_wizard/ConfiguratorTool_generateJavaScript.py
View file @
752833d9
REQUEST
=
context
.
REQUEST
active_process_id
=
REQUEST
.
get
(
'active_process_id'
,
None
)
erp5_site_id
=
context
.
getPortalObject
().
getId
()
js_string
=
"""
// Initialisation
...
...
bt5/erp5_configurator/SkinTemplateItem/portal_skins/erp5_configurator_wizard/ConfiguratorTool_viewRunningInstallationMessage.py
View file @
752833d9
...
...
@@ -7,8 +7,6 @@ calc_percentage = 0.0
is_activities_running
=
len
(
installation_status
[
'activity_list'
])
!=
0
is_bt5_building_running
=
installation_status
[
'bt5'
][
'all'
]
==
0
and
\
not
is_activities_running
is_bt5_installation_running
=
installation_status
[
'bt5'
][
'all'
]
!=
0
and
\
not
is_activities_running
if
not
is_bt5_building_running
:
all_bt5s
=
float
(
installation_status
[
'bt5'
][
'all'
])
...
...
bt5/erp5_configurator/TestTemplateItem/portal_components/test.erp5.testConfiguratorItem.py
View file @
752833d9
...
...
@@ -120,7 +120,6 @@ class TestConfiguratorItem(TestLiveConfiguratorWorkflowMixin):
def
testCategoryConfiguratorItem
(
self
):
""" Test Category Configurator Item """
configuration_save
=
self
.
createConfigurationSave
()
bc
=
configuration_save
.
getParentValue
()
category_id_0
=
"test_category_%s"
%
self
.
newUniqueUID
()
item0
=
configuration_save
.
addConfigurationItem
(
...
...
@@ -173,7 +172,6 @@ class TestConfiguratorItem(TestLiveConfiguratorWorkflowMixin):
def
testCurrencyConfiguratorItem
(
self
):
""" Test Category Configurator Item """
configuration_save
=
self
.
createConfigurationSave
()
bc
=
configuration_save
.
getParentValue
()
eur_currency_id
=
"EUR"
eur_currency_title
=
"Euro"
...
...
@@ -224,7 +222,6 @@ class TestConfiguratorItem(TestLiveConfiguratorWorkflowMixin):
be used for the script oucome. For now it does the minimum.
"""
configuration_save
=
self
.
createConfigurationSave
()
bc
=
configuration_save
.
getParentValue
()
expect_script_outcome
=
(
(
'ERP5Type_getSecurityCategoryFromAssignmentStrict'
,
[
'function'
]),
...
...
@@ -251,7 +248,6 @@ class TestConfiguratorItem(TestLiveConfiguratorWorkflowMixin):
def
testAccountConfiguratorItem
(
self
):
""" Test Account Configurator Item """
configuration_save
=
self
.
createConfigurationSave
()
bc
=
configuration_save
.
getParentValue
()
account_module
=
self
.
portal
.
account_module
account_dict
=
{
...
...
@@ -303,7 +299,6 @@ class TestConfiguratorItem(TestLiveConfiguratorWorkflowMixin):
def
testAlarmConfiguratorItem
(
self
):
""" Test Alarm Configurator Item """
configuration_save
=
self
.
createConfigurationSave
()
bc
=
configuration_save
.
getParentValue
()
property_map
=
{
"active_sense_method_id"
:
"Base_setDummy"
,
...
...
@@ -354,7 +349,6 @@ class TestConfiguratorItem(TestLiveConfiguratorWorkflowMixin):
def
testPortalTypeRolesSpreadsheetConfiguratorItem
(
self
):
""" Test Portal Type Roles Configurator Item """
configuration_save
=
self
.
createConfigurationSave
()
bc
=
configuration_save
.
getParentValue
()
category_tool
=
self
.
portal
.
portal_categories
test_folder_path
=
'/'
.
join
(
test_folder
.
__file__
.
split
(
'/'
)[:
-
1
])
...
...
@@ -430,17 +424,13 @@ class TestConfiguratorItem(TestLiveConfiguratorWorkflowMixin):
def
testCategoriesSpreadsheetConfiguratorItem
(
self
):
""" Test Portal Type Roles Configurator Item """
configuration_save
=
self
.
createConfigurationSave
()
bc
=
configuration_save
.
getParentValue
()
category_tool
=
self
.
portal
.
portal_categories
test_folder_path
=
'/'
.
join
(
test_folder
.
__file__
.
split
(
'/'
)[:
-
1
])
f
=
open
(
"%s/test_data/test_standard_categories.ods"
\
%
test_folder_path
,
"r"
)
try
:
with
open
(
"%s/test_data/test_standard_categories.ods"
\
%
test_folder_path
,
"r"
)
as
f
:
data
=
f
.
read
()
finally
:
f
.
close
()
item
=
configuration_save
.
addConfigurationItem
(
"Categories Spreadsheet Configurator Item"
,
...
...
@@ -481,7 +471,6 @@ class TestConfiguratorItem(TestLiveConfiguratorWorkflowMixin):
def
testRuleConfiguratorItem
(
self
):
""" Test Rules Configurator Item """
configuration_save
=
self
.
createConfigurationSave
()
bc
=
configuration_save
.
getParentValue
()
category_tool
=
self
.
portal
.
portal_categories
rule_tool
=
self
.
portal
.
portal_rules
...
...
@@ -510,7 +499,6 @@ class TestConfiguratorItem(TestLiveConfiguratorWorkflowMixin):
item
.
fixConsistency
()
self
.
tic
()
template_id
=
item
.
getId
()
rule_list
=
rule_tool
.
searchFolder
(
portal_type
=
self
.
portal
.
getPortalRuleTypeList
(),
validation_state
=
"validated"
,
reference
=
rule_reference
)
...
...
@@ -520,17 +508,12 @@ class TestConfiguratorItem(TestLiveConfiguratorWorkflowMixin):
def
testBusinessProcessConfiguratorItem
(
self
):
configuration_save
=
self
.
createConfigurationSave
()
bc
=
configuration_save
.
getParentValue
()
category_tool
=
self
.
portal
.
portal_categories
test_folder_path
=
'/'
.
join
(
test_folder
.
__file__
.
split
(
'/'
)[:
-
1
])
f
=
open
(
"%s/test_data/test_standard_business_process.ods"
\
%
test_folder_path
,
"r"
)
try
:
with
open
(
"%s/test_data/test_standard_business_process.ods"
\
%
test_folder_path
,
"r"
)
as
f
:
data
=
f
.
read
()
finally
:
f
.
close
()
reference
=
"testing_business_process_%s"
%
self
.
newUniqueUID
()
item
=
configuration_save
.
addConfigurationItem
(
...
...
bt5/erp5_configurator/TestTemplateItem/portal_components/test.erp5.testConfiguratorItem.xml
View file @
752833d9
...
...
@@ -6,6 +6,12 @@
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_recorded_property_dict
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
testConfiguratorItem
</string>
</value>
...
...
@@ -43,19 +49,7 @@
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple>
<string>
W:123, 4: Unused variable \'bc\' (unused-variable)
</string>
<string>
W:176, 4: Unused variable \'bc\' (unused-variable)
</string>
<string>
W:227, 4: Unused variable \'bc\' (unused-variable)
</string>
<string>
W:254, 4: Unused variable \'bc\' (unused-variable)
</string>
<string>
W:306, 4: Unused variable \'bc\' (unused-variable)
</string>
<string>
W:357, 4: Unused variable \'bc\' (unused-variable)
</string>
<string>
W:433, 4: Unused variable \'bc\' (unused-variable)
</string>
<string>
W:484, 4: Unused variable \'bc\' (unused-variable)
</string>
<string>
W:513, 4: Unused variable \'template_id\' (unused-variable)
</string>
<string>
W:523, 4: Unused variable \'bc\' (unused-variable)
</string>
<string>
W:524, 4: Unused variable \'category_tool\' (unused-variable)
</string>
</tuple>
<tuple/>
</value>
</item>
<item>
...
...
@@ -65,13 +59,28 @@
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
I
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
...
...
@@ -84,7 +93,7 @@
<item>
<key>
<string>
component_validation_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
Q
=
</string>
</persistent>
</value>
</item>
</dictionary>
...
...
@@ -93,7 +102,7 @@
</dictionary>
</pickle>
</record>
<record
id=
"
3"
aka=
"AAAAAAAAAAM
="
>
<record
id=
"
4"
aka=
"AAAAAAAAAAQ
="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
...
...
bt5/erp5_configurator/ToolComponentTemplateItem/portal_components/tool.erp5.ConfiguratorTool.py
View file @
752833d9
...
...
@@ -53,10 +53,10 @@ def _validateFormToRequest(form, REQUEST, **kw):
form
.
validate_all_to_request
(
REQUEST
)
validation_status
=
0
validation_errors
=
None
except
FormValidationError
,
validation_errors
:
except
FormValidationError
as
validation_errors
:
## not all fields valid
validation_status
=
1
except
Exception
,
validation_errors
:
except
Exception
as
validation_errors
:
## missing fields
validation_status
=
2
## extract form arguments and remove leading prefixes
...
...
@@ -75,6 +75,7 @@ def _validateFormToRequest(form, REQUEST, **kw):
pass
return
validation_status
,
form_kw
,
validation_errors
class
ConfiguratorTool
(
BaseTool
):
"""This tool provides a Configurator Tool.
"""
...
...
@@ -159,7 +160,7 @@ class ConfiguratorTool(BaseTool):
failed_forms_counter
=
0
transition
=
business_configuration
.
getNextTransition
()
form
=
getattr
(
business_configuration
,
transition
.
getTransitionFormId
())
for
form_key
in
filter
(
lambda
x
:
x
.
startswith
(
'field_'
),
kw
.
keys
())
:
for
form_key
in
[
x
for
x
in
kw
.
keys
()
if
x
.
startswith
(
'field_'
)]
:
form_kw
[
form_key
]
=
kw
[
form_key
]
## iterate all forms
for
form_counter
in
range
(
0
,
isMultiEntryTransition
):
...
...
@@ -184,9 +185,7 @@ class ConfiguratorTool(BaseTool):
## clean up REQUEST from traces from validate_all_to_request
## otherwise next form will use previous forms details
cleanup_keys
=
filter
(
lambda
x
:
x
.
startswith
(
'my_'
)
or
x
.
startswith
(
'your_'
),
self
.
REQUEST
.
other
.
keys
())
cleanup_keys
=
[
x
for
x
in
self
.
REQUEST
.
other
.
keys
()
if
x
.
startswith
(
'my_'
)
or
x
.
startswith
(
'your_'
)]
for
key
in
cleanup_keys
:
self
.
REQUEST
.
other
.
pop
(
key
,
None
)
## render HTML code
...
...
@@ -324,7 +323,6 @@ class ConfiguratorTool(BaseTool):
If installation is over the installation activities and reindexing
activities should not exists.
"""
global
installation_status
portal_activities
=
self
.
getPortalObject
().
portal_activities
if
0
==
len
(
portal_activities
.
getMessageList
()):
...
...
@@ -346,7 +344,6 @@ class ConfiguratorTool(BaseTool):
download/install bt5 template files and meanwhile offer
user a nice GUI to observe what's happening. """
global
installation_status
# init installation status
installation_status
[
'bt5'
][
'all'
]
=
1
installation_status
[
'bt5'
][
'current'
]
=
0
...
...
bt5/erp5_configurator/ToolComponentTemplateItem/portal_components/tool.erp5.ConfiguratorTool.xml
View file @
752833d9
...
...
@@ -6,6 +6,12 @@
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_recorded_property_dict
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
ConfiguratorTool
</string>
</value>
...
...
@@ -43,12 +49,7 @@
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple>
<string>
W:162, 22: map/filter on lambda could be replaced by comprehension (deprecated-lambda)
</string>
<string>
W:187, 23: map/filter on lambda could be replaced by comprehension (deprecated-lambda)
</string>
<string>
W:327, 4: Using global for \'installation_status\' but no assignment is done (global-variable-not-assigned)
</string>
<string>
W:349, 4: Using global for \'installation_status\' but no assignment is done (global-variable-not-assigned)
</string>
</tuple>
<tuple/>
</value>
</item>
<item>
...
...
@@ -58,13 +59,28 @@
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
I
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
...
...
@@ -77,7 +93,7 @@
<item>
<key>
<string>
component_validation_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
Q
=
</string>
</persistent>
</value>
</item>
</dictionary>
...
...
@@ -86,7 +102,7 @@
</dictionary>
</pickle>
</record>
<record
id=
"
3"
aka=
"AAAAAAAAAAM
="
>
<record
id=
"
4"
aka=
"AAAAAAAAAAQ
="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
...
...
bt5/erp5_configurator/bt/skip_coding_style_test
deleted
100644 → 0
View file @
9e95bc1d
1
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment