staff.patron.display.init.network_request.inactive_card=Patron account retrieved with an INACTIVE card.<br/><br/>
staff.patron.display.init.network_request.account_barred=Patron account is BARRED.<br/><br/>
staff.patron.display.init.network_request.account_inactive=Patron account is INACTIVE.<br/><br/>
+staff.patron.display.init.network_request.account_expire_soon=Patron account will expire soon. Please renew.<br/><br/>
staff.patron.display.init.network_request.account_expired=Patron account is EXPIRED.<br/><br/>
staff.patron.display.init.holds_ready=Holds available: %1$s
staff.patron.display.init.network_request.window_title=Alert
if (patron.expire_date()) {
var now = new Date();
now = now.getTime()/1000;
+ var preexpire = new Date();
+ preexpire.setDate(preexpire.getDate() + 28);
+ preexpire = preexpire.getTime()/1000;
var expire_parts = patron.expire_date().substr(0,10).split('-');
expire_parts[1] = expire_parts[1] - 1;
if (expire < now) {
msg += $("patronStrings").getString('staff.patron.display.init.network_request.account_expired');
- obj.stop_checkouts = true;
+ obj.stop_checkouts = true;
+ } else if (expire < preexpire) {
+ msg += $("patronStrings").getString('staff.patron.display.init.network_request.account_expire_soon');
}
}
var penalties = patron.standing_penalties();