zopyx
(Andreas Jung)
August 12, 2019, 8:11am
1
In our Onkopedia portal we use a slightly customized comments portlet registered as
name="onkopedia.comments"
for="xmldirector.connector.connector.IConnector"
manager="plone.app.layout.viewlets.interfaces.IBelowContent"
layer="onkopedia.policy.interfaces.IBrowserLayer"
class=".comments.CommentsViewlet"
template="comments.pt"
permission="zope2.View"
/>
The standard comments viewlet is disabled.
However our comment viewlet is rendered twice. However the code of the underlaying comments.py functionality is only executed once (e.g. the has_replies()
is called only once from the comments.pt template).
There is no Diazo transformation in the game here (stock Barceloneta).
Screenshot: https://nimb.ws/GnCfeu
Any idea?
espenmn
(Espen)
August 12, 2019, 8:19am
2
Are they both in the same viewlet manager?
Do you see anything (weird) at http://path/to/page/@@manage-viewlets ?
zopyx
(Andreas Jung)
August 12, 2019, 8:39am
3
plone.comments
and onkopedia.comments
are registered within the same manager but as said: plone.comments
is disabled.
https://nimb.ws/TkXiAU
espenmn
(Espen)
August 12, 2019, 9:38am
4
So both the viewlets you see are from the same viewlet manager, and you are sure that it is 'plone.comments' you see (not a duplicate of onkopedia.comments) ?
Does /@@manage-viewlets show only one viewlet?
zopyx
(Andreas Jung)
August 12, 2019, 9:51am
5
There is only one viewlet shown within the viewlet manager view. And said: the code/template comes from our portlet (verified).
pbauer
(Philip Bauer)
August 12, 2019, 10:38am
6
My guess is a issue with the diazo-rules. Do you still see it twice with ?diazo.off=1
?
zopyx
(Andreas Jung)
August 12, 2019, 12:45pm
7
But there is no Diazo involved here...this is with plain Barcloneta
espenmn
(Espen)
August 12, 2019, 1:10pm
8
Barceloneta is 'full of diazo rules'
<?xml version="1.0" encoding="utf-8"?>
<rules xmlns="http://namespaces.plone.org/diazo"
xmlns:css="http://namespaces.plone.org/diazo/css"
xmlns:xhtml="http://www.w3.org/1999/xhtml"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:xi="http://www.w3.org/2001/XInclude">
<theme href="index.html" />
<notheme css:if-not-content="#visual-portal-wrapper" />
<rules css:if-content="#portal-top">
<!-- Attributes -->
<copy attributes="*" css:theme="html" css:content="html" />
<!-- Base tag -->
<before css:theme="title" css:content="base" />
<!-- Title -->
<replace css:theme="title" css:content="title" />
<!-- Pull in Plone Meta -->
<after css:theme-children="head" css:content="head meta" />
<!-- Don't use Plone icons, use the theme's -->
This file has been truncated. show original
pbauer
(Philip Bauer)
August 19, 2019, 9:57pm
9
Again: Do you still see it twice with ?diazo.off=1
(only works in development-mode)?
zopyx
(Andreas Jung)
August 20, 2019, 5:46am
10
pbauer:
?diazo.off=1
Only one comment viewlet with Diazo disabled:
Barceloneta: