Open klausru opened 6 months ago
I'm not following your statement, "$article
isn't present as in article_summary.tpl
", as article_summary.tpl
does expect the $article
variable:
and we are setting the $article
variable in the foreach
:
https://github.com/pkp/browseBySection/blob/e64a9afb3230dd7f2a992f1535bf89e51728a079/templates/frontend/pages/section.tpl#L41
So I may be misunderstanding the bigger picture, but I do concur that article_summary.tpl
does also expect $primaryGenreIds
:
https://github.com/pkp/ojs/blob/8d31babfa19c0b27ae35d46a24014dbeb8e4f77d/templates/frontend/objects/article_summary.tpl#L16
And we are not setting them in this template.
The method for setting them can be found here: https://github.com/pkp/ojs/blob/9adc8ef421976d62714584e2860cf2d87f783a0b/pages/article/ArticleHandler.php#L263-L267
We would need to add this into BrowseBySectionHandler::view()
.
Dear all
I just figured that
$primaryGenreIds
is empty in https://github.com/pkp/browseBySection/blob/e64a9afb3230dd7f2a992f1535bf89e51728a079/templates/frontend/pages/section.tpl#L44In my
article_summary.tpl
I wanted to only show galley links for $primaryGenreIds and no galley links for supplementary material. This works fine in issues but not via thesection.tpl
How could that be solved as$article
isn't present as inarticle_summary.tpl