Java 类ims.core.vo.domain.LocSiteLiteVoAssembler 实例源码

项目:AvoinApotti    文件:ImagingEventsImpl.java   
/**
    * list Location Site
    */
    public ims.core.vo.LocSiteLiteVoCollection listLocSite(String locationName)
    {
        String location = locationName != null ? locationName.toUpperCase() + "%" : "%%";

        StringBuffer hql = new StringBuffer();
        hql.append(" from LocSite as ls");
        hql.append(" where");
        hql.append(" ls.upperName like :locationName");
        hql.append(" and ls.isActive =:active");
        hql.append(" and ls.isRIE is null");
        hql.append(" and ls.isVirtual =:virtual");//wdev-2730
        hql.append(" and ls.type.id != " + LocationType.SURGERY.getID());

        List list = getDomainFactory().find(hql.toString(), new String[]{"locationName", "active", "virtual"}, new Object[]{location, Boolean.TRUE, Boolean.FALSE});

        return LocSiteLiteVoAssembler.createLocSiteLiteVoCollectionFromLocSite(list);

//      OrganisationAndLocation orgLocImpl = (OrganisationAndLocation) getDomainImpl(OrganisationAndLocationImpl.class);
//      return orgLocImpl.listLocSite(locationName);
    }
项目:AvoinApotti    文件:BatchPrintingImpl.java   
public LocSiteLiteVoCollection listHospitals(String name) 
{
    ArrayList<String> markers = new ArrayList<String>();
    ArrayList<Object> values = new ArrayList<Object>();

    String hql = "select ls from LocSite as ls left join ls.codeMappings as t left join t.taxonomyName as tn where tn =:taxonomyType and ls.isActive = 1 and ls.type !=:SurgeryType and ls.isRIE is null and ls.isVirtual = 0";
    markers.add("SurgeryType");
    values.add(getDomLookup(LocationType.SURGERY));
    markers.add("taxonomyType");
    values.add(getDomLookup(TaxonomyType.PATH));

    if(name != null)
    {
        hql += " and ls.upperName like :locationName";
        markers.add("locationName");
        values.add(name.toUpperCase() + "%");
    }

    List list = getDomainFactory().find(hql, markers, values);

    return LocSiteLiteVoAssembler.createLocSiteLiteVoCollectionFromLocSite(list);
}
项目:AvoinApotti    文件:OrganisationAndLocationImpl.java   
public LocSiteLiteVoCollection listLocSite(String locationName)
{
    String location = locationName != null ? locationName.toUpperCase() + "%" : "%%";

    StringBuffer hql = new StringBuffer();
    hql.append(" from LocSite as ls");
    hql.append(" where");
    hql.append(" ls.upperName like :locationName");
    hql.append(" and ls.isActive =:active");
    hql.append(" and ls.isRIE is null");
    hql.append(" and ls.isVirtual =:virtual");//wdev-2730

    List list = getDomainFactory().find(hql.toString(), new String[]{"locationName", "active", "virtual"}, new Object[]{location, Boolean.TRUE, Boolean.FALSE});

    return LocSiteLiteVoAssembler.createLocSiteLiteVoCollectionFromLocSite(list);
}
项目:AvoinApotti    文件:LocationStartupSelectionImpl.java   
public LocSiteLiteVoCollection listLocationSites(ims.core.resource.place.vo.OrganisationRefVo organization)
{           
    Organisation doOrganisation = (Organisation) getDomainFactory().getDomainObject(organization);
    LocSiteLiteVoCollection result = LocSiteLiteVoAssembler.createLocSiteLiteVoCollectionFromLocSite(doOrganisation.getLocationSites());

    if(result == null)
        return null;

    LocSiteLiteVoCollection activeLocationSites = new LocSiteLiteVoCollection();

    for(int x = 0; x < result.size(); x++)
    {
        LocSiteLiteVo locationSite = result.get(x);
        if(locationSite != null 
            && locationSite.getIsActive() != null && locationSite.getIsActive().booleanValue()
            && locationSite.getIsVirtualIsNotNull() && ! locationSite.getIsVirtual().booleanValue())//wdev-2730
            activeLocationSites.add(locationSite);
    }

    return activeLocationSites.sort();
}
项目:AvoinApotti    文件:DementiaWorklistImpl.java   
public ims.core.vo.LocSiteLiteVoCollection listHospitals()
{
    DomainFactory factory = getDomainFactory();

    ArrayList<String> markers = new ArrayList<String>();
    ArrayList<Object> values = new ArrayList<Object>();

    StringBuffer hql = new StringBuffer();

    hql.append(" select hosp from LocSite as hosp left join hosp.type as hosptype");
    hql.append(" where hosp.isActive = 1 and hosp.isVirtual = 0 and hosptype.id=:HospType");
    hql.append(" order by UPPER(hosp.name) asc");

    markers.add("HospType");
    values.add(LocationType.HOSP.getID());

    return LocSiteLiteVoAssembler.createLocSiteLiteVoCollectionFromLocSite(factory.find(hql.toString(), markers, values));
}
项目:AvoinApotti    文件:VTERiskAssessmentWorklistImpl.java   
public ims.core.vo.LocSiteLiteVoCollection listHospitals()
{
    DomainFactory factory = getDomainFactory();

    ArrayList<String> markers = new ArrayList<String>();
    ArrayList<Object> values = new ArrayList<Object>();

    StringBuffer hql = new StringBuffer();

    hql.append(" select hosp from LocSite as hosp left join hosp.type as hosptype");
    hql.append(" where hosp.isActive = 1 and hosp.isVirtual = 0 and hosptype.id=:HospType");
    hql.append(" order by UPPER(hosp.name) asc");

    markers.add("HospType");
    values.add(LocationType.HOSP.getID());

    return LocSiteLiteVoAssembler.createLocSiteLiteVoCollectionFromLocSite(factory.find(hql.toString(), markers, values));
}
项目:openMAXIMS    文件:ImagingEventsImpl.java   
/**
    * list Location Site
    */
    public ims.core.vo.LocSiteLiteVoCollection listLocSite(String locationName)
    {
        String location = locationName != null ? locationName.toUpperCase() + "%" : "%%";

        StringBuffer hql = new StringBuffer();
        hql.append(" from LocSite as ls");
        hql.append(" where");
        hql.append(" ls.upperName like :locationName");
        hql.append(" and ls.isActive =:active");
        hql.append(" and ls.isRIE is null");
        hql.append(" and ls.isVirtual =:virtual");//wdev-2730
        hql.append(" and ls.type.id != " + LocationType.SURGERY.getID());

        List list = getDomainFactory().find(hql.toString(), new String[]{"locationName", "active", "virtual"}, new Object[]{location, Boolean.TRUE, Boolean.FALSE});

        return LocSiteLiteVoAssembler.createLocSiteLiteVoCollectionFromLocSite(list);

//      OrganisationAndLocation orgLocImpl = (OrganisationAndLocation) getDomainImpl(OrganisationAndLocationImpl.class);
//      return orgLocImpl.listLocSite(locationName);
    }
