return {
payment : owedSelected,
change : amt - owedSelected
- }
+ };
}
return {payment : amt, change : 0};
// Reset...
this.entries.forEach(row => row.paymentPending = 0);
- var amount = this.pendingPayment();
+ let amount = this.pendingPayment();
let done = false;
this.billGrid.context.rowSelector.selected().forEach(index => {
payments.forEach(payment => {
const entry =
- this.entries.filter(entry => entry.xact.id() === payment[0])[0];
+ this.entries.filter(e => e.xact.id() === payment[0])[0];
context.payments.push({
amount: payment[1],
return this.pcrud.search('mb', {xact: xactId}, {}, {authoritative: true})
.pipe(tap(billing => {
if (billing.voided() === 'f') {
- cents += billing.amount() * 100
+ cents += billing.amount() * 100;
billIds.push(billing.id());
}
}));
import {CircService, CircDisplayInfo} from '@eg/staff/share/circ/circ.service';
export interface BillGridEntry extends CircDisplayInfo {
- xact: IdlObject // mbt
+ xact: IdlObject; // mbt
billingLocation?: string;
paymentPending?: number;
}
const oneSurvey: any = {responses: []};
Object.keys(collection[sid]).forEach(qid => {
oneSurvey.survey = collection[sid][qid].survey();
- oneSurvey.responses.push(collection[sid][qid])
+ oneSurvey.responses.push(collection[sid][qid]);
});
this.surveys.push(oneSurvey);
});
let xactId;
promise.then(id => {
xactId = id;
- return this.createBill(id)
+ return this.createBill(id);
})
.then(billId => this.close({xactId: xactId, billId: billId}));
}
import {AudioService} from '@eg/share/util/audio.service';
export interface CreditCardPaymentParams {
- where_process?: 0 | 1,
- approval_code?: string,
- expire_month?: number,
- expire_year?: number,
- billing_first?: string,
- billing_last?: string,
- billing_address?: string,
- billing_city?: string,
- billing_state?: string,
- billing_zip?: string,
- note?: string
+ where_process?: 0 | 1;
+ approval_code?: string;
+ expire_month?: number;
+ expire_year?: number;
+ billing_first?: string;
+ billing_last?: string;
+ billing_address?: string;
+ billing_city?: string;
+ billing_state?: string;
+ billing_zip?: string;
+ note?: string;
}
@Injectable()
this.supportsExternal = true;
this.args.where_process = 1;
}
- })
+ });
});
}