Package bo

Examples of bo.Beneficiar


        List<Integer> idBeneficiari = geologBeneficiarDao.getGeologBeneficiariByGeologId(idGeolog);
        IBeneficiarDao beneficiarDao = new BeneficiarDao();
        Iterator it = idBeneficiari.iterator();
        while (it.hasNext()) {
            Integer idBeneficiar = (Integer) it.next();
            Beneficiar beneficiar = beneficiarDao.getBeneficiarByID(idBeneficiar);
            beneficiari.add(beneficiar);
        }
        if (getIdBeneficiarCurent() == 0) {
            setIdBeneficiarCurent(
                    beneficiari.get(0).getIdBeneficiar());
View Full Code Here


                return new ForwardResolution("/WEB-INF/jsp/adaugaBeneficiar.jsp");
            } else if (!isNumeric(cnp)) {
                setCnpIncorect(true);
                return new ForwardResolution("/WEB-INF/jsp/adaugaBeneficiar.jsp");
            }
            Beneficiar beneficiar = new Beneficiar(nume, cnp, mentiuni, null);
            beneficiarDao.saveOrUpdate(beneficiar);
            Beneficiar bAux = beneficiarDao.getBeneficiarCnp(cnp);
            int idGeolog = getIdGeologLogat();
            IGeologBeneficiarDao geologBeneficiarDao = new GeologBeneficiarDao();
            geologBeneficiarDao.saveOrUpdate(new GeologBeneficiar(idGeolog, bAux.getIdBeneficiar()));
            setBeneficiarAdaugat(true);
            return new ForwardResolution("/WEB-INF/jsp/adaugaBeneficiar.jsp");
        } //daca cream un proiect
        else if (proiect == 1) {
            if (getBtnRadio() == null) {
                setRadioNeselectat(true);
                return new ForwardResolution("/WEB-INF/jsp/adaugaBeneficiar.jsp");
            } else if (getBtnRadio().equals("1")) {
                Beneficiar beneficiarSelectat = beneficiarDao.getBeneficiarByID(Integer.parseInt(getSelectBeneficiarFilter()));
                IGeologBeneficiarDao geologBeneficiarDao = new GeologBeneficiarDao();
                int idGeolog = getIdGeologLogat();
                geologBeneficiarDao.saveOrUpdate(new GeologBeneficiar(idGeolog, beneficiarSelectat.getIdBeneficiar()));
                getContext().getRequest().getSession(true).setAttribute("beneficiarProiect", beneficiarSelectat);
                return new ForwardResolution("/WEB-INF/jsp/proiect.jsp");
            } else if (getBtnRadio().equals("2")) {
                if ((getNume() == null) || (getCnp() == null)) {
                    setCampuriNecompletate(true);
                    return new ForwardResolution("/WEB-INF/jsp/adaugaBeneficiar.jsp");
                }
                if (cnp.length() != 13) {
                    setCnpIncorect(true);
                    return new ForwardResolution("/WEB-INF/jsp/adaugaBeneficiar.jsp");
                } else if (!isNumeric(cnp)) {
                    setCnpIncorect(true);
                    return new ForwardResolution("/WEB-INF/jsp/adaugaBeneficiar.jsp");
                }
                Beneficiar beneficiar = new Beneficiar(nume, cnp, mentiuni, null);
                beneficiarDao.saveOrUpdate(beneficiar);
                Beneficiar bAux = beneficiarDao.getBeneficiarCnp(cnp);
                int idGeolog = getIdGeologLogat();
                IGeologBeneficiarDao geologBeneficiarDao = new GeologBeneficiarDao();
                geologBeneficiarDao.saveOrUpdate(new GeologBeneficiar(idGeolog, bAux.getIdBeneficiar()));
                getContext().getRequest().getSession(true).setAttribute("beneficiarProiect", bAux);
                return new ForwardResolution("/WEB-INF/jsp/proiect.jsp");
            }

View Full Code Here

        }
        return new ForwardResolution("/WEB-INF/jsp/adaugaBeneficiar.jsp");
    }

    public Resolution editare() {
        Beneficiar beneficiar = new Beneficiar();
        IBeneficiarDao beneficiarDao = new BeneficiarDao();
        beneficiar.setIdBeneficiar(Integer.parseInt(getBeneficiarFilter()));
        beneficiar.setCuiBeneficiar(getCnpEditare());
        beneficiar.setMentiuniBeneficiar(getMentiuniEditare());
        String numeB = beneficiarDao.getBeneficiarByID(Integer.parseInt(getBeneficiarFilter())).getNumeBeneficiar();
        beneficiar.setNumeBeneficiar(numeB);
        beneficiarDao.saveOrUpdate(beneficiar);
        setBeneficiarEditat(true);
        return new ForwardResolution("/WEB-INF/jsp/editareBeneficiar.jsp");
    }
