equal
deleted
inserted
replaced
15 |
15 |
16 # import standard library |
16 # import standard library |
17 |
17 |
18 # import interfaces |
18 # import interfaces |
19 from pyams_content.features.checker.interfaces import IContentChecker, MISSING_VALUE, MISSING_LANG_VALUE, ERROR_VALUE |
19 from pyams_content.features.checker.interfaces import IContentChecker, MISSING_VALUE, MISSING_LANG_VALUE, ERROR_VALUE |
20 from pyams_content.shared.logo.interfaces import ILogosParagraph |
20 from pyams_content.shared.logo.interfaces import ILogosParagraph, LOGOS_PARAGRAPH_TYPE |
21 from pyams_i18n.interfaces import II18nManager, INegotiator, II18n |
21 from pyams_i18n.interfaces import II18nManager, INegotiator, II18n |
22 from pyams_workflow.interfaces import IWorkflow, IWorkflowState |
22 from pyams_workflow.interfaces import IWorkflow, IWorkflowState |
23 |
23 |
24 # import packages |
24 # import packages |
25 from pyams_content.component.paragraph import BaseParagraph, IParagraphFactory, BaseParagraphFactory, \ |
25 from pyams_content.component.paragraph import BaseParagraph, IParagraphFactory, BaseParagraphFactory, \ |
49 yield reference, get_reference_target(reference, state) |
49 yield reference, get_reference_target(reference, state) |
50 else: |
50 else: |
51 yield get_reference_target(reference, state) |
51 yield get_reference_target(reference, state) |
52 |
52 |
53 |
53 |
54 @utility_config(name='Logos', provides=IParagraphFactory) |
54 @utility_config(name=LOGOS_PARAGRAPH_TYPE, provides=IParagraphFactory) |
55 class LogosParagraphFactory(BaseParagraphFactory): |
55 class LogosParagraphFactory(BaseParagraphFactory): |
56 """Logos paragraph factory""" |
56 """Logos paragraph factory""" |
57 |
57 |
58 name = _("Logos") |
58 name = _("Logos") |
59 content_type = LogosParagraph |
59 content_type = LogosParagraph |
|
60 secondary_menu = True |
60 |
61 |
61 |
62 |
62 @adapter_config(context=ILogosParagraph, provides=IContentChecker) |
63 @adapter_config(context=ILogosParagraph, provides=IContentChecker) |
63 class LogosParagraphContentChecker(BaseParagraphContentChecker): |
64 class LogosParagraphContentChecker(BaseParagraphContentChecker): |
64 """Logos paragraph content checker""" |
65 """Logos paragraph content checker""" |