Java 类ims.core.vo.lookups.MedicGrade 实例源码

项目:AvoinApotti    文件:Logic.java   
public void initialize(PatientShort patient, EpisodeofCareShortVo episodeOfCare, CareContextShortVo careContext, AdmissionDetailVo admissionDetail)
{
    form.getLocalContext().setPatient(patient);

    if (careContext != null)
        form.getLocalContext().setCareContext(domain.getCareContext(careContext));

    form.getLocalContext().setCurrentAdmissionDetail(admissionDetail);

    form.ccAdmittingConsultant().initialize(null, MedicGrade.CONS);
    form.ccAdmittingConsultant().isRequired(true);

    removeItemsFromReferredAdmittedComboBoxes();
    populateWardsCombo();
    open();
    updateControlsState();

}
项目:openMAXIMS    文件:Logic.java   
public void initialize(PatientShort patient, EpisodeofCareShortVo episodeOfCare, CareContextShortVo careContext, AdmissionDetailVo admissionDetail)
{
    form.getLocalContext().setPatient(patient);

    if (careContext != null)
        form.getLocalContext().setCareContext(domain.getCareContext(careContext));

    form.getLocalContext().setCurrentAdmissionDetail(admissionDetail);

    form.ccAdmittingConsultant().initialize(null, MedicGrade.CONS);
    form.ccAdmittingConsultant().isRequired(true);

    removeItemsFromReferredAdmittedComboBoxes();
    populateWardsCombo();
    open();
    updateControlsState();

}
项目:openMAXIMS    文件:PendingEmergencyWorklistImpl.java   
public ims.core.vo.MemberOfStaffLiteVoCollection listAcceptingConsultants(String name)
{
    if (name == null || name.length() == 0)
        return null;

    StringBuilder query = new StringBuilder("SELECT mos FROM Medic AS medic LEFT JOIN medic.mos AS mos LEFT JOIN medic.grade AS grade ");
    query.append(" WHERE ");
    query.append(" grade.id = :CONSULTANT AND (mos.name.upperSurname LIKE :SURNAME OR mos.name.upperForename LIKE :FORENAME) ");
    query.append(" ORDER BY mos.name.upperSurname, mos.name.upperForename ");

    ArrayList<String> paramNames = new ArrayList<String>();
    ArrayList<Object> paramValues = new ArrayList<Object>();

    paramNames.add("CONSULTANT");       paramValues.add(MedicGrade.CONS.getID());
    paramNames.add("SURNAME");          paramValues.add("%" + name.toUpperCase() + "%");
    paramNames.add("FORENAME");         paramValues.add("%" + name.toUpperCase() + "%");

    return MemberOfStaffLiteVoAssembler.createMemberOfStaffLiteVoCollectionFromMemberOfStaff(getDomainFactory().find(query.toString(), paramNames, paramValues));
}
项目: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    文件:PendingEmergencyAdmissionRequestImpl.java   
public HcpLiteVoCollection listConsultants(ServiceRefVo service, String name)
{
    if (name == null)
        return null;

    StringBuilder query = new StringBuilder("SELECT medic FROM Medic AS medic LEFT JOIN medic.mos AS mos LEFT JOIN medic.grade AS grade ");
    if (service != null) //WDEV-21422
    {
        query.append(" LEFT JOIN medic.serviceFunction as servf LEFT JOIN servf.service as service" );
    }

    query.append(" WHERE mos.name.upperSurname LIKE :NAME AND medic.isActive = 1 AND grade.id = :CONSULTANT" + (service != null ? " AND service.id = :SERVICE_ID" : "") +  
            " ORDER BY mos.name.upperSurname ");

    ArrayList<String> paramNames = new ArrayList<String>();
    ArrayList<Object> paramValues = new ArrayList<Object>();

    paramNames.add("NAME");                 paramValues.add(name.toUpperCase() + "%");
    paramNames.add("CONSULTANT");           paramValues.add(MedicGrade.CONS.getID());
    if (service != null)
    {
        paramNames.add("SERVICE_ID");           paramValues.add(service.getID_Service());
    }

    return HcpLiteVoAssembler.createHcpLiteVoCollectionFromHcp(getDomainFactory().find(query.toString(), paramNames, paramValues));
}
项目:openMAXIMS    文件:Logic.java   
private void initaliseAuthoringControls() 
{
    //Responsible HCP
//  If the logged on user is configured as a medic with medic grade of ‘Consultant’ and is a Responsible HCP, 
//  this field will default to the logged in user. If we cannot default based on logged in user, 
//  this will be blank and will search only those members of staff who are medics, 
//  with medic grade of ‘Consultant’ and are a Responsible HCP
    form.ccResponsibleHcp().initialize(null, MedicGrade.CONS);
    form.ccResponsibleHcp().initializeResponsibleHcp(MosType.MEDIC, true);
    form.ccResponsibleHcp().isRequired(true);

    form.ccSeenBy().isRequired(true);

//  If the logged on user is configured as a medic, this field will default to the logged in user. 
//  If we cannot default based on logged in user, this will be blank and will search only those members of staff who are medics.    
    form.ccSeenBy().initialize(MosType.MEDIC);

}
项目:openMAXIMS    文件:Logic.java   
private void qmbConsultantValueChanged()
{
    IMos consultant = form.lyr1().tabSearch().qmbConsultant().getValue();

    if (consultant != null)
    {
        MedicGradeVo medicGrade = domain.getMedicGrade(consultant.getIMosHcpId());

        if (medicGrade != null)
        {
            if (MedicGrade.CONS.equals(medicGrade.getGrade()))
                form.lyr1().tabSearch().cmbListType().setValue(ProfileListType.CONSULTANT);
            else if (MedicGrade.REG.equals(medicGrade.getGrade()))
                form.lyr1().tabSearch().cmbListType().setValue(ProfileListType.REGISTRAR);
            else if (MedicGrade.SHO.equals(medicGrade.getGrade()))
                form.lyr1().tabSearch().cmbListType().setValue(ProfileListType.SHO);
        }
    }
}
项目:openMAXIMS    文件:Logic.java   
public void initialize(PatientShort patient, EpisodeofCareShortVo episodeOfCare, CareContextShortVo careContext, AdmissionDetailVo admissionDetail)
{
    form.getLocalContext().setPatient(patient);

    if (careContext != null)
        form.getLocalContext().setCareContext(domain.getCareContext(careContext));

    form.getLocalContext().setCurrentAdmissionDetail(admissionDetail);

    form.ccAdmittingConsultant().initialize(null, MedicGrade.CONS);
    form.ccAdmittingConsultant().isRequired(true);

    removeItemsFromReferredAdmittedComboBoxes();
    populateWardsCombo();
    open();
    updateControlsState();

}
项目:openmaxims-linux    文件:Logic.java   
public void initialize(PatientShort patient, EpisodeofCareShortVo episodeOfCare, CareContextShortVo careContext, AdmissionDetailVo admissionDetail)
{
    form.getLocalContext().setPatient(patient);

    if (careContext != null)
        form.getLocalContext().setCareContext(domain.getCareContext(careContext));

    form.getLocalContext().setCurrentAdmissionDetail(admissionDetail);

    form.ccAdmittingConsultant().initialize(null, MedicGrade.CONS);
    form.ccAdmittingConsultant().isRequired(true);

    removeItemsFromReferredAdmittedComboBoxes();
    populateWardsCombo();
    open();
    updateControlsState();

}
项目:AvoinApotti    文件:Logic.java   
private void populateQmbConsultants()
{
    MedicLiteVo voMedic = new MedicLiteVo();
    // WDEV-8199
    HcpLiteVo currHcpUser = (HcpLiteVo) domain.getHcpLiteUser();

    if (domain.getHcpUser() instanceof MedicVo && MedicGrade.CONS.equals(((MedicVo) domain.getHcpUser()).getGrade()))
    {
        voMedic.setMos(currHcpUser.getMos());
        voMedic.setID_Hcp(currHcpUser.getID_Hcp());// wdev-10188
        form.qmbConsultant().newRow(voMedic, voMedic.getName().toString());
        form.qmbConsultant().setValue(voMedic);
    }
}
项目:AvoinApotti    文件:Logic.java   
private void prePopulateConsultantCombo()
{
    Object currUser = domain.getHcpUser();
    if (currUser instanceof MedicVo && MedicGrade.CONS.equals(((MedicVo)currUser).getGrade()))
    {
        HcpLiteVo hcpUser = (HcpLiteVo) domain.getHcpLiteUser();
        form.qmbConsultants().clear();
        form.qmbConsultants().newRow(hcpUser,hcpUser.getName()!= null ? hcpUser.getName().toString() : "");
        form.qmbConsultants().setValue(hcpUser);
    }

}
项目:AvoinApotti    文件:Logic.java   
private void populateQmbConsultants()
{
    MedicLiteVo voMedic = new MedicLiteVo();
    //WDEV-8199
    HcpLiteVo currHcpUser = (HcpLiteVo) domain.getHcpLiteUser();

    if (domain.getHcpUser() instanceof MedicVo && MedicGrade.CONS.equals(((MedicVo)domain.getHcpUser()).getGrade()))
    {
        voMedic.setMos(currHcpUser.getMos());
        voMedic.setID_Hcp(currHcpUser.getID_Hcp());//wdev-10188
        form.qmbConsultant().newRow(voMedic, voMedic.getName().toString());
        form.qmbConsultant().setValue(voMedic);
    }
}
项目:AvoinApotti    文件:Logic.java   
private boolean canUpdatePasId(MemberOfStaffShortVo voMos)
{
    if (!ConfigFlag.GEN.ALLOW_CONS_PAS_ID_UPDATE.getValue() && voMos.getHcpIsNotNull() && voMos.getHcp() instanceof MedicVo && ((MedicVo) voMos.getHcp()).getGradeIsNotNull() && ((MedicVo) voMos.getHcp()).getGrade().equals(MedicGrade.CONS))
    {
        return false;
    }
    return true;
}
项目:AvoinApotti    文件:MosAdminImpl.java   
public MemberOfStaffShortVoCollection listNCHDs()
{
    DomainFactory factory = getDomainFactory();
    List lstMedics =  factory.find("from Medic m where m.isActive = :bActive and m.grade != :medicGrade", new String[]{"medicGrade", "bActive"}, new Object[]{getDomLookup(MedicGrade.CONS), Boolean.TRUE});

    MemberOfStaffShortVoCollection voCollMos = new MemberOfStaffShortVoCollection();
    for (Iterator iter = lstMedics.iterator(); iter.hasNext();)
    {
        MemberOfStaff doMos = ((Medic) iter.next()).getMos();
        voCollMos.add(MemberOfStaffShortVoAssembler.create(doMos));
    }
    return voCollMos;       
}
项目:AvoinApotti    文件:ElectiveListManagementImpl.java   
public ims.core.vo.HcpLiteVoCollection listConsultants(String name)
{
    if(name == null || (name != null && name.length() == 0))
        throw new DomainRuntimeException("Can not search on null name.");

    StringBuffer hqlConditions = new StringBuffer();

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

    String hql = "select medic.mos.hcp from Medic as medic where medic.isActive = 1 and (medic.mos.name.upperSurname like :hcpSname or medic.mos.name.upperForename like :hcpFname) and medic.grade.id =:idMedicGrade";
    markers.add("hcpSname");
    values.add(name.toUpperCase() + "%");

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

    markers.add("idMedicGrade");
    values.add(getDomLookup(MedicGrade.CONS).getId());

    DomainFactory factory = getDomainFactory();
    List<?> list = factory.find((hql + hqlConditions.toString() + " order by medic.mos.name.upperSurname , medic.mos.name.upperForename asc").toString(), markers, values,400);

    if (list != null && list.size() > 0)
        return HcpLiteVoAssembler.createHcpLiteVoCollectionFromHcp(list);

    return null;
}
项目:AvoinApotti    文件:Logic.java   
private void initialize()
{
    form.grpFilterSpec().setEnabled(grpFilterSpecEnumeration.rdoAll,form.getGlobalContext().Clinical.getSurgicalAuditActualPlannedProcedure()==null);
    form.grpFilterSpec().setEnabled(grpFilterSpecEnumeration.rdoSpecialty,form.getGlobalContext().Clinical.getSurgicalAuditActualPlannedProcedure()==null);

    form.ccProcedure().setCodingItemType(CodingItemType.PROCEDURE);
    form.ccProcedure().setSpecialty(getSpecialty());
    form.ccProcedure().setIsRequired(true);
    form.ccProcedure().setParentEditing(true);

    form.grpFilterSpec().setValue(grpFilterSpecEnumeration.rdoSpecialty);
    form.ccProcedure().setHotlist(new Boolean(true));

    form.ccProcedure().setEnabled(true);

    //form.ccSurgeon().initialize(MosType.MEDIC);
    form.ccConsultantName().initialize(null,MedicGrade.CONS);
    populateSurgeonCombo();

    //default consultant to the admitting consultant from Care Context
    HcpLiteVo careContextHcp = form.getGlobalContext().Core.getEpisodeofCareShort().getResponsibleHCP();

    if (careContextHcp!=null && careContextHcp.getHcpType().equals(HcpDisType.MEDICAL)) //WDEV-15676
    {
        MedicLiteVo tempMedic = domain.getMedicLiteVo(careContextHcp);
        form.ccConsultantName().setValue(tempMedic);
    }

    //form.ccSurgeon().isRequired(true);
    form.ccConsultantName().isRequired(true);
    form.txtdummyStatus().setRequired(true);        //wdev-15739
}
项目:openMAXIMS    文件:Logic.java   
private void populateQmbConsultants()
{
    MedicLiteVo voMedic = new MedicLiteVo();
    // WDEV-8199
    HcpLiteVo currHcpUser = (HcpLiteVo) domain.getHcpLiteUser();

    if (domain.getHcpUser() instanceof MedicVo && MedicGrade.CONS.equals(((MedicVo) domain.getHcpUser()).getGrade()))
    {
        voMedic.setMos(currHcpUser.getMos());
        voMedic.setID_Hcp(currHcpUser.getID_Hcp());// wdev-10188
        form.qmbConsultant().newRow(voMedic, voMedic.getName().toString());
        form.qmbConsultant().setValue(voMedic);
    }
}
项目:openMAXIMS    文件:Logic.java   
public void initialize(HcpDisType medicType, MedicGrade medicGrade)
{
    clearSpecificSearchContexts();
    form.getLocalContext().setMosDiscipline(medicType);
    form.getLocalContext().setMedicGrade(medicGrade);

}
项目:openMAXIMS    文件:Logic.java   
public void initializeConsultantResponsibleHcp(MosType mosType, MedicGrade medicGrade, Boolean isResponsibleHcp)
{
    clearSpecificSearchContexts();
    form.getLocalContext().setMOSSearchType(mosType);
    form.getLocalContext().setMedicGrade(medicGrade);
    form.getLocalContext().setIsResponsibleHcp(isResponsibleHcp);
}
项目:openMAXIMS    文件:Logic.java   
public void initializeMedic(HcpDisType medicType, MedicGrade medicGrade)
{
    clearSpecificSearchContexts();
    form.getLocalContext().setMosDiscipline(medicType);
    form.getLocalContext().setMedicGrade(medicGrade);
    form.getLocalContext().setIsMedic(true);
}
项目:openMAXIMS    文件:Logic.java   
private void prePopulateConsultantCombo()
{
    Object currUser = domain.getHcpUser();
    if (currUser instanceof MedicVo && MedicGrade.CONS.equals(((MedicVo)currUser).getGrade()))
    {
        HcpLiteVo hcpUser = (HcpLiteVo) domain.getHcpLiteUser();
        form.qmbConsultants().clear();
        form.qmbConsultants().newRow(hcpUser,hcpUser.getName()!= null ? hcpUser.getName().toString() : "");
        form.qmbConsultants().setValue(hcpUser);
    }

}
项目:openMAXIMS    文件:Logic.java   
private void populateQmbConsultants()
{
    MedicLiteVo voMedic = new MedicLiteVo();
    //WDEV-8199
    HcpLiteVo currHcpUser = (HcpLiteVo) domain.getHcpLiteUser();

    if (domain.getHcpUser() instanceof MedicVo && MedicGrade.CONS.equals(((MedicVo)domain.getHcpUser()).getGrade()))
    {
        voMedic.setMos(currHcpUser.getMos());
        voMedic.setID_Hcp(currHcpUser.getID_Hcp());//wdev-10188
        form.qmbConsultant().newRow(voMedic, voMedic.getName().toString());
        form.qmbConsultant().setValue(voMedic);
    }
}
项目:openMAXIMS    文件:AdmitToWardImpl.java   
public MedicLiteVoCollection listConsultants(ServiceRefVo service, String name)
{
    if (service == null || service.getID_Service() == null)
        return null;

    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(" LEFT JOIN medic.serviceFunction AS servFunction ");
    query.append(" LEFT JOIN servFunction.service AS service ");
    query.append(" WHERE ");
    query.append(" service.id = :SERVICE_ID AND medicGrade.id = :CONSULTANT ");

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

    if (name != null && name.length() > 0)
    {
        query.append(" AND (mos.name.upperSurname LIKE :SURNAME OR 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    文件:EASSummaryImpl.java   
public Boolean isConsultant(HcpRefVo hcp) 
{
    if(hcp == null || hcp.getID_Hcp() == null)
        return false;

    String query = "select m from Medic as m left join m.grade as g where m.id = :MedicId and g.id = :Grade";
    DomainFactory factory = getDomainFactory();

    List<?> list = factory.find(query, new String[] {"MedicId", "Grade"}, new Object[] {hcp.getID_Hcp(), MedicGrade.CONS.getID()});

    if(list != null && list.size() > 0)
        return true;

    return false;
}
项目:openMAXIMS    文件:Logic.java   
private boolean canUpdatePasId(MemberOfStaffShortVo voMos)
{
    if (!ConfigFlag.GEN.ALLOW_CONS_PAS_ID_UPDATE.getValue() && voMos.getHcpIsNotNull() && voMos.getHcp() instanceof MedicVo && ((MedicVo) voMos.getHcp()).getGradeIsNotNull() && ((MedicVo) voMos.getHcp()).getGrade().equals(MedicGrade.CONS))
    {
        return false;
    }
    return true;
}
项目:openMAXIMS    文件:MosAdminImpl.java   
public MemberOfStaffShortVoCollection listNCHDs()
{
    DomainFactory factory = getDomainFactory();
    List lstMedics =  factory.find("from Medic m where m.isActive = :bActive and m.grade != :medicGrade", new String[]{"medicGrade", "bActive"}, new Object[]{getDomLookup(MedicGrade.CONS), Boolean.TRUE});

    MemberOfStaffShortVoCollection voCollMos = new MemberOfStaffShortVoCollection();
    for (Iterator iter = lstMedics.iterator(); iter.hasNext();)
    {
        MemberOfStaff doMos = ((Medic) iter.next()).getMos();
        voCollMos.add(MemberOfStaffShortVoAssembler.create(doMos));
    }
    return voCollMos;       
}
项目:openMAXIMS    文件:ElectiveListManagementImpl.java   
public ims.core.vo.HcpLiteVoCollection listConsultants(String name)
{
    if(name == null || (name != null && name.length() == 0))
        throw new DomainRuntimeException("Can not search on null name.");

    StringBuffer hqlConditions = new StringBuffer();

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

    String hql = "select medic.mos.hcp from Medic as medic where medic.isActive = 1 and (medic.mos.name.upperSurname like :hcpSname or medic.mos.name.upperForename like :hcpFname) and medic.grade.id =:idMedicGrade";
    markers.add("hcpSname");
    values.add(name.toUpperCase() + "%");

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

    markers.add("idMedicGrade");
    values.add(getDomLookup(MedicGrade.CONS).getId());

    DomainFactory factory = getDomainFactory();
    List<?> list = factory.find((hql + hqlConditions.toString() + " order by medic.mos.name.upperSurname , medic.mos.name.upperForename asc").toString(), markers, values,400);

    if (list != null && list.size() > 0)
        return HcpLiteVoAssembler.createHcpLiteVoCollectionFromHcp(list);

    return null;
}
项目:openMAXIMS    文件:Logic.java   
private void initialize()
{
    form.grpFilterSpec().setEnabled(grpFilterSpecEnumeration.rdoAll,form.getGlobalContext().Clinical.getSurgicalAuditActualPlannedProcedure()==null);
    form.grpFilterSpec().setEnabled(grpFilterSpecEnumeration.rdoSpecialty,form.getGlobalContext().Clinical.getSurgicalAuditActualPlannedProcedure()==null);

    form.ccProcedure().setCodingItemType(CodingItemType.PROCEDURE);
    form.ccProcedure().setSpecialty(getSpecialty());
    form.ccProcedure().setIsRequired(true);
    form.ccProcedure().setParentEditing(true);

    form.grpFilterSpec().setValue(grpFilterSpecEnumeration.rdoSpecialty);
    form.ccProcedure().setHotlist(new Boolean(true));

    form.ccProcedure().setEnabled(true);

    //form.ccSurgeon().initialize(MosType.MEDIC);
    form.ccConsultantName().initialize(null,MedicGrade.CONS);
    populateSurgeonCombo();

    //default consultant to the admitting consultant from Care Context
    HcpLiteVo careContextHcp = form.getGlobalContext().Core.getEpisodeofCareShort().getResponsibleHCP();

    if (careContextHcp!=null && careContextHcp.getHcpType().equals(HcpDisType.MEDICAL)) //WDEV-15676
    {
        MedicLiteVo tempMedic = domain.getMedicLiteVo(careContextHcp);
        form.ccConsultantName().setValue(tempMedic);
    }

    //form.ccSurgeon().isRequired(true);
    form.ccConsultantName().isRequired(true);
    form.txtdummyStatus().setRequired(true);        //wdev-15739
}
项目:openMAXIMS    文件:Logic.java   
private void populateQmbConsultants()
{
    MedicLiteVo voMedic = new MedicLiteVo();
    // WDEV-8199
    HcpLiteVo currHcpUser = (HcpLiteVo) domain.getHcpLiteUser();

    if (domain.getHcpUser() instanceof MedicVo && MedicGrade.CONS.equals(((MedicVo) domain.getHcpUser()).getGrade()))
    {
        voMedic.setMos(currHcpUser.getMos());
        voMedic.setID_Hcp(currHcpUser.getID_Hcp());// wdev-10188
        form.qmbConsultant().newRow(voMedic, voMedic.getName().toString());
        form.qmbConsultant().setValue(voMedic);
    }
}
项目:openMAXIMS    文件:Logic.java   
private void prePopulateConsultantCombo()
{
    Object currUser = domain.getHcpUser();
    if (currUser instanceof MedicVo && MedicGrade.CONS.equals(((MedicVo)currUser).getGrade()))
    {
        HcpLiteVo hcpUser = (HcpLiteVo) domain.getHcpLiteUser();
        form.qmbConsultants().clear();
        form.qmbConsultants().newRow(hcpUser,hcpUser.getName()!= null ? hcpUser.getName().toString() : "");
        form.qmbConsultants().setValue(hcpUser);
    }

}
项目:openMAXIMS    文件:Logic.java   
private void populateQmbConsultants()
{
    MedicLiteVo voMedic = new MedicLiteVo();
    //WDEV-8199
    HcpLiteVo currHcpUser = (HcpLiteVo) domain.getHcpLiteUser();

    if (domain.getHcpUser() instanceof MedicVo && MedicGrade.CONS.equals(((MedicVo)domain.getHcpUser()).getGrade()))
    {
        voMedic.setMos(currHcpUser.getMos());
        voMedic.setID_Hcp(currHcpUser.getID_Hcp());//wdev-10188
        form.qmbConsultant().newRow(voMedic, voMedic.getName().toString());
        form.qmbConsultant().setValue(voMedic);
    }
}
项目:openMAXIMS    文件:Logic.java   
private boolean canUpdatePasId(MemberOfStaffShortVo voMos)
{
    if (!ConfigFlag.GEN.ALLOW_CONS_PAS_ID_UPDATE.getValue() && voMos.getHcpIsNotNull() && voMos.getHcp() instanceof MedicVo && ((MedicVo) voMos.getHcp()).getGradeIsNotNull() && ((MedicVo) voMos.getHcp()).getGrade().equals(MedicGrade.CONS))
    {
        return false;
    }
    return true;
}
项目:openMAXIMS    文件:MosAdminImpl.java   
public MemberOfStaffShortVoCollection listNCHDs()
{
    DomainFactory factory = getDomainFactory();
    List lstMedics =  factory.find("from Medic m where m.isActive = :bActive and m.grade != :medicGrade", new String[]{"medicGrade", "bActive"}, new Object[]{getDomLookup(MedicGrade.CONS), Boolean.TRUE});

    MemberOfStaffShortVoCollection voCollMos = new MemberOfStaffShortVoCollection();
    for (Iterator iter = lstMedics.iterator(); iter.hasNext();)
    {
        MemberOfStaff doMos = ((Medic) iter.next()).getMos();
        voCollMos.add(MemberOfStaffShortVoAssembler.create(doMos));
    }
    return voCollMos;       
}
项目:openMAXIMS    文件:ElectiveListManagementImpl.java   
public ims.core.vo.HcpLiteVoCollection listConsultants(String name)
{
    if(name == null || (name != null && name.length() == 0))
        throw new DomainRuntimeException("Can not search on null name.");

    StringBuffer hqlConditions = new StringBuffer();

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

    String hql = "select medic.mos.hcp from Medic as medic where medic.isActive = 1 and (medic.mos.name.upperSurname like :hcpSname or medic.mos.name.upperForename like :hcpFname) and medic.grade.id =:idMedicGrade";
    markers.add("hcpSname");
    values.add(name.toUpperCase() + "%");

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

    markers.add("idMedicGrade");
    values.add(getDomLookup(MedicGrade.CONS).getId());

    DomainFactory factory = getDomainFactory();
    List<?> list = factory.find((hql + hqlConditions.toString() + " order by medic.mos.name.upperSurname , medic.mos.name.upperForename asc").toString(), markers, values,400);

    if (list != null && list.size() > 0)
        return HcpLiteVoAssembler.createHcpLiteVoCollectionFromHcp(list);

    return null;
}
项目:openMAXIMS    文件:Logic.java   
private void initialize()
{
    form.grpFilterSpec().setEnabled(grpFilterSpecEnumeration.rdoAll,form.getGlobalContext().Clinical.getSurgicalAuditActualPlannedProcedure()==null);
    form.grpFilterSpec().setEnabled(grpFilterSpecEnumeration.rdoSpecialty,form.getGlobalContext().Clinical.getSurgicalAuditActualPlannedProcedure()==null);

    form.ccProcedure().setCodingItemType(CodingItemType.PROCEDURE);
    form.ccProcedure().setSpecialty(getSpecialty());
    form.ccProcedure().setIsRequired(true);
    form.ccProcedure().setParentEditing(true);

    form.grpFilterSpec().setValue(grpFilterSpecEnumeration.rdoSpecialty);
    form.ccProcedure().setHotlist(new Boolean(true));

    form.ccProcedure().setEnabled(true);

    //form.ccSurgeon().initialize(MosType.MEDIC);
    form.ccConsultantName().initialize(null,MedicGrade.CONS);
    populateSurgeonCombo();

    //default consultant to the admitting consultant from Care Context
    HcpLiteVo careContextHcp = form.getGlobalContext().Core.getEpisodeofCareShort().getResponsibleHCP();

    if (careContextHcp!=null && careContextHcp.getHcpType().equals(HcpDisType.MEDICAL)) //WDEV-15676
    {
        MedicLiteVo tempMedic = domain.getMedicLiteVo(careContextHcp);
        form.ccConsultantName().setValue(tempMedic);
    }

    //form.ccSurgeon().isRequired(true);
    form.ccConsultantName().isRequired(true);
    form.txtdummyStatus().setRequired(true);        //wdev-15739
}
项目:openmaxims-linux    文件:Logic.java   
private void populateQmbConsultants()
{
    MedicLiteVo voMedic = new MedicLiteVo();
    // WDEV-8199
    HcpLiteVo currHcpUser = (HcpLiteVo) domain.getHcpLiteUser();

    if (domain.getHcpUser() instanceof MedicVo && MedicGrade.CONS.equals(((MedicVo) domain.getHcpUser()).getGrade()))
    {
        voMedic.setMos(currHcpUser.getMos());
        voMedic.setID_Hcp(currHcpUser.getID_Hcp());// wdev-10188
        form.qmbConsultant().newRow(voMedic, voMedic.getName().toString());
        form.qmbConsultant().setValue(voMedic);
    }
}
项目:openmaxims-linux    文件:Logic.java   
private void prePopulateConsultantCombo()
{
    Object currUser = domain.getHcpUser();
    if (currUser instanceof MedicVo && MedicGrade.CONS.equals(((MedicVo)currUser).getGrade()))
    {
        HcpLiteVo hcpUser = (HcpLiteVo) domain.getHcpLiteUser();
        form.qmbConsultants().clear();
        form.qmbConsultants().newRow(hcpUser,hcpUser.getName()!= null ? hcpUser.getName().toString() : "");
        form.qmbConsultants().setValue(hcpUser);
    }

}
项目:openmaxims-linux    文件:Logic.java   
private void populateQmbConsultants()
{
    MedicLiteVo voMedic = new MedicLiteVo();
    //WDEV-8199
    HcpLiteVo currHcpUser = (HcpLiteVo) domain.getHcpLiteUser();

    if (domain.getHcpUser() instanceof MedicVo && MedicGrade.CONS.equals(((MedicVo)domain.getHcpUser()).getGrade()))
    {
        voMedic.setMos(currHcpUser.getMos());
        voMedic.setID_Hcp(currHcpUser.getID_Hcp());//wdev-10188
        form.qmbConsultant().newRow(voMedic, voMedic.getName().toString());
        form.qmbConsultant().setValue(voMedic);
    }
}
项目:openmaxims-linux    文件:Logic.java   
private boolean canUpdatePasId(MemberOfStaffShortVo voMos)
{
    if (!ConfigFlag.GEN.ALLOW_CONS_PAS_ID_UPDATE.getValue() && voMos.getHcpIsNotNull() && voMos.getHcp() instanceof MedicVo && ((MedicVo) voMos.getHcp()).getGradeIsNotNull() && ((MedicVo) voMos.getHcp()).getGrade().equals(MedicGrade.CONS))
    {
        return false;
    }
    return true;
}
项目:openmaxims-linux    文件:MosAdminImpl.java   
public MemberOfStaffShortVoCollection listNCHDs()
{
    DomainFactory factory = getDomainFactory();
    List lstMedics =  factory.find("from Medic m where m.isActive = :bActive and m.grade != :medicGrade", new String[]{"medicGrade", "bActive"}, new Object[]{getDomLookup(MedicGrade.CONS), Boolean.TRUE});

    MemberOfStaffShortVoCollection voCollMos = new MemberOfStaffShortVoCollection();
    for (Iterator iter = lstMedics.iterator(); iter.hasNext();)
    {
        MemberOfStaff doMos = ((Medic) iter.next()).getMos();
        voCollMos.add(MemberOfStaffShortVoAssembler.create(doMos));
    }
    return voCollMos;       
}