<!ENTITY staff.portal.default.welcome "This is the Evergreen staff client portal page. You can customize this with the information or functionality your organization needs to support its operations. For example, you could add links to process and procedure documents.">
<!ENTITY ui.circ.patron_summary.horizontal "GUI: Alternative Horizontal Patron Summary Panel">
<!ENTITY ui.circ.patron_summary.horizontal.desc "This replaces the vertical Patron Summary Sidebar.">
+<!ENTITY ui.circ.in_house_use.entry_cap "GUI: Record In-House Use: Maximum # of uses allowed per entry.">
+<!ENTITY ui.circ.in_house_use.entry_cap.desc "The # of uses entry in the Record In-House Use interface may not exceed the value of this setting.">
+<!ENTITY ui.circ.in_house_use.entry_warn "GUI: Record In-House Use: # of uses threshold for Are You Sure? dialog.">
+<!ENTITY ui.circ.in_house_use.entry_warn.desc "In the Record In-House Use interface, a submission attempt will warn if the # of uses field exceeds the value of this setting.">
<!ENTITY ui.general.button_bar "GUI: Above-Tab Button Bar">
<!ENTITY ui.general.button_bar.desc "This enables a row of buttons and/or icons between the top-level menu system and the tabbed interfaces.">
<!ENTITY ui.network.progress_meter "GUI: Network Activity Meter">
desc : '&ui.circ.patron_summary.horizontal.desc;',
type : 'bool'
},
+ 'ui.circ.in_house_use.entry_cap' : {
+ label : '&ui.circ.in_house_use.entry_cap;',
+ desc : '&ui.circ.in_house_use.entry_cap.desc;',
+ type : 'integer'
+ },
+ 'ui.circ.in_house_use.entry_warn' : {
+ label : '&ui.circ.in_house_use.entry_warn;',
+ desc : '&ui.circ.in_house_use.entry_warn.desc;',
+ type : 'integer'
+ },
'ui.general.button_bar' : {
label : '&ui.general.button_bar;',
desc : '&ui.general.button_bar.desc;',
JSAN.use('util.barcode');
JSAN.use('util.date');
JSAN.use('OpenILS.data'); this.data = new OpenILS.data(); this.data.init({'via':'stash'});
+ JSAN.use('util.sound'); this.sound = new util.sound();
}
circ.in_house_use.prototype = {
var obj = this;
+ obj.entry_cap = Number( obj.data.hash.aous['ui.circ.in_house_use.entry_cap'] ) || 99;
+ obj.entry_warn = Number( obj.data.hash.aous['ui.circ.in_house_use.entry_warn'] ) || 20;
+
JSAN.use('circ.util');
var columns = circ.util.columns(
{
try {
var value = Number(ev.target.value);
if (value > 0) {
- if (value > 99) ev.target.value = 99;
+ if (value > obj.entry_cap) { throw(value); }
} else {
- ev.target.value = 1;
+ throw(value);
}
} catch(E) {
dump('in_house_use:multiplier: ' + E + '\n');
- ev.target.value = 1;
+ obj.sound.circ_bad();
+ setTimeout(
+ function() {
+ obj.controller.view.in_house_use_multiplier_textbox.focus();
+ obj.controller.view.in_house_use_multiplier_textbox.select();
+ }, 0
+ );
}
}
}
return;
}
- if (multiplier == 0 || multiplier > 99) {
+ if (multiplier == 0 || multiplier > obj.entry_cap) {
obj.controller.view.in_house_use_multiplier_textbox.focus();
obj.controller.view.in_house_use_multiplier_textbox.select();
return;
}
- if (multiplier > 20) {
+ if (multiplier > obj.entry_warn) {
var r = obj.error.yns_alert(
document.getElementById('circStrings').getFormattedString('staff.circ.in_house_use.confirm_multiple', [barcode, multiplier]),
document.getElementById('circStrings').getString('staff.circ.in_house_use.confirm_multiple.title'),
//I could override map_row_to_column here
}
);
+ obj.sound.circ_good();
if (typeof obj.on_in_house_use == 'function') {
obj.on_in_house_use(result);
<hbox id="in_house_use_top_ui">
<label id="in_house_use_multiplier_label" value="&staff.circ.in_house_use.multiplier.label;" control="in_house_use_multiplier_textbox" accesskey="&staff.circ.in_house_use.multiplier.accesskey;" hidden="false"/>
- <textbox id="in_house_use_multiplier_textbox" value="1" hidden="false" size="2" cols="2" context="clipboard"/>
+ <textbox id="in_house_use_multiplier_textbox" value="1" hidden="false" size="6" cols="6" context="clipboard"/>
<hbox id="in_house_use_menu_placeholder" flex="0"/>
<textbox id="in_house_use_barcode_entry_textbox" context="clipboard"/>
<button id="in_house_use_submit_barcode_button"