Bug 9534 - No way to get back to bib detail from edit record
authorLiz Rea <liz@catalyst.net.nz>
Thu, 7 Mar 2013 00:33:25 +0000 (13:33 +1300)
committerJared Camins-Esakov <jcamins@cpbibliography.com>
Sun, 31 Mar 2013 01:27:37 +0000 (21:27 -0400)
To test:

* Set your BiblioDefaultDisplay to one of the options (go through all three of them)
* view a record
* click "Edit Record"
* you should see a "Cancel" button on the toolbar - click it
* you will be redirected back to the detail page, in the default display method you have picked

* Click More -> Cataloging
* Click the Cancel button
* you should be redirected back to the cataloguing home page

This patch only applies on top of the patch for bug 9672 as it uses the bootstrap buttons.

Signed-off-by: Brendan <brendan@bywatersolutions.com>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Tested according to test plan, also with z39.50 overlay from
detail page.
All tests except for tt_valid and QA script pass.
Sending a follow-up to fix that problem.
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>

koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/addbiblio.tt

index 64298fa..eb955cd 100644 (file)
@@ -371,8 +371,14 @@ function Changefwk(FwkList) {
 
     [% UNLESS (circborrowernumber) %][%# Hide in fast cataloging %]
         <div class="btn-group"><a class="btn btn-small" href="#" id="z3950search"><i class="icon-search"></i> Z39.50 search</a></div>
-        <div class="btn-group">
-            <label for="Frameworks">Change framework: </label>
+        [% IF (biblionumber) %]
+            <div class="btn-group"><a class="btn btn-small" id="cancel" [% IF ( BiblioDefaultViewmarc ) %]href="/cgi-bin/koha/catalogue/MARCdetail.pl?biblionumber=[% biblionumber |url %]"> [% ELSIF ( BiblioDefaultViewlabeled_marc ) %] href="/cgi-bin/koha/catalogue/labeledMARCdetail.pl?biblionumber=[% biblionumber |url %]"> [% ELSIF ( BiblioDefaultViewisbd ) %] href="/cgi-bin/koha/catalogue/ISBDdetail.pl?biblionumber=[% biblionumber |url %]">[% ELSE %] href="/cgi-bin/koha/catalogue/detail.pl?biblionumber=[% biblionumber |url %]">[% END %]Cancel</a></div>
+        [% ELSE %]
+            <a class="btn btn-small" id="cancel" href="/cgi-bin/koha/cataloguing/addbooks.pl">Cancel</a>
+        [% END %]
+    [% END %]
+    <div class="btn-group">
+        <label for="Frameworks">Change framework: </label>
             <select name="frameworkcode" id="Frameworks" onchange="Changefwk(this);">
                 <option value="Default">Default</option>
                 [% FOREACH frameworkcodeloo IN frameworkcodeloop %]
@@ -381,12 +387,11 @@ function Changefwk(FwkList) {
                     [% ELSE %]
                         <option value="[% frameworkcodeloo.value %]">
                     [% END %]
-                     [% frameworkcodeloo.frameworktext %]
-                     </option>
+                       [% frameworkcodeloo.frameworktext %]
+                       </option>
                 [% END %]
-            </select>
-        </div>
-    [% END %]
+        </select>
+</div>
 </div>
 
 [% IF ( popup ) %]