Patch corrected to follow HDL's suggestion that link check
for existing vendor id and conditionally redirect based
on that.
---
 .../prog/en/modules/acqui/supplier.tmpl            |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/supplier.tmpl 
b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/supplier.tmpl
index e07b303..83b8631 100644
--- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/supplier.tmpl
+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/supplier.tmpl
@@ -145,7 +145,9 @@ if (f.company.value == "") {
                 <input type="hidden"  name="invoice_gst" value="0" />
             <!-- /TMPL_UNLESS -->
         </fieldset>
-        <fieldset class="action"><input type="button" value="Save" 
onclick="check(this.form);" /> <a class="cancel" 
href="/cgi-bin/koha/acqui/supplier.pl?supplierid=<!-- TMPL_VAR NAME="id" 
-->">Cancel</a></fieldset>
+        <fieldset class="action"><input type="button" value="Save" 
onclick="check(this.form);" /> <!--TMPL_IF Name="id"-->
+        <a class="cancel" 
href="/cgi-bin/koha/acqui/supplier.pl?supplierid=<!--TMPL_VAR 
Name="id"-->"><!--TMPL_ELSE--><a class="cancel" 
href="/cgi-bin/koha/acqui/acqui-home.pl">
+        <!--/TMPL_IF-->Cancel</a></fieldset>
         </div>
     </form>
 <!--TMPL_ELSE-->
-- 
1.7.0.4

_______________________________________________
Koha-patches mailing list
[email protected]
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-patches

Reply via email to