Package nextapp.echo2.app.event

Examples of nextapp.echo2.app.event.ActionListener


    public LblTblJbsBaseObject(String text, JbsBaseObject jbsBaseObject, Table table) {
        super(text);
        this.setJbsBaseObject(jbsBaseObject);
        this.setTable(table);
        this.getBtnMain().addActionListener(new ActionListener() {

            public void actionPerformed(ActionEvent arg0) {
                setSelectedJbsBaseObject();
            }
        });
View Full Code Here


    @Override
    public void newJbsObject() {
        //Ask for the contact-type to create the correct one:
        final FmSelectContactType fmContactType = new FmSelectContactType(JbsL10N.getString("Contact.selContactTypeMsg"),this.getInitialContactType());
        fmContactType.addActionListener(new ActionListener() {

            public void actionPerformed(ActionEvent arg0) {
                if (arg0.getActionCommand().equals(JbsDialogWindowOKCancel.ACTION_OK)) {
                    newContact(fmContactType.getSelectedContactType());
                }
View Full Code Here

    }
   
    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);
            }
View Full Code Here

    }
   
    protected void addPayment() {
        fmPaymentEdit = new FmPaymentEdit();
        fmPaymentEdit.showForm();
        fmPaymentEdit.addActionListener(new ActionListener() {

            public void actionPerformed(ActionEvent arg0) {
                logger.debug("Payment edited.");
                Payment payment = fmPaymentEdit.getPayment();
                payment.setCompany(ClientGlobals.getCompany());
View Full Code Here

        if (payment!=null) {
            logger.debug("Editing payment "+payment.getId());

            FmPaymentEdit fmPaymentEdit = new FmPaymentEdit();
            fmPaymentEdit.showForm(DlgState.dsEdit,payment);
            fmPaymentEdit.addActionListener(new ActionListener() {

                public void actionPerformed(ActionEvent arg0) {
                    logger.debug("Payment edited.");
                    reload();
                }
View Full Code Here

    private static final long serialVersionUID = -8714588054989331071L;

    public FmInvoiceEdit() {
        super(JbsL10N.getString("Invoice.formTitle"));
        PnInvoiceEdit pnInvoiceEdit = new PnInvoiceEdit();
        pnInvoiceEdit.addActionListener(new ActionListener() {

            public void actionPerformed(ActionEvent arg0) {
                if (arg0.getActionCommand().equals(PnInvoiceEdit.ACTION_TOCREDITNOTE)) {
                    cancelDialog();
                }
View Full Code Here

    }
   
    protected void deletePayment(final Payment payment) {
        if (payment!=null) {
            JbsOptionPane confirmDialog = JbsOptionPane.showConfirmDialog(this, JbsL10N.getString("Payment.deleteQuery"), JbsL10N.getString("Payment.deleteQueryTitle"), JbsOptionPane.YES_NO_OPTION);
            confirmDialog.addActionListener(new ActionListener() {

                public void actionPerformed(ActionEvent arg0) {
                    if (arg0.getActionCommand() == JbsOptionPane.YES_OPTION) {
                        if (logger.isDebugEnabled()) {
                            logger.debug("Deleting payment "+payment.getId());
View Full Code Here

        //this.setDefaultHeaderRenderer(new HrTblJbsBaseObject());
        this.setTblMJbsBaseObject(tblMJbsBaseObject);
        this.setSelectedJbsBaseObject(null);
        setStyleName("TblJbsBaseObject.Main");
       
        this.addActionListener(new ActionListener() {

            public void actionPerformed(ActionEvent arg0) {
                fireRowSelection();
            }
        });
View Full Code Here

    Logger logger = Logger.getLogger(JbsSupplierSelectField.class);

    public JbsSupplierSelectField() {
        this.getTextField().setEnabled(false);
        this.setSelectedListener(null);
        this.getBtnSelect().addActionListener(new ActionListener() {

            private static final long serialVersionUID = 1L;

            public void actionPerformed(ActionEvent arg0) {
                selectSupplier();
View Full Code Here

    protected void selectSupplier() {
        fmSelectSupplier = new FmJbsBaseObjectList(JbsL10N.getString("Supplier.selectSupplier"));
        fmSelectSupplier.setPnList(new PnSupplierList());
        fmSelectSupplier.showForm();
        fmSelectSupplier.addActionListener(new ActionListener() {

            private static final long serialVersionUID = 1L;

            public void actionPerformed(ActionEvent arg0) {
                if (arg0.getActionCommand().equals(JbsDialogWindowOKCancel.ACTION_OK)) {
View Full Code Here

TOP

Related Classes of nextapp.echo2.app.event.ActionListener

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.