Examples of IExternalCompanyDAO


Examples of org.libreplan.business.externalcompanies.daos.IExternalCompanyDAO

        return ourCompanyPassword;
    }

    @AssertTrue(message="company name must be unique. Company name already used")
    public boolean isUniqueNameConstraint() {
        IExternalCompanyDAO dao = Registry.getExternalCompanyDAO();

        if (isNewObject()) {
            return !dao.existsByNameInAnotherTransaction(name);
        } else {
            try {
                ExternalCompany company =
                    dao.findUniqueByNameInAnotherTransaction(name);
                return company.getId().equals(getId());
            } catch (InstanceNotFoundException e) {
                return true;
            }
        }
View Full Code Here

Examples of org.libreplan.business.externalcompanies.daos.IExternalCompanyDAO

        }
    }

    @AssertTrue(message="Company ID already used. It must be unique")
    public boolean isUniqueNifConstraint() {
        IExternalCompanyDAO dao = Registry.getExternalCompanyDAO();

        if (isNewObject()) {
            return !dao.existsByNifInAnotherTransaction(nif);
        } else {
            try {
                ExternalCompany company =
                    dao.findUniqueByNifInAnotherTransaction(nif);
                return company.getId().equals(getId());
            } catch (InstanceNotFoundException e) {
                return true;
            }
        }
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.