Bugzilla – Attachment 6510 Details for
Bug 7225
"Delete all items" should be greyed out when a title has no items
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 7225 - "Delete all items" should be greyed out when a title has no items
Bug-7225---Delete-all-items-should-be-greyed-out-w.patch (text/plain), 2.05 KB, created by
Chris Cormack
on 2011-12-02 07:26:21 UTC
(
hide
)
Description:
Bug 7225 - "Delete all items" should be greyed out when a title has no items
Filename:
MIME Type:
Creator:
Chris Cormack
Created:
2011-12-02 07:26:21 UTC
Size:
2.05 KB
patch
obsolete
>From ea6eb6a6344b1b5024e0a740b69ddda1a7511ff4 Mon Sep 17 00:00:00 2001 >From: Owen Leonard <oleonard@myacpl.org> >Date: Tue, 15 Nov 2011 12:01:19 -0500 >Subject: [PATCH] Bug 7225 - "Delete all items" should be greyed out when a > title has no items > >This patch changes the catalog toolbar so that when there are no >items attached to a record the "Delete all items" menu item appears >to be disabled. Clicking it will trigger an alert, "This record >has no items." > >Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz> >--- > .../intranet-tmpl/prog/en/includes/cat-toolbar.inc | 5 ++++- > 1 files changed, 4 insertions(+), 1 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/cat-toolbar.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/cat-toolbar.inc >index 6c7ffae..4b54c40 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/includes/cat-toolbar.inc >+++ b/koha-tmpl/intranet-tmpl/prog/en/includes/cat-toolbar.inc >@@ -55,6 +55,9 @@ function confirm_items_deletion() { > }else{ > return false; > } >+ } else { >+ alert(_("This record has no items.")); >+ return false; > } > } > [% END %] >@@ -102,7 +105,7 @@ function confirm_items_deletion() { > [% IF ( CAN_user_editcatalogue_edit_catalogue ) %]{ text: _("Edit as New (Duplicate)"), url: "/cgi-bin/koha/cataloguing/addbiblio.pl?biblionumber=[% biblionumber %]&frameworkcode=&op=duplicate" },[% END %] > [% IF ( CAN_user_editcatalogue_edit_catalogue ) %]{ text: _("Replace Record via Z39.50"), onclick: {fn: PopupZ3950 } },[% END %] > [% IF ( CAN_user_editcatalogue_edit_catalogue ) %]{ text: _("Delete Record"), onclick: {fn: confirm_deletion }[% IF ( count ) %],id:'disabled'[% END %] },[% END %] >- [% IF ( CAN_user_editcatalogue_edit_items ) %]{ text: _("Delete all Items"), onclick: {fn: confirm_items_deletion } }[% END %] >+ [% IF ( CAN_user_editcatalogue_edit_items ) %]{ text: _("Delete all Items"), onclick: {fn: confirm_items_deletion }[% UNLESS ( count ) %],id:'disabled'[% END %] }[% END %] > ]; > if(editmenu.length){ > new YAHOO.widget.Button({ >-- >1.7.5.4
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 7225
:
6312
| 6510