Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

unwrap search_base in portlets #187

Merged
merged 1 commit into from
May 31, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@ Changelog
2.0a12 (unreleased)
-------------------

- Unwrap search_base for portlets, as it might be wrapped by the portlet
renderer class. Fixes an error with getting the events to display.
[thet]

- Import BBB superclasses from plone.app.portlets.portlets.base so it works
with plone.app.portlets 3.0 and up
[frapell]
Expand Down
3 changes: 2 additions & 1 deletion plone/app/event/portlets/portlet_calendar.py
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,8 @@ class Renderer(base.Renderer):
def search_base(self):
if not self._search_base:
self._search_base = uuidToObject(self.data.search_base_uid)
return self._search_base
# aq_inner, because somehow search_base gets wrapped by the renderer
return aq_inner(self._search_base)

@property
def search_base_path(self):
Expand Down
3 changes: 2 additions & 1 deletion plone/app/event/portlets/portlet_events.py
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,8 @@ class Renderer(base.Renderer):
def search_base(self):
if not self._search_base:
self._search_base = uuidToObject(self.data.search_base_uid)
return self._search_base
# aq_inner, because somehow search_base gets wrapped by the renderer
return aq_inner(self._search_base)

@property
def search_base_path(self):
Expand Down