项目:openMAXIMS    文件:BatchPrintingImpl.java   
public LocSiteLiteVoCollection listHospitals(String name) 
{
    ArrayList<String> markers = new ArrayList<String>();
    ArrayList<Object> values = new ArrayList<Object>();

    String hql = "select ls from LocSite as ls left join ls.codeMappings as t left join t.taxonomyName as tn where tn =:taxonomyType and ls.isActive = 1 and ls.type !=:SurgeryType and ls.isRIE is null and ls.isVirtual = 0";
    markers.add("SurgeryType");
    values.add(getDomLookup(LocationType.SURGERY));
    markers.add("taxonomyType");
    values.add(getDomLookup(TaxonomyType.PATH));

    if(name != null)
    {
        hql += " and ls.upperName like :locationName";
        markers.add("locationName");
        values.add(name.toUpperCase() + "%");
    }

    List list = getDomainFactory().find(hql, markers, values);

    return LocSiteLiteVoAssembler.createLocSiteLiteVoCollectionFromLocSite(list);
}
项目:openMAXIMS    文件:WaitingListConfigurationImpl.java   
public LocSiteLiteVoCollection listHospitals(String name) //WDEV-20064
{
    DomainFactory factory = getDomainFactory();

    ArrayList<String> markers = new ArrayList<String>();
    ArrayList<Object> values = new ArrayList<Object>();

    StringBuffer hql = new StringBuffer();

    hql.append(" select loc from LocSite as loc ");//WDEV-20064
    hql.append(" where loc.upperName like :LocName and loc.isActive = 1 and loc.isVirtual = 0 and loc.type = :Hospital ");
    hql.append(" order by loc.upperName asc");

    markers.add("LocName");
    values.add(name.toUpperCase()+"%");

    markers.add("Hospital");
    values.add(getDomLookup(LocationType.HOSP));

    return LocSiteLiteVoAssembler.createLocSiteLiteVoCollectionFromLocSite(factory.find(hql.toString(), markers, values));
}
项目:openMAXIMS    文件:OrganisationAndLocationImpl.java   
public LocSiteLiteVoCollection listLocSite(String locationName)
{
    String location = locationName != null ? locationName.toUpperCase() + "%" : "%%";

    StringBuffer hql = new StringBuffer();
    hql.append(" from LocSite as ls");
    hql.append(" where");
    hql.append(" ls.upperName like :locationName");
    hql.append(" and ls.isActive =:active");
    hql.append(" and ls.isRIE is null");
    hql.append(" and ls.isVirtual =:virtual");//wdev-2730

    List list = getDomainFactory().find(hql.toString(), new String[]{"locationName", "active", "virtual"}, new Object[]{location, Boolean.TRUE, Boolean.FALSE});

    return LocSiteLiteVoAssembler.createLocSiteLiteVoCollectionFromLocSite(list);
}
项目:openMAXIMS    文件:LocationStartupSelectionImpl.java   
public LocSiteLiteVoCollection listLocationSites(ims.core.resource.place.vo.OrganisationRefVo organization)
{           
    Organisation doOrganisation = (Organisation) getDomainFactory().getDomainObject(organization);
    LocSiteLiteVoCollection result = LocSiteLiteVoAssembler.createLocSiteLiteVoCollectionFromLocSite(doOrganisation.getLocationSites());

    if(result == null)
        return null;

    LocSiteLiteVoCollection activeLocationSites = new LocSiteLiteVoCollection();

    for(int x = 0; x < result.size(); x++)
    {
        LocSiteLiteVo locationSite = result.get(x);
        if(locationSite != null 
            && locationSite.getIsActive() != null && locationSite.getIsActive().booleanValue()
            && locationSite.getIsVirtualIsNotNull() && ! locationSite.getIsVirtual().booleanValue())//wdev-2730
            activeLocationSites.add(locationSite);
    }

    return activeLocationSites.sort();
}
项目:openMAXIMS    文件:ClientAddressImpl.java   
public LocSiteLiteVoCollection listCCAs(OrgLiteVo lho)
{
    if (!lho.getID_OrganisationIsNotNull())
        return null;

    // WDEV-12550 - Added condition and parameters to filter only locations records of type CCA 
    StringBuffer hql = new StringBuffer();
    hql.append(" from LocSite as ls");
    hql.append(" where");
    hql.append(" ls.isActive =:active");
    hql.append(" and ls.isRIE is null");
    hql.append(" and ls.isVirtual =:virtual");
    hql.append(" and ls.type.id = :CCA");
    hql.append(" and ls.parentOrganisation.id =:lhoId order by ls.name asc");

    return LocSiteLiteVoAssembler.createLocSiteLiteVoCollectionFromLocSite(getDomainFactory().find(hql.toString(), new String[] { "active", "virtual", "CCA", "lhoId" }, new Object[] { Boolean.TRUE, Boolean.FALSE, LocationType.CCA.getID(), lho.getID_Organisation() }));
}
项目:openMAXIMS    文件:DementiaWorklistImpl.java   
public ims.core.vo.LocSiteLiteVoCollection listHospitals()
{
    DomainFactory factory = getDomainFactory();

    ArrayList<String> markers = new ArrayList<String>();
    ArrayList<Object> values = new ArrayList<Object>();

    StringBuffer hql = new StringBuffer();

    hql.append(" select hosp from LocSite as hosp left join hosp.type as hosptype");
    hql.append(" where hosp.isActive = 1 and hosp.isVirtual = 0 and hosptype.id=:HospType");
    hql.append(" order by hosp.upperName asc"); //WDEV-20219 UPPER(hosp.name)

    markers.add("HospType");
    values.add(LocationType.HOSP.getID());

    return LocSiteLiteVoAssembler.createLocSiteLiteVoCollectionFromLocSite(factory.find(hql.toString(), markers, values));
}
项目:openMAXIMS    文件:VTERiskAssessmentWorklistImpl.java   
public ims.core.vo.LocSiteLiteVoCollection listHospitals()
{
    DomainFactory factory = getDomainFactory();

    ArrayList<String> markers = new ArrayList<String>();
    ArrayList<Object> values = new ArrayList<Object>();

    StringBuffer hql = new StringBuffer();

    hql.append(" select hosp from LocSite as hosp left join hosp.type as hosptype");
    hql.append(" where hosp.isActive = 1 and hosp.isVirtual = 0 and hosptype.id=:HospType");
    hql.append(" order by hosp.upperName asc"); //WDEV-20219 UPPER(hosp.name)

    markers.add("HospType");
    values.add(LocationType.HOSP.getID());

    return LocSiteLiteVoAssembler.createLocSiteLiteVoCollectionFromLocSite(factory.find(hql.toString(), markers, values));
}
项目:openMAXIMS    文件:ImagingEventsImpl.java   
/**
    * list Location Site
    */
    public ims.core.vo.LocSiteLiteVoCollection listLocSite(String locationName)
    {
        String location = locationName != null ? locationName.toUpperCase() + "%" : "%%";

        StringBuffer hql = new StringBuffer();
        hql.append(" from LocSite as ls");
        hql.append(" where");
        hql.append(" ls.upperName like :locationName");
        hql.append(" and ls.isActive =:active");
        hql.append(" and ls.isRIE is null");
        hql.append(" and ls.isVirtual =:virtual");//wdev-2730
        hql.append(" and ls.type.id != " + LocationType.SURGERY.getID());

        List list = getDomainFactory().find(hql.toString(), new String[]{"locationName", "active", "virtual"}, new Object[]{location, Boolean.TRUE, Boolean.FALSE});

        return LocSiteLiteVoAssembler.createLocSiteLiteVoCollectionFromLocSite(list);

//      OrganisationAndLocation orgLocImpl = (OrganisationAndLocation) getDomainImpl(OrganisationAndLocationImpl.class);
//      return orgLocImpl.listLocSite(locationName);
    }
项目:openMAXIMS    文件:BatchPrintingImpl.java   
public LocSiteLiteVoCollection listHospitals(String name) 
{
    ArrayList<String> markers = new ArrayList<String>();
    ArrayList<Object> values = new ArrayList<Object>();

    String hql = "select ls from LocSite as ls left join ls.codeMappings as t left join t.taxonomyName as tn where tn =:taxonomyType and ls.isActive = 1 and ls.type !=:SurgeryType and ls.isRIE is null and ls.isVirtual = 0";
    markers.add("SurgeryType");
    values.add(getDomLookup(LocationType.SURGERY));
    markers.add("taxonomyType");
    values.add(getDomLookup(TaxonomyType.PATH));

    if(name != null)
    {
        hql += " and ls.upperName like :locationName";
        markers.add("locationName");
        values.add(name.toUpperCase() + "%");
    }

    List list = getDomainFactory().find(hql, markers, values);

    return LocSiteLiteVoAssembler.createLocSiteLiteVoCollectionFromLocSite(list);
}
项目:openMAXIMS    文件:OrganisationAndLocationImpl.java   
public LocSiteLiteVoCollection listLocSite(String locationName)
{
    String location = locationName != null ? locationName.toUpperCase() + "%" : "%%";

    StringBuffer hql = new StringBuffer();
    hql.append(" from LocSite as ls");
    hql.append(" where");
    hql.append(" ls.upperName like :locationName");
    hql.append(" and ls.isActive =:active");
    hql.append(" and ls.isRIE is null");
    hql.append(" and ls.isVirtual =:virtual");//wdev-2730

    List list = getDomainFactory().find(hql.toString(), new String[]{"locationName", "active", "virtual"}, new Object[]{location, Boolean.TRUE, Boolean.FALSE});

    return LocSiteLiteVoAssembler.createLocSiteLiteVoCollectionFromLocSite(list);
}
项目:openMAXIMS    文件:LocationStartupSelectionImpl.java   
public LocSiteLiteVoCollection listLocationSites(ims.core.resource.place.vo.OrganisationRefVo organization)
{           
    Organisation doOrganisation = (Organisation) getDomainFactory().getDomainObject(organization);
    LocSiteLiteVoCollection result = LocSiteLiteVoAssembler.createLocSiteLiteVoCollectionFromLocSite(doOrganisation.getLocationSites());

    if(result == null)
        return null;

    LocSiteLiteVoCollection activeLocationSites = new LocSiteLiteVoCollection();

    for(int x = 0; x < result.size(); x++)
    {
        LocSiteLiteVo locationSite = result.get(x);
        if(locationSite != null 
            && locationSite.getIsActive() != null && locationSite.getIsActive().booleanValue()
            && locationSite.getIsVirtualIsNotNull() && ! locationSite.getIsVirtual().booleanValue())//wdev-2730
            activeLocationSites.add(locationSite);
    }

    return activeLocationSites.sort();
}
项目:openMAXIMS    文件:DementiaWorklistImpl.java   
public ims.core.vo.LocSiteLiteVoCollection listHospitals()
{
    DomainFactory factory = getDomainFactory();

    ArrayList<String> markers = new ArrayList<String>();
    ArrayList<Object> values = new ArrayList<Object>();

    StringBuffer hql = new StringBuffer();

    hql.append(" select hosp from LocSite as hosp left join hosp.type as hosptype");
    hql.append(" where hosp.isActive = 1 and hosp.isVirtual = 0 and hosptype.id=:HospType");
    hql.append(" order by UPPER(hosp.name) asc");

    markers.add("HospType");
    values.add(LocationType.HOSP.getID());

    return LocSiteLiteVoAssembler.createLocSiteLiteVoCollectionFromLocSite(factory.find(hql.toString(), markers, values));
}
项目:openMAXIMS    文件:VTERiskAssessmentWorklistImpl.java   
public ims.core.vo.LocSiteLiteVoCollection listHospitals()
{
    DomainFactory factory = getDomainFactory();

    ArrayList<String> markers = new ArrayList<String>();
    ArrayList<Object> values = new ArrayList<Object>();

    StringBuffer hql = new StringBuffer();

    hql.append(" select hosp from LocSite as hosp left join hosp.type as hosptype");
    hql.append(" where hosp.isActive = 1 and hosp.isVirtual = 0 and hosptype.id=:HospType");
    hql.append(" order by UPPER(hosp.name) asc");

    markers.add("HospType");
    values.add(LocationType.HOSP.getID());

    return LocSiteLiteVoAssembler.createLocSiteLiteVoCollectionFromLocSite(factory.find(hql.toString(), markers, values));
}
项目:openmaxims-linux    文件:ImagingEventsImpl.java   
/**
    * list Location Site
    */
    public ims.core.vo.LocSiteLiteVoCollection listLocSite(String locationName)
    {
        String location = locationName != null ? locationName.toUpperCase() + "%" : "%%";

        StringBuffer hql = new StringBuffer();
        hql.append(" from LocSite as ls");
        hql.append(" where");
        hql.append(" ls.upperName like :locationName");
        hql.append(" and ls.isActive =:active");
        hql.append(" and ls.isRIE is null");
        hql.append(" and ls.isVirtual =:virtual");//wdev-2730
        hql.append(" and ls.type.id != " + LocationType.SURGERY.getID());

        List list = getDomainFactory().find(hql.toString(), new String[]{"locationName", "active", "virtual"}, new Object[]{location, Boolean.TRUE, Boolean.FALSE});

        return LocSiteLiteVoAssembler.createLocSiteLiteVoCollectionFromLocSite(list);

//      OrganisationAndLocation orgLocImpl = (OrganisationAndLocation) getDomainImpl(OrganisationAndLocationImpl.class);
//      return orgLocImpl.listLocSite(locationName);
    }
