Bug 35496: Open article requests tab by default on opac-user.pl after placing an article request
To test: 1 - Turn on ArticleRequests 2 - Place an Article Requests on the opac 3 - Note after placing the request the URL is: http://localhost:8080/cgi-bin/koha/opac-user.pl#opac-user-article-requests 4 - Note the article request tab is not active 5 - APPLY PATCH and restart_all 6. Try steps 2 - 4 again, this time the article request tab should be open by default. Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net> Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de> (cherry picked from commit33ba9c2701
) Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com> (cherry picked from commit7ad7038936
) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
This commit is contained in:
parent
d088c35445
commit
745655bddd
3 changed files with 5 additions and 1 deletions
|
@ -1094,6 +1094,9 @@
|
|||
[% IF ( opac_user_holds ) %]
|
||||
$("#opac-user-views a[href='#opac-user-holds_panel']").tab("show");
|
||||
[% END %]
|
||||
[% IF ( opac_user_article_requests ) %]
|
||||
$("#opac-user-views a[href='#opac-user-article-requests_panel']").tab("show");
|
||||
[% END %]
|
||||
$('#opac-user-article-requests caption .count').html(AR_CAPTION_COUNT.format('[% current_article_requests.size | html %]'));
|
||||
|
||||
$(".modal-nojs").addClass("modal").addClass("hide").removeClass("modal-nojs");
|
||||
|
|
|
@ -102,7 +102,7 @@ if ( $action eq 'create' ) {
|
|||
};
|
||||
|
||||
if ( $success ) {
|
||||
print $cgi->redirect("/cgi-bin/koha/opac-user.pl#opac-user-article-requests");
|
||||
print $cgi->redirect("/cgi-bin/koha/opac-user.pl?opac-user-article-requests=1");
|
||||
exit;
|
||||
}
|
||||
# Should we redirect?
|
||||
|
|
|
@ -430,6 +430,7 @@ $template->param(
|
|||
OpacHoldNotes => C4::Context->preference('OpacHoldNotes'),
|
||||
failed_holds => scalar $query->param('failed_holds'),
|
||||
opac_user_holds => scalar $query->param('opac-user-holds') || 0,
|
||||
opac_user_article_requests => scalar $query->param('opac-user-article-requests') || 0,
|
||||
);
|
||||
|
||||
# if not an empty string this indicates to return
|
||||
|
|
Loading…
Reference in a new issue