Java 类ims.core.vo.MedicLiteVoCollection 实例源码

项目:AvoinApotti    文件:Logic.java   
@Override
protected void onQmbConsultantTextSubmited(String value) throws ims.framework.exceptions.PresentationLogicException
{
    clearConsultantCombo();
    if (value != null)
    {
        MedicLiteVoCollection voMedicColl = domain.listActiveMedics(value);
        if (voMedicColl != null)
        {
            for (int i = 0; i < voMedicColl.size(); i++)
            {
                MedicLiteVo med = voMedicColl.get(i);
                form.qmbConsultant().newRow(med, med.toString());
            }
        }
        if (voMedicColl != null && voMedicColl.size() == 1)
            form.qmbConsultant().setValue(voMedicColl.get(0));
        else if (voMedicColl != null && voMedicColl.size() > 1)
            form.qmbConsultant().showOpened();
    }
}
项目:AvoinApotti    文件:Logic.java   
protected void onQmbSignedByTextSubmited(String value) throws PresentationLogicException
{
    form.qmbSignedBy().clear();

    MedicLiteVoCollection voCollMedics = domain.listSignatories(value);
    for (int i = 0; i < voCollMedics.size(); i++)
    {
        MedicLiteVo hcp = voCollMedics.get(i);
        form.qmbSignedBy().newRow(hcp, hcp.getMos().getName().toShortForm());
    }
    if (voCollMedics.size() == 1)
    {
        form.qmbSignedBy().setValue(voCollMedics.get(0));
    }
    else if (voCollMedics.size() > 1)
    {
        form.qmbSignedBy().showOpened();
    }
}
项目:AvoinApotti    文件:Logic.java   
private MedicLiteVoCollection listConsultantsByName(String consultantName) throws CodingRuntimeException
{
    // Leave throws so that clinics are not cleared when an invalid search is made
    if (consultantName == null || consultantName.trim().length() < 3)
        throw new CodingRuntimeException("Consultant name search must be at least 3 characters long");


    // Build filtering VO
    MedicLiteVo filterVo = new MedicLiteVo();
    filterVo.setMos(new MemberOfStaffLiteVo());
    filterVo.getMos().setName(new PersonName());
    filterVo.getMos().getName().setSurname(consultantName);
    filterVo.getMos().getName().setForename(consultantName);

    // Retrieve the consultants (list from domain)
    try
    {
        return domain.listConsultants(filterVo);
    }
    catch (DomainInterfaceException exception)
    {
        throw new CodingRuntimeException(exception.getMessage());
    }
}
项目:AvoinApotti    文件:Logic.java   
protected void onQmbConsultantTextSubmited(String value) throws PresentationLogicException
{
    clearConsultantCombo();
    if (value != null)
    {
        MedicLiteVoCollection voMedicColl = domain.listActiveMedics(value);
        if (voMedicColl != null)
        {
            for (int i = 0; i < voMedicColl.size(); i++)
            {
                MedicLiteVo med = voMedicColl.get(i);
                form.qmbConsultant().newRow(med, med.toString());
            }
        }
        if (voMedicColl != null && voMedicColl.size() == 1)
            form.qmbConsultant().setValue(voMedicColl.get(0));
        else if (voMedicColl != null && voMedicColl.size() > 1)
            form.qmbConsultant().showOpened();
    }
}
项目:AvoinApotti    文件:Logic.java   
private void populateQueryConsultants(DynamicGridCell cell, String textTyped) 
{
    cell.getItems().clear();
    MedicLiteVoCollection medicColl = domain.listConsultants(textTyped);

    if(medicColl != null)
    {
        for(int i=0; i<medicColl.size(); i++)
        {
            if(consultantNotOnScreen(medicColl.get(i), cell.getRow().getParent()))
            {
                DynamicGridCellItem newComboItem = cell.getItems().newItem(medicColl.get(i));
            }
        }

        if(medicColl.size() > 0)
        {
            cell.showOpened();
        }
    }
}
项目:AvoinApotti    文件:Logic.java   
private MedicLiteVoCollection listConsultantsByName(String medicName) throws CodingRuntimeException
{
    // Leave throws so that consultants are not cleared when an invalid search is made
    if (medicName == null || medicName.trim().length() < 3)
        throw new CodingRuntimeException("Consultant name search must be at least 3 characters long");


    // Build filtering VO
    MedicLiteVo filterVo = new MedicLiteVo();
    filterVo.setMos(new MemberOfStaffLiteVo());
    filterVo.getMos().setName(new PersonName());
    filterVo.getName().setSurname(medicName);
    filterVo.getName().setForename(medicName);

    // Retrieve the medics (list from domain)
    try
    {
        return domain.listConsultants(filterVo);
    }
    catch (DomainInterfaceException exception)
    {
        throw new CodingRuntimeException(exception.getMessage());
    }
}
项目:AvoinApotti    文件:Logic.java   
/**
 * 
 */
