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

项目:AvoinApotti    文件:Logic.java   
private void getLastHeightWeight()
{
    VSMetrics voMetrics = null;
    if ( ConfigFlag.UI.SHOW_VITAL_SIGNS_METRIC_CONTROLS.getValue())
        voMetrics = domain.getLastMetrics(form.getGlobalContext().Core.getCurrentCareContext());
    else
        voMetrics = domain.getLastMUSTMetrics(form.getGlobalContext().Core.getCurrentCareContext());

    if(voMetrics != null)
    {
        form.ctnMust().decHeight().setValue(voMetrics.getHeightValue());

        if(ConfigFlag.UI.HW_MEASURED_ESTIMATED_FUNCTIONALITY.getValue())//WDEV-15193
        {
            form.ctnMust().GroupH().setValue(Boolean.TRUE.equals(voMetrics.getHeightEstimatedMeasured()) ? GroupHEnumeration.rdoHM : GroupHEnumeration.rdoHE);
        }
    }
}
项目:AvoinApotti    文件:Logic.java   
public boolean save() throws PresentationLogicException
{
    VSMetrics record = populateDataFromScreen(form.getLocalContext().getSelectedInstanceIsNotNull()?(VSMetrics) form.getLocalContext().getSelectedInstance().clone():null);
    String[] errors = record.validate(validateUIRules());
    if (errors != null && errors.length>0)
    {
        engine.showErrors(errors);
        return false;
    }
    try
    {
        form.getLocalContext().setSelectedInstance(domain.save(record));
    }
    catch (StaleObjectException e)
    {
        engine.showErrors(new String[]{ConfigFlag.UI.STALE_OBJECT_MESSAGE.getValue()});
        open();
        return false;
    }
    return true;
}
项目:AvoinApotti    文件:Logic.java   
private void addRowToGrid(VSMetrics vsMetrics)
{
    if (vsMetrics == null )
        return;
    grdMetricsRow newRow = form.grdMetrics().getRows().newRow();
    newRow.setValue(vsMetrics);
    newRow.setColumnBMI(vsMetrics.getBMI());
    newRow.setColumnDateTime(vsMetrics.getAuthoringInformationIsNotNull()?vsMetrics.getAuthoringInformation().getAuthoringDateTime():null);
    newRow.setColumnHcp(vsMetrics.getAuthoringInformationIsNotNull()?vsMetrics.getAuthoringInformation().getAuthoringHcp():null);
    newRow.setColumnHeight(vsMetrics.getHeightValue());
    newRow.setColumnHEM(vsMetrics.getHeightEstimatedMeasuredIsNotNull() && vsMetrics.getHeightEstimatedMeasured()?form.getImages().Nursing.HeightMeasured16:form.getImages().Nursing.HeightEstimated16);
    newRow.setTooltipForColumnHEM(vsMetrics.getHeightEstimatedMeasuredIsNotNull()&& vsMetrics.getHeightEstimatedMeasured()?"Height was measured":"Height was estimated");
    newRow.setColumnSurface(bodySurfaceArea(vsMetrics.getHeightValue(),vsMetrics.getWeightValue()));
    newRow.setColumnWeight(vsMetrics.getWeightValue());
    newRow.setColumnWEM(vsMetrics.getWeightEstimatedMeasuredIsNotNull() && vsMetrics.getWeightEstimatedMeasured()?form.getImages().Nursing.WeightMeasured16:form.getImages().Nursing.WeightEstimated16);
    newRow.setTooltipForColumnWEM(vsMetrics.getWeightEstimatedMeasuredIsNotNull()&& vsMetrics.getWeightEstimatedMeasured()?"Weight was measured":"Weight was estimated");

    populateBMIandSurface();


}
项目:AvoinApotti    文件:VitalSignsImpl.java   
public VSMetrics getMetricsFromPatient(PatientRefVo voPatientRef)
{
    if (voPatientRef == null || voPatientRef.getID_Patient() == null)
        throw new CodingRuntimeException("Patient not Provided to retrive Metrics record");

    DomainFactory factory = getDomainFactory();

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

    String query = "SELECT metric FROM Metrics AS metric WHERE metric.patient.id = :ID_PATIENT ORDER BY metric.systemInformation.creationDateTime DESC";

    paramNames.add("ID_PATIENT");
    paramValues.add(voPatientRef.getID_Patient());

    return VSMetricsAssembler.create((Metrics) factory.findFirst(query, paramNames, paramValues));
}
项目:openMAXIMS    文件:Logic.java   
private void getLastHeightWeight()
{
    VSMetrics voMetrics = null;
    if ( ConfigFlag.UI.SHOW_VITAL_SIGNS_METRIC_CONTROLS.getValue())
        voMetrics = domain.getLastMetrics(form.getGlobalContext().Core.getCurrentCareContext());
    else
        voMetrics = domain.getLastMUSTMetrics(form.getGlobalContext().Core.getCurrentCareContext());

    if(voMetrics != null)
    {
        form.ctnMust().decHeight().setValue(voMetrics.getHeightValue());

        if(ConfigFlag.UI.HW_MEASURED_ESTIMATED_FUNCTIONALITY.getValue())//WDEV-15193
        {
            form.ctnMust().GroupH().setValue(Boolean.TRUE.equals(voMetrics.getHeightEstimatedMeasured()) ? GroupHEnumeration.rdoHM : GroupHEnumeration.rdoHE);
        }
    }
}
项目:openMAXIMS    文件:Logic.java   
public boolean save() throws PresentationLogicException
{
    VSMetrics record = populateDataFromScreen(form.getLocalContext().getSelectedInstanceIsNotNull()?(VSMetrics) form.getLocalContext().getSelectedInstance().clone():null);
    String[] errors = record.validate(validateUIRules());
    if (errors != null && errors.length>0)
    {
        engine.showErrors(errors);
        return false;
    }
    try
    {
        form.getLocalContext().setSelectedInstance(domain.save(record));
    }
    catch (StaleObjectException e)
    {
        engine.showErrors(new String[]{ConfigFlag.UI.STALE_OBJECT_MESSAGE.getValue()});
        open();
        return false;
    }
    return true;
}
项目:openMAXIMS    文件:Logic.java   
private void addRowToGrid(VSMetrics vsMetrics)
{
    if (vsMetrics == null )
        return;
    grdMetricsRow newRow = form.grdMetrics().getRows().newRow();
    newRow.setValue(vsMetrics);
    newRow.setColumnBMI(vsMetrics.getBMI());
    newRow.setColumnDateTime(vsMetrics.getAuthoringInformationIsNotNull()?vsMetrics.getAuthoringInformation().getAuthoringDateTime():null);
    newRow.setColumnHcp(vsMetrics.getAuthoringInformationIsNotNull()?vsMetrics.getAuthoringInformation().getAuthoringHcp():null);
    newRow.setColumnHeight(vsMetrics.getHeightValue());
    newRow.setColumnHEM(vsMetrics.getHeightEstimatedMeasuredIsNotNull() && vsMetrics.getHeightEstimatedMeasured()?form.getImages().Nursing.HeightMeasured16:form.getImages().Nursing.HeightEstimated16);
    newRow.setTooltipForColumnHEM(vsMetrics.getHeightEstimatedMeasuredIsNotNull()&& vsMetrics.getHeightEstimatedMeasured()?"Height was measured":"Height was estimated");
    newRow.setColumnSurface(bodySurfaceArea(vsMetrics.getHeightValue(),vsMetrics.getWeightValue()));
    newRow.setColumnWeight(vsMetrics.getWeightValue());
    newRow.setColumnWEM(vsMetrics.getWeightEstimatedMeasuredIsNotNull() && vsMetrics.getWeightEstimatedMeasured()?form.getImages().Nursing.WeightMeasured16:form.getImages().Nursing.WeightEstimated16);
    newRow.setTooltipForColumnWEM(vsMetrics.getWeightEstimatedMeasuredIsNotNull()&& vsMetrics.getWeightEstimatedMeasured()?"Weight was measured":"Weight was estimated");

    populateBMIandSurface();


}
项目:openMAXIMS    文件:VitalSignsImpl.java   
public VSMetrics getMetricsFromPatient(PatientRefVo voPatientRef)
{
    if (voPatientRef == null || voPatientRef.getID_Patient() == null)
        throw new CodingRuntimeException("Patient not Provided to retrive Metrics record");

    DomainFactory factory = getDomainFactory();

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

    String query = "SELECT metric FROM Metrics AS metric WHERE metric.patient.id = :ID_PATIENT ORDER BY metric.systemInformation.creationDateTime DESC";

    paramNames.add("ID_PATIENT");
    paramValues.add(voPatientRef.getID_Patient());

    return VSMetricsAssembler.create((Metrics) factory.findFirst(query, paramNames, paramValues));
}
项目:openMAXIMS    文件:Logic.java   
private void getLastHeightWeight()
{
    VSMetrics voMetrics = null;
    if ( ConfigFlag.UI.SHOW_VITAL_SIGNS_METRIC_CONTROLS.getValue())
        voMetrics = domain.getLastMetrics(form.getGlobalContext().Core.getCurrentCareContext());
    else
        voMetrics = domain.getLastMUSTMetrics(form.getGlobalContext().Core.getCurrentCareContext());

    if(voMetrics != null)
    {
        form.ctnMust().decHeight().setValue(voMetrics.getHeightValue());

        if(ConfigFlag.UI.HW_MEASURED_ESTIMATED_FUNCTIONALITY.getValue())//WDEV-15193
        {
            form.ctnMust().GroupH().setValue(Boolean.TRUE.equals(voMetrics.getHeightEstimatedMeasured()) ? GroupHEnumeration.rdoHM : GroupHEnumeration.rdoHE);
        }
    }
}
项目:openMAXIMS    文件:Logic.java   
public boolean save() throws PresentationLogicException
{
    VSMetrics record = populateDataFromScreen(form.getLocalContext().getSelectedInstanceIsNotNull()?(VSMetrics) form.getLocalContext().getSelectedInstance().clone():null);
    String[] errors = record.validate(validateUIRules());
    if (errors != null && errors.length>0)
    {
        engine.showErrors(errors);
        return false;
    }
    try
    {
        form.getLocalContext().setSelectedInstance(domain.save(record));
    }
    catch (StaleObjectException e)
    {
        engine.showErrors(new String[]{ConfigFlag.UI.STALE_OBJECT_MESSAGE.getValue()});
        open();
        return false;
    }
    return true;
}
项目:openMAXIMS    文件:Logic.java   
private void addRowToGrid(VSMetrics vsMetrics)
{
    if (vsMetrics == null )
        return;
    grdMetricsRow newRow = form.grdMetrics().getRows().newRow();
    newRow.setValue(vsMetrics);
    newRow.setColumnBMI(vsMetrics.getBMI());
    newRow.setColumnDateTime(vsMetrics.getAuthoringInformationIsNotNull()?vsMetrics.getAuthoringInformation().getAuthoringDateTime():null);
    newRow.setColumnHcp(vsMetrics.getAuthoringInformationIsNotNull()?vsMetrics.getAuthoringInformation().getAuthoringHcp():null);
    newRow.setColumnHeight(vsMetrics.getHeightValue());
    newRow.setColumnHEM(vsMetrics.getHeightEstimatedMeasuredIsNotNull() && vsMetrics.getHeightEstimatedMeasured()?form.getImages().Nursing.HeightMeasured16:form.getImages().Nursing.HeightEstimated16);
    newRow.setTooltipForColumnHEM(vsMetrics.getHeightEstimatedMeasuredIsNotNull()&& vsMetrics.getHeightEstimatedMeasured()?"Height was measured":"Height was estimated");
    newRow.setColumnSurface(bodySurfaceArea(vsMetrics.getHeightValue(),vsMetrics.getWeightValue()));
    newRow.setColumnWeight(vsMetrics.getWeightValue());
    newRow.setColumnWEM(vsMetrics.getWeightEstimatedMeasuredIsNotNull() && vsMetrics.getWeightEstimatedMeasured()?form.getImages().Nursing.WeightMeasured16:form.getImages().Nursing.WeightEstimated16);
    newRow.setTooltipForColumnWEM(vsMetrics.getWeightEstimatedMeasuredIsNotNull()&& vsMetrics.getWeightEstimatedMeasured()?"Weight was measured":"Weight was estimated");

    populateBMIandSurface();


}
项目:openMAXIMS    文件:VitalSignsImpl.java   
public VSMetrics getMetricsFromPatient(PatientRefVo voPatientRef)
{
    if (voPatientRef == null || voPatientRef.getID_Patient() == null)
        throw new CodingRuntimeException("Patient not Provided to retrive Metrics record");

    DomainFactory factory = getDomainFactory();

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

    String query = "SELECT metric FROM Metrics AS metric WHERE metric.patient.id = :ID_PATIENT ORDER BY metric.systemInformation.creationDateTime DESC";

    paramNames.add("ID_PATIENT");
    paramValues.add(voPatientRef.getID_Patient());

    return VSMetricsAssembler.create((Metrics) factory.findFirst(query, paramNames, paramValues));
}
项目:openmaxims-linux    文件:Logic.java   
private void getLastHeightWeight()
{
    VSMetrics voMetrics = null;
    if ( ConfigFlag.UI.SHOW_VITAL_SIGNS_METRIC_CONTROLS.getValue())
        voMetrics = domain.getLastMetrics(form.getGlobalContext().Core.getCurrentCareContext());
    else
        voMetrics = domain.getLastMUSTMetrics(form.getGlobalContext().Core.getCurrentCareContext());

    if(voMetrics != null)
    {
        form.ctnMust().decHeight().setValue(voMetrics.getHeightValue());

        if(ConfigFlag.UI.HW_MEASURED_ESTIMATED_FUNCTIONALITY.getValue())//WDEV-15193
        {
            form.ctnMust().GroupH().setValue(Boolean.TRUE.equals(voMetrics.getHeightEstimatedMeasured()) ? GroupHEnumeration.rdoHM : GroupHEnumeration.rdoHE);
        }
    }
}
项目:openmaxims-linux    文件:Logic.java   
public boolean save() throws PresentationLogicException
{
    VSMetrics record = populateDataFromScreen(form.getLocalContext().getSelectedInstanceIsNotNull()?(VSMetrics) form.getLocalContext().getSelectedInstance().clone():null);
    String[] errors = record.validate(validateUIRules());
    if (errors != null && errors.length>0)
    {
        engine.showErrors(errors);
        return false;
    }
    try
    {
        form.getLocalContext().setSelectedInstance(domain.save(record));
    }
    catch (StaleObjectException e)
    {
        engine.showErrors(new String[]{ConfigFlag.UI.STALE_OBJECT_MESSAGE.getValue()});
        open();
        return false;
    }
    return true;
}
项目:openmaxims-linux    文件:Logic.java   
private void addRowToGrid(VSMetrics vsMetrics)
{
    if (vsMetrics == null )
        return;
    grdMetricsRow newRow = form.grdMetrics().getRows().newRow();
    newRow.setValue(vsMetrics);
    newRow.setColumnBMI(vsMetrics.getBMI());
    newRow.setColumnDateTime(vsMetrics.getAuthoringInformationIsNotNull()?vsMetrics.getAuthoringInformation().getAuthoringDateTime():null);
    newRow.setColumnHcp(vsMetrics.getAuthoringInformationIsNotNull()?vsMetrics.getAuthoringInformation().getAuthoringHcp():null);
    newRow.setColumnHeight(vsMetrics.getHeightValue());
    newRow.setColumnHEM(vsMetrics.getHeightEstimatedMeasuredIsNotNull() && vsMetrics.getHeightEstimatedMeasured()?form.getImages().Nursing.HeightMeasured16:form.getImages().Nursing.HeightEstimated16);
    newRow.setTooltipForColumnHEM(vsMetrics.getHeightEstimatedMeasuredIsNotNull()&& vsMetrics.getHeightEstimatedMeasured()?"Height was measured":"Height was estimated");
    newRow.setColumnSurface(bodySurfaceArea(vsMetrics.getHeightValue(),vsMetrics.getWeightValue()));
    newRow.setColumnWeight(vsMetrics.getWeightValue());
    newRow.setColumnWEM(vsMetrics.getWeightEstimatedMeasuredIsNotNull() && vsMetrics.getWeightEstimatedMeasured()?form.getImages().Nursing.WeightMeasured16:form.getImages().Nursing.WeightEstimated16);
    newRow.setTooltipForColumnWEM(vsMetrics.getWeightEstimatedMeasuredIsNotNull()&& vsMetrics.getWeightEstimatedMeasured()?"Weight was measured":"Weight was estimated");

    populateBMIandSurface();


}
项目:openmaxims-linux    文件:VitalSignsImpl.java   
public VSMetrics getMetricsFromPatient(PatientRefVo voPatientRef)
{
    if (voPatientRef == null || voPatientRef.getID_Patient() == null)
        throw new CodingRuntimeException("Patient not Provided to retrive Metrics record");

    DomainFactory factory = getDomainFactory();

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

    String query = "SELECT metric FROM Metrics AS metric WHERE metric.patient.id = :ID_PATIENT ORDER BY metric.systemInformation.creationDateTime DESC";

    paramNames.add("ID_PATIENT");
    paramValues.add(voPatientRef.getID_Patient());

    return VSMetricsAssembler.create((Metrics) factory.findFirst(query, paramNames, paramValues));
}
项目:AvoinApotti    文件:Logic.java   
private void populateHeightWeightFields()
{
    VSMetricsCollection voMetricsColl = new VSMetricsCollection();
    voMetricsColl = domain.listMetricsData(form.getGlobalContext().Core.getPatientShort());
    if(voMetricsColl.size()<= 0)
        return;
    else
    {
        VSMetrics voMetrics = voMetricsColl.get(0);
        form.decHeight().setValue(voMetrics.getHeightValue());
        form.decWeight().setValue(voMetrics.getWeightValue());
    }
}
项目:AvoinApotti    文件:Logic.java   
private void populateHeightWeightFields()
{
    VSMetricsCollection voMetricsColl = new VSMetricsCollection();
    voMetricsColl = domain.listMetricsData(form.getGlobalContext().Core.getPatientShort());
    if(voMetricsColl.size()<= 0)
        return;
    else
    {
        VSMetrics voMetrics = voMetricsColl.get(0);
        form.cntSleeping().decHeight().setValue(voMetrics.getHeightValue());
        form.cntSleeping().decWeight().setValue(voMetrics.getWeightValue());
    }
}
项目:AvoinApotti    文件:Logic.java   
private void getLatestMetrics()
{
    VSMetrics voMetrics = domain.getMetricsFromPatient(form.getGlobalContext().Core.getPatientShort());
    if(voMetrics != null)
    {
        form.decHeight().setValue(voMetrics.getHeightValue());
        form.decWeight().setValue(voMetrics.getWeightValue());
        form.decBmi().setValue(voMetrics.getBMI()); //WDEV-15761
    }

}
项目:AvoinApotti    文件:Logic.java   
@Override
protected void onGraphingMetricPointClicked(GraphingPoint point)
{
    if (FormMode.VIEW.equals(form.getMode()) && point.getTag() instanceof VSMetrics)
    {
        form.grdMetrics().setValue((VSMetrics) point.getTag());
        selectInstance();
        updateControlsState();
    }

}
项目:AvoinApotti    文件:Logic.java   
@Override
protected void populateScreenFromData(VSMetrics value)
{
    clearScreen();
    if(value == null)
        return;
    super.populateScreenFromData(value);
    form.ccRecording().setValue(value.getAuthoringInformation());
    form.GroupH().setValue(value.getHeightEstimatedMeasuredIsNotNull()&&value.getHeightEstimatedMeasured()?GroupHEnumeration.rdoHM:GroupHEnumeration.rdoHE);
    form.GroupW().setValue(value.getWeightEstimatedMeasuredIsNotNull()&&value.getWeightEstimatedMeasured()?GroupWEnumeration.rdoWM:GroupWEnumeration.rdoWE);
    populateBMIandSurface();
}
项目:AvoinApotti    文件:Logic.java   
@Override
protected VSMetrics populateDataFromScreen(VSMetrics value)
{
    VSMetrics result = super.populateDataFromScreen(value);
    if (!result.getPatientIsNotNull())
    {
        result.setPatient(form.getGlobalContext().Core.getPatientShort());
    }
    result.setAuthoringInformation(form.ccRecording().getValue());
    result.setHeightEstimatedMeasured(form.GroupH().getValue()==GroupHEnumeration.rdoHM?true:false);
    result.setWeightEstimatedMeasured(form.GroupW().getValue()==GroupWEnumeration.rdoWM?true:false);
    return result;
}
项目:AvoinApotti    文件:Logic.java   
public int compare(VSMetrics o1, VSMetrics o2)
{
    int direction = 1;
    if (order == SortOrder.DESCENDING)
        direction = -1;
    return direction*o1.getAuthoringInformation().getAuthoringDateTime().compareTo(o2.getAuthoringInformation().getAuthoringDateTime());
}
项目:AvoinApotti    文件:Logic.java   
public int compare(VSMetrics o1, VSMetrics o2)
{
    int direction = 1;
    if (order == SortOrder.DESCENDING)
        direction = -1;
    return direction*o1.getAuthoringInformation().getAuthoringHcp().compareTo(o2.getAuthoringInformation().getAuthoringHcp());
}
项目:AvoinApotti    文件:MUSTImpl.java   
public VSMetrics getLastMetrics(CareContextRefVo voCareContext) 
{
    VitalSignsMetrics metrics = (VitalSignsMetrics) getDomainImpl(VitalSignsImpl.class);
    VitalSignsVoCollection voVsColl = metrics.listMetrics(null, null, voCareContext);
    if (voVsColl != null)
    {
        if (voVsColl.size() > 0 && voVsColl.get(0).getMetricsIsNotNull())
            return voVsColl.get(0).getMetrics();
    }       
    return null;        
}
项目:AvoinApotti    文件:MUSTImpl.java   
public VSMetrics getLastMUSTMetrics(CareContextRefVo voCareContext)
{
    if (voCareContext == null)
        return null;

    MUSTVo voMust = getLastComplementedMustRecord(voCareContext);
    if (voMust != null)
        return voMust.getMetrics();
    else
        return null;
}
项目:AvoinApotti    文件:VitalSignsImpl.java   
public VSMetrics saveMetricsToPatient(VSMetrics voMetrics) throws StaleObjectException
{
    if(voMetrics == null || !voMetrics.isValidated())
        throw new CodingRuntimeException("Metrics record is null or has not been validated");

    DomainFactory factory = getDomainFactory();
    Metrics doMetrics = VSMetricsAssembler.extractMetrics(factory, voMetrics);
    factory.save(doMetrics);
    return VSMetricsAssembler.create(doMetrics);
}
项目:AvoinApotti    文件:VitalSignsBaselineAndAllImpl.java   
/**
* get Metrics From Patient
*/
public ims.core.vo.VSMetrics getMetricsFromPatient(ims.core.patient.vo.PatientRefVo voPatientRef)
{
    if (voPatientRef == null || voPatientRef.getID_Patient() == null)
        throw new CodingRuntimeException("Patient not Provided to retrive Metrics record");

    DomainFactory factory = getDomainFactory();
    List metrics = factory.find("from Metrics metric where metric.patient.id = :idPatient order by metric.systemInformation",new String[] {"idPatient"},new Object[] {voPatientRef.getID_Patient()});
    if(metrics != null && metrics.size() > 0)
        return (VSMetricsAssembler.create((Metrics)metrics.get(0)));

    return null;
}
项目:AvoinApotti    文件:VitalSignsBaselineAndAllImpl.java   
/**
* save Metrics To Core Clinical
*/
public ims.core.vo.VSMetrics saveMetricsToPatient(ims.core.vo.VSMetrics voMetrics) throws ims.domain.exceptions.StaleObjectException
{
    if(voMetrics == null || !voMetrics.isValidated())
        throw new CodingRuntimeException("Metrics record is null or has not been validated");

    DomainFactory factory = getDomainFactory();
    Metrics doMetrics = VSMetricsAssembler.extractMetrics(factory, voMetrics);
    factory.save(doMetrics);
    return VSMetricsAssembler.create(doMetrics);
}
项目:openMAXIMS    文件:Logic.java   
private void populateHeightWeightFields()
{
    VSMetricsCollection voMetricsColl = new VSMetricsCollection();
    voMetricsColl = domain.listMetricsData(form.getGlobalContext().Core.getPatientShort());
    if(voMetricsColl.size()<= 0)
        return;
    else
    {
        VSMetrics voMetrics = voMetricsColl.get(0);
        form.decHeight().setValue(voMetrics.getHeightValue());
        form.decWeight().setValue(voMetrics.getWeightValue());
    }
}
项目:openMAXIMS    文件:Logic.java   
private void populateHeightWeightFields()
{
    VSMetricsCollection voMetricsColl = new VSMetricsCollection();
    voMetricsColl = domain.listMetricsData(form.getGlobalContext().Core.getPatientShort());
    if(voMetricsColl.size()<= 0)
        return;
    else
    {
        VSMetrics voMetrics = voMetricsColl.get(0);
        form.cntSleeping().decHeight().setValue(voMetrics.getHeightValue());
        form.cntSleeping().decWeight().setValue(voMetrics.getWeightValue());
    }
}
项目:openMAXIMS    文件:Logic.java   
private void getLatestMetrics()
{
    VSMetrics voMetrics = domain.getMetricsFromPatient(form.getGlobalContext().Core.getPatientShort());
    if(voMetrics != null)
    {
        form.decHeight().setValue(voMetrics.getHeightValue());
        form.decWeight().setValue(voMetrics.getWeightValue());
        form.decBmi().setValue(voMetrics.getBMI()); //WDEV-15761
    }

}
项目:openMAXIMS    文件:Logic.java   
@Override
protected void onGraphingMetricPointClicked(GraphingPoint point)
{
    if (FormMode.VIEW.equals(form.getMode()) && point.getTag() instanceof VSMetrics)
    {
        form.grdMetrics().setValue((VSMetrics) point.getTag());
        selectInstance();
        updateControlsState();
    }

}
项目:openMAXIMS    文件:Logic.java   
@Override
protected void populateScreenFromData(VSMetrics value)
{
    clearScreen();
    if(value == null)
        return;
    super.populateScreenFromData(value);
    form.ccRecording().setValue(value.getAuthoringInformation());
    form.GroupH().setValue(value.getHeightEstimatedMeasuredIsNotNull()&&value.getHeightEstimatedMeasured()?GroupHEnumeration.rdoHM:GroupHEnumeration.rdoHE);
    form.GroupW().setValue(value.getWeightEstimatedMeasuredIsNotNull()&&value.getWeightEstimatedMeasured()?GroupWEnumeration.rdoWM:GroupWEnumeration.rdoWE);
    populateBMIandSurface();
}
项目:openMAXIMS    文件:Logic.java   
@Override
protected VSMetrics populateDataFromScreen(VSMetrics value)
{
    VSMetrics result = super.populateDataFromScreen(value);
    if (!result.getPatientIsNotNull())
    {
        result.setPatient(form.getGlobalContext().Core.getPatientShort());
    }
    result.setAuthoringInformation(form.ccRecording().getValue());
    result.setHeightEstimatedMeasured(form.GroupH().getValue()==GroupHEnumeration.rdoHM?true:false);
    result.setWeightEstimatedMeasured(form.GroupW().getValue()==GroupWEnumeration.rdoWM?true:false);
    return result;
}
项目:openMAXIMS    文件:Logic.java   
public int compare(VSMetrics o1, VSMetrics o2)
{
    int direction = 1;
    if (order == SortOrder.DESCENDING)
        direction = -1;
    return direction*o1.getAuthoringInformation().getAuthoringDateTime().compareTo(o2.getAuthoringInformation().getAuthoringDateTime());
}
项目:openMAXIMS    文件:Logic.java   
public int compare(VSMetrics o1, VSMetrics o2)
{
    int direction = 1;
    if (order == SortOrder.DESCENDING)
        direction = -1;
    return direction*o1.getAuthoringInformation().getAuthoringHcp().compareTo(o2.getAuthoringInformation().getAuthoringHcp());
}
项目:openMAXIMS    文件:MUSTImpl.java   
public VSMetrics getLastMetrics(CareContextRefVo voCareContext) 
{
    VitalSignsMetrics metrics = (VitalSignsMetrics) getDomainImpl(VitalSignsImpl.class);
    VitalSignsVoCollection voVsColl = metrics.listMetrics(null, null, voCareContext);
    if (voVsColl != null)
    {
        if (voVsColl.size() > 0 && voVsColl.get(0).getMetricsIsNotNull())
            return voVsColl.get(0).getMetrics();
    }       
    return null;        
}
项目:openMAXIMS    文件:MUSTImpl.java   
public VSMetrics getLastMUSTMetrics(CareContextRefVo voCareContext)
{
    if (voCareContext == null)
        return null;

    MUSTVo voMust = getLastComplementedMustRecord(voCareContext);
    if (voMust != null)
        return voMust.getMetrics();
    else
        return null;
}
项目:openMAXIMS    文件:EPrescribingImpl.java   
public VSMetrics getLatestMetricsForPatient(PatientRefVo patient)
        throws DomainInterfaceException 
{
    if (patient == null || patient.getID_Patient() == null)
        return null;

    DomainFactory factory = getDomainFactory();
    List metrics = factory.find("from Metrics metric where metric.patient.id = :idPatient " +
            " and (rie is null or rie = 0) order by metric.systemInformation.creationDateTime desc",new String[] {"idPatient"},new Object[] {patient.getID_Patient()});     
    if(metrics != null && metrics.size() > 0)
        return (VSMetricsAssembler.create((Metrics)metrics.get(0)));

    return null;
}