Added illustration support for several contents
authorThierry Florac <thierry.florac@onf.fr>
Mon, 05 Feb 2018 17:04:08 +0100
changeset 353 4839285629d1
parent 352 a84cf36e9d1b
child 354 871c7cb35fd6
Added illustration support for several contents
src/pyams_content/shared/blog/__init__.py
src/pyams_content/shared/blog/manager.py
src/pyams_content/shared/news/__init__.py
src/pyams_content/shared/site/__init__.py
src/pyams_content/shared/site/folder.py
src/pyams_content/shared/site/manager.py
--- a/src/pyams_content/shared/blog/__init__.py	Mon Feb 05 17:03:10 2018 +0100
+++ b/src/pyams_content/shared/blog/__init__.py	Mon Feb 05 17:04:08 2018 +0100
@@ -16,6 +16,7 @@
 # import standard library
 
 # import interfaces
+from pyams_content.component.illustration import IIllustrationTarget
 from pyams_content.component.paragraph.interfaces import IParagraphContainerTarget
 from pyams_content.component.theme.interfaces import IThemesTarget
 from pyams_content.features.preview.interfaces import IPreviewTarget
@@ -29,7 +30,7 @@
 
 
 @implementer(IWfBlogPost, IParagraphContainerTarget, IThemesTarget,
-             IPreviewTarget, IReviewTarget)
+             IIllustrationTarget, IPreviewTarget, IReviewTarget)
 class WfBlogPost(WfSharedContent):
     """Base blog post"""
 
--- a/src/pyams_content/shared/blog/manager.py	Mon Feb 05 17:03:10 2018 +0100
+++ b/src/pyams_content/shared/blog/manager.py	Mon Feb 05 17:04:08 2018 +0100
@@ -16,6 +16,7 @@
 # import standard library
 
 # import interfaces
+from pyams_content.component.illustration import IIllustrationTarget
 from pyams_content.component.paragraph.interfaces import IParagraphFactorySettings
 from pyams_content.component.theme.interfaces import IThemesManagerTarget
 from pyams_content.shared.blog.interfaces import IBlogManager, BLOG_CONTENT_TYPE, IBlogFolder
@@ -46,7 +47,8 @@
         return True
 
 
-@implementer(IBlogManager, IParagraphFactorySettings, IThemesManagerTarget, IAttributeAnnotatable, IPortalContext)
+@implementer(IBlogManager, IParagraphFactorySettings, IThemesManagerTarget,
+             IIllustrationTarget, IPortalContext, IAttributeAnnotatable)
 class BlogManager(SharedTool, UserSkinnableContent):
     """Nlog manager class"""
 
--- a/src/pyams_content/shared/news/__init__.py	Mon Feb 05 17:03:10 2018 +0100
+++ b/src/pyams_content/shared/news/__init__.py	Mon Feb 05 17:04:08 2018 +0100
@@ -16,6 +16,7 @@
 # import standard library
 
 # import interfaces
+from pyams_content.component.illustration import IIllustrationTarget
 from pyams_content.component.paragraph.interfaces import IParagraphContainerTarget
 from pyams_content.component.theme.interfaces import IThemesTarget
 from pyams_content.features.preview.interfaces import IPreviewTarget
@@ -27,7 +28,7 @@
 from zope.interface import implementer
 
 
-@implementer(IWfNewsEvent, IParagraphContainerTarget, IThemesTarget,
+@implementer(IWfNewsEvent, IIllustrationTarget, IParagraphContainerTarget, IThemesTarget,
              IPreviewTarget, IReviewTarget)
 class WfNewsEvent(WfSharedContent):
     """Base news event"""
--- a/src/pyams_content/shared/site/__init__.py	Mon Feb 05 17:03:10 2018 +0100
+++ b/src/pyams_content/shared/site/__init__.py	Mon Feb 05 17:04:08 2018 +0100
@@ -16,6 +16,7 @@
 # import standard library
 
 # import interfaces
+from pyams_content.component.illustration import IIllustrationTarget
 from pyams_content.component.paragraph.interfaces import IParagraphContainerTarget
 from pyams_content.component.theme.interfaces import IThemesTarget
 from pyams_content.features.preview.interfaces import IPreviewTarget
@@ -30,7 +31,7 @@
 
 
 @implementer(IWfTopic, IParagraphContainerTarget, IThemesTarget,
-             IPreviewTarget, IReviewTarget)
+             IIllustrationTarget, IPreviewTarget, IReviewTarget)
 class WfTopic(WfSharedContent):
     """Base topic"""
 
--- a/src/pyams_content/shared/site/folder.py	Mon Feb 05 17:03:10 2018 +0100
+++ b/src/pyams_content/shared/site/folder.py	Mon Feb 05 17:04:08 2018 +0100
@@ -16,6 +16,7 @@
 # import standard library
 
 # import interfaces
+from pyams_content.component.illustration import IIllustrationTarget
 from pyams_content.interfaces import MANAGE_SITE_PERMISSION
 from pyams_content.shared.site.interfaces import ISiteFolder, ISiteManager, ISiteFolderRoles
 from pyams_form.interfaces.form import IFormContextPermissionChecker
@@ -41,7 +42,7 @@
 
 
 @implementer(IDefaultProtectionPolicy, ISiteFolder, ISiteFolderRoles,
-             IPortalContext, IAttributeAnnotatable)
+             IIllustrationTarget, IPortalContext, IAttributeAnnotatable)
 class SiteFolder(SiteContainerMixin, OrderedContainer, BaseSharedTool):
     """Site folder persistent class"""
 
--- a/src/pyams_content/shared/site/manager.py	Mon Feb 05 17:03:10 2018 +0100
+++ b/src/pyams_content/shared/site/manager.py	Mon Feb 05 17:04:08 2018 +0100
@@ -16,6 +16,7 @@
 # import standard library
 
 # import interfaces
+from pyams_content.component.illustration import IIllustrationTarget
 from pyams_content.component.paragraph.interfaces import IParagraphFactorySettings
 from pyams_content.component.theme.interfaces import IThemesManagerTarget
 from pyams_content.interfaces import MANAGE_SITE_PERMISSION
@@ -46,7 +47,7 @@
 
 
 @implementer(ISiteManager, IParagraphFactorySettings, IThemesManagerTarget,
-             IPortalContext, IAttributeAnnotatable)
+             IIllustrationTarget, IPortalContext, IAttributeAnnotatable)
 class SiteManager(SiteContainerMixin, OrderedContainer, BaseSharedTool, UserSkinnableContent):
     """Site manager persistent class"""