From 8f08df952f1dc2ce87d3589e221effd87f051287 Mon Sep 17 00:00:00 2001 From: pines Date: Wed, 6 Sep 2006 06:19:02 +0000 Subject: [PATCH] don't use the mobts total call for styling has_bills git-svn-id: svn://svn.open-ils.org/ILS/trunk@5981 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- Open-ILS/xul/staff_client/server/patron/summary.js | 3 ++- Open-ILS/xul/staff_client/server/patron/util.js | 2 ++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/Open-ILS/xul/staff_client/server/patron/summary.js b/Open-ILS/xul/staff_client/server/patron/summary.js index 45d24a22b4..123a36a802 100644 --- a/Open-ILS/xul/staff_client/server/patron/summary.js +++ b/Open-ILS/xul/staff_client/server/patron/summary.js @@ -140,7 +140,8 @@ patron.summary.prototype = { for (var i = 0; i < list.length; i++) { var robj = typeof list[i] == 'object' ? list[i] : obj.network.simple_request('FM_MBTS_RETRIEVE',[ses(),list[i]]); sum += robj.balance_owed(); - } + } + if (sum > 0) addCSSClass(document.documentElement,'PATRON_HAS_BILLS'); JSAN.use('util.money'); e.setAttribute('value', '$' + util.money.sanitize( sum )); } diff --git a/Open-ILS/xul/staff_client/server/patron/util.js b/Open-ILS/xul/staff_client/server/patron/util.js index 16469b03f6..de12cfe73b 100644 --- a/Open-ILS/xul/staff_client/server/patron/util.js +++ b/Open-ILS/xul/staff_client/server/patron/util.js @@ -485,9 +485,11 @@ patron.util.set_penalty_css = function(patron) { try { JSAN.use('util.network'); var net = new util.network(); + /* net.simple_request('FM_MOBTS_TOTAL_HAVING_BALANCE',[ ses(), patron.id() ], function(req) { if (req.getResultObject() > 0) addCSSClass(document.documentElement,'PATRON_HAS_BILLS'); }); + */ net.simple_request('FM_CIRC_COUNT_RETRIEVE_VIA_USER',[ ses(), patron.id() ], function(req) { var co = req.getResultObject(); if (co.overdue > 0 || co.long_overdue > 0) addCSSClass(document.documentElement,'PATRON_HAS_OVERDUES'); -- 2.43.2