<form class="form-inline" role="form">
<div class="checkbox">
<label>
- <input id="receipt_on_pay" type="checkbox" ng-model="receipt_on_pay.isChecked"/>
+ <input id="receipt_on_pay" type="checkbox" ng-model="receipt_on_pay.isChecked" ng-change="onReceiptOnPayChanged()"/>
[% l('Receipt On Payment') %]
</label>
</div>
$scope.amount_verified = false;
$scope.disable_auto_print = false;
+ // check receipt_on_pay setting default persisted
+ egCore.hatch.getItem('circ.bills.receiptonpay')
+ .then(function(rcptOnPay){
+ if (rcptOnPay) $scope.receipt_on_pay.isChecked = rcptOnPay;
+ });
+
// pre-define list-returning funcs in case we access them
// before the grid instantiates
$scope.gridControls = {
})
}
+ $scope.onReceiptOnPayChanged = function(){
+ egCore.hatch.setItem('circ.bills.receiptonpay', $scope.receipt_on_pay.isChecked);
+ }
+
function printReceipt(type, payment_ids, payments_made, note) {
var payment_blobs = [];
angular.forEach(payments_made, function(payment) {