diff --git a/castle/cms/indexing/configure.zcml b/castle/cms/indexing/configure.zcml index 93f82b9f7..43d7d58ad 100644 --- a/castle/cms/indexing/configure.zcml +++ b/castle/cms/indexing/configure.zcml @@ -42,5 +42,6 @@ + diff --git a/castle/cms/indexing/indexers.py b/castle/cms/indexing/indexers.py index faa98ae45..1c796a871 100644 --- a/castle/cms/indexing/indexers.py +++ b/castle/cms/indexing/indexers.py @@ -3,6 +3,7 @@ from wildcard.hps.interfaces import IReindexActive from OFS.interfaces import IItem from plone import api +from plone.app.textfield.value import RichTextValue from plone.app.uuid.utils import uuidToCatalogBrain as get_brain from plone.app.contenttypes.interfaces import IFile, IImage from plone.dexterity.interfaces import IDexterityContent @@ -13,6 +14,7 @@ from Products.CMFCore.interfaces._content import IFolderish from ZODB.POSException import POSKeyError from zope.globalrequest import getRequest +import six from castle.cms.behaviors.location import ILocation from castle.cms.interfaces import IHasDefaultImage @@ -220,3 +222,22 @@ def self_or_child_has_title_description_and_image(obj): def has_custom_markup(image): if image.custom_markup: return True + + +@indexer(IItem) +def raw_output(obj): + text = getattr(obj, 'text', None) + + if not text: + return u'' + + if hasattr(text, 'raw'): + try: + return text.raw or u'' + except Exception: + return u'' + + try: + return six.text_type(text) + except Exception: + return u'' diff --git a/castle/cms/profiles/3020/catalog.xml b/castle/cms/profiles/3020/catalog.xml new file mode 100644 index 000000000..566d0c941 --- /dev/null +++ b/castle/cms/profiles/3020/catalog.xml @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git a/castle/cms/profiles/default/catalog.xml b/castle/cms/profiles/default/catalog.xml index 0aa405de7..3b5159480 100644 --- a/castle/cms/profiles/default/catalog.xml +++ b/castle/cms/profiles/default/catalog.xml @@ -51,4 +51,6 @@ + + diff --git a/castle/cms/profiles/default/metadata.xml b/castle/cms/profiles/default/metadata.xml index 672289d74..97f9b71ee 100644 --- a/castle/cms/profiles/default/metadata.xml +++ b/castle/cms/profiles/default/metadata.xml @@ -1,6 +1,6 @@ - 3019 + 3020 profile-plone.app.querystring:default profile-plone.app.mosaic:default diff --git a/castle/cms/static/images/previews/querylisting/full-content.png b/castle/cms/static/images/previews/querylisting/full-content.png new file mode 100644 index 000000000..280c3e340 Binary files /dev/null and b/castle/cms/static/images/previews/querylisting/full-content.png differ diff --git a/castle/cms/tiles/configure.zcml b/castle/cms/tiles/configure.zcml index ab0ac0973..88f7991b3 100644 --- a/castle/cms/tiles/configure.zcml +++ b/castle/cms/tiles/configure.zcml @@ -446,6 +446,12 @@ for="plone.dexterity.interfaces.IDexterityContent ..interfaces.ICastleLayer" factory=".querylisting.BlogView" /> + + .dt-default li .focuspoint.overlay-image-container img.overlay-image { + position: absolute; + bottom: 0; + left: 0; + top: unset; + height: 20%; + width: 100%; + min-height: 25px; + max-height: 50px; + } + .full-content-item { + border-bottom: 1px solid #eee; + +} + .full-content-item:last-child { + border-bottom: none; +} + + diff --git a/castle/cms/upgrades.zcml b/castle/cms/upgrades.zcml index b2307a3e1..6ac2ffbed 100644 --- a/castle/cms/upgrades.zcml +++ b/castle/cms/upgrades.zcml @@ -312,5 +312,26 @@ profile="castle.cms:default" /> + + + + + diff --git a/castle/cms/upgrades/__init__.py b/castle/cms/upgrades/__init__.py index b42c7f992..d266153f6 100644 --- a/castle/cms/upgrades/__init__.py +++ b/castle/cms/upgrades/__init__.py @@ -7,6 +7,7 @@ from Products.CMFPlone.resources.browser.cook import cookWhenChangingSettings from Products.CMFCore.utils import getToolByName from zope.interface import noLongerProvides +from OFS.interfaces import IItem import plone.api as api @@ -144,3 +145,11 @@ def upgrade_3011(site, logger=CASTLE_LOGGER): upgrade_3017 = default_upgrade_factory('3017') upgrade_3018 = default_upgrade_factory('3018') upgrade_3019 = default_upgrade_factory('3019') + + +upgrade_3020a = default_upgrade_factory('3020') +def upgrade_3020b(context): + catalog = getToolByName(context, 'portal_catalog') + for brain in catalog(): + obj = brain.getObject() + catalog.catalog_object(obj, idxs=[])