[open-ils-commits] r11678 - in trunk/Open-ILS/xul/staff_client/server: main patron
svn at svn.open-ils.org
svn at svn.open-ils.org
Tue Dec 23 17:22:40 EST 2008
Author: phasefx
Date: 2008-12-23 17:22:36 -0500 (Tue, 23 Dec 2008)
New Revision: 11678
Modified:
trunk/Open-ILS/xul/staff_client/server/main/verify_credentials.js
trunk/Open-ILS/xul/staff_client/server/patron/display.js
trunk/Open-ILS/xul/staff_client/server/patron/summary.js
trunk/Open-ILS/xul/staff_client/server/patron/summary.xul
trunk/Open-ILS/xul/staff_client/server/patron/summary_overlay.xul
Log:
another entry point for verify credentials, via patron sidebar. also disable some of the interface if thus invoked
Modified: trunk/Open-ILS/xul/staff_client/server/main/verify_credentials.js
===================================================================
--- trunk/Open-ILS/xul/staff_client/server/main/verify_credentials.js 2008-12-23 21:54:09 UTC (rev 11677)
+++ trunk/Open-ILS/xul/staff_client/server/main/verify_credentials.js 2008-12-23 22:22:36 UTC (rev 11678)
@@ -69,7 +69,11 @@
} catch(E) {
alert(E);
}
- document.getElementById('name_prompt').focus();
+ if (document.getElementById('name_prompt').disabled) {
+ document.getElementById('password_prompt').focus();
+ } else {
+ document.getElementById('name_prompt').focus();
+ }
},
false
);
@@ -97,7 +101,16 @@
false
);
- document.getElementById('name_prompt').focus();
+ if (xulG.barcode) {
+ document.getElementById('name_prompt').disabled = true;
+ document.getElementById('name_prompt').value = xulG.usrname;
+ document.getElementById('barcode_prompt').disabled = true;
+ document.getElementById('barcode_prompt').value = xulG.barcode;
+ document.getElementById('cmd_retrieve').setAttribute('disabled','true');
+ document.getElementById('password_prompt').focus();
+ } else {
+ document.getElementById('name_prompt').focus();
+ }
} catch(E) {
alert(E);
Modified: trunk/Open-ILS/xul/staff_client/server/patron/display.js
===================================================================
--- trunk/Open-ILS/xul/staff_client/server/patron/display.js 2008-12-23 21:54:09 UTC (rev 11677)
+++ trunk/Open-ILS/xul/staff_client/server/patron/display.js 2008-12-23 22:22:36 UTC (rev 11678)
@@ -365,7 +365,17 @@
{},
{
'barcode' : obj.barcode,
- 'id' : obj.id,
+ 'id' : obj.id,
+ 'verify_credentials' : function(patron) {
+ var vframe = obj.right_deck.reset_iframe(
+ urls.XUL_VERIFY_CREDENTIALS,
+ {},
+ {
+ 'barcode' : patron.card().barcode(),
+ 'usrname' : patron.usrname()
+ }
+ );
+ },
'on_finished' : function(patron) {
obj.patron = patron; obj.controller.render();
Modified: trunk/Open-ILS/xul/staff_client/server/patron/summary.js
===================================================================
--- trunk/Open-ILS/xul/staff_client/server/patron/summary.js 2008-12-23 21:54:09 UTC (rev 11677)
+++ trunk/Open-ILS/xul/staff_client/server/patron/summary.js 2008-12-23 22:22:36 UTC (rev 11678)
@@ -35,6 +35,12 @@
['command'],
function() { alert($("commonStrings").getString('common.unimplemented')); }
],
+ 'cmd_verify_credentials' : [
+ ['command'],
+ function() {
+ xulG.verify_credentials(obj.patron);
+ }
+ ],
'patron_alert' : [
['render'],
function(e) {
Modified: trunk/Open-ILS/xul/staff_client/server/patron/summary.xul
===================================================================
--- trunk/Open-ILS/xul/staff_client/server/patron/summary.xul 2008-12-23 21:54:09 UTC (rev 11677)
+++ trunk/Open-ILS/xul/staff_client/server/patron/summary.xul 2008-12-23 22:22:36 UTC (rev 11678)
@@ -70,6 +70,7 @@
<messagecatalog id="commonStrings" src="/xul/server/locale/<!--#echo var='locale'-->/common.properties" />
<commandset id="patron_summary_cmds">
+ <command id="cmd_verify_credentials"/>
</commandset>
<box id="patron_summary_main" />
Modified: trunk/Open-ILS/xul/staff_client/server/patron/summary_overlay.xul
===================================================================
--- trunk/Open-ILS/xul/staff_client/server/patron/summary_overlay.xul 2008-12-23 21:54:09 UTC (rev 11677)
+++ trunk/Open-ILS/xul/staff_client/server/patron/summary_overlay.xul 2008-12-23 22:22:36 UTC (rev 11678)
@@ -137,9 +137,14 @@
<row id="pdsgr0">
<label id="PatronSummaryContact_library_card_label" class="text_left card label"
value="&staff.patron_display.library_card.label;"/>
- <label id="patron_card" class="card value" style="text-decoration: underline; color: blue; -moz-user-focus: normal;" onclick="try { copy_to_clipboard(event); } catch(E) { alert(E); }"/>
- <!--<textbox id="patron_card" class="plain" readonly="true" onclick="this.select()"/>-->
+ <label id="patron_card" class="card value click_link" onclick="try { copy_to_clipboard(event); } catch(E) { alert(E); }"/>
</row>
+ <row id="pdsgr0a">
+ <button id="PatronSummary_verify_passwd_label"
+ label="&staff.patron_display.verify_password.label;" accesskey="&staff.patron_display.verify_password.accesskey;"
+ command="cmd_verify_credentials"/>
+ <spacer/>
+ </row>
<row id="pdsgr1">
<label id="PatronSummaryContact_ident_label" class="text_left"
value="&staff.patron_display.ident1.label;"/>
More information about the open-ils-commits
mailing list