private void listConsultants() 
{
    MedicLiteVoCollection voCollConsultants = domain.listConsultants();     
    if (voCollConsultants != null)
    {           
        form.grdConsultant().getRows().clear();         
        for (int i=0; i < voCollConsultants.size(); i++)
        {
            GenForm.grdConsultantRow consRow = form.grdConsultant().getRows().newRow();             
            consRow.setValue(voCollConsultants.get(i));
            consRow.setColConsultantImage(form.getImages().Admin.MemberOfStaff);
            consRow.setcolConsultant(voCollConsultants.get(i).getMos().getName().toShortForm());
        }
    }
}
项目:AvoinApotti    文件:NoLetterRequiredAdminConfigImpl.java   
public MedicLiteVoCollection listConsultants(String textTyped) 
{
    if(textTyped == null)
        throw new CodingRuntimeException("Cannot search on null text!");

    MedicLiteVoCollection voCollMedicsLite = new MedicLiteVoCollection();
    List lstMedics = listActiveMedics(textTyped);
    if (lstMedics != null)
    {
        for (int i = 0; i < lstMedics.size(); i++)
        {
            Hcp hcp = (Hcp) lstMedics.get(i);
            if (Medic.class.isAssignableFrom(hcp.getClass()))
                voCollMedicsLite.add(MedicLiteVoAssembler.create((Medic) hcp));
        }
    }

    return voCollMedicsLite;
}
项目:AvoinApotti    文件:GlossaryAdminConfigurationImpl.java   
private MedicLiteVoCollection listMedicsLite(String textToSearch) 
{
    MedicLiteVoCollection voCollMedicsLite = new MedicLiteVoCollection();
    List lstMedics = listActiveMedics(textToSearch);
    if (lstMedics != null)
    {
        for (int i = 0; i < lstMedics.size(); i++)
        {
            Hcp hcp = (Hcp) lstMedics.get(i);
            if (Medic.class.isAssignableFrom(hcp.getClass()))
                voCollMedicsLite.add(MedicLiteVoAssembler.create((Medic) hcp));
        }
    }

    return voCollMedicsLite;
}
项目:AvoinApotti    文件:Logic.java   
@Override
protected void onQmbConsTextSubmited(String value) throws ims.framework.exceptions.PresentationLogicException
{
    form.qmbCons().clear();

    if (value != null)
    {
        MedicLiteVo med = null;
        MedicLiteVoCollection voMedicColl = domain.listConsultants(value);
        if (voMedicColl != null)
        {
            for (int i = 0; i < voMedicColl.size(); i++)
            {
                med = voMedicColl.get(i);
                form.qmbCons().newRow(med, med.toString());         
            }
        }
        if (voMedicColl != null &&
                voMedicColl.size() == 1)
                        form.qmbCons().setValue(voMedicColl.get(0));
        else if (voMedicColl != null &&
                    voMedicColl.size() > 1)
                        form.qmbCons().showOpened();
    }
}
项目:AvoinApotti    文件:Logic.java   
protected void onQmbConsultantTextSubmited(String value) throws PresentationLogicException
{
    clearConsultantCombo();
    if (value != null)
    {
        MedicLiteVoCollection voMedicColl = domain.listActiveMedics(value);
        if (voMedicColl != null)
        {
            for (int i = 0; i < voMedicColl.size(); i++)
            {
                MedicLiteVo med = voMedicColl.get(i);
                form.qmbConsultant().newRow(med, med.toString());
            }
        }
        if (voMedicColl != null && voMedicColl.size() == 1)
            form.qmbConsultant().setValue(voMedicColl.get(0));
        else if (voMedicColl != null && voMedicColl.size() > 1)
            form.qmbConsultant().showOpened();
    }
}
项目:AvoinApotti    文件:MosAdminImpl.java   
public MedicLiteVoCollection listMedicsLite() 
{
    MedicLiteVoCollection voCollMedicsLite = new MedicLiteVoCollection();
    List lstMedics = listActiveMedics();
    if (lstMedics != null)
    {
        for (int i = 0; i < lstMedics.size(); i++)
        {
            Hcp hcp = (Hcp) lstMedics.get(i);
            if (Medic.class.isAssignableFrom(hcp.getClass()))
                voCollMedicsLite.add(MedicLiteVoAssembler.create((Medic) hcp));
        }
    }

    return voCollMedicsLite;
}
项目:AvoinApotti    文件:MosAdminImpl.java   
public MedicVoCollection listFullMedicsForMedicLites(MedicLiteVoCollection voCollLiteMedics) 
{
    DomainFactory factory = getDomainFactory();
    StringBuffer hqlStart = new StringBuffer();
    String hql;

    hqlStart.append("from Hcp hcp where hcp.id in ( ");
    for (int i = 0; i < voCollLiteMedics.size(); i++)
        hqlStart.append(voCollLiteMedics.get(i) + ",");

    if (hqlStart.toString().endsWith(","))
        hql = hqlStart.toString().substring(0, hqlStart.length() - 1);
    else
        hql = hqlStart.toString();

    hql += " )";

    return MedicVoAssembler.createMedicVoCollectionFromMedic(factory.find(hql));
}
项目:AvoinApotti    文件:Logic.java   
@Override
protected void onQmbConsultantSearchTextSubmited(String value) throws PresentationLogicException 
{
    form.qmbConsultantSearch().clear();

    MedicLiteVoCollection coll = domain.listMedics(value);

    for (int i = 0; i < coll.size(); i++)
    {
        MedicLiteVo med = coll.get(i);

        form.qmbConsultantSearch().newRow(med, med.getMos().getName().toString());
    }
    if (coll.size() == 1)
    {
        form.qmbConsultantSearch().setValue(coll.get(0));
    }
    else if (coll.size() > 1)
    {
        form.qmbConsultantSearch().showOpened();
    }
}
项目:AvoinApotti    文件:Logic.java   
private MedicLiteVoCollection getAnaesthetist()
{
    MedicLiteVoCollection tempColl = new MedicLiteVoCollection();

    for( int i = 0; i < form.grdAnaesthetist().getRows().size();i++)
    {
         tempColl.add(form.grdAnaesthetist().getRows().get(i).getValue());
    }
    for( int j = 0; j < form.grdAnaesthetistAssistedBy().getRows().size();j++)
    {
         tempColl.add(form.grdAnaesthetistAssistedBy().getRows().get(j).getValue());
    }
    for( int k = 0; k < form.grdOperationPerformedBy().getRows().size();k++)
    {
        tempColl.add(form.grdOperationPerformedBy().getRows().get(k).getValue());
    }
    for( int l = 0; l < form.grdConsultantAssistedBy().getRows().size();l++)
    {
        tempColl.add(form.grdConsultantAssistedBy().getRows().get(l).getValue());
    }
    return tempColl;
}
项目:AvoinApotti    文件:Logic.java   
private MedicLiteVoCollection getAllMedics() 
{
    MedicLiteVoCollection tempColl = new MedicLiteVoCollection();

    for( int i = 0; i < form.grdAnaesthetist().getRows().size();i++)
    {
         tempColl.add(form.grdAnaesthetist().getRows().get(i).getValue());
    }
    for( int j = 0; j < form.grdAnaesthetistAssistedBy().getRows().size();j++)
    {
         tempColl.add(form.grdAnaesthetistAssistedBy().getRows().get(j).getValue());
    }
    for( int k = 0; k < form.grdOperationPerformedBy().getRows().size();k++)
    {
        tempColl.add(form.grdOperationPerformedBy().getRows().get(k).getValue());
    }
    for( int l = 0; l < form.grdConsultantAssistedBy().getRows().size();l++)
    {
        tempColl.add(form.grdConsultantAssistedBy().getRows().get(l).getValue());
    }

    return tempColl;
}
项目:AvoinApotti    文件:PlannedPerformedProcedureDialogImpl.java   
public MedicLiteVo getMedicLiteVo(HcpRefVo hcp)
{
    if( hcp == null )
        return null;

    DomainFactory factory = getDomainFactory();
    List medics = factory.find("select m1_1 from Medic as m1_1 left join m1_1.mos as m2_1 left join m2_1.hcp as h1_1 where  (h1_1.id = :hcpId)", new String[] {"hcpId"}, new Object[] {hcp.getID_Hcp()});


    if( medics != null && medics.size() > 0)
    {
        MedicLiteVoCollection tempColl = MedicLiteVoAssembler.createMedicLiteVoCollectionFromMedic(medics);
        if( tempColl != null && tempColl.size() > 0)
            return tempColl.get(0);
    }

    return null;
}
项目:openMAXIMS    文件:Logic.java   
protected void onQmbConsultantTextSubmited(String value) throws PresentationLogicException
{
    clearConsultantCombo();
    if (value != null)
    {
        MedicLiteVoCollection voMedicColl = domain.listActiveMedics(value);
        if (voMedicColl != null)
        {
            for (int i = 0; i < voMedicColl.size(); i++)
            {
                MedicLiteVo med = voMedicColl.get(i);
                form.qmbConsultant().newRow(med, med.toString());
            }
        }
        if (voMedicColl != null && voMedicColl.size() == 1)
            form.qmbConsultant().setValue(voMedicColl.get(0));
        else if (voMedicColl != null && voMedicColl.size() > 1)
            form.qmbConsultant().showOpened();
    }
}
项目:openMAXIMS    文件:Logic.java   
private void populateQueryConsultants(DynamicGridCell cell, String textTyped) 
{
    cell.getItems().clear();
    MedicLiteVoCollection medicColl = domain.listConsultants(textTyped);

    if(medicColl != null)
    {
        for(int i=0; i<medicColl.size(); i++)
        {
            if(consultantNotOnScreen(medicColl.get(i), cell.getRow().getParent()))
            {
                DynamicGridCellItem newComboItem = cell.getItems().newItem(medicColl.get(i));
            }
        }

        if(medicColl.size() > 0)
        {
            cell.showOpened();
        }
    }
}
项目:openMAXIMS    文件:MosAdminImpl.java   
public MedicVoCollection listFullMedicsForMedicLites(MedicLiteVoCollection voCollLiteMedics) 
{
    DomainFactory factory = getDomainFactory();
    StringBuffer hqlStart = new StringBuffer();
    String hql;

    hqlStart.append("from Hcp hcp where hcp.id in ( ");
    for (int i = 0; i < voCollLiteMedics.size(); i++)
        hqlStart.append(voCollLiteMedics.get(i) + ",");

    if (hqlStart.toString().endsWith(","))
        hql = hqlStart.toString().substring(0, hqlStart.length() - 1);
    else
        hql = hqlStart.toString();

    hql += " )";

    return MedicVoAssembler.createMedicVoCollectionFromMedic(factory.find(hql));
}
项目:openmaxims-linux    文件:Logic.java   
protected void onQmbConsultantTextSubmited(String value) throws PresentationLogicException
{
    clearConsultantCombo();
    if (value != null)
    {
        MedicLiteVoCollection voMedicColl = domain.listActiveMedics(value);
        if (voMedicColl != null)
        {
            for (int i = 0; i < voMedicColl.size(); i++)
            {
                MedicLiteVo med = voMedicColl.get(i);
                form.qmbConsultant().newRow(med, med.toString());
            }
        }
        if (voMedicColl != null && voMedicColl.size() == 1)
            form.qmbConsultant().setValue(voMedicColl.get(0));
        else if (voMedicColl != null && voMedicColl.size() > 1)
            form.qmbConsultant().showOpened();
    }
}
项目:openMAXIMS    文件:Logic.java   
/**
 * 
 */
