|
Lines 68-74
Link Here
|
| 68 |
|
68 |
|
| 69 |
[% PROCESS 'account-table.inc' ACCOUNT_LINES = ACCOUNT_LINES, ENABLE_OPAC_PAYMENTS = ENABLE_OPAC_PAYMENTS, plugins = plugins %] |
69 |
[% PROCESS 'account-table.inc' ACCOUNT_LINES = ACCOUNT_LINES, ENABLE_OPAC_PAYMENTS = ENABLE_OPAC_PAYMENTS, plugins = plugins %] |
| 70 |
|
70 |
|
| 71 |
|
|
|
| 72 |
</div> <!-- / #useraccount --> |
71 |
</div> <!-- / #useraccount --> |
| 73 |
</div> <!-- / .span10 --> |
72 |
</div> <!-- / .span10 --> |
| 74 |
</div> <!-- / .row-fluid --> |
73 |
</div> <!-- / .row-fluid --> |
|
Lines 82-95
Link Here
|
| 82 |
$( document ).ready(function() { |
81 |
$( document ).ready(function() { |
| 83 |
|
82 |
|
| 84 |
var MSG_MIN_THRESHOLD = _("Minimum amount needed by this service is %s"); |
83 |
var MSG_MIN_THRESHOLD = _("Minimum amount needed by this service is %s"); |
|
|
84 |
var txtActivefilter = _("Filter paid transactions"); |
| 85 |
var txtInactivefilter = _("Show all transactions"); |
| 85 |
|
86 |
|
| 86 |
$("#finestable").dataTable($.extend(true, {}, dataTablesDefaults, { |
87 |
var fines_table = $("#finestable").dataTable($.extend(true, {}, dataTablesDefaults, { |
| 87 |
"columnDefs": [ |
88 |
"columnDefs": [ |
| 88 |
{ "type": "title-string", "targets" : [ "title-string" ] } |
89 |
{ "type": "title-string", "targets" : [ "title-string" ] } |
| 89 |
], |
90 |
], |
| 90 |
"order": [[ 0, "desc" ]] |
91 |
[% IF ENABLE_OPAC_PAYMENTS %] |
|
|
92 |
"order": [[ 1, "desc" ]], |
| 93 |
[% ELSE %] |
| 94 |
"order": [[ 0, "desc" ]], |
| 95 |
[% END %] |
| 96 |
"dom": '<"#filter_p">', |
| 91 |
} )); |
97 |
} )); |
| 92 |
|
98 |
|
|
|
99 |
$("#filter_p").html('<p><a href="#" id="filter_paid"><i class="fa fa-filter"></i> '+txtActivefilter+'</a>'); |
| 100 |
$('#filter_paid').click(function(e) { |
| 101 |
e.preventDefault(); |
| 102 |
if ($(this).hasClass('filtered')) { |
| 103 |
var filteredValue = ''; |
| 104 |
$(this).html('<i class="fa fa-filter"></i> '+txtActivefilter); |
| 105 |
} else { //Not filtered. Let's do it! |
| 106 |
var filteredValue = '^((?!0.00).*)$'; //Filter not matching 0.00 http://stackoverflow.com/a/406408 |
| 107 |
$(this).html('<i class="fa fa-filter"></i> '+txtInactivefilter); |
| 108 |
} |
| 109 |
fines_table.fnFilter(filteredValue, -1, true, false); |
| 110 |
$(this).toggleClass('filtered'); |
| 111 |
}); |
| 112 |
|
| 113 |
//Start filtered |
| 114 |
$('#filter_paid').click(); |
| 115 |
|
| 93 |
$(".paypal").on("click", function() { |
116 |
$(".paypal").on("click", function() { |
| 94 |
window.open('https://www.paypal.com/webapps/mpp/paypal-popup','WIPaypal','toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=yes, resizable=yes, width=1060, height=700'); |
117 |
window.open('https://www.paypal.com/webapps/mpp/paypal-popup','WIPaypal','toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=yes, resizable=yes, width=1060, height=700'); |
| 95 |
return false; |
118 |
return false; |
| 96 |
- |
|
|