something sets the iframe url to '$BASE_URL/{{url}}' (encoded as '%7B%7Burl%7D%7D') when the page is reloaded or the URL is accessed directly.
Open-ILS/web/js/ui/default/staff/cat/catalog/app.js cannot extract the record id from this value, so a blank page is ultimately loaded.
superfluous reloads can be avoided by skipping the $scope.onchange event when the new url is invalid (ends with '{{url}}').
Signed-off-by: a. bellenir <ab@grpl.org>
});
}
- if ($scope.onchange) $scope.onchange(page);
+ // skip firing onchange if page url ends with "{{url}}"
+ if ($scope.onchange && !page.match(/%7B%7Burl%7D%7D$/)) $scope.onchange(page);
}
// open a new tab with the embedded URL