private void listConsultants() 
{
    MedicLiteVoCollection voCollConsultants = domain.listConsultants();     
    if (voCollConsultants != null)
    {           
        form.grdConsultant().getRows().clear();         
        for (int i=0; i < voCollConsultants.size(); i++)
        {
            GenForm.grdConsultantRow consRow = form.grdConsultant().getRows().newRow();             
            consRow.setValue(voCollConsultants.get(i));
            consRow.setColConsultantImage(form.getImages().Admin.MemberOfStaff);
            consRow.setcolConsultant(voCollConsultants.get(i).getMos().getName().toShortForm());
        }
    }
}
项目:openmaxims-linux    文件:MosAdminImpl.java   
public MedicVoCollection listFullMedicsForMedicLites(MedicLiteVoCollection voCollLiteMedics) 
{
    DomainFactory factory = getDomainFactory();
    StringBuffer hqlStart = new StringBuffer();
    String hql;

    hqlStart.append("from Hcp hcp where hcp.id in ( ");
    for (int i = 0; i < voCollLiteMedics.size(); i++)
        hqlStart.append(voCollLiteMedics.get(i) + ",");

    if (hqlStart.toString().endsWith(","))
        hql = hqlStart.toString().substring(0, hqlStart.length() - 1);
    else
        hql = hqlStart.toString();

    hql += " )";

    return MedicVoAssembler.createMedicVoCollectionFromMedic(factory.find(hql));
}
项目:openMAXIMS    文件:MosAdminImpl.java   
public MedicLiteVoCollection listMedicsLite() 
{
    MedicLiteVoCollection voCollMedicsLite = new MedicLiteVoCollection();
    List lstMedics = listActiveMedics();
    if (lstMedics != null)
    {
        for (int i = 0; i < lstMedics.size(); i++)
        {
            Hcp hcp = (Hcp) lstMedics.get(i);
            if (Medic.class.isAssignableFrom(hcp.getClass()))
                voCollMedicsLite.add(MedicLiteVoAssembler.create((Medic) hcp));
        }
    }

    return voCollMedicsLite;
}
项目:openMAXIMS    文件:GlossaryAdminConfigurationImpl.java   
private MedicLiteVoCollection listMedicsLite(String textToSearch) 
{
    MedicLiteVoCollection voCollMedicsLite = new MedicLiteVoCollection();
    List lstMedics = listActiveMedics(textToSearch);
    if (lstMedics != null)
    {
        for (int i = 0; i < lstMedics.size(); i++)
        {
            Hcp hcp = (Hcp) lstMedics.get(i);
            if (Medic.class.isAssignableFrom(hcp.getClass()))
                voCollMedicsLite.add(MedicLiteVoAssembler.create((Medic) hcp));
        }
    }

    return voCollMedicsLite;
}
项目:openMAXIMS    文件:Logic.java   
/**
 * Function to populate consultants
 * @param consultants - values to be populated
 */
