I'm trying to Stash and output an entry from a channel. Since I also need a dynamic=no menu on the left, I've been able to use a match of the {segment_2} against the url-title to dinamically display the actual entry.
I would like to display, under the main content, its related entries, which are stored as matrix rows. Each related entry has a custom title, a custom bodycopy and a link to the actual entry. The link is stored in one of the Matrix fields as a Playa field. So far I've been able to achieve most of my requirements, but I can't seem to find a way to indicate the context in the get_list for the Playa.
Each related entry, lists links from other rows too. So, if I get 4 related results, each result lists its link and the ones from it's siblings (3+1) too.
{exp:stash:set_list name="patologie_list" parse_tags="yes" parse_depth="2"}
{exp:channel:entries channel="elements_patologie" dynamic="no"}
{stash:entry_id}{entry_id}{/stash:entry_id}
{stash:title}{title}{/stash:title}
{stash:testo_patologia}{testo_patologia}{/stash:testo_patologia}
{stash:url_title}{url_title}{/stash:url_title}
{exp:stash:set_list:matrix name="matrix_link_patologia" context="{entry_id}" parse_tags="yes"}
{matrix_link_patologia}
{stash:titolo_link_patologia}{titolo_link_patologia}{/stash:titolo_link_patologia}
{stash:testo_link_patologia}{testo_link_patologia}{/stash:testo_link_patologia}
{exp:stash:set_list:playa parse_tags="yes" name="resources"}
{exp:playa:children col="link_patologia"}
{stash:link_patologia}{url_title}{/stash:link_patologia}
{/exp:playa:children}
{/exp:stash:set_list:playa}
{/matrix_link_patologia}
{/exp:stash:set_list:matrix}
{/exp:channel:entries}
{/exp:stash:set_list}
<div class="page" id="patologie">
<div class="container">
<aside class="aside-navigation">
<nav class="side-menu">
<ul>
{exp:stash:get_list name="patologie_list"}
<li><a href="{url_title}" class="active">{title}</a></li>
{/exp:stash:get_list}
</ul>
</nav>
</aside>
<section class="main">
<h1>Le patologie trattate</h1>
{exp:stash:get_list name="patologie_list" match="#^{segment_2}$#" against="url_title"}
<h2>{title}</h2>
{testo_patologia}
<div class="related_entries">
<ul>
{exp:stash:get_list:matrix name="matrix_link_patologia" context="{entry_id}" limit="4"}
<li>
<h3>{titolo_link_patologia}</h3>
<p>{testo_link_patologia}
{exp:stash:get_list:playa name="resources"}
<a href="{link_patologia}">Continua</a></p>
{/exp:stash:get_list:playa}
</li>
{/exp:stash:get_list:matrix}
</ul>
</div>
{/exp:stash:get_list}
</section>
</div>