[open-ils-commits] r16545 - in trunk/Open-ILS/web/opac/skin/default: js xml/common xml/myopac (senator)
svn at svn.open-ils.org
svn at svn.open-ils.org
Tue Jun 1 13:38:25 EDT 2010
Author: senator
Date: 2010-06-01 13:38:21 -0400 (Tue, 01 Jun 2010)
New Revision: 16545
Modified:
trunk/Open-ILS/web/opac/skin/default/js/myopac.js
trunk/Open-ILS/web/opac/skin/default/xml/common/js_common.xml
trunk/Open-ILS/web/opac/skin/default/xml/myopac/myopac_fines.xml
Log:
Remove accidentally committed OPAC CC payment test code.
Only the changes in payment.js and selfcheck.js were supposed to be commited
in 16542. The opac changes themselves were only a rough test and aren't
seaworthy.
Modified: trunk/Open-ILS/web/opac/skin/default/js/myopac.js
===================================================================
--- trunk/Open-ILS/web/opac/skin/default/js/myopac.js 2010-06-01 17:21:31 UTC (rev 16544)
+++ trunk/Open-ILS/web/opac/skin/default/js/myopac.js 2010-06-01 17:38:21 UTC (rev 16545)
@@ -10,7 +10,6 @@
var allowPendingAddr = false;
var myopacEnableRefWorks = false;
var myopacRefWorksHost = 'http://www.refworks.com';
-var paymentForm = new PaymentForm();
function clearNodes( node, keepArray ) {
@@ -568,54 +567,15 @@
balance = _finesFormatNumber(summary.balance_owed());
var req = new Request(FETCH_TRANSACTIONS, G.user.session, G.user.id() );
- req.callback(function(r) { myOPACShowTransactions(r, balance); });
+ req.callback(myOPACShowTransactions);
req.send();
}
$('myopac_fines_summary_total').appendChild(text(total));
$('myopac_fines_summary_paid').appendChild(text(paid));
- $("myopac_fines_summary_balance").appendChild(text(balance));
-
+ $('myopac_fines_summary_balance').appendChild(text(balance));
}
-function preparePaymentForm(balance, transactions) {
- if (Number(balance) > 0) {
- var cxl_link = $("myopac_fines_payment_cancel_link");
- var pay_link = $("myopac_fines_payment_link");
-
- cxl_link.onclick = function() {
- hideMe(cxl_link);
- unHideMe(pay_link);
- unHideMe($("myopac_circ_trans_div"));
- $("myopac_payment_div").innerHTML = "";
- };
- pay_link.onclick = function() {
- dojo.xhrGet({
- "url": "/eg/circ/selfcheck/payment",
- "load": function(resp) {
- hideMe($("myopac_circ_trans_div"));
- $("myopac_payment_div").innerHTML = resp;
- dojo.parser.parse($("myopac_payment_div"));
- paymentForm.drawPayFinesPage(
- G.user, balance, dojo.map(
- transactions, function(t) {
- return [t.id(), Number(t.balance_owed()).toFixed(2)];
- }
- ),
- function() { alert("Payment registered"); /* LFW XXX */ }
- );
- hideMe(pay_link);
- unHideMe(cxl_link);
- },
- "error": function(e) {
- alert("Error preparing payment form: " + e); // XXX i18n; user-friendliness
- }
- });
- };
- unHideMe($("myopac_fines_payment"));
- }
-}
-
function _finesFormatNumber(num) {
if(isNull(num)) num = 0;
num = num + "";
@@ -640,12 +600,11 @@
return d.iso8601Format('YMDHM',null,true,true);
}
-function myOPACShowTransactions(r, balance) {
+function myOPACShowTransactions(r) {
if(myopacGenericTransTemplate || myopacCircTransTemplate) return;
var transactions = r.getResultObject();
- var payment_xacts = [];
for( var idx in transactions ) {
@@ -659,16 +618,12 @@
else if(trans.xact_type() == 'grocery' )
myopacShowGenericTransaction( trans );
- payment_xacts.push(trans);
-
/* XXX need to copy circulation output function here
else if(trans.xact_type() == 'reservation' )
myopacShowReservationTransaction( trans );
*/
}
-
- preparePaymentForm(balance, payment_xacts);
}
var myopacGenericTransTemplate;
Modified: trunk/Open-ILS/web/opac/skin/default/xml/common/js_common.xml
===================================================================
--- trunk/Open-ILS/web/opac/skin/default/xml/common/js_common.xml 2010-06-01 17:21:31 UTC (rev 16544)
+++ trunk/Open-ILS/web/opac/skin/default/xml/common/js_common.xml 2010-06-01 17:38:21 UTC (rev 16545)
@@ -57,20 +57,15 @@
<script type="text/javascript" src='/js/dojo/dojo/dojo.js'></script>
<script type="text/javascript" src='/js/dojo/dojo/openils_dojo.js'></script>
- <script type="text/javascript" src='/js/dojo/opensrf/opensrf.js'></script>
- <script type="text/javascript" src="/js/ui/default/circ/selfcheck/payment.js"></script>
+ <script type="text/javascript" src='/js/dojo/opensrf/opensrf.js'></script>
<script language="javascript" type="text/javascript">
dojo.addOnLoad(init);
dojo.require("dijit._Calendar");
dojo.require("dijit.form.DateTextBox");
- dojo.require("dijit.form.NumberSpinner");
- dojo.require("dijit.form.CheckBox");
- dojo.require("dijit.form.TextBox");
dojo.require("dijit.form.FilteringSelect");
dojo.require("dojo.date.locale");
dojo.require("dojo.date.stamp");
dojo.require("dojo.parser");
dojo.require("openils.I18N");
- dojo.require("openils.Util");
</script>
Modified: trunk/Open-ILS/web/opac/skin/default/xml/myopac/myopac_fines.xml
===================================================================
--- trunk/Open-ILS/web/opac/skin/default/xml/myopac/myopac_fines.xml 2010-06-01 17:21:31 UTC (rev 16544)
+++ trunk/Open-ILS/web/opac/skin/default/xml/myopac/myopac_fines.xml 2010-06-01 17:38:21 UTC (rev 16545)
@@ -17,14 +17,7 @@
<tr id='myopac_fines_summary_row' class='hide_me'>
<td id='myopac_fines_summary_total' >&common.currency;</td>
<td id='myopac_fines_summary_paid' >&common.currency;</td>
- <td style="color:red;font-weight: bold;">
- &common.currency;<span
- id="myopac_fines_summary_balance"></span>
- <span class="hide_me" id="myopac_fines_payment">
- [ <a id="myopac_fines_payment_link" href="javascript:void(0);">Pay this online</a>
- <a id="myopac_fines_payment_cancel_link" href="javascript:void(0);" class="hide_me">Cancel payment</a> ]
- </span>
- </td>
+ <td id='myopac_fines_summary_balance' style='color:red;font-weight: bold;'>&common.currency;</td>
</tr>
</tbody>
</table>
@@ -37,7 +30,6 @@
</div>
-->
- <div id="myopac_payment_div"></div>
<!-- Table for circulation transactions only -->
<div id='myopac_circ_trans_div' class='hide_me'>
More information about the open-ils-commits
mailing list