Search in sources :

Example 1 with OrganizationISOCategoryDAO

use of com.autentia.tnt.dao.hibernate.OrganizationISOCategoryDAO in project TNTConcept by autentia.

the class ContactPositionManagerTest method insertInitialData.

/**
 * Metodo encargado de insertar datos muy generales pero que son necesarios
 * en la gestion de contactos
 */
private void insertInitialData() {
    final ProvinceDAO provinceDAO = (ProvinceDAO) SpringUtilsForTesting.getSpringBean("daoProvince");
    final OrganizationISOCategoryDAO organizationISOCategoryDAO = (OrganizationISOCategoryDAO) SpringUtilsForTesting.getSpringBean("daoOrganizationISOCategory");
    final OrganizationTypeDAO organizationTypeDAO = (OrganizationTypeDAO) SpringUtilsForTesting.getSpringBean("daoOrganizationType");
    final OrganizationDAO organizationDAO = (OrganizationDAO) SpringUtilsForTesting.getSpringBean("daoOrganization");
    final DepartmentDAO departmentDAO = (DepartmentDAO) SpringUtilsForTesting.getSpringBean("daoDepartment");
    // provincia
    province.setName("Madrid");
    provinceDAO.insert(province);
    // categoria de la organizacion
    organizationType.setName("prospecto");
    organizationTypeDAO.insert(organizationType);
    // categoria ISO de la organizacion
    organizationISOCategory.setName("A");
    organizationISOCategoryDAO.insert(organizationISOCategory);
    // organizacion
    organization.setName("Tecnologías de España");
    organization.setProvince(province);
    organization.setType(organizationType);
    organization.setCategory(organizationISOCategory);
    organizationDAO.insert(organization);
    // departamento
    department.setName("comercial");
    department.setDescription("comercial");
    departmentDAO.insert(department);
}
Also used : OrganizationTypeDAO(com.autentia.tnt.dao.hibernate.OrganizationTypeDAO) OrganizationISOCategoryDAO(com.autentia.tnt.dao.hibernate.OrganizationISOCategoryDAO) ProvinceDAO(com.autentia.tnt.dao.hibernate.ProvinceDAO) DepartmentDAO(com.autentia.tnt.dao.hibernate.DepartmentDAO) OrganizationDAO(com.autentia.tnt.dao.hibernate.OrganizationDAO)

Aggregations

DepartmentDAO (com.autentia.tnt.dao.hibernate.DepartmentDAO)1 OrganizationDAO (com.autentia.tnt.dao.hibernate.OrganizationDAO)1 OrganizationISOCategoryDAO (com.autentia.tnt.dao.hibernate.OrganizationISOCategoryDAO)1 OrganizationTypeDAO (com.autentia.tnt.dao.hibernate.OrganizationTypeDAO)1 ProvinceDAO (com.autentia.tnt.dao.hibernate.ProvinceDAO)1