Commit 7f68a76a authored by Rafael Monnerat's avatar Rafael Monnerat

erp5_adminstration: Extend what can be ignored

See merge request !1477
parents 764aba45 3d31a305
Pipeline #16897 failed with stage
in 0 seconds
if ignore_business_template_list is None:
ignore_business_template_list = []
for business_template in sorted(context.getPortalObject().portal_templates.contentValues(portal_type='Business Template'),
key=lambda x:x.getTitle()):
if business_template.getInstallationState() == 'installed':
if business_template.getInstallationState() == 'installed' and \
business_template.getTitle() not in ignore_business_template_list:
print business_template.getTitle()
return printed
......@@ -50,7 +50,7 @@
</item>
<item>
<key> <string>_params</string> </key>
<value> <string></string> </value>
<value> <string>ignore_business_template_list=None</string> </value>
</item>
<item>
<key> <string>id</string> </key>
......
import hashlib
portal = context.getPortalObject()
if ignore_folder_list is None:
ignore_folder_list = []
if ignore_skin_list is None:
ignore_skin_list = []
if ignore_custom:
ignore_folder_list.append("custom")
def getSkinHash(skin, skin_container):
content = ''
......@@ -24,9 +32,11 @@ def getSkinHash(skin, skin_container):
for skin_folder in portal.portal_skins.objectValues('Folder'):
if ignore_custom and skin_folder.getId() == 'custom':
if skin_folder.getId() in ignore_folder_list:
continue
for skin in skin_folder.objectValues():
if skin.getId() in ignore_skin_list:
continue
print getSkinHash(skin, skin_folder)
if include_workflow_scripts:
......
......@@ -50,7 +50,7 @@
</item>
<item>
<key> <string>_params</string> </key>
<value> <string>ignore_custom=True, include_workflow_scripts=True</string> </value>
<value> <string>ignore_custom=True, include_workflow_scripts=True, ignore_folder_list=None, ignore_skin_list=None</string> </value>
</item>
<item>
<key> <string>id</string> </key>
......
if ignore_property_sheet_list is None:
ignore_property_sheet_list = []
for ps in sorted(context.getPortalObject().portal_property_sheets.contentValues(), key=lambda x:x.getId()):
for pd in sorted(ps.contentValues(), key=lambda x:x.getId()):
ps_id = ps.getId()
if ps_id in ignore_property_sheet_list:
continue
print ps.getId()
info_list = ['id', 'portal_type', 'reference']
std_prop_list = ['elementary_type', 'property_default', 'storage_id', 'multivaluated', 'range', 'preference', 'read_permission', 'write_permission', 'translatable', 'translation_domain']
......
......@@ -50,7 +50,7 @@
</item>
<item>
<key> <string>_params</string> </key>
<value> <string></string> </value>
<value> <string>ignore_property_sheet_list=None</string> </value>
</item>
<item>
<key> <string>id</string> </key>
......
......@@ -10,5 +10,8 @@
skin_tool = context.getPortalObject().portal_skins
for name, layers in skin_tool.getSkinPaths():
for layer in layers.split(','):
if ignore_skin_folder_list is not None and\
layer in ignore_skin_folder_list:
continue
print '%s,%s' % (name, layer)
return printed
......@@ -50,7 +50,7 @@
</item>
<item>
<key> <string>_params</string> </key>
<value> <string></string> </value>
<value> <string>ignore_skin_folder_list=None</string> </value>
</item>
<item>
<key> <string>id</string> </key>
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment