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

项目:AvoinApotti    文件:ReportsToModalityConfigFormImpl.java   
@SuppressWarnings({ "rawtypes", "unchecked" })
//  @Override
    public ModalityReportsVoCollection listModalityReports(TemplateBoRefVo template, ServiceRefVo modality, Boolean dft) throws DomainInterfaceException
    {
        StringBuffer hql = new StringBuffer();
        StringBuffer cond = new StringBuffer();

        ArrayList markers = new ArrayList();
        ArrayList values = new ArrayList();
        String andStr = " ";


        DomainFactory factory = getDomainFactory();
        hql.append("select m from ModalityReports as m left join m.modality as s");

        if(template != null)
        {
            cond.append(andStr + "m.template.id = (:TID)");
            markers.add("TID");
            values.add(template.getID_TemplateBo());
            andStr = " and ";
        }

        if(modality != null)
        {
            cond.append(andStr + "m.modality.id = (:MID)");
            markers.add("MID");
            values.add(modality.getID_Service());
            andStr = " and ";
        }

        cond.append(andStr + "m.dFTReport = (:DFT)");
        markers.add("DFT");
        values.add(dft);
        andStr = " and ";

        if (andStr.equals(" and "))
        {
            hql.append(" where ");
        }

        hql.append(cond.toString());
        hql.append(" order by UPPER(s.serviceName)");

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

        return ModalityReportsVoAssembler.createModalityReportsVoCollectionFromModalityReports(list);
    }
项目:openMAXIMS    文件:ReportsToModalityConfigFormImpl.java   
@SuppressWarnings({ "rawtypes", "unchecked" })
public ModalityReportsVoCollection listModalityReports(TemplateBoRefVo template, ServiceRefVo modality, Boolean dft) throws DomainInterfaceException
{
    StringBuffer hql = new StringBuffer();
    StringBuffer cond = new StringBuffer();

    ArrayList markers = new ArrayList();
    ArrayList values = new ArrayList();
    String andStr = " ";


    DomainFactory factory = getDomainFactory();
    hql.append("select m from ModalityReports as m left join m.modality as s");

    if(template != null)
    {
        cond.append(andStr + "m.template.id = (:TID)");
        markers.add("TID");
        values.add(template.getID_TemplateBo());
        andStr = " and ";
    }

    if(modality != null)
    {
        cond.append(andStr + "m.modality.id = (:MID)");
        markers.add("MID");
        values.add(modality.getID_Service());
        andStr = " and ";
    }

    cond.append(andStr + "m.dFTReport = (:DFT)");
    markers.add("DFT");
    values.add(dft);
    andStr = " and ";

    if (andStr.equals(" and "))
    {
        hql.append(" where ");
    }

    hql.append(cond.toString());
    hql.append(" order by s.upperName"); //WDEV-20219 UPPER(s.serviceName)

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

    return ModalityReportsVoAssembler.createModalityReportsVoCollectionFromModalityReports(list);
}
项目:openMAXIMS    文件:ReportsToModalityConfigFormImpl.java   
@SuppressWarnings({ "rawtypes", "unchecked" })
//  @Override
    public ModalityReportsVoCollection listModalityReports(TemplateBoRefVo template, ServiceRefVo modality, Boolean dft) throws DomainInterfaceException
    {
        StringBuffer hql = new StringBuffer();
        StringBuffer cond = new StringBuffer();

        ArrayList markers = new ArrayList();
        ArrayList values = new ArrayList();
        String andStr = " ";


        DomainFactory factory = getDomainFactory();
        hql.append("select m from ModalityReports as m left join m.modality as s");

        if(template != null)
        {
            cond.append(andStr + "m.template.id = (:TID)");
            markers.add("TID");
            values.add(template.getID_TemplateBo());
            andStr = " and ";
        }

        if(modality != null)
        {
            cond.append(andStr + "m.modality.id = (:MID)");
            markers.add("MID");
            values.add(modality.getID_Service());
            andStr = " and ";
        }

        cond.append(andStr + "m.dFTReport = (:DFT)");
        markers.add("DFT");
        values.add(dft);
        andStr = " and ";

        if (andStr.equals(" and "))
        {
            hql.append(" where ");
        }

        hql.append(cond.toString());
        hql.append(" order by UPPER(s.serviceName)");

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

        return ModalityReportsVoAssembler.createModalityReportsVoCollectionFromModalityReports(list);
    }
项目:openmaxims-linux    文件:ReportsToModalityConfigFormImpl.java   
@SuppressWarnings({ "rawtypes", "unchecked" })
//  @Override
    public ModalityReportsVoCollection listModalityReports(TemplateBoRefVo template, ServiceRefVo modality, Boolean dft) throws DomainInterfaceException
    {
        StringBuffer hql = new StringBuffer();
        StringBuffer cond = new StringBuffer();

        ArrayList markers = new ArrayList();
        ArrayList values = new ArrayList();
        String andStr = " ";


        DomainFactory factory = getDomainFactory();
        hql.append("select m from ModalityReports as m left join m.modality as s");

        if(template != null)
        {
            cond.append(andStr + "m.template.id = (:TID)");
            markers.add("TID");
            values.add(template.getID_TemplateBo());
            andStr = " and ";
        }

        if(modality != null)
        {
            cond.append(andStr + "m.modality.id = (:MID)");
            markers.add("MID");
            values.add(modality.getID_Service());
            andStr = " and ";
        }

        cond.append(andStr + "m.dFTReport = (:DFT)");
        markers.add("DFT");
        values.add(dft);
        andStr = " and ";

        if (andStr.equals(" and "))
        {
            hql.append(" where ");
        }

        hql.append(cond.toString());
        hql.append(" order by UPPER(s.serviceName)");

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

        return ModalityReportsVoAssembler.createModalityReportsVoCollectionFromModalityReports(list);
    }