Java 类ims.clinical.vo.domain.NeonatalVoAssembler 实例源码

项目:AvoinApotti    文件:EDischargeSpecialCareBabyUnitDischargeComponentImpl.java   
/**
* getNeonatalByCareContext
*/
public ims.clinical.vo.NeonatalVo getNeonatalByCareContext(ims.core.admin.vo.CareContextRefVo careContext)
{
    if (careContext == null || careContext.getID_CareContext() == null)
        throw new CodingRuntimeException("careContext is null or id not provided in method getNeonatalByCareContext");

    DomainFactory factory = getDomainFactory();
    List nnItems =  factory.find("from NeoNatal nn where nn.careContext.id = " + careContext.getID_CareContext());

    if(nnItems != null && nnItems.size() > 0)
        return NeonatalVoAssembler.create((NeoNatal) nnItems.get(0));

    return null;
}
项目:AvoinApotti    文件:EDischargeSpecialCareBabyUnitDischargeComponentImpl.java   
/**
* saveNeonatal
*/
public void saveNeonatal(ims.clinical.vo.NeonatalVo neonatal, SummaryRefVo summary) throws ims.domain.exceptions.StaleObjectException
{
    if (neonatal == null)
        throw new CodingRuntimeException("neonatal is null in method saveNeonatal");
    if (!neonatal.isValidated())
        throw new CodingRuntimeException("neonatal has not been validated in method saveNeonatal");

    DomainFactory factory = getDomainFactory();
    factory.save(NeonatalVoAssembler.extractNeoNatal(factory, neonatal));

    //updating summary WDEV-11348
    IEDischargeHelper impl = (IEDischargeHelper) getDomainImpl(EDischargeHelper.class); 
    impl.updateSummaryIfRequired(neonatal, summary, factory);
}
项目:openMAXIMS    文件:EDischargeSpecialCareBabyUnitDischargeComponentImpl.java   
/**
* getNeonatalByCareContext
*/
public ims.clinical.vo.NeonatalVo getNeonatalByCareContext(ims.core.admin.vo.CareContextRefVo careContext)
{
    if (careContext == null || careContext.getID_CareContext() == null)
        throw new CodingRuntimeException("careContext is null or id not provided in method getNeonatalByCareContext");

    DomainFactory factory = getDomainFactory();
    List nnItems =  factory.find("from NeoNatal nn where nn.careContext.id = " + careContext.getID_CareContext());

    if(nnItems != null && nnItems.size() > 0)
        return NeonatalVoAssembler.create((NeoNatal) nnItems.get(0));

    return null;
}
项目:openMAXIMS    文件:EDischargeSpecialCareBabyUnitDischargeComponentImpl.java   
/**
* saveNeonatal
*/
public void saveNeonatal(ims.clinical.vo.NeonatalVo neonatal, SummaryRefVo summary) throws ims.domain.exceptions.StaleObjectException
{
    if (neonatal == null)
        throw new CodingRuntimeException("neonatal is null in method saveNeonatal");
    if (!neonatal.isValidated())
        throw new CodingRuntimeException("neonatal has not been validated in method saveNeonatal");

    DomainFactory factory = getDomainFactory();
    factory.save(NeonatalVoAssembler.extractNeoNatal(factory, neonatal));

    //updating summary WDEV-11348
    IEDischargeHelper impl = (IEDischargeHelper) getDomainImpl(EDischargeHelper.class); 
    impl.updateSummaryIfRequired(neonatal, summary, factory);
}
项目:openMAXIMS    文件:EDischargeSpecialCareBabyUnitDischargeComponentImpl.java   
/**
* getNeonatalByCareContext
*/
public ims.clinical.vo.NeonatalVo getNeonatalByCareContext(ims.core.admin.vo.CareContextRefVo careContext)
{
    if (careContext == null || careContext.getID_CareContext() == null)
        throw new CodingRuntimeException("careContext is null or id not provided in method getNeonatalByCareContext");

    DomainFactory factory = getDomainFactory();
    List nnItems =  factory.find("from NeoNatal nn where nn.careContext.id = " + careContext.getID_CareContext());

    if(nnItems != null && nnItems.size() > 0)
        return NeonatalVoAssembler.create((NeoNatal) nnItems.get(0));

    return null;
}
项目:openMAXIMS    文件:EDischargeSpecialCareBabyUnitDischargeComponentImpl.java   
/**
* saveNeonatal
*/
public void saveNeonatal(ims.clinical.vo.NeonatalVo neonatal, SummaryRefVo summary) throws ims.domain.exceptions.StaleObjectException
{
    if (neonatal == null)
        throw new CodingRuntimeException("neonatal is null in method saveNeonatal");
    if (!neonatal.isValidated())
        throw new CodingRuntimeException("neonatal has not been validated in method saveNeonatal");

    DomainFactory factory = getDomainFactory();
    factory.save(NeonatalVoAssembler.extractNeoNatal(factory, neonatal));

    //updating summary WDEV-11348
    IEDischargeHelper impl = (IEDischargeHelper) getDomainImpl(EDischargeHelper.class); 
    impl.updateSummaryIfRequired(neonatal, summary, factory);
}
项目:openmaxims-linux    文件:EDischargeSpecialCareBabyUnitDischargeComponentImpl.java   
/**
* getNeonatalByCareContext
*/
public ims.clinical.vo.NeonatalVo getNeonatalByCareContext(ims.core.admin.vo.CareContextRefVo careContext)
{
    if (careContext == null || careContext.getID_CareContext() == null)
        throw new CodingRuntimeException("careContext is null or id not provided in method getNeonatalByCareContext");

    DomainFactory factory = getDomainFactory();
    List nnItems =  factory.find("from NeoNatal nn where nn.careContext.id = " + careContext.getID_CareContext());

    if(nnItems != null && nnItems.size() > 0)
        return NeonatalVoAssembler.create((NeoNatal) nnItems.get(0));

    return null;
}
项目:openmaxims-linux    文件:EDischargeSpecialCareBabyUnitDischargeComponentImpl.java   
/**
* saveNeonatal
*/
public void saveNeonatal(ims.clinical.vo.NeonatalVo neonatal, SummaryRefVo summary) throws ims.domain.exceptions.StaleObjectException
{
    if (neonatal == null)
        throw new CodingRuntimeException("neonatal is null in method saveNeonatal");
    if (!neonatal.isValidated())
        throw new CodingRuntimeException("neonatal has not been validated in method saveNeonatal");

    DomainFactory factory = getDomainFactory();
    factory.save(NeonatalVoAssembler.extractNeoNatal(factory, neonatal));

    //updating summary WDEV-11348
    IEDischargeHelper impl = (IEDischargeHelper) getDomainImpl(EDischargeHelper.class); 
    impl.updateSummaryIfRequired(neonatal, summary, factory);
}