private void populateConsultants(MedicLiteVoCollection consultants)
{
    form.qmbConsultant().clear();

    if (consultants == null)
        return;

    for (MedicLiteVo consultant : consultants)
    {
        form.qmbConsultant().newRow(consultant, consultant.getIMosName());
    }

    if (consultants.size() == 1)
        form.qmbConsultant().setValue(consultants.get(0));
    else
        form.qmbConsultant().showOpened();
}
项目:openMAXIMS    文件:Logic.java   
private MedicLiteVoCollection getAllMedics() 
{
    MedicLiteVoCollection tempColl = new MedicLiteVoCollection();

    for( int i = 0; i < form.grdAnaesthetist().getRows().size();i++)
    {
         tempColl.add(form.grdAnaesthetist().getRows().get(i).getValue());
    }
    for( int j = 0; j < form.grdAnaesthetistAssistedBy().getRows().size();j++)
    {
         tempColl.add(form.grdAnaesthetistAssistedBy().getRows().get(j).getValue());
    }
    for( int k = 0; k < form.grdOperationPerformedBy().getRows().size();k++)
    {
        tempColl.add(form.grdOperationPerformedBy().getRows().get(k).getValue());
    }
    for( int l = 0; l < form.grdConsultantAssistedBy().getRows().size();l++)
    {
        tempColl.add(form.grdConsultantAssistedBy().getRows().get(l).getValue());
    }

    return tempColl;
}
项目:openMAXIMS    文件:Logic.java   
@Override
protected void onQmbConsTextSubmited(String value) throws ims.framework.exceptions.PresentationLogicException
{
    form.qmbCons().clear();

    if (value != null)
    {
        MedicLiteVo med = null;
        MedicLiteVoCollection voMedicColl = domain.listConsultants(value);
        if (voMedicColl != null)
        {
            for (int i = 0; i < voMedicColl.size(); i++)
            {
                med = voMedicColl.get(i);
                form.qmbCons().newRow(med, med.toString());         
            }
        }
        if (voMedicColl != null &&
                voMedicColl.size() == 1)
                        form.qmbCons().setValue(voMedicColl.get(0));
        else if (voMedicColl != null &&
                    voMedicColl.size() > 1)
                        form.qmbCons().showOpened();
    }
}
项目:openMAXIMS    文件:AdmitToWardImpl.java   
public MedicLiteVoCollection listReferringConsultants(String name)
{
    ArrayList<String> paramNames = new ArrayList<String>();
    ArrayList<Object> paramValues = new ArrayList<Object>();

    StringBuilder query = new StringBuilder("SELECT medic FROM Medic AS medic ");
    query.append(" LEFT JOIN medic.mos AS mos ");
    query.append(" LEFT JOIN medic.grade AS medicGrade ");
    query.append(" WHERE ");
    query.append(" medicGrade.id = :CONSULTANT ");

    paramNames.add("CONSULTANT");           paramValues.add(MedicGrade.CONS.getID());

    if (name != null && name.length() > 0)
    {
        query.append(" AND mos.name.upperSurname LIKE :SURNAME AND mos.name.upperForename LIKE :FORENAME " );

        paramNames.add("SURNAME");          paramValues.add(name.toUpperCase() + "%");
        paramNames.add("FORENAME");         paramValues.add(name.toUpperCase() + "%");
    }

    query.append(" ORDER BY mos.name.upperSurname, mos.name.upperForename ");

    return MedicLiteVoAssembler.createMedicLiteVoCollectionFromMedic(getDomainFactory().find(query.toString(), paramNames, paramValues));
}
项目:openMAXIMS    文件:MosAdminImpl.java   
public MedicLiteVoCollection listMedicsLite() 
{
    MedicLiteVoCollection voCollMedicsLite = new MedicLiteVoCollection();
    List lstMedics = listActiveMedics();
    if (lstMedics != null)
    {
        for (int i = 0; i < lstMedics.size(); i++)
        {
            Hcp hcp = (Hcp) lstMedics.get(i);
            if (Medic.class.isAssignableFrom(hcp.getClass()))
                voCollMedicsLite.add(MedicLiteVoAssembler.create((Medic) hcp));
        }
    }

    return voCollMedicsLite;
}
项目:openMAXIMS    文件:Logic.java   
@Override
protected void onGrdAssistingSurgeonsGridQueryComboBoxTextSubmited(int column, grdAssistingSurgeonsRow row, String text) throws PresentationLogicException
{
    if (text == null || text.length() < 3)
    {
        engine.showMessage("Please enter a minimum of 3 characters to search by");
        return;
    }

    MedicLiteVoCollection voCollMedics = domain.listMedicLiteVo(text);

    //WDEV-21778
    row.getColAssistingSurgeon().clear();

    for (int i = 0; i < voCollMedics.size(); i++)
    {
        row.getColAssistingSurgeon().newRow(voCollMedics.get(i), voCollMedics.get(i).getMos().toString());
    }

    if (voCollMedics.size() == 1)
        row.getColAssistingSurgeon().setValue(voCollMedics.get(0));
    else
        row.getColAssistingSurgeon().showOpened();
}
项目:openMAXIMS    文件:Logic.java   
@Override
protected void onGrdAssistingSurgeonsGridQueryComboBoxTextSubmited(int column, grdAssistingSurgeonsRow row, String text) throws PresentationLogicException
{
    if (text == null || text.length() < 3)
    {
        engine.showMessage("Please enter a minimum of 3 characters to search by");
        return;
    }

    MedicLiteVoCollection voCollMedics = domain.listMedicLiteVo(text);

    for (int i = 0; i < voCollMedics.size(); i++)
    {
        row.getColAssistingSurgeon().newRow(voCollMedics.get(i), voCollMedics.get(i).getMos().toString());
    }

    if (voCollMedics.size() == 1)
        row.getColAssistingSurgeon().setValue(voCollMedics.get(0));
    else
        row.getColAssistingSurgeon().showOpened();
}
项目:openMAXIMS    文件:Logic.java   
private MedicLiteVoCollection getAnaesthetist()
{
    MedicLiteVoCollection tempColl = new MedicLiteVoCollection();

    for( int i = 0; i < form.grdAnaesthetist().getRows().size();i++)
    {
         tempColl.add(form.grdAnaesthetist().getRows().get(i).getValue());
    }
    for( int j = 0; j < form.grdAnaesthetistAssistedBy().getRows().size();j++)
    {
         tempColl.add(form.grdAnaesthetistAssistedBy().getRows().get(j).getValue());
    }
    for( int k = 0; k < form.grdOperationPerformedBy().getRows().size();k++)
    {
        tempColl.add(form.grdOperationPerformedBy().getRows().get(k).getValue());
    }
    for( int l = 0; l < form.grdConsultantAssistedBy().getRows().size();l++)
    {
        tempColl.add(form.grdConsultantAssistedBy().getRows().get(l).getValue());
    }
    return tempColl;
}
项目:openmaxims-linux    文件:Logic.java   
protected void onQmbSignedByTextSubmited(String value) throws PresentationLogicException
{
    form.qmbSignedBy().clear();

    MedicLiteVoCollection voCollMedics = domain.listSignatories(value);
    for (int i = 0; i < voCollMedics.size(); i++)
    {
        MedicLiteVo hcp = voCollMedics.get(i);
        form.qmbSignedBy().newRow(hcp, hcp.getMos().getName().toShortForm());
    }
    if (voCollMedics.size() == 1)
    {
        form.qmbSignedBy().setValue(voCollMedics.get(0));
    }
    else if (voCollMedics.size() > 1)
    {
        form.qmbSignedBy().showOpened();
    }
}
项目:openMAXIMS    文件:Logic.java   
protected void onQmbSignedByTextSubmited(String value) throws PresentationLogicException
{
    form.qmbSignedBy().clear();

    MedicLiteVoCollection voCollMedics = domain.listSignatories(value);
    for (int i = 0; i < voCollMedics.size(); i++)
    {
        MedicLiteVo hcp = voCollMedics.get(i);
        form.qmbSignedBy().newRow(hcp, hcp.getMos().getName().toShortForm());
    }
    if (voCollMedics.size() == 1)
    {
        form.qmbSignedBy().setValue(voCollMedics.get(0));
    }
    else if (voCollMedics.size() > 1)
    {
        form.qmbSignedBy().showOpened();
    }
}
项目:openmaxims-linux    文件:NoLetterRequiredAdminConfigImpl.java   
public MedicLiteVoCollection listConsultants(String textTyped) 
{
    if(textTyped == null)
        throw new CodingRuntimeException("Cannot search on null text!");

    MedicLiteVoCollection voCollMedicsLite = new MedicLiteVoCollection();
    List lstMedics = listActiveMedics(textTyped);
    if (lstMedics != null)
    {
        for (int i = 0; i < lstMedics.size(); i++)
        {
            Hcp hcp = (Hcp) lstMedics.get(i);
            if (Medic.class.isAssignableFrom(hcp.getClass()))
                voCollMedicsLite.add(MedicLiteVoAssembler.create((Medic) hcp));
        }
    }

    return voCollMedicsLite;
}
项目:openmaxims-linux    文件:Logic.java   
@Override
protected void onQmbConsultantSearchTextSubmited(String value) throws PresentationLogicException 
{
    form.qmbConsultantSearch().clear();

    MedicLiteVoCollection coll = domain.listMedics(value);

    for (int i = 0; i < coll.size(); i++)
    {
        MedicLiteVo med = coll.get(i);

        form.qmbConsultantSearch().newRow(med, med.getMos().getName().toString());
    }
    if (coll.size() == 1)
    {
        form.qmbConsultantSearch().setValue(coll.get(0));
    }
    else if (coll.size() > 1)
    {
        form.qmbConsultantSearch().showOpened();
    }
}
项目:openMAXIMS    文件:Logic.java   
protected void onQmbConsultantTextSubmited(String value) throws PresentationLogicException
{
    clearConsultantCombo();
    if (value != null)
    {
        MedicLiteVoCollection voMedicColl = domain.listActiveMedics(value);
        if (voMedicColl != null)
        {
            for (int i = 0; i < voMedicColl.size(); i++)
            {
                MedicLiteVo med = voMedicColl.get(i);
                form.qmbConsultant().newRow(med, med.toString());
            }
        }
        if (voMedicColl != null && voMedicColl.size() == 1)
            form.qmbConsultant().setValue(voMedicColl.get(0));
        else if (voMedicColl != null && voMedicColl.size() > 1)
            form.qmbConsultant().showOpened();
    }
}
项目:openmaxims-linux    文件:Logic.java   
private MedicLiteVoCollection listConsultantsByName(String consultantName) throws CodingRuntimeException
{
    // Leave throws so that clinics are not cleared when an invalid search is made
    if (consultantName == null || consultantName.trim().length() < 3)
        throw new CodingRuntimeException("Consultant name search must be at least 3 characters long");


    // Build filtering VO
    MedicLiteVo filterVo = new MedicLiteVo();
    filterVo.setMos(new MemberOfStaffLiteVo());
    filterVo.getMos().setName(new PersonName());
    filterVo.getMos().getName().setSurname(consultantName);
    filterVo.getMos().getName().setForename(consultantName);

    // Retrieve the consultants (list from domain)
    try
    {
        return domain.listConsultants(filterVo);
    }
    catch (DomainInterfaceException exception)
    {
        throw new CodingRuntimeException(exception.getMessage());
    }
}
项目:openMAXIMS    文件:Logic.java   
private MedicLiteVoCollection listConsultantsByName(String medicName) throws CodingRuntimeException
{
    // Leave throws so that consultants are not cleared when an invalid search is made
    if (medicName == null || medicName.trim().length() < 3)
        throw new CodingRuntimeException("Consultant name search must be at least 3 characters long");


    // Build filtering VO
    MedicLiteVo filterVo = new MedicLiteVo();
    filterVo.setMos(new MemberOfStaffLiteVo());
    filterVo.getMos().setName(new PersonName());
    filterVo.getName().setSurname(medicName);
    filterVo.getName().setForename(medicName);

    // Retrieve the medics (list from domain)
    try
    {
        return domain.listConsultants(filterVo);
    }
    catch (DomainInterfaceException exception)
    {
        throw new CodingRuntimeException(exception.getMessage());
    }
}