'flex' : 1,
'primary' : false,
'hidden' : true,
+ 'sort_value' : function(my,scratch_data) {
+ var acn_id;
+ if (my.acn) {
+ if (typeof my.acn == 'object') {
+ acn_id = my.acn.id();
+ } else {
+ acn_id = my.acn;
+ }
+ } else if (my.acp) {
+ if (typeof my.acp.call_number() == 'object' && my.acp.call_number() != null) {
+ acn_id = my.acp.call_number().id();
+ } else {
+ acn_id = my.acp.call_number();
+ }
+ }
+ if (!acn_id && acn_id != 0) {
+ return '';
+ } else if (acn_id == -1) {
+ return document.getElementById('circStrings').getString('staff.circ.utils.not_cataloged');
+ } else if (acn_id == -2) {
+ return document.getElementById('circStrings').getString('staff.circ.utils.retrieving');
+ } else {
+ if (!my.acn) {
+ if (typeof scratch_data == 'undefined' || scratch_data == null) {
+ scratch_data = {};
+ }
+ if (typeof scratch_data['acn_map'] == 'undefined') {
+ scratch_data['acn_map'] = {};
+ }
+ if (typeof scratch_data['acn_map'][ acn_id ] == 'undefined') {
+ var x = network.simple_request("FM_ACN_RETRIEVE.authoritative",[ acn_id ]);
+ if (x.ilsevent) {
+ return document.getElementById('circStrings').getString('staff.circ.utils.not_cataloged');
+ } else {
+ my.acn = x;
+ scratch_data['acn_map'][ acn_id ] = my.acn;
+ }
+ } else {
+ my.acn = scratch_data['acn_map'][ acn_id ];
+ }
+ }
+ return my.acn.label_sortkey();
+ }
+ },
'editable' : false, 'render' : function(my,scratch_data) {
var acn_id;
if (my.acn) {