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

项目:AvoinApotti    文件:Logic.java   
private void updateControlsState()
{
    boolean editMode = form.getMode().equals(FormMode.EDIT);
    boolean enable   = canEnableControls();

    form.txtName().setEnabled(enable && isNameTextBoxEnableable());
    form.txtDescription().setEnabled(enable);
    form.cmbActiveStatus().setEnabled(editMode);
    //WDEV-1751 - Category should be updatable
    form.cmbCategory().setEnabled(editMode);
    form.chkIsMultirole().setEnabled(enable);
    form.chkFlatView().setEnabled(enable && !isDpp());
    if(editMode)
        form.lyrTabs().tabAssessments().dyngrdDetails().setReadOnly(isNonScoringAssessment()?false:!enable);
    else
        form.lyrTabs().tabAssessments().dyngrdDetails().setReadOnly(true);
    form.chkMultipleGroup().setEnabled(enable && !isDpp());
    form.chkCustomWidth().setEnabled(enable);
    form.intCustomWidth().setEnabled(enable && form.chkCustomWidth().getValue());
    if(isNonScoringAssessment())
    {
        form.lblScoringMethod().setVisible(false);
        form.cmbScoringMethod().setVisible(false);
    }
    else
    {
        form.lblScoringMethod().setVisible(true);
        form.cmbScoringMethod().setVisible(true);
        form.cmbScoringMethod().setEnabled(enable);
    }

    form.chkCanCopy().setEnabled(enable);
    form.cmbCopyLast().setEnabled(enable && form.chkCanCopy().getValue());
    form.chkStorePrintedAssessment().setEnabled(form.getMode().equals(FormMode.EDIT) && !isStatusInactive()); //WDEV-16982
    form.lyrTabs().tabTaxonomy().ccTaxonomy().setComponentMode(form.getMode());

    //WDEV-14123
    showHideServiceTab(form.cmbCategory().getValue() != null && form.cmbCategory().getValue().equals(UserAssessmentCategory.SAFETY_QUESTIONNAIRE));
}
项目:AvoinApotti    文件:UserAssessmentsImpl.java   
public UserAssessmentShortVoCollection listAssessments(String name, UserAssessmentCategory category, UserDefinedAssessmentType assessmentType)
{
    UserDefinedAssessmentTypeCollection lkpColl = new UserDefinedAssessmentTypeCollection();
    if (assessmentType != null)
        lkpColl.add(assessmentType);
    return listAssessments(name, category, lkpColl, null);
}
项目:openMAXIMS    文件:CancerReferralImpl.java   
/**
* Function will retrieve the configuration of the first active UserAssessment of type Referral Assessment
*/
public ims.assessment.vo.UserAssessmentVo getReferralAssessment()
{
    DomainFactory factory = getDomainFactory();

    String query = "from UserAssessment as ua where ua.activeStatus.id = :status and ua.category.id = :category and ua.isRIE is null order by ua.systemInformation.creationDateTime desc";
    DomainObject doUserAssessment = factory.findFirst(query, new String[] {"status", "category"}, new Object[] {PreActiveActiveInactiveStatus.ACTIVE.getID(), UserAssessmentCategory.REFERRAL_ASSESSMENT.getID()});

    if(doUserAssessment == null)
        return null;

    return UserAssessmentVoAssembler.create((UserAssessment) doUserAssessment);
}
项目:openMAXIMS    文件:Logic.java   
private void updateControlsState()
{
    boolean editMode = form.getMode().equals(FormMode.EDIT);
    boolean enable   = canEnableControls();

    form.txtName().setEnabled(enable && isNameTextBoxEnableable());
    form.txtDescription().setEnabled(enable);
    form.cmbActiveStatus().setEnabled(editMode);
    //WDEV-1751 - Category should be updatable
    form.cmbCategory().setEnabled(editMode);
    form.chkIsMultirole().setEnabled(enable);
    form.chkFlatView().setEnabled(enable && !isDpp());
    if(editMode)
        form.lyrTabs().tabAssessments().dyngrdDetails().setReadOnly(isNonScoringAssessment()?false:!enable);
    else
        form.lyrTabs().tabAssessments().dyngrdDetails().setReadOnly(true);
    form.chkMultipleGroup().setEnabled(enable && !isDpp());
    form.chkCustomWidth().setEnabled(enable);
    form.intCustomWidth().setEnabled(enable && form.chkCustomWidth().getValue());
    if(isNonScoringAssessment())
    {
        form.lblScoringMethod().setVisible(false);
        form.cmbScoringMethod().setVisible(false);
    }
    else
    {
        form.lblScoringMethod().setVisible(true);
        form.cmbScoringMethod().setVisible(true);
        form.cmbScoringMethod().setEnabled(enable);
    }

    form.chkCanCopy().setEnabled(form.getMode().equals(FormMode.EDIT) && !isStatusInactive()); //WDEV-18752 
    form.cmbCopyLast().setEnabled(form.getMode().equals(FormMode.EDIT) && !isStatusInactive() && form.chkCanCopy().getValue()); //WDEV-18752 
    form.chkStorePrintedAssessment().setEnabled(form.getMode().equals(FormMode.EDIT) && !isStatusInactive()); //WDEV-16982
    form.lyrTabs().tabTaxonomy().ccTaxonomy().setComponentMode(form.getMode());

    //WDEV-14123
    showHideServiceTab(form.cmbCategory().getValue() != null && form.cmbCategory().getValue().equals(UserAssessmentCategory.SAFETY_QUESTIONNAIRE));
}
项目:openMAXIMS    文件:UserAssessmentsImpl.java   
public UserAssessmentShortVoCollection listAssessments(String name, UserAssessmentCategory category, UserDefinedAssessmentType assessmentType)
{
    UserDefinedAssessmentTypeCollection lkpColl = new UserDefinedAssessmentTypeCollection();
    if (assessmentType != null)
        lkpColl.add(assessmentType);
    return listAssessments(name, category, lkpColl, null);
}
项目:openMAXIMS    文件:Logic.java   
private void updateControlsState()
{
    boolean editMode = form.getMode().equals(FormMode.EDIT);
    boolean enable   = canEnableControls();

    form.txtName().setEnabled(enable && isNameTextBoxEnableable());
    form.txtDescription().setEnabled(enable);
    form.cmbActiveStatus().setEnabled(editMode);
    //WDEV-1751 - Category should be updatable
    form.cmbCategory().setEnabled(editMode);
    form.chkIsMultirole().setEnabled(enable);
    form.chkFlatView().setEnabled(enable && !isDpp());
    if(editMode)
        form.lyrTabs().tabAssessments().dyngrdDetails().setReadOnly(isNonScoringAssessment()?false:!enable);
    else
        form.lyrTabs().tabAssessments().dyngrdDetails().setReadOnly(true);
    form.chkMultipleGroup().setEnabled(enable && !isDpp());
    form.chkCustomWidth().setEnabled(enable);
    form.intCustomWidth().setEnabled(enable && form.chkCustomWidth().getValue());
    if(isNonScoringAssessment())
    {
        form.lblScoringMethod().setVisible(false);
        form.cmbScoringMethod().setVisible(false);
    }
    else
    {
        form.lblScoringMethod().setVisible(true);
        form.cmbScoringMethod().setVisible(true);
        form.cmbScoringMethod().setEnabled(enable);
    }

    form.chkCanCopy().setEnabled(enable);
    form.cmbCopyLast().setEnabled(enable && form.chkCanCopy().getValue());
    form.chkStorePrintedAssessment().setEnabled(form.getMode().equals(FormMode.EDIT) && !isStatusInactive()); //WDEV-16982
    form.lyrTabs().tabTaxonomy().ccTaxonomy().setComponentMode(form.getMode());

    //WDEV-14123
    showHideServiceTab(form.cmbCategory().getValue() != null && form.cmbCategory().getValue().equals(UserAssessmentCategory.SAFETY_QUESTIONNAIRE));
}
项目:openMAXIMS    文件:UserAssessmentsImpl.java   
public UserAssessmentShortVoCollection listAssessments(String name, UserAssessmentCategory category, UserDefinedAssessmentType assessmentType)
{
    UserDefinedAssessmentTypeCollection lkpColl = new UserDefinedAssessmentTypeCollection();
    if (assessmentType != null)
        lkpColl.add(assessmentType);
    return listAssessments(name, category, lkpColl, null);
}
项目:openmaxims-linux    文件:Logic.java   
private void updateControlsState()
{
    boolean editMode = form.getMode().equals(FormMode.EDIT);
    boolean enable   = canEnableControls();

    form.txtName().setEnabled(enable && isNameTextBoxEnableable());
    form.txtDescription().setEnabled(enable);
    form.cmbActiveStatus().setEnabled(editMode);
    //WDEV-1751 - Category should be updatable
    form.cmbCategory().setEnabled(editMode);
    form.chkIsMultirole().setEnabled(enable);
    form.chkFlatView().setEnabled(enable && !isDpp());
    if(editMode)
        form.lyrTabs().tabAssessments().dyngrdDetails().setReadOnly(isNonScoringAssessment()?false:!enable);
    else
        form.lyrTabs().tabAssessments().dyngrdDetails().setReadOnly(true);
    form.chkMultipleGroup().setEnabled(enable && !isDpp());
    form.chkCustomWidth().setEnabled(enable);
    form.intCustomWidth().setEnabled(enable && form.chkCustomWidth().getValue());
    if(isNonScoringAssessment())
    {
        form.lblScoringMethod().setVisible(false);
        form.cmbScoringMethod().setVisible(false);
    }
    else
    {
        form.lblScoringMethod().setVisible(true);
        form.cmbScoringMethod().setVisible(true);
        form.cmbScoringMethod().setEnabled(enable);
    }

    form.chkCanCopy().setEnabled(enable);
    form.cmbCopyLast().setEnabled(enable && form.chkCanCopy().getValue());
    form.chkStorePrintedAssessment().setEnabled(form.getMode().equals(FormMode.EDIT) && !isStatusInactive()); //WDEV-16982
    form.lyrTabs().tabTaxonomy().ccTaxonomy().setComponentMode(form.getMode());

    //WDEV-14123
    showHideServiceTab(form.cmbCategory().getValue() != null && form.cmbCategory().getValue().equals(UserAssessmentCategory.SAFETY_QUESTIONNAIRE));
}
项目:openmaxims-linux    文件:UserAssessmentsImpl.java   
public UserAssessmentShortVoCollection listAssessments(String name, UserAssessmentCategory category, UserDefinedAssessmentType assessmentType)
{
    UserDefinedAssessmentTypeCollection lkpColl = new UserDefinedAssessmentTypeCollection();
    if (assessmentType != null)
        lkpColl.add(assessmentType);
    return listAssessments(name, category, lkpColl, null);
}
项目:AvoinApotti    文件:ManchesterTreatmentProtocolAdminImpl.java   
public UserAssessmentShortVoCollection listAssessments(String name, UserAssessmentCategory category, UserDefinedAssessmentType assessmentType) 
{
    DomainFactory factory = getDomainFactory();
    StringBuffer hql = new StringBuffer(" ");
    String query = "from UserAssessment u ";
    ArrayList markers = new ArrayList();
    ArrayList values = new ArrayList();
    String andStr = " ";

    if (name != null && name.length() > 0)
    {
        hql.append(andStr + " upper(u.name) like :name");
        markers.add("name");
        values.add(name.toUpperCase());
        andStr = " and ";

    }
    if (category != null)
    {
        hql.append(andStr + " u.category.id =:category");
        markers.add("category");
        values.add(new Integer(category.getId()));
        andStr = " and ";
    }

    hql.append(andStr);
    hql.append(" u.assessmentType.id =:assessmentType");
    markers.add("assessmentType");
    values.add(assessmentType.getID());
    andStr = " or ";

    hql.append(andStr);
    hql.append(" u.activeStatus =:isactive");
    markers.add("isactive");
    values.add(getDomLookup(PreActiveActiveInactiveStatus.ACTIVE)); 

    hql.append(")");    

    if (markers.size() > 0)
        query += " where ";

    query += hql.toString();

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

    return UserAssessmentShortVoAssembler.createUserAssessmentShortVoCollectionFromUserAssessment(list).sort();
}
项目:AvoinApotti    文件:UserAssessmentsImpl.java   
public UserAssessmentShortVoCollection listAssessments(String name, ims.core.vo.lookups.UserAssessmentCategory category, UserDefinedAssessmentTypeCollection assessmentTypeColl, ims.core.vo.lookups.PreActiveActiveInactiveStatus status)
{
    DomainFactory factory = getDomainFactory();
    StringBuffer hql = new StringBuffer(" ");
    String query = "from UserAssessment u ";
    ArrayList markers = new ArrayList();
    ArrayList values = new ArrayList();
    String andStr = " ";

    if (name != null && name.length() > 0)
    {
        hql.append(andStr + " upper(u.name) like :name");
        markers.add("name");
        values.add(name.toUpperCase());
        andStr = " and ";

    }
    if (category != null)
    {
        hql.append(andStr + " u.category.id =:category");
        markers.add("category");
        values.add(new Integer(category.getId()));
        andStr = " and ";
    }

    if (status != null)
    {
        hql.append(andStr + " u.activeStatus =:status");
        markers.add("status");
        values.add(getDomLookup(status));
        andStr = " and ";
    }

    if (assessmentTypeColl != null)
    {
        int size = assessmentTypeColl.size();
        for (int i = 0; i < size; i++)
        {
            UserDefinedAssessmentType assType = assessmentTypeColl.get(i);
            hql.append(andStr);
            if (i == 0)
                hql.append(" (");
            hql.append(" u.assessmentType.id =:assessmentType" + Integer.toString(i));
            markers.add("assessmentType" + i);
            values.add(new Integer(assType.getId()));
            andStr = " or ";

            if (i == (size - 1))
                hql.append(")");    
        }
    }

    if (markers.size() > 0)
        query += " where ";

    query += hql.toString();

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

    return UserAssessmentShortVoAssembler.createUserAssessmentShortVoCollectionFromUserAssessment(list).sort();
}
项目:AvoinApotti    文件:ClinicalNoteDrawingImpl.java   
public UserAssessmentShortVoCollection listAssessments(String name, UserAssessmentCategory category, UserDefinedAssessmentTypeCollection assessmentType, PreActiveActiveInactiveStatus status) 
{
    UserAssessments impl = (UserAssessments)getDomainImpl(UserAssessmentsImpl.class);
    return impl.listAssessments(name,category,assessmentType,status);
}
项目:openMAXIMS    文件:UserAssessmentsImpl.java   
public UserAssessmentShortVoCollection listAssessments(String name, ims.core.vo.lookups.UserAssessmentCategory category, UserDefinedAssessmentTypeCollection assessmentTypeColl, ims.core.vo.lookups.PreActiveActiveInactiveStatus status)
{
    DomainFactory factory = getDomainFactory();
    StringBuffer hql = new StringBuffer(" ");
    String query = "from UserAssessment u ";
    ArrayList markers = new ArrayList();
    ArrayList values = new ArrayList();
    String andStr = " ";

    if (name != null && name.length() > 0)
    {
        hql.append(andStr + " upper(u.name) like :name");
        markers.add("name");
        values.add(name.toUpperCase());
        andStr = " and ";

    }
    if (category != null)
    {
        hql.append(andStr + " u.category.id =:category");
        markers.add("category");
        values.add(new Integer(category.getId()));
        andStr = " and ";
    }

    if (status != null)
    {
        hql.append(andStr + " u.activeStatus =:status");
        markers.add("status");
        values.add(getDomLookup(status));
        andStr = " and ";
    }

    if (assessmentTypeColl != null)
    {
        int size = assessmentTypeColl.size();
        for (int i = 0; i < size; i++)
        {
            UserDefinedAssessmentType assType = assessmentTypeColl.get(i);
            hql.append(andStr);
            if (i == 0)
                hql.append(" (");
            hql.append(" u.assessmentType.id =:assessmentType" + Integer.toString(i));
            markers.add("assessmentType" + i);
            values.add(new Integer(assType.getId()));
            andStr = " or ";

            if (i == (size - 1))
                hql.append(")");    
        }
    }

    if (markers.size() > 0)
        query += " where ";

    query += hql.toString();

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

    return UserAssessmentShortVoAssembler.createUserAssessmentShortVoCollectionFromUserAssessment(list).sort();
}
项目:openMAXIMS    文件:ClinicalNoteDrawingImpl.java   
public UserAssessmentShortVoCollection listAssessments(String name, UserAssessmentCategory category, UserDefinedAssessmentTypeCollection assessmentType, PreActiveActiveInactiveStatus status) 
{
    UserAssessments impl = (UserAssessments)getDomainImpl(UserAssessmentsImpl.class);
    return impl.listAssessments(name,category,assessmentType,status);
}
项目:openMAXIMS    文件:ManchesterTreatmentProtocolAdminImpl.java   
public UserAssessmentShortVoCollection listAssessments(String name, UserAssessmentCategory category, UserDefinedAssessmentType assessmentType) 
{
    DomainFactory factory = getDomainFactory();
    StringBuffer hql = new StringBuffer(" ");
    String query = "from UserAssessment u ";
    ArrayList markers = new ArrayList();
    ArrayList values = new ArrayList();
    String andStr = " ";

    if (name != null && name.length() > 0)
    {
        hql.append(andStr + " upper(u.name) like :name");
        markers.add("name");
        values.add(name.toUpperCase());
        andStr = " and ";

    }
    if (category != null)
    {
        hql.append(andStr + " u.category.id =:category");
        markers.add("category");
        values.add(new Integer(category.getId()));
        andStr = " and ";
    }

    hql.append(andStr);
    hql.append(" u.assessmentType.id =:assessmentType");
    markers.add("assessmentType");
    values.add(assessmentType.getID());
    andStr = " or ";

    hql.append(andStr);
    hql.append(" u.activeStatus =:isactive");
    markers.add("isactive");
    values.add(getDomLookup(PreActiveActiveInactiveStatus.ACTIVE)); 

    hql.append(")");    

    if (markers.size() > 0)
        query += " where ";

    query += hql.toString();

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

    return UserAssessmentShortVoAssembler.createUserAssessmentShortVoCollectionFromUserAssessment(list).sort();
}
项目:openMAXIMS    文件:UserAssessmentsImpl.java   
public UserAssessmentShortVoCollection listAssessments(String name, ims.core.vo.lookups.UserAssessmentCategory category, UserDefinedAssessmentTypeCollection assessmentTypeColl, ims.core.vo.lookups.PreActiveActiveInactiveStatus status)
{
    DomainFactory factory = getDomainFactory();
    StringBuffer hql = new StringBuffer(" ");
    String query = "from UserAssessment u ";
    ArrayList markers = new ArrayList();
    ArrayList values = new ArrayList();
    String andStr = " ";

    if (name != null && name.length() > 0)
    {
        hql.append(andStr + " upper(u.name) like :name");
        markers.add("name");
        values.add(name.toUpperCase());
        andStr = " and ";

    }
    if (category != null)
    {
        hql.append(andStr + " u.category.id =:category");
        markers.add("category");
        values.add(new Integer(category.getId()));
        andStr = " and ";
    }

    if (status != null)
    {
        hql.append(andStr + " u.activeStatus =:status");
        markers.add("status");
        values.add(getDomLookup(status));
        andStr = " and ";
    }

    if (assessmentTypeColl != null)
    {
        int size = assessmentTypeColl.size();
        for (int i = 0; i < size; i++)
        {
            UserDefinedAssessmentType assType = assessmentTypeColl.get(i);
            hql.append(andStr);
            if (i == 0)
                hql.append(" (");
            hql.append(" u.assessmentType.id =:assessmentType" + Integer.toString(i));
            markers.add("assessmentType" + i);
            values.add(new Integer(assType.getId()));
            andStr = " or ";

            if (i == (size - 1))
                hql.append(")");    
        }
    }

    if (markers.size() > 0)
        query += " where ";

    query += hql.toString();

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

    return UserAssessmentShortVoAssembler.createUserAssessmentShortVoCollectionFromUserAssessment(list).sort();
}
项目:openMAXIMS    文件:ClinicalNoteDrawingImpl.java   
public UserAssessmentShortVoCollection listAssessments(String name, UserAssessmentCategory category, UserDefinedAssessmentTypeCollection assessmentType, PreActiveActiveInactiveStatus status) 
{
    UserAssessments impl = (UserAssessments)getDomainImpl(UserAssessmentsImpl.class);
    return impl.listAssessments(name,category,assessmentType,status);
}
项目:openmaxims-linux    文件:ManchesterTreatmentProtocolAdminImpl.java   
public UserAssessmentShortVoCollection listAssessments(String name, UserAssessmentCategory category, UserDefinedAssessmentType assessmentType) 
{
    DomainFactory factory = getDomainFactory();
    StringBuffer hql = new StringBuffer(" ");
    String query = "from UserAssessment u ";
    ArrayList markers = new ArrayList();
    ArrayList values = new ArrayList();
    String andStr = " ";

    if (name != null && name.length() > 0)
    {
        hql.append(andStr + " upper(u.name) like :name");
        markers.add("name");
        values.add(name.toUpperCase());
        andStr = " and ";

    }
    if (category != null)
    {
        hql.append(andStr + " u.category.id =:category");
        markers.add("category");
        values.add(new Integer(category.getId()));
        andStr = " and ";
    }

    hql.append(andStr);
    hql.append(" u.assessmentType.id =:assessmentType");
    markers.add("assessmentType");
    values.add(assessmentType.getID());
    andStr = " or ";

    hql.append(andStr);
    hql.append(" u.activeStatus =:isactive");
    markers.add("isactive");
    values.add(getDomLookup(PreActiveActiveInactiveStatus.ACTIVE)); 

    hql.append(")");    

    if (markers.size() > 0)
        query += " where ";

    query += hql.toString();

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

    return UserAssessmentShortVoAssembler.createUserAssessmentShortVoCollectionFromUserAssessment(list).sort();
}
项目:openmaxims-linux    文件:UserAssessmentsImpl.java   
public UserAssessmentShortVoCollection listAssessments(String name, ims.core.vo.lookups.UserAssessmentCategory category, UserDefinedAssessmentTypeCollection assessmentTypeColl, ims.core.vo.lookups.PreActiveActiveInactiveStatus status)
{
    DomainFactory factory = getDomainFactory();
    StringBuffer hql = new StringBuffer(" ");
    String query = "from UserAssessment u ";
    ArrayList markers = new ArrayList();
    ArrayList values = new ArrayList();
    String andStr = " ";

    if (name != null && name.length() > 0)
    {
        hql.append(andStr + " upper(u.name) like :name");
        markers.add("name");
        values.add(name.toUpperCase());
        andStr = " and ";

    }
    if (category != null)
    {
        hql.append(andStr + " u.category.id =:category");
        markers.add("category");
        values.add(new Integer(category.getId()));
        andStr = " and ";
    }

    if (status != null)
    {
        hql.append(andStr + " u.activeStatus =:status");
        markers.add("status");
        values.add(getDomLookup(status));
        andStr = " and ";
    }

    if (assessmentTypeColl != null)
    {
        int size = assessmentTypeColl.size();
        for (int i = 0; i < size; i++)
        {
            UserDefinedAssessmentType assType = assessmentTypeColl.get(i);
            hql.append(andStr);
            if (i == 0)
                hql.append(" (");
            hql.append(" u.assessmentType.id =:assessmentType" + Integer.toString(i));
            markers.add("assessmentType" + i);
            values.add(new Integer(assType.getId()));
            andStr = " or ";

            if (i == (size - 1))
                hql.append(")");    
        }
    }

    if (markers.size() > 0)
        query += " where ";

    query += hql.toString();

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

    return UserAssessmentShortVoAssembler.createUserAssessmentShortVoCollectionFromUserAssessment(list).sort();
}
项目:openmaxims-linux    文件:ClinicalNoteDrawingImpl.java   
public UserAssessmentShortVoCollection listAssessments(String name, UserAssessmentCategory category, UserDefinedAssessmentTypeCollection assessmentType, PreActiveActiveInactiveStatus status) 
{
    UserAssessments impl = (UserAssessments)getDomainImpl(UserAssessmentsImpl.class);
    return impl.listAssessments(name,category,assessmentType,status);
}