项目:openmaxims-linux    文件:BatchPrintingImpl.java   
public LocSiteLiteVoCollection listHospitals(String name) 
{
    ArrayList<String> markers = new ArrayList<String>();
    ArrayList<Object> values = new ArrayList<Object>();

    String hql = "select ls from LocSite as ls left join ls.codeMappings as t left join t.taxonomyName as tn where tn =:taxonomyType and ls.isActive = 1 and ls.type !=:SurgeryType and ls.isRIE is null and ls.isVirtual = 0";
    markers.add("SurgeryType");
    values.add(getDomLookup(LocationType.SURGERY));
    markers.add("taxonomyType");
    values.add(getDomLookup(TaxonomyType.PATH));

    if(name != null)
    {
        hql += " and ls.upperName like :locationName";
        markers.add("locationName");
        values.add(name.toUpperCase() + "%");
    }

    List list = getDomainFactory().find(hql, markers, values);

    return LocSiteLiteVoAssembler.createLocSiteLiteVoCollectionFromLocSite(list);
}
项目:openmaxims-linux    文件:OrganisationAndLocationImpl.java   
public LocSiteLiteVoCollection listLocSite(String locationName)
{
    String location = locationName != null ? locationName.toUpperCase() + "%" : "%%";

    StringBuffer hql = new StringBuffer();
    hql.append(" from LocSite as ls");
    hql.append(" where");
    hql.append(" ls.upperName like :locationName");
    hql.append(" and ls.isActive =:active");
    hql.append(" and ls.isRIE is null");
    hql.append(" and ls.isVirtual =:virtual");//wdev-2730

    List list = getDomainFactory().find(hql.toString(), new String[]{"locationName", "active", "virtual"}, new Object[]{location, Boolean.TRUE, Boolean.FALSE});

    return LocSiteLiteVoAssembler.createLocSiteLiteVoCollectionFromLocSite(list);
}
项目:openmaxims-linux    文件:LocationStartupSelectionImpl.java   
public LocSiteLiteVoCollection listLocationSites(ims.core.resource.place.vo.OrganisationRefVo organization)
{           
    Organisation doOrganisation = (Organisation) getDomainFactory().getDomainObject(organization);
    LocSiteLiteVoCollection result = LocSiteLiteVoAssembler.createLocSiteLiteVoCollectionFromLocSite(doOrganisation.getLocationSites());

    if(result == null)
        return null;

    LocSiteLiteVoCollection activeLocationSites = new LocSiteLiteVoCollection();

    for(int x = 0; x < result.size(); x++)
    {
        LocSiteLiteVo locationSite = result.get(x);
        if(locationSite != null 
            && locationSite.getIsActive() != null && locationSite.getIsActive().booleanValue()
            && locationSite.getIsVirtualIsNotNull() && ! locationSite.getIsVirtual().booleanValue())//wdev-2730
            activeLocationSites.add(locationSite);
    }

    return activeLocationSites.sort();
}
项目:openmaxims-linux    文件:DementiaWorklistImpl.java   
public ims.core.vo.LocSiteLiteVoCollection listHospitals()
{
    DomainFactory factory = getDomainFactory();

    ArrayList<String> markers = new ArrayList<String>();
    ArrayList<Object> values = new ArrayList<Object>();

    StringBuffer hql = new StringBuffer();

    hql.append(" select hosp from LocSite as hosp left join hosp.type as hosptype");
    hql.append(" where hosp.isActive = 1 and hosp.isVirtual = 0 and hosptype.id=:HospType");
    hql.append(" order by UPPER(hosp.name) asc");

    markers.add("HospType");
    values.add(LocationType.HOSP.getID());

    return LocSiteLiteVoAssembler.createLocSiteLiteVoCollectionFromLocSite(factory.find(hql.toString(), markers, values));
}
项目:openmaxims-linux    文件:VTERiskAssessmentWorklistImpl.java   
public ims.core.vo.LocSiteLiteVoCollection listHospitals()
{
    DomainFactory factory = getDomainFactory();

    ArrayList<String> markers = new ArrayList<String>();
    ArrayList<Object> values = new ArrayList<Object>();

    StringBuffer hql = new StringBuffer();

    hql.append(" select hosp from LocSite as hosp left join hosp.type as hosptype");
    hql.append(" where hosp.isActive = 1 and hosp.isVirtual = 0 and hosptype.id=:HospType");
    hql.append(" order by UPPER(hosp.name) asc");

    markers.add("HospType");
    values.add(LocationType.HOSP.getID());

    return LocSiteLiteVoAssembler.createLocSiteLiteVoCollectionFromLocSite(factory.find(hql.toString(), markers, values));
}
项目:AvoinApotti    文件:ChemotherapyDetailsImpl.java   
public LocSiteLiteVoCollection listHospitals(String locationName)
{
    DomainFactory factory = getDomainFactory();
    IMSCriteria imsc=new IMSCriteria(LocSite.class,factory);
    imsc.equal("type", getDomLookup(LocationType.HOSP));
    imsc.like("name", locationName + "%" );
    imsc.equal("isActive", true);
    List locations = imsc.find();
    if (locations!=null)
        return LocSiteLiteVoAssembler.createLocSiteLiteVoCollectionFromLocSite(locations);
    else
        return null;
}
项目:AvoinApotti    文件:RadioTherapyDetailsImpl.java   
public LocSiteLiteVoCollection listHospitals(String locationName)
{
    DomainFactory factory = getDomainFactory();
    IMSCriteria imsc = new IMSCriteria(LocSite.class, factory);
    imsc.equal("type", getDomLookup(LocationType.HOSP));
    imsc.like("name", locationName + "%");
    List<?> locations = imsc.find();
    if (locations != null)
        return LocSiteLiteVoAssembler.createLocSiteLiteVoCollectionFromLocSite(locations);
    else
        return null;
}
项目:AvoinApotti    文件:CareContextSelectDialogImpl.java   
public LocSiteLiteMappingsVoCollection listLocSites()
{
    String locationName="%";
    String location = locationName != null ? locationName.toUpperCase() + "%" : "%%";
    StringBuffer hql = new StringBuffer();
    hql.append("select ls, t.taxonomyCode");
    hql.append(" from LocSite as ls");
    hql.append(" left join ls.codeMappings as t left join t.taxonomyName as tn where tn =:taxonomyType");
    hql.append(" and");
    hql.append(" ls.upperName like :locationName");
    hql.append(" and ls.isActive =:active");
    hql.append(" and ls.type !=:SurgeryType");
    hql.append(" and ls.isRIE is null");
    hql.append(" and ls.isVirtual =:virtual");//wdev-2730


    LocSiteLiteMappingsVoCollection locSitesWithMappings = new LocSiteLiteMappingsVoCollection();
    List list = getDomainFactory().find(hql.toString(), new String[]{"locationName", "active", "SurgeryType","virtual","taxonomyType"}, new Object[]{location, Boolean.TRUE, getDomLookup(LocationType.SURGERY),Boolean.FALSE,getDomLookup(TaxonomyType.PATH)});
    for (Object obj : list)
    {
        Object[]array = (Object[]) obj;
        LocSiteLiteVo lslVo = LocSiteLiteVoAssembler.create((LocSite)array[0]);
        LocSiteLiteMappingsVo llm= new LocSiteLiteMappingsVo();
        llm.setProviderHospital(lslVo);
        llm.setPathMapping((String)array[1]);
        locSitesWithMappings.add(llm);
    }
    return locSitesWithMappings.sort();
}
项目:AvoinApotti    文件:InpatientClinicalCodingWorklistImpl.java   
public LocSiteLiteVo getCurrentHospital(ILocation location)
{
    if(location == null)
        return null;

    DomainFactory factory = getDomainFactory();

    Location currentHospital = getHospital((Location) factory.getDomainObject(Location.class, location.getID()));

    if(currentHospital instanceof LocSite)
        return LocSiteLiteVoAssembler.create((LocSite) currentHospital);

    return null;
}
项目:AvoinApotti    文件:HospitalAtNightWorklistImpl.java   
public LocSiteLiteVoCollection listHospitals() 
{
    String query = "select h from HospitalAtNightCutOverPointsConfig as hc left join hc.hospital as h order by upper(h.name) asc";
    List<?> list = getDomainFactory().find(query);

    return LocSiteLiteVoAssembler.createLocSiteLiteVoCollectionFromLocSite(list);
}
项目:AvoinApotti    文件:HospitalAtNightWorklistImpl.java   
public LocSiteLiteVo getCurrentHospital(ILocation location) 
{
    if(location == null)
        return null;

    DomainFactory factory = getDomainFactory();

    Location currentHospital = getHospital((Location) factory.getDomainObject(Location.class, location.getID()));

    if(currentHospital instanceof LocSite)
        return LocSiteLiteVoAssembler.create((LocSite) currentHospital);

    return null;
}
项目:AvoinApotti    文件:DementiaWorklistImpl.java   
public ims.core.vo.LocSiteLiteVo getCurrentHospital(ims.framework.interfaces.ILocation location)
{
    if (location == null)
        return null;

    DomainFactory factory = getDomainFactory();

    Location currentHospital = getHospital((Location) factory.getDomainObject(Location.class, location.getID()));

    if (currentHospital instanceof LocSite)
        return LocSiteLiteVoAssembler.create((LocSite) currentHospital);

    return null;
}
项目:AvoinApotti    文件:HospitalAtNightCutOffPointsConfigImpl.java   
public ims.core.vo.LocSiteLiteVoCollection listHospital(String hospitalName)
{
    DomainFactory factory = getDomainFactory();

    ArrayList<String> markers = new ArrayList<String>();
    ArrayList<Object> values = new ArrayList<Object>();

    if (hospitalName == null || (hospitalName != null && hospitalName.trim().length() == 0))
        throw new DomainRuntimeException("String for search is null.");

    String hospNameLite = hospitalName != null ? hospitalName.toUpperCase() + "%" : "%%";

    StringBuffer hql = new StringBuffer();

    hql.append(" select hosp from LocSite as hosp left join hosp.type as hosptype");
    hql.append(" where hosp.name like :HospNam and hosp.isActive = 1 and hosp.isVirtual = 0 and hosptype.id=:HospType");
    hql.append(" and hosp.id not in (select h1_1.hospital.id  from HospitalAtNightCutOverPointsConfig as h1_1)"); //WDEV-14022 
    hql.append(" order by UPPER(hosp.name) asc");

    markers.add("HospNam");
    markers.add("HospType");
    values.add(hospNameLite);
    values.add(LocationType.HOSP.getID());

    return LocSiteLiteVoAssembler.createLocSiteLiteVoCollectionFromLocSite(factory.find(hql.toString(), markers, values));

}
项目:AvoinApotti    文件:VTERiskAssessmentWorklistImpl.java   
public LocSiteLiteVo getCurrentHospital(ILocation location) 
{
    if(location == null)
        return null;

    DomainFactory factory = getDomainFactory();

    Location currentHospital = getHospital((Location) factory.getDomainObject(Location.class, location.getID()));

    if(currentHospital instanceof LocSite)
        return LocSiteLiteVoAssembler.create((LocSite) currentHospital);

    return null;
}
项目:openMAXIMS    文件:CareContextSelectDialogImpl.java   
public LocSiteLiteMappingsVoCollection listLocSites()
{
    String locationName="%";
    String location = locationName != null ? locationName.toUpperCase() + "%" : "%%";
    StringBuffer hql = new StringBuffer();
    hql.append("select ls, t.taxonomyCode");
    hql.append(" from LocSite as ls");
    hql.append(" left join ls.codeMappings as t left join t.taxonomyName as tn where tn =:taxonomyType");
    hql.append(" and");
    hql.append(" ls.upperName like :locationName");
    hql.append(" and ls.isActive =:active");
    hql.append(" and ls.type !=:SurgeryType");
    hql.append(" and ls.isRIE is null");
    hql.append(" and ls.isVirtual =:virtual");//wdev-2730


    LocSiteLiteMappingsVoCollection locSitesWithMappings = new LocSiteLiteMappingsVoCollection();
    List list = getDomainFactory().find(hql.toString(), new String[]{"locationName", "active", "SurgeryType","virtual","taxonomyType"}, new Object[]{location, Boolean.TRUE, getDomLookup(LocationType.SURGERY),Boolean.FALSE,getDomLookup(TaxonomyType.PATH)});
    for (Object obj : list)
    {
        Object[]array = (Object[]) obj;
        LocSiteLiteVo lslVo = LocSiteLiteVoAssembler.create((LocSite)array[0]);
        LocSiteLiteMappingsVo llm= new LocSiteLiteMappingsVo();
        llm.setProviderHospital(lslVo);
        llm.setPathMapping((String)array[1]);
        locSitesWithMappings.add(llm);
    }
    return locSitesWithMappings.sort();
}
项目:openMAXIMS    文件:PHNListImpl.java   
public ims.core.vo.LocSiteLiteVoCollection listCCA()
{
    DomainFactory factory = getDomainFactory();

    // WDEV-12633 - Updated query to list back only CCA locations
    String query = "from LocSite as ls where ls.type.id = " + LocationType.CCA.getID();

    return LocSiteLiteVoAssembler.createLocSiteLiteVoCollectionFromLocSite(factory.find(query));
}
项目:openMAXIMS    文件:InternalReferralsIncomingListComponentImpl.java   
private LocSiteLiteVo getCurrentHospital(ILocation location) 
{
    if(location == null)
        return null;

    DomainFactory factory = getDomainFactory();

    Location currentHospital = getHospital((Location) factory.getDomainObject(Location.class, location.getID()));

    if(currentHospital instanceof LocSite)
        return LocSiteLiteVoAssembler.create((LocSite) currentHospital);

    return null;
}
项目:openMAXIMS    文件:HospitalAtNightWorklistImpl.java   
public LocSiteLiteVoCollection listHospitals() 
{
    String query = "select h from HospitalAtNightCutOverPointsConfig as hc left join hc.hospital as h order by h.upperName asc"; //WDEV-20219 upper(h.name)
    List<?> list = getDomainFactory().find(query);

    return LocSiteLiteVoAssembler.createLocSiteLiteVoCollectionFromLocSite(list);
}
项目:openMAXIMS    文件:HospitalAtNightWorklistImpl.java   
public LocSiteLiteVo getCurrentHospital(ILocation location) 
{
    if(location == null)
        return null;

    DomainFactory factory = getDomainFactory();

    Location currentHospital = getHospital((Location) factory.getDomainObject(Location.class, location.getID()));

    if(currentHospital instanceof LocSite)
        return LocSiteLiteVoAssembler.create((LocSite) currentHospital);

    return null;
}