<div class="rdetail_header">
<span class="rdetail_results">
<a href='[% mkurl(ctx.opac_root _ '/results', {}, stop_parms); %]'><span class="nav_arrow_fix">◄</span> [% l('Search Results') %]</a>
+ <!-- stash these in JS for the web staff client to find -->
+ <script>
+ window.search_result_hit_count = [% ctx.hit_count %];
+ window.search_result_index = [% ctx.search_result_index %];
+ </script>
<span class="rdetail_result_count">
[% l('Showing Item [_1] of [_2]', ctx.search_result_index + 1, ctx.hit_count) %]
</span>
[% l('End') %]
</button>
<button type="button" ng-disabled="from_route" class="btn btn-default" ng-click="opac_call('rdetailBackToResults', true)">
- [% l('Back To Results') %]
+ [% l('Back To Results') %] ( {{ search_result_index }} / {{ search_result_hit_count }} )
</button>
</div>
<div class="col-md-3">
$scope.opac_iframe = null;
$scope.parts_iframe = null;
+ $scope.search_result_index = 1;
+ $scope.search_result_hit_count = 1;
+
+ $scope.$watch(
+ 'opac_iframe.dom.contentWindow.search_result_index',
+ function (n,o) {
+ if (!isNaN(parseInt(n)))
+ $scope.search_result_index = n + 1;
+ }
+ );
+
+ $scope.$watch(
+ 'opac_iframe.dom.contentWindow.search_result_hit_count',
+ function (n,o) {
+ if (!isNaN(parseInt(n)))
+ $scope.search_result_hit_count = n;
+ }
+ );
+
$scope.in_opac_call = false;
$scope.opac_call = function (opac_frame_function, force_opac_tab) {
if ($scope.opac_iframe) {