1 | import re, os |
---|
2 | try: |
---|
3 | from Products.CMFCore import permissions |
---|
4 | except: |
---|
5 | from Products.CMFCore import CMFCorePermissions as permissions |
---|
6 | |
---|
7 | ## Base Product Constants |
---|
8 | GLOBALS = globals() |
---|
9 | PROJECTNAME = "qPloneSkinDump" |
---|
10 | ADD_CONTENT_PERMISSION = permissions.AddPortalContent |
---|
11 | CONFIGURATION_CONFIGLET = "qploneskindump_configuration" |
---|
12 | |
---|
13 | |
---|
14 | ## Constants for Scin Product generation |
---|
15 | TEMPLATE_PATH = "skin_template" |
---|
16 | |
---|
17 | |
---|
18 | ## Constants for slots castomization |
---|
19 | SLOT_FORMING_LIST = ["blend_with_skin", "blend_with_site", "replace"] |
---|
20 | DEFAULT_SLOT_FORMING = "blend_with_skin" |
---|
21 | MAIN_COLUMN_LIST = ["left", "right", "both"] |
---|
22 | DEFAULT_MAIN_COLUMN = "both" |
---|
23 | |
---|
24 | |
---|
25 | ## Constants for Exporting objects |
---|
26 | IMPORTING_POLICY_LIST = ["only_new","backup","overwrite"] |
---|
27 | DEFAULT_IMPORTING_POLICY = "only_new" |
---|
28 | FORBIDDEN_EXP_PREFIXES = re.compile('^(portal_)') |
---|
29 | FORBIDDEN_EXP_NAMES = ["ResourceRegistryCache", "MailHost", "HTTPCache", "Members", "RAMCache", "acl_users",\ |
---|
30 | "archetype_tool", "caching_policy_manager", "content_type_registry", \ |
---|
31 | "cookie_authentication", "error_log", "kupu_library_tool",\ |
---|
32 | "mimetypes_registry", "plone_utils", "reference_catalog",\ |
---|
33 | "translation_service", "uid_catalog"] |
---|
34 | |
---|
35 | |
---|
36 | ## Resource registries proprties |
---|
37 | CSS_REG_PROPS = ['id', 'expression', 'enabled', 'cookable', 'cacheable' \ |
---|
38 | ,'media', 'rel', 'title', 'rendering', 'compression'] |
---|
39 | JS_REG_PROPS = ['id', 'expression', 'enabled', 'cookable', 'cacheable' \ |
---|
40 | ,'inline', 'compression'] |
---|
41 | |
---|
42 | |
---|
43 | from Globals import package_home |
---|
44 | PRODUCTS_PATH = os.sep.join(package_home(GLOBALS).split(os.sep)[:-1]) |
---|
45 | |
---|
46 | import Products |
---|
47 | from OFS.Application import get_products |
---|