From 82f4844b39819578c2a90a77b7991d59cca4196e Mon Sep 17 00:00:00 2001 From: Mark Cooper Date: Wed, 3 Apr 2013 10:29:10 -0700 Subject: [PATCH] View an authority record by id Suggested by cataloging staff, there is no way to view an authority record directly by id. The 'Manage Authorities' interface does not allow retrieval of an authority record by id. This branch leverages Supercat to display an authority as marctxt in the staff client. Staff are ambivalent about the right-click interface for viewing authorities in the marc editor (which could be a separate issue), so they feel this is important. Primary use case is to quickly view authority using id indicated in $0 subfield. Outstanding question -- should this really load the authority in the marc editor? Signed-off-by: Mark Cooper --- Open-ILS/web/opac/locale/en-US/lang.dtd | 2 ++ Open-ILS/xul/staff_client/chrome/content/main/constants.js | 3 ++- Open-ILS/xul/staff_client/chrome/content/main/menu.js | 14 ++++++++++++++ .../staff_client/chrome/content/main/menu_frame_menus.xul | 3 +++ .../staff_client/chrome/locale/en-US/offline.properties | 2 ++ 5 files changed, 23 insertions(+), 1 deletion(-) diff --git a/Open-ILS/web/opac/locale/en-US/lang.dtd b/Open-ILS/web/opac/locale/en-US/lang.dtd index d52ae7833f..75700a846b 100644 --- a/Open-ILS/web/opac/locale/en-US/lang.dtd +++ b/Open-ILS/web/opac/locale/en-US/lang.dtd @@ -1162,6 +1162,8 @@ + + diff --git a/Open-ILS/xul/staff_client/chrome/content/main/constants.js b/Open-ILS/xul/staff_client/chrome/content/main/constants.js index 0956d9e4f8..0c0a6ddd9c 100644 --- a/Open-ILS/xul/staff_client/chrome/content/main/constants.js +++ b/Open-ILS/xul/staff_client/chrome/content/main/constants.js @@ -517,5 +517,6 @@ var urls = { 'SERIAL_PRINT_ROUTING_LIST_USERS' : 'oils://remote/eg/serial/print_routing_list_users', 'XUL_SERIAL_BATCH_RECEIVE': 'oils://remote/xul/server/serial/batch_receive.xul', 'EG_TRIGGER_EVENTS' : 'oils://remote/eg/actor/user/event_log', - 'XUL_SEARCH_PREFS' : 'chrome://open_ils_staff_client/content/main/search_prefs.xul' + 'XUL_SEARCH_PREFS' : 'chrome://open_ils_staff_client/content/main/search_prefs.xul', + 'SUPERCAT_AUTHORITY_TXT' : 'oils://remote/opac/extras/supercat/retrieve/marctxt/authority/' } diff --git a/Open-ILS/xul/staff_client/chrome/content/main/menu.js b/Open-ILS/xul/staff_client/chrome/content/main/menu.js index aab90009ea..4f56237814 100644 --- a/Open-ILS/xul/staff_client/chrome/content/main/menu.js +++ b/Open-ILS/xul/staff_client/chrome/content/main/menu.js @@ -477,6 +477,20 @@ main.menu.prototype = { ); } ], + 'cmd_search_auth_id' : [ + ['oncommand'], + function(event) { + var auth_id = prompt(offlineStrings.getString('menu.cmd_search_auth_id.tab'),'',offlineStrings.getString('menu.cmd_search_auth_id.prompt')); + if (!auth_id) return; + + var loc = urls.XUL_BROWSER + '?url=' + window.escape(obj.url_prefix('SUPERCAT_AUTHORITY_TXT') + auth_id); + obj.new_tab( + loc, + {}, + {'tab_name': auth_id, 'show_print_button' : true} + ); + } + ], 'cmd_copy_status' : [ ['oncommand'], function(event) { diff --git a/Open-ILS/xul/staff_client/chrome/content/main/menu_frame_menus.xul b/Open-ILS/xul/staff_client/chrome/content/main/menu_frame_menus.xul index 2d274a6e7d..e377f44175 100644 --- a/Open-ILS/xul/staff_client/chrome/content/main/menu_frame_menus.xul +++ b/Open-ILS/xul/staff_client/chrome/content/main/menu_frame_menus.xul @@ -41,6 +41,7 @@ + + @@ -489,6 +491,7 @@ +