In occurrences, we have two "types" of related object representations. Some are "internal" and some other "external".
The idea is to show in the detail display, very clearly, that difference.
We came with two ideas to see if somehow we could achieve this.
Trying to use two different representationViewers in the occurrence detail page, one by filtering the thumbnails with relationship type A,B,C,D, etc. (internal) and another only including those with relationship type Z (external). But we werent able to find a way to do that filtering when calling caObjectRepresentationThumbnails, and also, it would be desirable to have under every thumbnail a small text, in this case the representation label.
Using "browseResultsContainer" and caNavUrl function. In this case the small text under the thubmnail is solved, but we need to address how to show every picture in a big "viewer" when selecting it.
As an alternative we are also considering to use object representations only for "internal" and , for "external" created a new metadata container with two submetadatas image (media) and text to see if this way we could achieve this objective. The problem is how to get ccurrences.container.mediafile and occurrences.container.text in the caNavUrl in the following code
{{{<ifcount code="ca_objects" min="2">
<div class="row">
<div id="browseResultsContainer">
<?php print caBusyIndicatorIcon($this->request).' '.addslashes(_t('Loading...')); ?>
</div><!-- end browseResultsContainer -->
</div><!-- end row -->
<script type="text/javascript">
jQuery(document).ready(function() {
jQuery("#browseResultsContainer").load("<?php print caNavUrl($this->request, '', 'Search', '????', array('search' => 'occurrence_id:^ca_occurrences.occurrence_id AND ???'), array('dontURLEncodeParameters' => true)); ?>", function() {
jQuery('#browseResultsContainer').jscroll({
autoTrigger: true,
loadingHtml: '<?php print caBusyIndicatorIcon($this->request).' '.addslashes(_t('Loading...')); ?>',
padding: 20,
nextSelector: 'a.jscroll-next'
});
});
});
</script>
</ifcount>}}}
Any other ideas or suggestions?