View Full Code Here

        List<Integer> idBeneficiari = geologBeneficiarDao.getGeologBeneficiariByGeologId(idGeolog);
        IBeneficiarDao beneficiarDao = new BeneficiarDao();
        Iterator it = idBeneficiari.iterator();
        while (it.hasNext()) {
            Integer idBeneficiar = (Integer) it.next();
            Beneficiar beneficiar = beneficiarDao.getBeneficiarByID(idBeneficiar);
            beneficiari.add(beneficiar);
        }

        return beneficiari;
    }
View Full Code Here

    public String getMentiuniBeneficiar() {
        if (getBeneficiarFilter() == null) {
            return "";
        } else {
            IBeneficiarDao beneficiarDao = new BeneficiarDao();
            Beneficiar beneficiar = beneficiarDao.getBeneficiarByID(Integer.parseInt(getBeneficiarFilter()));
            return beneficiar.getMentiuniBeneficiar();
        }
    }
View Full Code Here

    public String getCnpBeneficiar() {
        if (getBeneficiarFilter() == null) {
            return "";
        } else {
            IBeneficiarDao beneficiarDao = new BeneficiarDao();
            Beneficiar beneficiar = beneficiarDao.getBeneficiarByID(Integer.parseInt(getBeneficiarFilter()));
            return beneficiar.getCuiBeneficiar();
        }
    }
View Full Code Here

        return new ForwardResolution("/WEB-INF/jsp/adaugaAmplasament.jsp");
    }

    public Resolution adauga() {
        IBeneficiarDao beneficiarDao = new BeneficiarDao();
        Beneficiar beneficiar = beneficiarDao.getBeneficiarByID(Integer.parseInt(getBeneficiarFilter()));
        IOrasDao orasDao = new OrasDao();
        Oras oras = orasDao.getOrasByID(Integer.parseInt(getOrasFilter()));
        Amplasament amplasament = new Amplasament();
        amplasament.setBeneficiar(beneficiar);
        amplasament.setOras(oras);
View Full Code Here

        List<Integer> idBeneficiari = geologBeneficiarDao.getGeologBeneficiariByGeologId(idGeolog);
        IBeneficiarDao beneficiarDao = new BeneficiarDao();
        Iterator it = idBeneficiari.iterator();
        while (it.hasNext()) {
            Integer idBeneficiar = (Integer) it.next();
            Beneficiar beneficiar = beneficiarDao.getBeneficiarByID(idBeneficiar);
            beneficiari.add(beneficiar);
        }
        return beneficiari;
    }
View Full Code Here

    }

    public Resolution adauga() {
        //adaugam beneficiarul si la subgeologul corespunzator
        IGeologBeneficiarDao geologBeneficiarDao = new GeologBeneficiarDao();
        Beneficiar beneficiar = (Beneficiar) getContext().getRequest().getSession().getAttribute("beneficiarProiect");
        int idBeneficiar = beneficiar.getIdBeneficiar();
        int idGeolog = Integer.parseInt(getGeologFilter());
        geologBeneficiarDao.saveOrUpdate(new GeologBeneficiar(idGeolog, idBeneficiar));

        //adaugam amplasamentul
        int idProiect = ((Proiect) getContext().getRequest().getSession().getAttribute("proiectInLucru")).getIdProiect();
View Full Code Here

            IGeologBeneficiarDao geologBeneficiarDao = new GeologBeneficiarDao();
            List<Integer> idBeneficiari = geologBeneficiarDao.getGeologBeneficiariByGeologId(idGeolog);
            Iterator it = idBeneficiari.iterator();
            while (it.hasNext()) {
                Integer idBeneficiar = (Integer) it.next();
                Beneficiar beneficiar = beneficiarDao.getBeneficiarByID(idBeneficiar);
                beneficiari.add(beneficiar);
            }
        } else {
            beneficiari = getBeneficiariPublici();
            getContext().getRequest().getSession(true).setAttribute("geologiPublici", beneficiari);
View Full Code Here

TOP

Related Classes of bo.Beneficiar

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.