}
}
protected void initToolbar() {
tbMain = new JbsToolbar();
btnAddPayment = new BtnToolbar("add.png");
btnAddPayment.addActionListener(new ActionListener() {
public void actionPerformed(ActionEvent arg0) {
logger.debug("Adding payment");
addPayment();
/*
Payment payment = new Payment();
payment.setAmount(new Double(10.0));
payment.setCompany(ClientGlobals.getCompany());
payment.setOwner(ClientGlobals.getUser());
payment.setGroup(ClientGlobals.getUser().getMainGroup());
payment.setTransaction(getPnTransactionEdit().getTransaction());
payment.setPaymentDate(Calendar.getInstance());
getInvoice().getPayments().add(payment);
tblPayments.reload(getInvoice().getPayments());
*/
}
});
tbMain.addButton(btnAddPayment);
btnEditPayment = new BtnToolbar("edit.png");
btnEditPayment.addActionListener(new ActionListener() {
public void actionPerformed(ActionEvent arg0) {
//Payment payment = tblPayments.getSelectedPayment();
Payment payment = getSelectedPayment();
editPayment(payment);
}
});
tbMain.add(btnEditPayment);
btnDeletePayment = new BtnToolbar("remove.png");
btnDeletePayment.addActionListener(new ActionListener() {
public void actionPerformed(ActionEvent arg0) {
Payment payment = getSelectedPayment();
deletePayment(payment);