From: Michael Peters Date: Wed, 22 Jun 2011 14:14:55 +0000 (-0400) Subject: LP#790639: Provide actual text, rather than id values in patron search results for... X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=e6c4793e80e770002a59e9bea43607bc16b3b6dc;p=evergreen%2Fpines.git LP#790639: Provide actual text, rather than id values in patron search results for various columns Cleaned up some tabs versus spaces and a needless trailing comma from original patch. Not porting to master, hoping to use collab/phasefx/fm_columns instead. Signed-off-by: Jason Etheridge Signed-off-by: Michael Peters --- diff --git a/Open-ILS/xul/staff_client/server/locale/en-US/patron.properties b/Open-ILS/xul/staff_client/server/locale/en-US/patron.properties index ba789c859d..ada0d4ead7 100644 --- a/Open-ILS/xul/staff_client/server/locale/en-US/patron.properties +++ b/Open-ILS/xul/staff_client/server/locale/en-US/patron.properties @@ -343,6 +343,8 @@ staff.patron.search_result.init.search_clipboard=patron search clipboard staff.patron.search_result.init.search_saving_columns=patron search saving columns staff.patron.search_result.mailing_address_column_label_prefix=Mailing Addr: staff.patron.search_result.billing_address_column_label_prefix=Billing Addr: +staff.patron.search_result.ident_type_column_label_prefix=Ident Type: +staff.patron.search_result.ident_type2_column_label_prefix=Ident Type 2: staff.patron.summary.patron_bill.money=$ %1$s staff.patron.summary.retrieve.no_barcode=summary: No barcode or ID staff.patron.summary.patron_net_access=Internet diff --git a/Open-ILS/xul/staff_client/server/patron/search_result.js b/Open-ILS/xul/staff_client/server/patron/search_result.js index fadbb684ff..d4beacabfe 100644 --- a/Open-ILS/xul/staff_client/server/patron/search_result.js +++ b/Open-ILS/xul/staff_client/server/patron/search_result.js @@ -36,13 +36,20 @@ patron.search_result.prototype = { 'au_family_name' : { 'hidden' : false }, 'au_first_given_name' : { 'hidden' : false }, 'au_second_given_name' : { 'hidden' : false }, - 'au_dob' : { 'hidden' : false } + 'au_dob' : { 'hidden' : false }, + 'au_profile' : { 'remove_me' : true }, + 'au_ident_type' : { 'remove_me' : true }, + 'au_ident_type2' : { 'remove_me' : true } }).concat( obj.list.fm_columns('ac',{ '*' : { 'remove_virtual' : true, 'expanded_label' : true, 'hidden' : true }, 'ac_barcode' : { 'hidden' : false } }) ).concat( + obj.list.fm_columns('pgt',{ + '*' : { 'remove_virtual' : true, 'expanded_label' : true, 'hidden' : true } + }) + ).concat( obj.list.fm_columns('aua',{ '*' : { 'dataobj' : 'billing_aua', @@ -60,6 +67,24 @@ patron.search_result.prototype = { 'hidden' : true } },'mailing_') + ).concat( + obj.list.fm_columns('cit',{ + '*' : { + 'dataobj' : 'ident_type', + 'remove_virtual' : true, + 'label_prefix' : $('patronStrings').getString('staff.patron.search_result.ident_type_column_label_prefix'), + 'hidden' : true + } + },'ident_type_') + ).concat( + obj.list.fm_columns('cit',{ + '*' : { + 'dataobj' : 'ident_type2', + 'remove_virtual' : true, + 'label_prefix' : $('patronStrings').getString('staff.patron.search_result.ident_type2_column_label_prefix'), + 'hidden' : true + } + },'ident_type2_') ); obj.list.init( @@ -80,6 +105,9 @@ patron.search_result.prototype = { row.my.ac = row.my.au.card(); row.my.billing_aua = row.my.au.billing_address(); row.my.mailing_aua = row.my.au.mailing_address(); + row.my.pgt = typeof row.my.au.profile() == 'object' ? row.my.au.profile() : obj.OpenILS.data.hash.pgt[ row.my.au.profile() ]; + row.my.ident_type = typeof row.my.au.ident_type() == 'object' ? row.my.au.ident_type() : obj.OpenILS.data.hash.cit[ row.my.au.ident_type() ]; + row.my.ident_type2 = typeof row.my.au.ident_type2() == 'object' ? row.my.au.ident_type2() : obj.OpenILS.data.hash.cit[ row.my.au.ident_type2() ]; if (typeof params.on_retrieve == 'function') { params.on_retrieve(row); } else {