Preserve sort parameter when saving bookbag notes, other similar actions bookbag-goodies-tto
authorLebbeous Fogle-Weekley <lebbeous@esilibrary.com>
Wed, 31 Aug 2011 18:28:52 +0000 (14:28 -0400)
committerLebbeous Fogle-Weekley <lebbeous@esilibrary.com>
Wed, 31 Aug 2011 18:28:52 +0000 (14:28 -0400)
Signed-off-by: Lebbeous Fogle-Weekley <lebbeous@esilibrary.com>
Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Account.pm
Open-ILS/web/templates/default/opac/myopac/lists.tt2

index fc345ec..120d17b 100644 (file)
@@ -1295,7 +1295,9 @@ sub load_myopac_bookbag_update {
     # may need to add some back in for paging.
 
     my $url = "https://" . $self->apache->hostname .
-        $self->ctx->{opac_root} . "/myopac/lists";
+        $self->ctx->{opac_root} . "/myopac/lists?";
+
+    $url .= 'sort=' . uri_escape($cgi->param("sort")) if $cgi->param("sort");
 
     if ($action eq 'create') {
         $list = Fieldmapper::container::biblio_record_entry_bucket->new;
index 8a5a7cb..1b7adc0 100644 (file)
             </div>
             <form action="[% ctx.opac_root %]/myopac/list/update" method="POST">
             <input type="hidden" name="list" value="[% bbag.id %]" />
+            <input type="hidden" name="sort" value="[% CGI.param('sort') | uri %]" />
             <table cellpadding='0' cellspacing='0' border='0'>
                 <thead id="acct_list_header">
                     <tr>
                         <td width="32%">
                             [% l('Notes') %]
                             [% IF CGI.param("edit_notes") != bbag.id %]
-                            | <a href="[% ctx.opac_root %]/myopac/lists?edit_notes=[% bbag.id %]">[% l('Edit') %]</a>
+                            | <a href="[% ctx.opac_root %]/myopac/lists?[% IF CGI.param('sort'); 'sort='; (CGI.param('sort')) | uri; '&amp;'; END %]edit_notes=[% bbag.id %]">[% l('Edit') %]</a>
                             [% END %]
                         </td>
                         <td width="1%" class="nowrap">