diff -r fbe52dda730c -r 3a4788a4127c src/pyams_content/component/extfile/__init__.py --- a/src/pyams_content/component/extfile/__init__.py Mon Jul 20 15:21:56 2020 +0200 +++ b/src/pyams_content/component/extfile/__init__.py Mon Aug 31 14:35:09 2020 +0200 @@ -10,24 +10,25 @@ # FOR A PARTICULAR PURPOSE. # -__docformat__ = 'restructuredtext' - import os from pyramid.events import subscriber from pyramid.threadlocal import get_current_registry +from zope.dublincore.interfaces import IZopeDublinCore from zope.interface import alsoProvides, implementer from zope.lifecycleevent import ObjectModifiedEvent -from zope.lifecycleevent.interfaces import IObjectAddedEvent, IObjectModifiedEvent, IObjectRemovedEvent +from zope.lifecycleevent.interfaces import IObjectAddedEvent, IObjectModifiedEvent, \ + IObjectRemovedEvent from zope.schema.fieldproperty import FieldProperty from zope.schema.vocabulary import SimpleTerm, SimpleVocabulary from pyams_content.component.association import AssociationItem from pyams_content.component.association.interfaces import IAssociationInfo -from pyams_content.component.extfile.interfaces import IBaseExtFile, IExtAudio, IExtFile, IExtFileManagerInfo, \ - IExtImage, IExtMedia, IExtVideo +from pyams_content.component.extfile.interfaces import IBaseExtFile, IExtAudio, IExtFile, \ + IExtFileManagerInfo, IExtImage, IExtMedia, IExtVideo from pyams_content.features.checker import BaseContentChecker -from pyams_content.features.checker.interfaces import IContentChecker, MISSING_LANG_VALUE, MISSING_VALUE +from pyams_content.features.checker.interfaces import IContentChecker, MISSING_LANG_VALUE, \ + MISSING_VALUE from pyams_content.shared.common.interfaces import IWfSharedContent from pyams_file.file import EXTENSIONS_THUMBNAILS from pyams_file.interfaces import IFileInfo, IImage, IResponsiveImage @@ -40,6 +41,9 @@ from pyams_utils.traversing import get_parent from pyams_utils.vocabulary import vocabulary_config + +__docformat__ = 'restructuredtext' + from pyams_content import _ @@ -90,7 +94,8 @@ title = self.context.filename if '.' in title: title, extension = title.rsplit('.', 1) - return '{0} {1}'.format(II18n(manager_info).query_attribute('default_title_prefix', request=request) or '', + return '{0} {1}'.format(II18n(manager_info).query_attribute('default_title_prefix', + request=request) or '', title) @property