Examples of Descuento


Examples of org.salamanca.domain.Descuento

    private void loadDescuentosDisponibles() {
        modelDescuentosDisponibles.clear();
        Vector v = BrokerServer.instance().getAll(Descuento.class);
        Enumeration enumer = v.elements();
        while (enumer.hasMoreElements()) {
            Descuento descuento = (Descuento) enumer.nextElement();
            modelDescuentosDisponibles.addElement(descuento.getNombre());
        }

    }
View Full Code Here

Examples of org.salamanca.domain.Descuento

    private void loadDescuentosDelAlumno() {
        this.jLabelPersona.setText(persona.getNombre());
        modelDescuentosDelAlumno.clear();
        Iterator iter = persona.getSetDescuento().iterator();
        while (iter.hasNext()) {
            Descuento descuento = (Descuento) iter.next();
            modelDescuentosDelAlumno.addElement(descuento.getNombre());
        }

    }
View Full Code Here

Examples of org.salamanca.domain.Descuento

            String nombre = (String) jListDescuentosDisponibles.
                            getSelectedValue();
            Vector v = BrokerServer.instance().query(Descuento.class,
                    "nombre==\"" + nombre + "\"");
            if (v.size() > 0) {
                Descuento descuento = (Descuento) v.firstElement();
                ICommand agregarDescuentoAPersona = CommandFactory.
                        createAgregarDescuentoAPersona(
                                persona, descuento);
                try {
                    agregarDescuentoAPersona.execute();
View Full Code Here

Examples of org.salamanca.domain.Descuento

            String nombre = (Stringthis.jListDescuentosDelAlumno.
                            getSelectedValue();


            Descuento elDescuento=null;
                    Iterator iter =  persona.getSetDescuento().iterator();
                    while (iter.hasNext()) {
                        Descuento descuento = (Descuento) iter.next();
                        if(descuento.getNombre().equals(nombre) ){
                        elDescuento=descuento;
                        }
                    }
             if (elDescuento!=null) {
View Full Code Here

Examples of org.salamanca.domain.Descuento

                                getPersistenceManager();

        pm.currentTransaction().begin();
        Persona personaPM = (Persona) pm.getObjectById(javax.jdo.JDOHelper.
                getObjectId(persona), true);
        Descuento descuentoPM = (Descuento) pm.getObjectById(javax.jdo.JDOHelper.
                getObjectId(descuento), true);
        personaPM.removeDescuento(descuentoPM);
        pm.currentTransaction().commit();

    }
View Full Code Here

Examples of org.salamanca.domain.Descuento

                                getPersistenceManager();

        pm.currentTransaction().begin();
        Persona personaPM = (Persona) pm.getObjectById(javax.jdo.JDOHelper.
                getObjectId(persona), true);
        Descuento descuentoPM = (Descuento) pm.getObjectById(javax.jdo.JDOHelper.
                getObjectId(descuento), true);
        personaPM.addDescuento(descuentoPM);
        pm.currentTransaction().commit();

    }
View Full Code Here

Examples of org.salamanca.domain.Descuento

            Extent ext = BrokerServer.instance().getPMF().
                         getPersistenceManager().getExtent(Descuento.class, true);
            Vector v = new Vector();
            Iterator iter = ext.iterator();
            while (iter.hasNext()) {
                Descuento descuento = (Descuento) iter.next();
                v.add(descuento);
            }
//cargo todos los descuentos
            if ((v != null) && (v.size() > 0)) {
                Object[][] trabajo = new Object[v.size()][5];
                for (int i = 0; i < v.size(); i++) {
                    Descuento descuento = (Descuento) v.elementAt(i);
                    trabajo[i][0] = descuento.getNombre();
                    trabajo[i][1] = new Double(0);
                    trabajo[i][2] = new Double(0);
                    if (descuento instanceof DescuentoSumaFija) {
                        trabajo[i][1] = new Double(((DescuentoSumaFija)
                                descuento).getSumaFija());
View Full Code Here

Examples of org.salamanca.domain.Descuento

    public void compomenteABMCListDescuentos_Eliminacion(EliminarEvent e) {
        String oidStr = ((String) ((Vector) e.getVector()).elementAt(3));
        kodo.util.Id oid = new kodo.util.Id(oidStr);

        Descuento descuento = (Descuento) BrokerServer.instance().getPMF().
                              getPersistenceManager().getObjectById(oid, true);

        if (descuento instanceof DescuentoSumaFija) {
            ICommand eliminarDescuentoSumaFija = CommandFactory.
                                                 createEliminarDescuentoSumaFija((
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.