[Koha-patches] [PATCH] Fixes Bug 4851 Batch delete shouldn't show delete button if no items were found

Ebin Joseph ebin.joseph at osslabs.biz
Thu Jul 15 13:18:03 CEST 2010


---
 .../prog/en/modules/tools/batchMod-del.tmpl        |   19 ++++++++++++++++---
 1 files changed, 16 insertions(+), 3 deletions(-)

diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/batchMod-del.tmpl b/koha-tmpl/intranet-tmpl/prog/en/modules/tools/batchMod-del.tmpl
index c6f82b9..0d35e62 100644
--- a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/batchMod-del.tmpl
+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/tools/batchMod-del.tmpl
@@ -124,19 +124,32 @@
 
 		<div id="cataloguing_additem_newitem">
 	     <input type="hidden" name="op" value="<!-- TMPL_VAR NAME="op" -->" />
-	     <p>This will delete <!-- TMPL_IF NAME="too_many_items" -->all the<!-- TMPL_ELSE -->the selected<!-- /TMPL_IF --> items.</p>
+			 <!-- TMPL_IF name="notfoundbarcodes" -->
+			 <p>There are no matching items</p>
+			 <!-- TMPL_ELSE-->            	
+	     		 <p>This will delete <!-- TMPL_IF NAME="too_many_items" -->all the<!-- TMPL_ELSE -->the selected<!-- /TMPL_IF --> items.</p>
+			  <!-- /TMPL_IF -->
 	     <input type="hidden" name="del" value="1" />
 	     <fieldset class="action">    
 		<div id="jobpanel">
 		    <div id="jobstatus">Job progress: <div id="jobprogress"></div> <span id="jobprogresspercent">0</span>%</div>
 		    <div id="jobfailed"></div>
 		</div>
-		<input type="submit" name="mainformsubmit" value="Delete selected items" onclick="return submitBackgroundJob(this.form);" />
+			<!-- TMPL_IF name="notfoundbarcodes" -->
+			<input type="hidden" name="mainformsubmit" value="Delete selected items" onclick="return submitBackgroundJob(this.form);" />
+			<!-- /TMPL_IF-->
+			<!-- TMPL_IF name="too_many_items"-->
+			<input type="submit" name="mainformsubmit" value="Delete selected items" onclick="return submitBackgroundJob(this.form);" />
+			<!-- TMPL_ELSE-->
+			 <input type="hidden" name="mainformsubmit" value="Delete selected items" onclick="return submitBackgroundJob(this.form);" />
+                        <!-- /TMPL_IF -->
+	
 		<a href="/cgi-bin/koha/tools/batchMod.pl?del=1" class="cancel">Cancel</a>
 	    </fieldset>
 	</div>
 	<!-- /TMPL_IF -->
-    <!-- /TMPL_UNLESS -->
+    <!-- /TMPL_UNLESS --<!-- TMPL_IF name="notfoundbarcodes" -->
+
 
 <!-- TMPL_IF name="action" -->
 	<div class="dialog message"><p><!-- TMPL_VAR NAME="deleted_items" --> item(s) deleted.</p></div>
-- 
1.6.4.2



More information about the Koha-patches mailing list