Java 类ims.emergency.vo.InvestigationAttendenceDetailVo 实例源码

项目:AvoinApotti    文件:Logic.java   
private void addInvestigation() 
{
    InvestigationAttendenceDetailVo newRecord = new InvestigationAttendenceDetailVo();
    newRecord.setPatient(form.getLocalContext().getPatient());
    newRecord.setEpisode(form.getLocalContext().getEpisodeOfCare());
    newRecord.setAttendance(form.getLocalContext().getCareContext());

    if(Boolean.TRUE.equals(form.getLocalContext().getAddedDuringCoding()))
    {
        newRecord.setAddedDuringCoding(true);
    }

    form.getGlobalContext().Emergency.setInvestigationAttendenceDetail(newRecord);

    engine.open(form.getForms().Emergency.InvestigationAttendenceDetailDialog);
}
项目:AvoinApotti    文件:Logic.java   
private boolean save() 
{
    InvestigationAttendenceDetailVo record = populateDataFromScreen(form.getGlobalContext().Emergency.getInvestigationAttendenceDetail());

    String[] errors = record.validate();
    if(errors != null && errors.length > 0)
    {
        engine.showErrors(errors);
        return false;
    }

    try 
    {
        form.getGlobalContext().Emergency.setInvestigationAttendenceDetail(domain.save(record));
    } 
    catch (StaleObjectException e) 
    {
        e.printStackTrace();
        engine.showMessage(ConfigFlag.UI.STALE_OBJECT_MESSAGE.getValue());
        engine.close(DialogResult.OK);
        return false;
    }

    return true;
}
项目:openMAXIMS    文件:Logic.java   
private void addInvestigation() 
{
    InvestigationsForAttendVo invForAttend = form.getLocalContext().getSelectedInvestigationsForAttend();

    if(invForAttend == null)
    {
        invForAttend = new InvestigationsForAttendVo();
        invForAttend.setPatient(form.getLocalContext().getPatient());
        invForAttend.setEpisode(form.getLocalContext().getEpisodeOfCare());
        invForAttend.setAttendance(form.getLocalContext().getCareContext());
    }

    form.getGlobalContext().Emergency.setInvestigationsForAttend(invForAttend);

    InvestigationAttendenceDetailVo newInv = new InvestigationAttendenceDetailVo();

    if (form.getLocalContext().getHcpUser() == null)
        newInv.setAddedDuringCoding(form.getLocalContext().getAddedDuringCoding());

    form.getGlobalContext().Emergency.setInvestigationAttendenceDetail(newInv);

    engine.open(form.getForms().Emergency.InvestigationAttendenceDetailDialog);
}
项目:openMAXIMS    文件:Logic.java   
private InvestigationAttendenceDetailVo createInvestigationAttendanceDetails(OrderInvestigationForAttendenceNotesCcVo inv)
{
    InvestigationAttendenceDetailVo newInvAtt = new InvestigationAttendenceDetailVo();
    newInvAtt.setActive(true);

    AuthoringInformationVo auth = new AuthoringInformationVo();
    auth.setAuthoringHcp(form.getLocalContext().getHcpUser());
    auth.setAuthoringDateTime(new DateTime());

    newInvAtt.setAuthoringInformation(auth);

    if (form.getLocalContext().getHcpUser() == null)
        newInvAtt.setAddedDuringCoding(form.getLocalContext().getAddedDuringCoding());

    newInvAtt.setOCSInvestigation(inv);

    return newInvAtt;
}
项目:openMAXIMS    文件:InterventionsDiagnosisInvestigationsCcImpl.java   
public InvestigationAttendenceDetailVo inactivateInvestigationAttendenceDetail(InvestigationAttendenceDetailVo record, AttendDiagInvTreatStatusVo attendDiagInvTreatStatus) throws StaleObjectException
{
    if(record == null)
        throw new CodingRuntimeException("Cannot save a null InvestigationAttendenceDetailVo.");

    if(!record.isValidated())
        throw new CodingRuntimeException("InvestigationAttendenceDetailVo is not validated.");

    DomainFactory factory = getDomainFactory();

    InvestigationAttendenceDetail doRecord = InvestigationAttendenceDetailVoAssembler.extractInvestigationAttendenceDetail(factory, record);
    factory.save(doRecord);

    if(attendDiagInvTreatStatus != null)
    {
        AttendDiagInvTreatStatus doAttendDiagInvTreat = AttendDiagInvTreatStatusVoAssembler.extractAttendDiagInvTreatStatus(factory, attendDiagInvTreatStatus);
        factory.save(doAttendDiagInvTreat);
    }

    return record;
}
项目:openMAXIMS    文件:Logic.java   
private void addInvestigation() 
{
    InvestigationAttendenceDetailVo newRecord = new InvestigationAttendenceDetailVo();
    newRecord.setPatient(form.getLocalContext().getPatient());
    newRecord.setEpisode(form.getLocalContext().getEpisodeOfCare());
    newRecord.setAttendance(form.getLocalContext().getCareContext());

    if(Boolean.TRUE.equals(form.getLocalContext().getAddedDuringCoding()))
    {
        newRecord.setAddedDuringCoding(true);
    }

    form.getGlobalContext().Emergency.setInvestigationAttendenceDetail(newRecord);

    engine.open(form.getForms().Emergency.InvestigationAttendenceDetailDialog);
}
项目:openMAXIMS    文件:Logic.java   
private boolean save() 
{
    InvestigationAttendenceDetailVo record = populateDataFromScreen(form.getGlobalContext().Emergency.getInvestigationAttendenceDetail());

    String[] errors = record.validate();
    if(errors != null && errors.length > 0)
    {
        engine.showErrors(errors);
        return false;
    }

    try 
    {
        form.getGlobalContext().Emergency.setInvestigationAttendenceDetail(domain.save(record));
    } 
    catch (StaleObjectException e) 
    {
        e.printStackTrace();
        engine.showMessage(ConfigFlag.UI.STALE_OBJECT_MESSAGE.getValue());
        engine.close(DialogResult.OK);
        return false;
    }

    return true;
}
项目:openmaxims-linux    文件:Logic.java   
private void addInvestigation() 
{
    InvestigationAttendenceDetailVo newRecord = new InvestigationAttendenceDetailVo();
    newRecord.setPatient(form.getLocalContext().getPatient());
    newRecord.setEpisode(form.getLocalContext().getEpisodeOfCare());
    newRecord.setAttendance(form.getLocalContext().getCareContext());

    if(Boolean.TRUE.equals(form.getLocalContext().getAddedDuringCoding()))
    {
        newRecord.setAddedDuringCoding(true);
    }

    form.getGlobalContext().Emergency.setInvestigationAttendenceDetail(newRecord);

    engine.open(form.getForms().Emergency.InvestigationAttendenceDetailDialog);
}
项目:openmaxims-linux    文件:Logic.java   
private boolean save() 
{
    InvestigationAttendenceDetailVo record = populateDataFromScreen(form.getGlobalContext().Emergency.getInvestigationAttendenceDetail());

    String[] errors = record.validate();
    if(errors != null && errors.length > 0)
    {
        engine.showErrors(errors);
        return false;
    }

    try 
    {
        form.getGlobalContext().Emergency.setInvestigationAttendenceDetail(domain.save(record));
    } 
    catch (StaleObjectException e) 
    {
        e.printStackTrace();
        engine.showMessage(ConfigFlag.UI.STALE_OBJECT_MESSAGE.getValue());
        engine.close(DialogResult.OK);
        return false;
    }

    return true;
}
项目:AvoinApotti    文件:Logic.java   
private void editInvestigation() 
{
    if(form.grdInvestigations().getValue() instanceof InvestigationAttendenceDetailVo)
    {
        form.getGlobalContext().Emergency.setInvestigationAttendenceDetail((InvestigationAttendenceDetailVo) form.grdInvestigations().getValue());

        engine.open(form.getForms().Emergency.InvestigationAttendenceDetailDialog);
    }
}
项目:AvoinApotti    文件:Logic.java   
private boolean doRemoveInvestigation() 
{
    if(form.grdInvestigations().getValue() instanceof InvestigationAttendenceDetailVo)
    {
        InvestigationAttendenceDetailVo record = (InvestigationAttendenceDetailVo) form.grdInvestigations().getValue();
        record.setActive(false);

        String[] errors = record.validate();
        if(errors != null && errors.length > 0)
        {
            engine.showErrors(errors);
            return false;
        }

        try 
        {
            domain.save(record);
        } 
        catch (StaleObjectException e) 
        {
            e.printStackTrace();
            engine.showMessage(ConfigFlag.UI.STALE_OBJECT_MESSAGE.getValue());
            populateInvestigationsGrid(form.getLocalContext().getPatient(), form.getLocalContext().getCareContext());
            return false;
        }

        return true;
    }

    return false;
}
项目:openMAXIMS    文件:Logic.java   
private void editInvestigation() 
{
    if(form.grdInvestigations().getValue() instanceof InvestigationAttendenceDetailVo)
    {
        form.getGlobalContext().Emergency.setInvestigationAttendenceDetail((InvestigationAttendenceDetailVo) form.grdInvestigations().getValue());

        engine.open(form.getForms().Emergency.InvestigationAttendenceDetailDialog);
    }
}
项目:openMAXIMS    文件:Logic.java   
private boolean canInvestigationBeRemoved(InvestigationAttendenceDetailVo value)
{
    if(value == null)
        return true;

    if(value.getOCSInvestigation() == null)
        return true;

    if(value.getOCSInvestigation().getOrdInvCurrentStatus() != null && OrderInvStatus.CANCELLED.equals(value.getOCSInvestigation().getOrdInvCurrentStatus().getOrdInvStatus()))
        return true;

    return false;
}
项目:openMAXIMS    文件:Logic.java   
private String populateInvestigationsGrid()
{
    form.grdInvestigations().getRows().clear();

    String orderInvestigationIDSAlreadyAdded = "";

    InvestigationsForAttendVo investigationsForAttend = domain.getInvestigationsForAttend(form.getLocalContext().getCareContext());

    form.getLocalContext().setSelectedInvestigationsForAttend(investigationsForAttend);

    if(investigationsForAttend != null && investigationsForAttend.getInvestigations() != null)
    {
        for(InvestigationAttendenceDetailVo inv : investigationsForAttend.getInvestigations())
        {
            if(inv == null)
                continue;

            if(inv.getOCSInvestigation() != null)
            {
                orderInvestigationIDSAlreadyAdded += (orderInvestigationIDSAlreadyAdded.length() > 0 ? "," : "") + inv.getOCSInvestigation().getID_OrderInvestigation();
            }

            if(Boolean.FALSE.equals(form.getLocalContext().getAddedDuringCoding()) && Boolean.TRUE.equals(inv.getAddedDuringCoding()))
                continue;

            if(!Boolean.TRUE.equals(inv.getActive()))
                continue;

            ims.emergency.forms.interventionsdiagnosisinvestigationscc.GenForm.grdInvestigationsRow row = form.grdInvestigations().getRows().newRow();
            row.setColInvestigation(getInvestigationText(inv));
            row.setValue(inv);
        }
    }

    return orderInvestigationIDSAlreadyAdded.length() > 0 ? orderInvestigationIDSAlreadyAdded : null;
}
项目:openMAXIMS    文件:Logic.java   
private String getInvestigationText(InvestigationAttendenceDetailVo inv)
{
    if(inv == null)
        return null;

    if(inv.getOCSInvestigation() != null)
        return inv.getOCSInvestigation().getInvestigation().getInvestigationIndex().getName();

    return inv.getAttendenceInvestigation() != null ? inv.getAttendenceInvestigation().getText() : null;
}
项目:openMAXIMS    文件:Logic.java   
private boolean doRemoveInvestigation() 
{
    if(form.grdInvestigations().getValue() instanceof InvestigationAttendenceDetailVo)
    {
        InvestigationAttendenceDetailVo record = (InvestigationAttendenceDetailVo) form.grdInvestigations().getValue();
        record.setActive(false);

        String[] errors = record.validate();
        if(errors != null && errors.length > 0)
        {
            engine.showErrors(errors);
            return false;
        }

        try 
        {
            domain.inactivateInvestigationAttendenceDetail(record, (form.grdInvestigations().getRows().size() == 1 ? populateAttendDiagInvTreatStatus(false, true, null, null, null, null) : null));
        } 
        catch (StaleObjectException e) 
        {
            e.printStackTrace();
            engine.showMessage(ConfigFlag.UI.STALE_OBJECT_MESSAGE.getValue());
            refresh();
            return false;
        }

        return true;
    }

    return false;
}
项目:openMAXIMS    文件:Logic.java   
private boolean save() 
{
    InvestigationAttendenceDetailVo record = populateDataFromScreen(form.getGlobalContext().Emergency.getInvestigationAttendenceDetail());

    InvestigationsForAttendVo investigationsForAttend = form.getGlobalContext().Emergency.getInvestigationsForAttend();
    if(investigationsForAttend == null)
    {
        investigationsForAttend = new InvestigationsForAttendVo();
        investigationsForAttend.setPatient(form.getGlobalContext().Core.getPatientShort());
        investigationsForAttend.setEpisode(form.getGlobalContext().Core.getEpisodeofCareShort());
        investigationsForAttend.setAttendance(form.getGlobalContext().Core.getCurrentCareContext());
    }

    String[] errors = record.validate(investigationsForAttend.validate(validateUIRules()));
    if(errors != null && errors.length > 0)
    {
        engine.showErrors(errors);
        return false;
    }

    try 
    {
        form.getGlobalContext().Emergency.setInvestigationAttendenceDetail(domain.save(record, investigationsForAttend));
    } 
    catch (StaleObjectException e) 
    {
        e.printStackTrace();
        engine.showMessage(ConfigFlag.UI.STALE_OBJECT_MESSAGE.getValue());
        engine.close(DialogResult.OK);
        return false;
    }

    return true;
}
项目:openMAXIMS    文件:Logic.java   
private void editInvestigation() 
{
    if(form.grdInvestigations().getValue() instanceof InvestigationAttendenceDetailVo)
    {
        form.getGlobalContext().Emergency.setInvestigationAttendenceDetail((InvestigationAttendenceDetailVo) form.grdInvestigations().getValue());

        engine.open(form.getForms().Emergency.InvestigationAttendenceDetailDialog);
    }
}
项目:openMAXIMS    文件:Logic.java   
private boolean doRemoveInvestigation() 
{
    if(form.grdInvestigations().getValue() instanceof InvestigationAttendenceDetailVo)
    {
        InvestigationAttendenceDetailVo record = (InvestigationAttendenceDetailVo) form.grdInvestigations().getValue();
        record.setActive(false);

        String[] errors = record.validate();
        if(errors != null && errors.length > 0)
        {
            engine.showErrors(errors);
            return false;
        }

        try 
        {
            domain.save(record);
        } 
        catch (StaleObjectException e) 
        {
            e.printStackTrace();
            engine.showMessage(ConfigFlag.UI.STALE_OBJECT_MESSAGE.getValue());
            populateInvestigationsGrid(form.getLocalContext().getPatient(), form.getLocalContext().getCareContext());
            return false;
        }

        return true;
    }

    return false;
}
项目:openmaxims-linux    文件:Logic.java   
private void editInvestigation() 
{
    if(form.grdInvestigations().getValue() instanceof InvestigationAttendenceDetailVo)
    {
        form.getGlobalContext().Emergency.setInvestigationAttendenceDetail((InvestigationAttendenceDetailVo) form.grdInvestigations().getValue());

        engine.open(form.getForms().Emergency.InvestigationAttendenceDetailDialog);
    }
}
项目:openmaxims-linux    文件:Logic.java   
private boolean doRemoveInvestigation() 
{
    if(form.grdInvestigations().getValue() instanceof InvestigationAttendenceDetailVo)
    {
        InvestigationAttendenceDetailVo record = (InvestigationAttendenceDetailVo) form.grdInvestigations().getValue();
        record.setActive(false);

        String[] errors = record.validate();
        if(errors != null && errors.length > 0)
        {
            engine.showErrors(errors);
            return false;
        }

        try 
        {
            domain.save(record);
        } 
        catch (StaleObjectException e) 
        {
            e.printStackTrace();
            engine.showMessage(ConfigFlag.UI.STALE_OBJECT_MESSAGE.getValue());
            populateInvestigationsGrid(form.getLocalContext().getPatient(), form.getLocalContext().getCareContext());
            return false;
        }

        return true;
    }

    return false;
}
项目:AvoinApotti    文件:Logic.java   
private void updateControlsState() 
{
    form.getContextMenus().Emergency.getInterventionsTreatmentsMenuEDITItem().setVisible(form.getLocalContext().getCareContextIsNotNull() 
            && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled())); //wdev-17637

    form.getContextMenus().Emergency.getInterventionsTreatmentsMenuREMOVEItem().setVisible(form.getLocalContext().getCareContextIsNotNull() 
            && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdInterventionsTreatments().getValue() != null);

    form.getContextMenus().Emergency.getInterventionsTreatmentsMenuMOVE_DOWNItem().setVisible(form.getLocalContext().getCareContextIsNotNull() 
            && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdInterventionsTreatments().getValue() != null 
            && form.grdInterventionsTreatments().canMoveCurrentDown()
            && Boolean.TRUE.equals(form.getLocalContext().getAddedDuringCoding()));
    form.getContextMenus().Emergency.getInterventionsTreatmentsMenuMOVE_UPItem().setVisible(form.getLocalContext().getCareContextIsNotNull() 
            && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdInterventionsTreatments().getValue() != null 
            && form.grdInterventionsTreatments().canMoveCurrentUp()
            && Boolean.TRUE.equals(form.getLocalContext().getAddedDuringCoding()));

    form.getContextMenus().Emergency.getDiagnosisForAttendanceNotesMenuADDItem().setVisible(form.getLocalContext().getCareContextIsNotNull() && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()));
    form.getContextMenus().Emergency.getDiagnosisForAttendanceNotesMenuEDITItem().setVisible(form.getLocalContext().getCareContextIsNotNull() && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdDiagnosis().getValue() != null);
    form.getContextMenus().Emergency.getDiagnosisForAttendanceNotesMenuREMOVEItem().setVisible(form.getLocalContext().getCareContextIsNotNull() && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdDiagnosis().getValue() != null && engine.hasRight(AppRight.ED_ATTENDENCE_NOTES_CAN_RIE_DIAGNOSIS));

    form.getContextMenus().Emergency.getDiagnosisForAttendanceNotesMenuMOVE_DOWNItem().setVisible(form.getLocalContext().getCareContextIsNotNull() 
            && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdDiagnosis().getValue() != null 
            && form.grdDiagnosis().canMoveCurrentDown()
            && Boolean.TRUE.equals(form.getLocalContext().getAddedDuringCoding()));
    form.getContextMenus().Emergency.getDiagnosisForAttendanceNotesMenuMOVE_UPItem().setVisible(form.getLocalContext().getCareContextIsNotNull() 
            && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdDiagnosis().getValue() != null 
            && form.grdDiagnosis().canMoveCurrentUp()
            && Boolean.TRUE.equals(form.getLocalContext().getAddedDuringCoding()));

    form.getContextMenus().Emergency.getInvestigationsForAttendanceNotesMenuADDItem().setVisible(form.getLocalContext().getCareContextIsNotNull() && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()));
    form.getContextMenus().Emergency.getInvestigationsForAttendanceNotesMenuEDITItem().setVisible(form.getLocalContext().getCareContextIsNotNull() && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdInvestigations().getValue() instanceof InvestigationAttendenceDetailVo);
    form.getContextMenus().Emergency.getInvestigationsForAttendanceNotesMenuREMOVEItem().setVisible(form.getLocalContext().getCareContextIsNotNull() && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdInvestigations().getValue() instanceof InvestigationAttendenceDetailVo);

    form.getContextMenus().Emergency.getInvestigationsForAttendanceNotesMenuMOVE_DOWNItem().setVisible(form.getLocalContext().getCareContextIsNotNull() 
            && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdInvestigations().getValue() != null 
            && form.grdInvestigations().canMoveCurrentDown()
            && Boolean.TRUE.equals(form.getLocalContext().getAddedDuringCoding()));
    form.getContextMenus().Emergency.getInvestigationsForAttendanceNotesMenuMOVE_UPItem().setVisible(form.getLocalContext().getCareContextIsNotNull() 
            && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdInvestigations().getValue() != null 
            && form.grdInvestigations().canMoveCurrentUp()
            && Boolean.TRUE.equals(form.getLocalContext().getAddedDuringCoding()));

    boolean bShowSaveCancel = false;
    if (Boolean.TRUE.equals(form.getLocalContext().getInterventionSequenceChanged()) //WDEV-18335
            || Boolean.TRUE.equals(form.getLocalContext().getInvestigationsSequenceChanged())
            || Boolean.TRUE.equals(form.getLocalContext().getDiagnosisSequenceChanged()))
        bShowSaveCancel = true;
        form.btnSave().setVisible(bShowSaveCancel);
        form.btnCancel().setVisible(bShowSaveCancel);
        form.btnSave().setEnabled(bShowSaveCancel);
        form.btnCancel().setEnabled(bShowSaveCancel);
}
项目:AvoinApotti    文件:InterventionsDiagnosisInvestigationsCcImpl.java   
public InvestigationAttendenceDetailVo save(InvestigationAttendenceDetailVo record) throws StaleObjectException 
{
    InvestigationAttendenceDetailDialog impl = (InvestigationAttendenceDetailDialog) getDomainImpl(InvestigationAttendenceDetailDialogImpl.class);
    return impl.save(record);
}
项目:openMAXIMS    文件:InvestigationAttendenceDetailDialogImpl.java   
public ims.emergency.vo.InvestigationAttendenceDetailVo save(ims.emergency.vo.InvestigationAttendenceDetailVo record, InvestigationsForAttendVo investigationsForAttend) throws ims.domain.exceptions.StaleObjectException
{
    if(record == null)
        throw new CodingRuntimeException("Cannot save a null InvestigationAttendenceDetailVo.");

    if(!record.isValidated())
        throw new CodingRuntimeException("InvestigationAttendenceDetailVo is not validated.");

    DomainFactory factory = getDomainFactory();

    InvestigationAttendenceDetail doRecord = InvestigationAttendenceDetailVoAssembler.extractInvestigationAttendenceDetail(factory, record);
    factory.save(doRecord);

    InvestigationAttendenceDetailVo newRecord = InvestigationAttendenceDetailVoAssembler.create(doRecord);

    if(investigationsForAttend != null)
    {
        if(record.getID_InvestigationAttendenceDetail() == null)
        {
            if(investigationsForAttend.getInvestigations() == null)
            {
                investigationsForAttend.setInvestigations(new InvestigationAttendenceDetailVoCollection());
            }

            investigationsForAttend.getInvestigations().add(newRecord);

            InvestigationsForAttend doInvestigationsForAttend = InvestigationsForAttendVoAssembler.extractInvestigationsForAttend(factory, investigationsForAttend);
            factory.save(doInvestigationsForAttend);
        }

        //WDEV-19057
        if(!Boolean.TRUE.equals(record.getAddedDuringCoding()))
        {
            AttendDiagInvTreatStatusVo attendDiagInvTreatStatus = getAttendDiagInvTreatStatus(investigationsForAttend.getAttendance());
            if (attendDiagInvTreatStatus != null && (Boolean.TRUE.equals(attendDiagInvTreatStatus.getNoInvestigations()) || Boolean.TRUE.equals(attendDiagInvTreatStatus.getInvestigationNotRecorded())))
            {
                attendDiagInvTreatStatus.setNoInvestigations(null);
                attendDiagInvTreatStatus.setInvestigationNotRecorded(null);

                AttendDiagInvTreatStatus doAttendDiagInvTreatStatus = AttendDiagInvTreatStatusVoAssembler.extractAttendDiagInvTreatStatus(factory, attendDiagInvTreatStatus);
                factory.save(doAttendDiagInvTreatStatus);
            }
        }
    }

    return newRecord;
}
项目:openMAXIMS    文件:Logic.java   
private void updateControlsState() 
{
    form.getContextMenus().Emergency.getInterventionsTreatmentsMenuEDITItem().setVisible(form.getLocalContext().getCareContextIsNotNull() 
            && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled())); //wdev-17637

    form.getContextMenus().Emergency.getInterventionsTreatmentsMenuREMOVEItem().setVisible(form.getLocalContext().getCareContextIsNotNull() 
            && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdInterventionsTreatments().getValue() != null);

    form.getContextMenus().Emergency.getInterventionsTreatmentsMenuMOVE_DOWNItem().setVisible(form.getLocalContext().getCareContextIsNotNull() 
            && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdInterventionsTreatments().getValue() != null 
            && form.grdInterventionsTreatments().canMoveCurrentDown()
            && Boolean.TRUE.equals(form.getLocalContext().getAddedDuringCoding()));
    form.getContextMenus().Emergency.getInterventionsTreatmentsMenuMOVE_UPItem().setVisible(form.getLocalContext().getCareContextIsNotNull() 
            && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdInterventionsTreatments().getValue() != null 
            && form.grdInterventionsTreatments().canMoveCurrentUp()
            && Boolean.TRUE.equals(form.getLocalContext().getAddedDuringCoding()));

    form.getContextMenus().Emergency.getDiagnosisForAttendanceNotesMenuADDItem().setVisible(form.getLocalContext().getCareContextIsNotNull() && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()));
    form.getContextMenus().Emergency.getDiagnosisForAttendanceNotesMenuEDITItem().setVisible(form.getLocalContext().getCareContextIsNotNull() && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdDiagnosis().getValue() != null);
    form.getContextMenus().Emergency.getDiagnosisForAttendanceNotesMenuREMOVEItem().setVisible(form.getLocalContext().getCareContextIsNotNull() && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdDiagnosis().getValue() != null && engine.hasRight(AppRight.ED_ATTENDENCE_NOTES_CAN_RIE_DIAGNOSIS));

    form.getContextMenus().Emergency.getDiagnosisForAttendanceNotesMenuMOVE_DOWNItem().setVisible(form.getLocalContext().getCareContextIsNotNull() 
            && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdDiagnosis().getValue() != null 
            && form.grdDiagnosis().canMoveCurrentDown()
            && Boolean.TRUE.equals(form.getLocalContext().getAddedDuringCoding()));
    form.getContextMenus().Emergency.getDiagnosisForAttendanceNotesMenuMOVE_UPItem().setVisible(form.getLocalContext().getCareContextIsNotNull() 
            && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdDiagnosis().getValue() != null 
            && form.grdDiagnosis().canMoveCurrentUp()
            && Boolean.TRUE.equals(form.getLocalContext().getAddedDuringCoding()));

    form.getContextMenus().Emergency.getInvestigationsForAttendanceNotesMenuADDItem().setVisible(form.getLocalContext().getCareContextIsNotNull() && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()));
    form.getContextMenus().Emergency.getInvestigationsForAttendanceNotesMenuEDITItem().setVisible(form.getLocalContext().getCareContextIsNotNull() && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdInvestigations().getValue() instanceof InvestigationAttendenceDetailVo);
    form.getContextMenus().Emergency.getInvestigationsForAttendanceNotesMenuREMOVEItem().setVisible(form.getLocalContext().getCareContextIsNotNull() && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdInvestigations().getValue() instanceof InvestigationAttendenceDetailVo);

    form.getContextMenus().Emergency.getInvestigationsForAttendanceNotesMenuMOVE_DOWNItem().setVisible(form.getLocalContext().getCareContextIsNotNull() 
            && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdInvestigations().getValue() != null 
            && form.grdInvestigations().canMoveCurrentDown()
            && Boolean.TRUE.equals(form.getLocalContext().getAddedDuringCoding()));
    form.getContextMenus().Emergency.getInvestigationsForAttendanceNotesMenuMOVE_UPItem().setVisible(form.getLocalContext().getCareContextIsNotNull() 
            && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdInvestigations().getValue() != null 
            && form.grdInvestigations().canMoveCurrentUp()
            && Boolean.TRUE.equals(form.getLocalContext().getAddedDuringCoding()));

    boolean bShowSaveCancel = false;
    if (Boolean.TRUE.equals(form.getLocalContext().getInterventionSequenceChanged()) //WDEV-18335
            || Boolean.TRUE.equals(form.getLocalContext().getInvestigationsSequenceChanged())
            || Boolean.TRUE.equals(form.getLocalContext().getDiagnosisSequenceChanged()))
        bShowSaveCancel = true;
        form.btnSave().setVisible(bShowSaveCancel);
        form.btnCancel().setVisible(bShowSaveCancel);
        form.btnSave().setEnabled(bShowSaveCancel);
        form.btnCancel().setEnabled(bShowSaveCancel);
}
项目:openMAXIMS    文件:InterventionsDiagnosisInvestigationsCcImpl.java   
public InvestigationAttendenceDetailVo save(InvestigationAttendenceDetailVo record) throws StaleObjectException 
{
    InvestigationAttendenceDetailDialog impl = (InvestigationAttendenceDetailDialog) getDomainImpl(InvestigationAttendenceDetailDialogImpl.class);
    return impl.save(record);
}
项目:openmaxims-linux    文件:Logic.java   
private void updateControlsState() 
{
    form.getContextMenus().Emergency.getInterventionsTreatmentsMenuEDITItem().setVisible(form.getLocalContext().getCareContextIsNotNull() 
            && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled())); //wdev-17637

    form.getContextMenus().Emergency.getInterventionsTreatmentsMenuREMOVEItem().setVisible(form.getLocalContext().getCareContextIsNotNull() 
            && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdInterventionsTreatments().getValue() != null);

    form.getContextMenus().Emergency.getInterventionsTreatmentsMenuMOVE_DOWNItem().setVisible(form.getLocalContext().getCareContextIsNotNull() 
            && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdInterventionsTreatments().getValue() != null 
            && form.grdInterventionsTreatments().canMoveCurrentDown()
            && Boolean.TRUE.equals(form.getLocalContext().getAddedDuringCoding()));
    form.getContextMenus().Emergency.getInterventionsTreatmentsMenuMOVE_UPItem().setVisible(form.getLocalContext().getCareContextIsNotNull() 
            && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdInterventionsTreatments().getValue() != null 
            && form.grdInterventionsTreatments().canMoveCurrentUp()
            && Boolean.TRUE.equals(form.getLocalContext().getAddedDuringCoding()));

    form.getContextMenus().Emergency.getDiagnosisForAttendanceNotesMenuADDItem().setVisible(form.getLocalContext().getCareContextIsNotNull() && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()));
    form.getContextMenus().Emergency.getDiagnosisForAttendanceNotesMenuEDITItem().setVisible(form.getLocalContext().getCareContextIsNotNull() && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdDiagnosis().getValue() != null);
    form.getContextMenus().Emergency.getDiagnosisForAttendanceNotesMenuREMOVEItem().setVisible(form.getLocalContext().getCareContextIsNotNull() && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdDiagnosis().getValue() != null && engine.hasRight(AppRight.ED_ATTENDENCE_NOTES_CAN_RIE_DIAGNOSIS));

    form.getContextMenus().Emergency.getDiagnosisForAttendanceNotesMenuMOVE_DOWNItem().setVisible(form.getLocalContext().getCareContextIsNotNull() 
            && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdDiagnosis().getValue() != null 
            && form.grdDiagnosis().canMoveCurrentDown()
            && Boolean.TRUE.equals(form.getLocalContext().getAddedDuringCoding()));
    form.getContextMenus().Emergency.getDiagnosisForAttendanceNotesMenuMOVE_UPItem().setVisible(form.getLocalContext().getCareContextIsNotNull() 
            && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdDiagnosis().getValue() != null 
            && form.grdDiagnosis().canMoveCurrentUp()
            && Boolean.TRUE.equals(form.getLocalContext().getAddedDuringCoding()));

    form.getContextMenus().Emergency.getInvestigationsForAttendanceNotesMenuADDItem().setVisible(form.getLocalContext().getCareContextIsNotNull() && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()));
    form.getContextMenus().Emergency.getInvestigationsForAttendanceNotesMenuEDITItem().setVisible(form.getLocalContext().getCareContextIsNotNull() && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdInvestigations().getValue() instanceof InvestigationAttendenceDetailVo);
    form.getContextMenus().Emergency.getInvestigationsForAttendanceNotesMenuREMOVEItem().setVisible(form.getLocalContext().getCareContextIsNotNull() && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdInvestigations().getValue() instanceof InvestigationAttendenceDetailVo);

    form.getContextMenus().Emergency.getInvestigationsForAttendanceNotesMenuMOVE_DOWNItem().setVisible(form.getLocalContext().getCareContextIsNotNull() 
            && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdInvestigations().getValue() != null 
            && form.grdInvestigations().canMoveCurrentDown()
            && Boolean.TRUE.equals(form.getLocalContext().getAddedDuringCoding()));
    form.getContextMenus().Emergency.getInvestigationsForAttendanceNotesMenuMOVE_UPItem().setVisible(form.getLocalContext().getCareContextIsNotNull() 
            && Boolean.TRUE.equals(form.getLocalContext().getIsEnabled()) && form.grdInvestigations().getValue() != null 
            && form.grdInvestigations().canMoveCurrentUp()
            && Boolean.TRUE.equals(form.getLocalContext().getAddedDuringCoding()));

    boolean bShowSaveCancel = false;
    if (Boolean.TRUE.equals(form.getLocalContext().getInterventionSequenceChanged()) //WDEV-18335
            || Boolean.TRUE.equals(form.getLocalContext().getInvestigationsSequenceChanged())
            || Boolean.TRUE.equals(form.getLocalContext().getDiagnosisSequenceChanged()))
        bShowSaveCancel = true;
        form.btnSave().setVisible(bShowSaveCancel);
        form.btnCancel().setVisible(bShowSaveCancel);
        form.btnSave().setEnabled(bShowSaveCancel);
        form.btnCancel().setEnabled(bShowSaveCancel);
}
项目:openmaxims-linux    文件:InterventionsDiagnosisInvestigationsCcImpl.java   
public InvestigationAttendenceDetailVo save(InvestigationAttendenceDetailVo record) throws StaleObjectException 
{
    InvestigationAttendenceDetailDialog impl = (InvestigationAttendenceDetailDialog) getDomainImpl(InvestigationAttendenceDetailDialogImpl.class);
    return impl.save(record);
}