Index: denali.pro =================================================================== diff -u -r3b4b381d23c267fbc5af29f29e231f03e26ca23b -r7ed86349cdad43d311f776a69ed54c2023265e53 --- denali.pro (.../denali.pro) (revision 3b4b381d23c267fbc5af29f29e231f03e26ca23b) +++ denali.pro (.../denali.pro) (revision 7ed86349cdad43d311f776a69ed54c2023265e53) @@ -51,8 +51,6 @@ sources/main.h \ sources/model/MDGDebugText.h \ sources/model/MHDDebugText.h \ - sources/model/hd/adjustment/MTreatmentAdjustSalineResponse.h \ - sources/model/hd/data/MTreatmentSalineData.h \ sources/storage/DriveWatcher.h \ sources/threads.h \ sources/maintimer.h \ @@ -74,6 +72,7 @@ sources/model/hd/adjustment/MTreatmentAdjustUltrafiltrationStateResponse.h \ sources/model/hd/adjustment/MTreatmentAdjustUltrafiltrationEditResponse.h \ sources/model/hd/adjustment/MTreatmentAdjustUltrafiltrationConfirmResponse.h \ + sources/model/hd/adjustment/MTreatmentAdjustSalineResponse.h \ \ # ---------- Models - HD - Data sources/model/hd/data/MTreatmentTimeData.h \ sources/model/hd/data/MTreatmentFlowsData.h \ @@ -82,6 +81,7 @@ sources/model/hd/data/MTreatmentPressureOcclusionData.h \ sources/model/hd/data/MTreatmentStatesData.h \ sources/model/hd/data/MHDOperationModeData.h \ + sources/model/hd/data/MTreatmentSalineData.h \ \ # ---------- Models - DG - Data sources/model/dg/data/MDGDrainPumpData.h \ sources/model/dg/data/MDGHeatersData.h \ @@ -126,13 +126,15 @@ sources/view/vtreatmentultrafiltration.h \ sources/view/vtreatmentranges.h \ sources/view/vtreatmentpressureocclusion.h \ + sources/view/VTreatmentSalineData.h \ \ # Treatment Adjustments sources/view/vtreatmentadjustmentresponsebase.h \ sources/view/vtreatmentadjustmentduration.h \ sources/view/vtreatmentadjustmentflows.h \ sources/view/vtreatmentadjustmentultrafiltrationstate.h \ sources/view/vtreatmentadjustmentultrafiltrationedit.h \ sources/view/vtreatmentadjustmentultrafiltrationconfirm.h \ + sources/view/VTreatmentAdjustmentSaline.h \ \ # Storage sources/storage/storageglobals.h \ sources/storage/filehandler.h \ @@ -151,8 +153,6 @@ main.cpp \ sources/model/MDGDebugText.cpp \ sources/model/MHDDebugText.cpp \ - sources/model/hd/adjustment/MTreatmentAdjustSalineResponse.cpp \ - sources/model/hd/data/MTreatmentSalineData.cpp \ sources/storage/DriveWatcher.cpp \ sources/threads.cpp \ sources/maintimer.cpp \ @@ -172,6 +172,7 @@ sources/model/hd/adjustment/MTreatmentAdjustUltrafiltrationStateResponse.cpp \ sources/model/hd/adjustment/MTreatmentAdjustUltrafiltrationEditResponse.cpp \ sources/model/hd/adjustment/MTreatmentAdjustUltrafiltrationConfirmResponse.cpp \ + sources/model/hd/adjustment/MTreatmentAdjustSalineResponse.cpp \ \ # ---------- Models - HD - Data sources/model/hd/data/MTreatmentTimeData.cpp \ sources/model/hd/data/MTreatmentFlowsData.cpp \ @@ -180,6 +181,7 @@ sources/model/hd/data/MTreatmentPressureOcclusionData.cpp \ sources/model/hd/data/MTreatmentStatesData.cpp \ sources/model/hd/data/MHDOperationModeData.cpp \ + sources/model/hd/data/MTreatmentSalineData.cpp \ \ # ---------- Models - DG - Data sources/model/dg/data/MDGDrainPumpData.cpp \ sources/model/dg/data/MDGHeatersData.cpp \ @@ -222,13 +224,15 @@ sources/view/vtreatmentultrafiltration.cpp \ sources/view/vtreatmentranges.cpp \ sources/view/vtreatmentpressureocclusion.cpp \ + sources/view/VTreatmentSalineData.cpp \ \ # Treatment Adjustments sources/view/vtreatmentadjustmentresponsebase.cpp \ sources/view/vtreatmentadjustmentduration.cpp \ sources/view/vtreatmentadjustmentflows.cpp \ sources/view/vtreatmentadjustmentultrafiltrationstate.cpp \ sources/view/vtreatmentadjustmentultrafiltrationedit.cpp \ sources/view/vtreatmentadjustmentultrafiltrationconfirm.cpp \ + sources/view/VTreatmentAdjustmentSaline.cpp \ \ # Storage sources/storage/storageglobals.cpp \ sources/storage/filehandler.cpp \ Index: denali.qrc =================================================================== diff -u -r73b965e55528619f22a12ae3b3408c9dcecc9144 -r7ed86349cdad43d311f776a69ed54c2023265e53 --- denali.qrc (.../denali.qrc) (revision 73b965e55528619f22a12ae3b3408c9dcecc9144) +++ denali.qrc (.../denali.qrc) (revision 7ed86349cdad43d311f776a69ed54c2023265e53) @@ -93,6 +93,7 @@ sources/gui/qml/pages/treatment/sections/TreatmentUltrafiltration.qml sources/gui/qml/pages/treatment/sections/TreatmentFluid.qml sources/gui/qml/pages/treatment/sections/TreatmentTime.qml + sources/gui/qml/pages/treatment/sections/TreatmentSaline.qml sources/gui/qml/pages/treatment/adjustments/TreatmentAdjustmentFlow.qml Index: sources/canbus/messagedispatcher.cpp =================================================================== diff -u -rbf645acccabb7b5a84801620c4f7fa0b0e6878e0 -r7ed86349cdad43d311f776a69ed54c2023265e53 --- sources/canbus/messagedispatcher.cpp (.../messagedispatcher.cpp) (revision bf645acccabb7b5a84801620c4f7fa0b0e6878e0) +++ sources/canbus/messagedispatcher.cpp (.../messagedispatcher.cpp) (revision 7ed86349cdad43d311f776a69ed54c2023265e53) @@ -281,7 +281,20 @@ onActionTransmit(GuiActionType::ID_AdjustUltrafiltrationConfirmReq, mData); } +/*! + * \brief MessageDispatcher::onAdjustment + * \details This method transmits the Saline Bolus Adjustment Denali message. + * \param vData - Data model contains treatment Saline Bolus adjustment state. + * \return void + */ +void MessageDispatcher::onAdjustment(const AdjustSalineRequestData &vData) +{ + QVariantList mData; + mData += vData.requestedState; + onActionTransmit(GuiActionType::ID_AdjustSalineReq, mData); +} + /*! * \brief MessageDispatcher::actionTransmit * \details This method is called by slot MessageDispatcher::onActionTransmit Index: sources/canbus/messageglobals.h =================================================================== diff -u -rd2035a8728794afeefaa244bf8d1597926d945f5 -r7ed86349cdad43d311f776a69ed54c2023265e53 --- sources/canbus/messageglobals.h (.../messageglobals.h) (revision d2035a8728794afeefaa244bf8d1597926d945f5) +++ sources/canbus/messageglobals.h (.../messageglobals.h) (revision 7ed86349cdad43d311f776a69ed54c2023265e53) @@ -54,6 +54,7 @@ {Gui::GuiActionType::ID_DialysateInletFlow , 7 * 4 }, // 7 parameters each 4bytes {Gui::GuiActionType::ID_DialysateOutletFlow , 7 * 4 }, // 7 parameters each 4bytes {Gui::GuiActionType::ID_PressureOcclusion , 5 * 4 }, // 5 parameters each 4bytes + {Gui::GuiActionType::ID_Saline , 3 * 4 }, // 3 parameters each 4bytes // ---- {Gui::GuiActionType::ID_HDOperationModeData , 1 * 4 }, // 1 parameter each 4bytes @@ -96,10 +97,14 @@ {Gui::GuiActionType::ID_AdjustUltrafiltrationEditRsp , 8 * 4 }, // 8 parameters each 4bytes // ---- - {Gui::GuiActionType::ID_AdjustUltrafiltrationConfirmReq , 2 * 4 }, // 2 parameters each 4bytes - {Gui::GuiActionType::ID_AdjustUltrafiltrationConfirmRsp , 5 * 4 }, + {Gui::GuiActionType::ID_AdjustUltrafiltrationConfirmReq , 2 * 4 }, // 2 parameters each 4bytes + {Gui::GuiActionType::ID_AdjustUltrafiltrationConfirmRsp , 5 * 4 }, // ---- + {Gui::GuiActionType::ID_AdjustSalineReq , 1 * 4 }, // 1 parameter each 4bytes + {Gui::GuiActionType::ID_AdjustSalineRsp , 3 * 4 }, // 3 parameters each 4bytes + + // ---- {Gui::GuiActionType::ID_CANBusFaultCount , 1 }, {Gui::GuiActionType::ID_RawData , 255 }, {Gui::GuiActionType::ID_Acknow , 0 }, Index: sources/canbus/messageinterpreter.cpp =================================================================== diff -u -r74005a93d93ec4b12230bac72ed29b948eb1aa0a -r7ed86349cdad43d311f776a69ed54c2023265e53 --- sources/canbus/messageinterpreter.cpp (.../messageinterpreter.cpp) (revision 74005a93d93ec4b12230bac72ed29b948eb1aa0a) +++ sources/canbus/messageinterpreter.cpp (.../messageinterpreter.cpp) (revision 7ed86349cdad43d311f776a69ed54c2023265e53) @@ -236,6 +236,12 @@ LOG_EVENT(AdjustUltrafiltrationConfirmRequestData::toString(vData)); break; + case Gui::GuiActionType::ID_AdjustSalineReq: + if ( ! count ) { logInvalidLength(vActionId); return false; } + vPayload = Format::fromVariant(vData); + LOG_EVENT(AdjustSalineRequestData::toString(vData)); + break; + case Gui::GuiActionType::ID_AlarmSilenceReq: if ( ! count ) { logInvalidLength(vActionId); return false; } vPayload = Format::fromVariant(vData); @@ -314,6 +320,7 @@ case Gui::GuiActionType::ID_TreatmentRanges : ok = notify(vMessage, vData, Gui::GuiActionType::ID_TreatmentRanges ); break; case Gui::GuiActionType::ID_PressureOcclusion : ok = notify(vMessage, vData, Gui::GuiActionType::ID_PressureOcclusion ); break; case Gui::GuiActionType::ID_TreatmentStates : ok = notify(vMessage, vData, Gui::GuiActionType::ID_TreatmentStates ); break; + case Gui::GuiActionType::ID_Saline : ok = notify(vMessage, vData, Gui::GuiActionType::ID_Saline ); break; // ----- Events case Gui::GuiActionType::ID_HDOperationModeData : ok = notify(vMessage, vData, Gui::GuiActionType::ID_HDOperationModeData ); break; @@ -329,11 +336,12 @@ // Adjustment Response Messages case Gui::GuiActionType::ID_AdjustDurationRsp : ok = notify(vMessage, vData, Gui::GuiActionType::ID_AdjustDurationRsp ); break; case Gui::GuiActionType::ID_AdjustBloodDialysateRsp : ok = notify(vMessage, vData, Gui::GuiActionType::ID_AdjustBloodDialysateRsp); break; + case Gui::GuiActionType::ID_AdjustSalineRsp : ok = notify(vMessage, vData, Gui::GuiActionType::ID_AdjustSalineRsp ); break; case Gui::GuiActionType::ID_AdjustUltrafiltrationStateReq : ok = adjustUltrafiltrationState (vMessage, vData); break; // TODO : implement notify<>() case Gui::GuiActionType::ID_AdjustUltrafiltrationEditRsp : ok = adjustUltrafiltrationEdit (vMessage, vData); break; // TODO : implement notify<>() case Gui::GuiActionType::ID_AdjustUltrafiltrationConfirmRsp : ok = adjustUltrafiltrationConfirm (vMessage, vData); break; // TODO : implement notify<>() - // unhandles messages: these will only be logged as received message + // unhandled messages: these will only be logged as received message // there has nothing been defined for these messages. default : printUnhandled (vMessage ); break; } Index: sources/gui/guiglobals.cpp =================================================================== diff -u -r9a7be58dc7d9d8a2b502a91b684dd4b046b6a96a -r7ed86349cdad43d311f776a69ed54c2023265e53 --- sources/gui/guiglobals.cpp (.../guiglobals.cpp) (revision 9a7be58dc7d9d8a2b502a91b684dd4b046b6a96a) +++ sources/gui/guiglobals.cpp (.../guiglobals.cpp) (revision 7ed86349cdad43d311f776a69ed54c2023265e53) @@ -36,6 +36,7 @@ #include "vtreatmenttime.h" #include "vtreatmentranges.h" #include "VHDOperationModeData.h" +#include "VTreatmentSalineData.h" #include "VDGDrainPumpData.h" #include "VDGHeatersData.h" @@ -51,6 +52,7 @@ #include "vtreatmentadjustmentflows.h" #include "vtreatmentadjustmentultrafiltrationedit.h" #include "vtreatmentadjustmentultrafiltrationconfirm.h" +#include "VTreatmentAdjustmentSaline.h" namespace Gui { QQuickView *_viewer = nullptr; Index: sources/gui/guiglobals.h =================================================================== diff -u -rd2035a8728794afeefaa244bf8d1597926d945f5 -r7ed86349cdad43d311f776a69ed54c2023265e53 --- sources/gui/guiglobals.h (.../guiglobals.h) (revision d2035a8728794afeefaa244bf8d1597926d945f5) +++ sources/gui/guiglobals.h (.../guiglobals.h) (revision 7ed86349cdad43d311f776a69ed54c2023265e53) @@ -64,12 +64,13 @@ ID_TreatmentRanges = 0x1A00, // 26 ID_PressureOcclusion = 0x0900, ID_TreatmentStates = 0x0F00, // 15 + ID_Saline = 0x2F00, // 47 ID_AlarmStatus = 0x0200, ID_AlarmTriggered = 0x0300, ID_AlarmCleared = 0x0400, - ID_AlarmSilenceReq = 0x2F00, // 47 - Not implemented yet on FW side - ID_AlarmSilenceRsp = 0x3000, // 48 - Not implemented yet on FW side + ID_AlarmSilenceReq = 0x3200, // 50 - Not implemented yet on FW side + ID_AlarmSilenceRsp = 0x0000, // Needs to be removed. ID_HDOperationModeData = 0x2500, // 37 @@ -97,6 +98,10 @@ ID_AdjustDurationReq = 0x1600, // 22 ID_AdjustDurationRsp = 0x1B00, // 27 + + ID_AdjustSalineReq = 0x1200, // 18 + ID_AdjustSalineRsp = 0x1400, // 20 + }; enum class GuiActionsData_Enum /*: quint8 QML doesn't support*/ { Index: sources/gui/qml/globals/Variables.qml =================================================================== diff -u -rd2035a8728794afeefaa244bf8d1597926d945f5 -r7ed86349cdad43d311f776a69ed54c2023265e53 --- sources/gui/qml/globals/Variables.qml (.../Variables.qml) (revision d2035a8728794afeefaa244bf8d1597926d945f5) +++ sources/gui/qml/globals/Variables.qml (.../Variables.qml) (revision 7ed86349cdad43d311f776a69ed54c2023265e53) @@ -110,4 +110,8 @@ // - Vitals readonly property string unitTextBloodPressure : qsTr("mmHg") readonly property string unitTextHeartBeat : qsTr("BPM" ) + // - Fluid + readonly property string unitTextSaline : qsTr("mL") + readonly property string unitTextHeparin : qsTr("mL") + } Index: sources/gui/qml/main.qml =================================================================== diff -u -r9cc1608f615e66d0f1c3a022aa6d19579d76b241 -r7ed86349cdad43d311f776a69ed54c2023265e53 --- sources/gui/qml/main.qml (.../main.qml) (revision 9cc1608f615e66d0f1c3a022aa6d19579d76b241) +++ sources/gui/qml/main.qml (.../main.qml) (revision 7ed86349cdad43d311f776a69ed54c2023265e53) @@ -103,6 +103,7 @@ _alarm_dialog.visible = false; } } + VPowerOff { id: vPowerOff } VHDOperationMode { id: vHDOperationMode } VTreatmentBloodFlow { id: vTreatmentBloodFlow } Index: sources/gui/qml/pages/treatment/TreatmentStack.qml =================================================================== diff -u -rd2035a8728794afeefaa244bf8d1597926d945f5 -r7ed86349cdad43d311f776a69ed54c2023265e53 --- sources/gui/qml/pages/treatment/TreatmentStack.qml (.../TreatmentStack.qml) (revision d2035a8728794afeefaa244bf8d1597926d945f5) +++ sources/gui/qml/pages/treatment/TreatmentStack.qml (.../TreatmentStack.qml) (revision 7ed86349cdad43d311f776a69ed54c2023265e53) @@ -1,23 +1,24 @@ /*! - * + * * Copyright (c) 2019-2020 Diality Inc. - All Rights Reserved. * \copyright * THIS CODE MAY NOT BE COPIED OR REPRODUCED IN ANY FORM, IN PART OR IN * WHOLE, WITHOUT THE EXPLICIT PERMISSION OF THE COPYRIGHT OWNER. - * + * * \file TreatmentStack.qml - * \author (last) Behrouz NemaiPour + * \author (last) Behrouz NematiPour * \date (last) 18-Jun-2020 * \author (original) Behrouz NematiPour * \date (original) 27-Jan-2020 - * + * */ // Qt import QtQuick 2.12 // Project import VTreatmentRanges 0.1 +import VTreatmentAdjustmentSaline 0.1; // Qml imports import "qrc:/globals" @@ -34,8 +35,11 @@ stackView.initialItem : _treatmentHome - VTreatmentRanges { id: vTreatmentRanges } + // Views + VTreatmentRanges { id: vTreatmentRanges } + VTreatmentAdjustmentSaline { id: vTreatmentAdjustmentSaline } + // Components MainMenu { id: _treatmentMenu y : -Variables.mainMenuHeight position : MainMenu.Position.Top @@ -198,4 +202,5 @@ _treatmentAdjustmentUltrafiltrationConfirm.notification.text = vTreatmentAdjustmentUltrafiltrationConfirm.text() } } - }} + } +} Index: sources/gui/qml/pages/treatment/TreatmentStart.qml =================================================================== diff -u -r44a85c96ab55e424866ec4cca0270aa218355f82 -r7ed86349cdad43d311f776a69ed54c2023265e53 --- sources/gui/qml/pages/treatment/TreatmentStart.qml (.../TreatmentStart.qml) (revision 44a85c96ab55e424866ec4cca0270aa218355f82) +++ sources/gui/qml/pages/treatment/TreatmentStart.qml (.../TreatmentStart.qml) (revision 7ed86349cdad43d311f776a69ed54c2023265e53) @@ -102,15 +102,11 @@ } } Line { x: rightLinesX; y: row1LineY; length: lineLength } - TreatmentFluid { id: _SalineTouchArea - // TODO : Another component should be inherited from this for Saline - buttonText: qsTr("START BOLUS") - + TreatmentSaline { id: _SalineTouchArea x : rightColumnX y : row2Y width : areaWidth height : areaHeightRow2 - title : qsTr("SALINE BOLUS") } Line { x: rightLinesX; y: row2LineY; length: lineLength; } TreatmentFluid { id: _heparinTouchArea Index: sources/gui/qml/pages/treatment/sections/TreatmentFluid.qml =================================================================== diff -u -r44a85c96ab55e424866ec4cca0270aa218355f82 -r7ed86349cdad43d311f776a69ed54c2023265e53 --- sources/gui/qml/pages/treatment/sections/TreatmentFluid.qml (.../TreatmentFluid.qml) (revision 44a85c96ab55e424866ec4cca0270aa218355f82) +++ sources/gui/qml/pages/treatment/sections/TreatmentFluid.qml (.../TreatmentFluid.qml) (revision 7ed86349cdad43d311f776a69ed54c2023265e53) @@ -26,22 +26,27 @@ * \brief Treatment Screen Fluid Management section */ TouchArea { id: _root - x : 0 - y : 0 - width : 200 - height : 200 - isTouchable: false - title: qsTr("FLUID MANAGEMENT") property int rowTextSpacing : 10 property int volumeTextWidth: 60 property bool cumulativeVisible: true - // may need to be removed later when created separate Saline/Heparin object property string buttonText: "" - TouchRect { id: _startButton + property string unit + property alias valueTarget : _fluidTarget .value + property alias valueCumulative : _cumulativeValue .value + property alias valueDelivered : _fluidProgressBar .value + + x : 0 + y : 0 + width : 200 + height : 200 + isTouchable: false + title: qsTr("FLUID MANAGEMENT") + + TouchRect { id: _startFluidButton y : 45 width : 340 height : 55 @@ -53,11 +58,14 @@ } animated: true duration: 100 + onClicked: { + _root.clicked() + } } ProgressBar { id: _fluidProgressBar anchors { - top: _startButton.bottom + top: _startFluidButton.bottom topMargin: 50 } width : parent.width @@ -78,13 +86,14 @@ text: qsTr("Volume Delivered") font.pixelSize: Fonts.fontPixelFluidText color: Colors.fluidText - Text { id: _fluidVolume + Text { id: _fluidTarget + property real value: 0 width: volumeTextWidth anchors { right: parent.right baseline: parent.baseline } - text: qsTr("(100 mL)") + text: qsTr("(%1 %2)").arg(value).arg(_root.unit) font.pixelSize: Fonts.fontPixelFluidVolume color: Colors.fluidUnit } @@ -94,7 +103,7 @@ rightMargin: volumeTextWidth + rowTextSpacing baseline: parent.baseline } - text: qsTr("mL") + text: _root.unit font.pixelSize: Fonts.fontPixelFluidUnit color: Colors.fluidUnit } @@ -129,13 +138,12 @@ rightMargin: volumeTextWidth + rowTextSpacing baseline: parent.baseline } - text: qsTr("mL") + text: _root.unit font.pixelSize: Fonts.fontPixelFluidUnit color: Colors.fluidUnit } Text { id: _cumulativeValue - property int valueLast : 0 // needs to be bound to a model to keep cumulative value - property int value : 0 // needs to be bound to a model to keep cumulative value + property real value : 0 anchors { right: _cumulativeUnit.left rightMargin: rowTextSpacing Index: sources/gui/qml/pages/treatment/sections/TreatmentSaline.qml =================================================================== diff -u --- sources/gui/qml/pages/treatment/sections/TreatmentSaline.qml (revision 0) +++ sources/gui/qml/pages/treatment/sections/TreatmentSaline.qml (revision 7ed86349cdad43d311f776a69ed54c2023265e53) @@ -0,0 +1,48 @@ +/*! + * + * Copyright (c) 2019-2020 Diality Inc. - All Rights Reserved. + * \copyright + * THIS CODE MAY NOT BE COPIED OR REPRODUCED IN ANY FORM, IN PART OR IN + * WHOLE, WITHOUT THE EXPLICIT PERMISSION OF THE COPYRIGHT OWNER. + * + * \file TreatmentFluid.qml + * \author (last) Behrouz NematiPour + * \date (last) 08-Jun-2020 + * \author (original) Behrouz NematiPour + * \date (original) 27-Jan-2020 + * + */ + +// Qt +import QtQuick 2.12 + +// Project +import VTreatmentSaline 0.1; + +// Qml imports +import "qrc:/globals" +import "qrc:/components" + +/*! + * \brief Treatment Screen Saline Management section + */ +TreatmentFluid { id: _root + + buttonText : vTreatmentAdjustmentSaline.isStarted ? qsTr("STOP BOLUS") : qsTr("START BOLUS") + title : qsTr("SALINE BOLUS") + unit : Variables.unitTextSaline + + VTreatmentSaline { id: vTreatmentSaline } + + valueTarget : vTreatmentSaline.target ; + valueCumulative: vTreatmentSaline.cumulative .toFixed(0); + valueDelivered : vTreatmentSaline.delivered .toFixed(0); + + onClicked: { + vTreatmentAdjustmentSaline.doAdjustment() + } + notification { + visible: true + text : vTreatmentAdjustmentSaline.adjustment_ReasonText + } +} Index: sources/gui/qml/pages/treatment/sections/TreatmentUltrafiltration.qml =================================================================== diff -u -rd2035a8728794afeefaa244bf8d1597926d945f5 -r7ed86349cdad43d311f776a69ed54c2023265e53 --- sources/gui/qml/pages/treatment/sections/TreatmentUltrafiltration.qml (.../TreatmentUltrafiltration.qml) (revision d2035a8728794afeefaa244bf8d1597926d945f5) +++ sources/gui/qml/pages/treatment/sections/TreatmentUltrafiltration.qml (.../TreatmentUltrafiltration.qml) (revision 7ed86349cdad43d311f776a69ed54c2023265e53) @@ -38,14 +38,15 @@ width : 200 height : 200 - isTouchable : true + isTouchable : ! vTreatmentAdjustmentSaline.isStarted title : qsTr("ULTRAFILTRATION VOLUME") + " " + Variables.unitTextUltrafiltrationVolume notification { imageSource: "qrc:/images/iPauseGray" text : vTreatmentAdjustmentUltrafiltrationState.isPaused ? qsTr("Ultrafiltration Paused") : "" } ProgressBarEx { id: _progressbarex + enabled: ! vTreatmentAdjustmentSaline.isStarted y : 75 width : parent.width height : Variables.progressbarHeight Index: sources/model/MModel.h =================================================================== diff -u -r15de0cd12dad1ea5107c52e5ed89280bc9e29b1d -r7ed86349cdad43d311f776a69ed54c2023265e53 --- sources/model/MModel.h (.../MModel.h) (revision 15de0cd12dad1ea5107c52e5ed89280bc9e29b1d) +++ sources/model/MModel.h (.../MModel.h) (revision 7ed86349cdad43d311f776a69ed54c2023265e53) @@ -27,6 +27,7 @@ #include "MTreatmentPressureOcclusionData.h" #include "MTreatmentRangesData.h" #include "MTreatmentStatesData.h" +#include "MTreatmentSalineData.h" #include "MDGDrainPumpData.h" #include "MDGHeatersData.h" @@ -48,6 +49,7 @@ #include "MTreatmentAdjustUltrafiltrationStateResponse.h" #include "MTreatmentAdjustUltrafiltrationEditResponse.h" #include "MTreatmentAdjustUltrafiltrationConfirmResponse.h" +#include "MTreatmentAdjustSalineResponse.h" /*! * \brief Message interpretation instruction @@ -127,6 +129,7 @@ REGISTER_METATYPE( AlarmTriggeredData ) \ REGISTER_METATYPE( AlarmClearedData ) \ REGISTER_METATYPE( TreatmentStatesData ) \ + REGISTER_METATYPE( TreatmentSalineData ) \ REGISTER_METATYPE( HDOperationModeData ) \ \ REGISTER_METATYPE( DGROPumpData ) \ @@ -141,18 +144,20 @@ \ REGISTER_METATYPE( HDDebugTextData ) \ REGISTER_METATYPE( DGDebugTextData ) \ - \ + /* Request */ \ REGISTER_METATYPE( AdjustBloodDialysateRequestData ) \ REGISTER_METATYPE( AdjustDurationRequestData ) \ REGISTER_METATYPE( AdjustUltrafiltrationStateRequestData ) \ REGISTER_METATYPE( AdjustUltrafiltrationEditRequestData ) \ REGISTER_METATYPE( AdjustUltrafiltrationConfirmRequestData ) \ - \ + REGISTER_METATYPE( AdjustSalineRequestData ) \ + /* Response */ \ REGISTER_METATYPE( AdjustBloodDialysateResponseData ) \ REGISTER_METATYPE( AdjustDurationResponseData ) \ REGISTER_METATYPE( AdjustUltrafiltrationStateResponseData ) \ REGISTER_METATYPE( AdjustUltrafiltrationEditResponseData ) \ - REGISTER_METATYPE( AdjustUltrafiltrationConfirmResponseData ) + REGISTER_METATYPE( AdjustUltrafiltrationConfirmResponseData ) \ + REGISTER_METATYPE( AdjustSalineResponseData ) //===============================================================================// #define ACTION_RECEIVE_MODEL_BRIDGE_CONNECTIONS(vSOURCE) \ @@ -167,6 +172,7 @@ ACTION_RECEIVE_BRIDGE_CONNECTION(vSOURCE, AlarmTriggeredData ) \ ACTION_RECEIVE_BRIDGE_CONNECTION(vSOURCE, AlarmClearedData ) \ ACTION_RECEIVE_BRIDGE_CONNECTION(vSOURCE, TreatmentStatesData ) \ + ACTION_RECEIVE_BRIDGE_CONNECTION(vSOURCE, TreatmentSalineData ) \ ACTION_RECEIVE_BRIDGE_CONNECTION(vSOURCE, HDOperationModeData ) \ \ ACTION_RECEIVE_BRIDGE_CONNECTION(vSOURCE, DGROPumpData ) \ @@ -181,19 +187,21 @@ \ ACTION_RECEIVE_BRIDGE_CONNECTION(vSOURCE, HDDebugTextData ) \ ACTION_RECEIVE_BRIDGE_CONNECTION(vSOURCE, DGDebugTextData ) \ - \ + /* Response */ \ ACTION_RECEIVE_BRIDGE_CONNECTION(vSOURCE, AdjustUltrafiltrationStateResponseData ) \ ACTION_RECEIVE_BRIDGE_CONNECTION(vSOURCE, AdjustBloodDialysateResponseData ) \ ACTION_RECEIVE_BRIDGE_CONNECTION(vSOURCE, AdjustDurationResponseData ) \ ACTION_RECEIVE_BRIDGE_CONNECTION(vSOURCE, AdjustUltrafiltrationEditResponseData ) \ - ACTION_RECEIVE_BRIDGE_CONNECTION(vSOURCE, AdjustUltrafiltrationConfirmResponseData ) -//--------------------------------------------------------------------------------// + ACTION_RECEIVE_BRIDGE_CONNECTION(vSOURCE, AdjustUltrafiltrationConfirmResponseData ) \ + ACTION_RECEIVE_BRIDGE_CONNECTION(vSOURCE, AdjustSalineResponseData ) +// /* Request */ ---------------------------------------------------------// #define ADJUST_TRANSMT_MODEL_BRIDGE_CONNECTIONS(vSOURCE) \ ADJUST_TRANSMT_BRIDGE_CONNECTION(vSOURCE, AdjustBloodDialysateRequestData ) \ ADJUST_TRANSMT_BRIDGE_CONNECTION(vSOURCE, AdjustDurationRequestData ) \ ADJUST_TRANSMT_BRIDGE_CONNECTION(vSOURCE, AdjustUltrafiltrationStateRequestData ) \ ADJUST_TRANSMT_BRIDGE_CONNECTION(vSOURCE, AdjustUltrafiltrationEditRequestData ) \ - ADJUST_TRANSMT_BRIDGE_CONNECTION(vSOURCE, AdjustUltrafiltrationConfirmRequestData ) + ADJUST_TRANSMT_BRIDGE_CONNECTION(vSOURCE, AdjustUltrafiltrationConfirmRequestData ) \ + ADJUST_TRANSMT_BRIDGE_CONNECTION(vSOURCE, AdjustSalineRequestData ) //===============================================================================// #define ACTION_RECEIVE_MODEL_BRIDGE_DEFINITIONS \ ACTION_RECEIVE_BRIDGE_DEFINITION( BloodFlowData ) \ @@ -207,6 +215,7 @@ ACTION_RECEIVE_BRIDGE_DEFINITION( AlarmTriggeredData ) \ ACTION_RECEIVE_BRIDGE_DEFINITION( AlarmClearedData ) \ ACTION_RECEIVE_BRIDGE_DEFINITION( TreatmentStatesData ) \ + ACTION_RECEIVE_BRIDGE_DEFINITION( TreatmentSalineData ) \ ACTION_RECEIVE_BRIDGE_DEFINITION( HDOperationModeData ) \ \ ACTION_RECEIVE_BRIDGE_DEFINITION( DGROPumpData ) \ @@ -221,33 +230,37 @@ \ ACTION_RECEIVE_BRIDGE_DEFINITION( HDDebugTextData ) \ ACTION_RECEIVE_BRIDGE_DEFINITION( DGDebugTextData ) \ - \ + /* Response */ \ ACTION_RECEIVE_BRIDGE_DEFINITION( AdjustUltrafiltrationStateResponseData ) \ ACTION_RECEIVE_BRIDGE_DEFINITION( AdjustBloodDialysateResponseData ) \ ACTION_RECEIVE_BRIDGE_DEFINITION( AdjustDurationResponseData ) \ ACTION_RECEIVE_BRIDGE_DEFINITION( AdjustUltrafiltrationEditResponseData ) \ - ACTION_RECEIVE_BRIDGE_DEFINITION( AdjustUltrafiltrationConfirmResponseData ) -//--------------------------------------------------------------------------------// + ACTION_RECEIVE_BRIDGE_DEFINITION( AdjustUltrafiltrationConfirmResponseData ) \ + ACTION_RECEIVE_BRIDGE_DEFINITION( AdjustSalineResponseData ) +// /* Request */ ---------------------------------------------------------// #define ADJUST_TRANSMT_MODEL_BRIDGE_DEFINITIONS \ ADJUST_TRANSMT_BRIDGE_DEFINITION( AdjustBloodDialysateRequestData ) \ ADJUST_TRANSMT_BRIDGE_DEFINITION( AdjustDurationRequestData ) \ ADJUST_TRANSMT_BRIDGE_DEFINITION( AdjustUltrafiltrationStateRequestData ) \ ADJUST_TRANSMT_BRIDGE_DEFINITION( AdjustUltrafiltrationEditRequestData ) \ - ADJUST_TRANSMT_BRIDGE_DEFINITION( AdjustUltrafiltrationConfirmRequestData ) -//--------------------------------------------------------------------------------// + ADJUST_TRANSMT_BRIDGE_DEFINITION( AdjustUltrafiltrationConfirmRequestData ) \ + ADJUST_TRANSMT_BRIDGE_DEFINITION( AdjustSalineRequestData ) +// /* Request */ ----------------------- NoEmit --------------------------// #define ADJUST_TRANSMT_MODEL_BRIDGE_DEFINITIONS_NOEMIT \ ADJUST_TRANSMT_BRIDGE_DEFINITION_NOEMIT( AdjustBloodDialysateRequestData ) \ ADJUST_TRANSMT_BRIDGE_DEFINITION_NOEMIT( AdjustDurationRequestData ) \ ADJUST_TRANSMT_BRIDGE_DEFINITION_NOEMIT( AdjustUltrafiltrationStateRequestData ) \ ADJUST_TRANSMT_BRIDGE_DEFINITION_NOEMIT( AdjustUltrafiltrationEditRequestData ) \ - ADJUST_TRANSMT_BRIDGE_DEFINITION_NOEMIT( AdjustUltrafiltrationConfirmRequestData ) -//--------------------------------------------------------------------------------// + ADJUST_TRANSMT_BRIDGE_DEFINITION_NOEMIT( AdjustUltrafiltrationConfirmRequestData ) \ + ADJUST_TRANSMT_BRIDGE_DEFINITION_NOEMIT( AdjustSalineRequestData ) +// /* Request */ ----------------------- public --------------------------// #define ADJUST_TRANSMT_MODEL_BRIDGE_DEFINITIONS_PUBLIC \ ADJUST_TRANSMT_BRIDGE_DEFINITION_PUBLIC( AdjustBloodDialysateRequestData ) \ ADJUST_TRANSMT_BRIDGE_DEFINITION_PUBLIC( AdjustDurationRequestData ) \ ADJUST_TRANSMT_BRIDGE_DEFINITION_PUBLIC( AdjustUltrafiltrationStateRequestData ) \ ADJUST_TRANSMT_BRIDGE_DEFINITION_PUBLIC( AdjustUltrafiltrationEditRequestData ) \ - ADJUST_TRANSMT_BRIDGE_DEFINITION_PUBLIC( AdjustUltrafiltrationConfirmRequestData ) + ADJUST_TRANSMT_BRIDGE_DEFINITION_PUBLIC( AdjustUltrafiltrationConfirmRequestData ) \ + ADJUST_TRANSMT_BRIDGE_DEFINITION_PUBLIC( AdjustSalineRequestData ) //===============================================================================// #define ACTION_RECEIVE_SIGNALS \ ACTION_RECEIVE_SIGNAL( BloodFlowData ) \ @@ -261,6 +274,7 @@ ACTION_RECEIVE_SIGNAL( AlarmTriggeredData ) \ ACTION_RECEIVE_SIGNAL( AlarmClearedData ) \ ACTION_RECEIVE_SIGNAL( TreatmentStatesData ) \ + ACTION_RECEIVE_SIGNAL( TreatmentSalineData ) \ ACTION_RECEIVE_SIGNAL( HDOperationModeData ) \ \ ACTION_RECEIVE_SIGNAL( DGROPumpData ) \ @@ -275,11 +289,12 @@ \ ACTION_RECEIVE_SIGNAL( HDDebugTextData ) \ ACTION_RECEIVE_SIGNAL( DGDebugTextData ) \ - \ + /* Response */ \ ACTION_RECEIVE_SIGNAL( AdjustUltrafiltrationStateResponseData ) \ ACTION_RECEIVE_SIGNAL( AdjustBloodDialysateResponseData ) \ ACTION_RECEIVE_SIGNAL( AdjustDurationResponseData ) \ ACTION_RECEIVE_SIGNAL( AdjustUltrafiltrationEditResponseData ) \ - ACTION_RECEIVE_SIGNAL( AdjustUltrafiltrationConfirmResponseData ) + ACTION_RECEIVE_SIGNAL( AdjustUltrafiltrationConfirmResponseData ) \ + ACTION_RECEIVE_SIGNAL( AdjustSalineResponseData ) //--------------------------------------------------------------------------------// //--------------------------------------------------------------------------------// Index: sources/model/hd/adjustment/MTreatmentAdjustSalineResponse.cpp =================================================================== diff -u -r3b4b381d23c267fbc5af29f29e231f03e26ca23b -r7ed86349cdad43d311f776a69ed54c2023265e53 --- sources/model/hd/adjustment/MTreatmentAdjustSalineResponse.cpp (.../MTreatmentAdjustSalineResponse.cpp) (revision 3b4b381d23c267fbc5af29f29e231f03e26ca23b) +++ sources/model/hd/adjustment/MTreatmentAdjustSalineResponse.cpp (.../MTreatmentAdjustSalineResponse.cpp) (revision 7ed86349cdad43d311f776a69ed54c2023265e53) @@ -19,16 +19,16 @@ QVariantList MAdjustSalineResponse::parameters() const { return { _data.mAccepted.value, - _data.mReasin .value, - _data.mVolume .value + _data.mReason .value, + _data.mTarget .value }; } bool MAdjustSalineResponse::fromByteArray(const QByteArray &vByteArray, int *vIndex) { int index = 0; // message data start position if (GetValue(vByteArray, index, _data.mAccepted )) if (GetValue(vByteArray, index, _data.mReason )) - if (GetValue(vByteArray, index, _data.mVolume )) + if (GetValue(vByteArray, index, _data.mTarget )) return true ; else { if(vIndex) *vIndex = index; return false; } else { if(vIndex) *vIndex = index; return false; } @@ -39,6 +39,6 @@ Data data; data.mAccepted = _data.mAccepted.value; data.mReason = _data.mReason .value; - data.mUFVolume = _data.mVolume .value; + data.mTarget = _data.mTarget .value; return data; } Index: sources/model/hd/adjustment/MTreatmentAdjustSalineResponse.h =================================================================== diff -u -r3b4b381d23c267fbc5af29f29e231f03e26ca23b -r7ed86349cdad43d311f776a69ed54c2023265e53 --- sources/model/hd/adjustment/MTreatmentAdjustSalineResponse.h (.../MTreatmentAdjustSalineResponse.h) (revision 3b4b381d23c267fbc5af29f29e231f03e26ca23b) +++ sources/model/hd/adjustment/MTreatmentAdjustSalineResponse.h (.../MTreatmentAdjustSalineResponse.h) (revision 7ed86349cdad43d311f776a69ed54c2023265e53) @@ -35,7 +35,7 @@ struct { Types::U32 mAccepted; Types::U32 mReason ; - Types::U32 mVolume ; + Types::U32 mTarget ; } _data; public: @@ -47,7 +47,7 @@ struct Data { bool mAccepted = 0; /*!< Accepted value of type quint32 extracted out */ quint32 mReason = 0; /*!< Reason value of type quint32 extracted out */ - quint32 mVolume = 0; /*!< Bolus Volume value of type quint32 extracted out */ + quint32 mTarget = 0; /*!< Target Volume value of type quint32 extracted out */ }; MAdjustSalineResponse () { } Index: sources/model/hd/data/MTreatmentSalineData.cpp =================================================================== diff -u -r3b4b381d23c267fbc5af29f29e231f03e26ca23b -r7ed86349cdad43d311f776a69ed54c2023265e53 --- sources/model/hd/data/MTreatmentSalineData.cpp (.../MTreatmentSalineData.cpp) (revision 3b4b381d23c267fbc5af29f29e231f03e26ca23b) +++ sources/model/hd/data/MTreatmentSalineData.cpp (.../MTreatmentSalineData.cpp) (revision 7ed86349cdad43d311f776a69ed54c2023265e53) @@ -15,29 +15,29 @@ using namespace Model; -QVariantList MTreatmentTime::parameters() const { +QVariantList MTreatmentSaline::parameters() const { return { _data.mTarget .value, _data.mCumulative .value, - _data.mDelivering .value, + _data.mDelivered .value, }; } -bool MTreatmentTime::fromByteArray(const QByteArray &vByteArray, int *vIndex) { +bool MTreatmentSaline::fromByteArray(const QByteArray &vByteArray, int *vIndex) { int index = 0; // message data start position if (GetValue(vByteArray, index, _data.mTarget )) if (GetValue(vByteArray, index, _data.mCumulative )) - if (GetValue(vByteArray, index, _data.mDelivering )) + if (GetValue(vByteArray, index, _data.mDelivered )) return true ; else { if(vIndex) *vIndex = index; return false; } else { if(vIndex) *vIndex = index; return false; } else { if(vIndex) *vIndex = index; return false; } } -MTreatmentTime::Data MTreatmentTime::data() const { +MTreatmentSaline::Data MTreatmentSaline::data() const { Data data; data.mTarget = _data.mTarget .value; data.mCumulative = _data.mCumulative .value; - data.mDelivering = _data.mDelivering .value; + data.mDelivered = _data.mDelivered .value; return data; } Index: sources/model/hd/data/MTreatmentSalineData.h =================================================================== diff -u -r3b4b381d23c267fbc5af29f29e231f03e26ca23b -r7ed86349cdad43d311f776a69ed54c2023265e53 --- sources/model/hd/data/MTreatmentSalineData.h (.../MTreatmentSalineData.h) (revision 3b4b381d23c267fbc5af29f29e231f03e26ca23b) +++ sources/model/hd/data/MTreatmentSalineData.h (.../MTreatmentSalineData.h) (revision 7ed86349cdad43d311f776a69ed54c2023265e53) @@ -35,8 +35,8 @@ struct { Types::U32 mTarget ; - Types::U32 mCumulative ; - Types::U32 mDelivering ; + Types::F32 mCumulative ; + Types::F32 mDelivered ; } _data; public: @@ -47,8 +47,8 @@ struct Data { quint32 mTarget = 0; /*!< Target Target volume for the current started saline bolus */ - quint32 mCumulative = 0; /*!< Cumulative Cumulative volume of all saline deliveries during current treatment */ - quint32 mDelivering = 0; /*!< Delivering Current delivering saline volume */ + float mCumulative = 0; /*!< Cumulative Cumulative volume of all saline deliveries during current treatment */ + float mDelivered = 0; /*!< Delivered Current delivered saline volume */ }; public: Index: sources/view/VTreatmentAdjustmentSaline.cpp =================================================================== diff -u --- sources/view/VTreatmentAdjustmentSaline.cpp (revision 0) +++ sources/view/VTreatmentAdjustmentSaline.cpp (revision 7ed86349cdad43d311f776a69ed54c2023265e53) @@ -0,0 +1,52 @@ +/*! + * + * Copyright (c) 2019-2020 Diality Inc. - All Rights Reserved. + * \copyright + * THIS CODE MAY NOT BE COPIED OR REPRODUCED IN ANY FORM, IN PART OR IN + * WHOLE, WITHOUT THE EXPLICIT PERMISSION OF THE COPYRIGHT OWNER. + * + * \file VTreatmentAdjustmentSaline.cpp + * \author Behrouz NematiPour (last) + * \date 10-Aug-2020 (last) + * \author Behrouz NematiPour (original) + * \date 10-Aug-2020 (original) + * + */ +#include "VTreatmentAdjustmentSaline.h" + +// Project +#include "guicontroller.h" + +VIEW_DEF_CLASS_ADJUSTMENT(VTreatmentAdjustmentSaline, AdjustSalineResponseData) + +void VTreatmentAdjustmentSaline::initConnections() { + ACTION_VIEW_CONNECTION(AdjustSalineResponseData); + ADJUST_VIEW_CONNECTION(AdjustSalineRequestData ); +} + +void VTreatmentAdjustmentSaline::onActionReceive(const AdjustSalineResponseData &vData) +{ + adjustment_Accepted ( vData.mAccepted ); + adjustment_Reason ( vData.mReason ); + + target ( vData.mTarget ); + if (adjustment_Accepted()) { + // the response doesn't have the state so the requested state which has been accepted is used. + isStarted ( _data.requestedState == AdjustSalineRequestData::eStart ); + } + + // *** has to be the last to let the information to be set and then emit the signal *** + // *** otherwise will use the previous values before being set. *** + adjustment ( true ); +} + +void View::VTreatmentAdjustmentSaline::doAdjustment() +{ + if (isStarted()) { + _data.requestedState = AdjustSalineRequestData::eStop; + } + else { + _data.requestedState = AdjustSalineRequestData::eStart; + } + emit didAdjustment(_data); // notify the controllers to do the adjustment +} Index: sources/view/VTreatmentAdjustmentSaline.h =================================================================== diff -u --- sources/view/VTreatmentAdjustmentSaline.h (revision 0) +++ sources/view/VTreatmentAdjustmentSaline.h (revision 7ed86349cdad43d311f776a69ed54c2023265e53) @@ -0,0 +1,53 @@ +/*! + * + * Copyright (c) 2019-2020 Diality Inc. - All Rights Reserved. + * \copyright + * THIS CODE MAY NOT BE COPIED OR REPRODUCED IN ANY FORM, IN PART OR IN + * WHOLE, WITHOUT THE EXPLICIT PERMISSION OF THE COPYRIGHT OWNER. + * + * \file VTreatmentAdjustmentSaline.h + * \author Behrouz NematiPour (last) + * \date 10-Aug-2020 (last) + * \author Behrouz NematiPour (original) + * \date 10-Aug-2020 (original) + * + */ +#pragma once + +#include + +// Project +#include "vtreatmentadjustmentresponsebase.h" + +namespace View { + +class VTreatmentAdjustmentSaline : public VTreatmentAdjustmentResponseBase +{ + Q_OBJECT + + // friends + friend class ::tst_views; + + AdjustSalineRequestData _data; + + // coco begin validated: + // The property adjustment_Triggered has to be always true + // and to always trigger the change event to work as a notifier for GUI + // has been manually tested that it works perfectly fine + TRIGGER( bool , adjustment , 0 ) + // coco end + + PROPERTY( qint32 , target , 0 ) + PROPERTY( bool , isStarted , false ) + + VIEW_DEC_CLASS_ADJUSTMENT(VTreatmentAdjustmentSaline, AdjustSalineResponseData) + +// ---------- Start/Stop Saline Bolus +public slots: + void doAdjustment(); + +signals: + void didAdjustment(const AdjustSalineRequestData &vData); +}; + +} Index: sources/view/VTreatmentSalineData.cpp =================================================================== diff -u --- sources/view/VTreatmentSalineData.cpp (revision 0) +++ sources/view/VTreatmentSalineData.cpp (revision 7ed86349cdad43d311f776a69ed54c2023265e53) @@ -0,0 +1,27 @@ +/*! + * + * Copyright (c) 2019-2020 Diality Inc. - All Rights Reserved. + * \copyright + * THIS CODE MAY NOT BE COPIED OR REPRODUCED IN ANY FORM, IN PART OR IN + * WHOLE, WITHOUT THE EXPLICIT PERMISSION OF THE COPYRIGHT OWNER. + * + * \file vTreatmentSalineData.cpp + * \author Behrouz NematiPour (last) + * \date 10-Aug-2020 (last) + * \author Behrouz NematiPour (original) + * \date 10-Aug-2020 (original) + * + */ +#include "VTreatmentSalineData.h" + +// Project +#include "guicontroller.h" + +VIEW_DEF(VTreatmentSaline, TreatmentSalineData) + +void VTreatmentSaline::onActionReceive(const TreatmentSalineData &vData) +{ + target (vData.mTarget ); + cumulative (vData.mCumulative); + delivered (vData.mDelivered ); +} Index: sources/view/VTreatmentSalineData.h =================================================================== diff -u --- sources/view/VTreatmentSalineData.h (revision 0) +++ sources/view/VTreatmentSalineData.h (revision 7ed86349cdad43d311f776a69ed54c2023265e53) @@ -0,0 +1,38 @@ +/*! + * + * Copyright (c) 2019-2020 Diality Inc. - All Rights Reserved. + * \copyright + * THIS CODE MAY NOT BE COPIED OR REPRODUCED IN ANY FORM, IN PART OR IN + * WHOLE, WITHOUT THE EXPLICIT PERMISSION OF THE COPYRIGHT OWNER. + * + * \file vTreatmentSalineData.h + * \author Behrouz NematiPour (last) + * \date 10-Aug-2020 (last) + * \author Behrouz NematiPour (original) + * \date 10-Aug-2020 (original) + * + */ +#pragma once + +// Qt +#include + +// Project +#include "MModel.h" +#include "vview.h" + +// namespace +namespace View { + +class VTreatmentSaline : public QObject +{ + Q_OBJECT + + PROPERTY( quint32 , target , 0) + PROPERTY( float , cumulative , 0) + PROPERTY( float , delivered , 0) + + VIEW_DEC(VTreatmentSaline, TreatmentSalineData) + +}; +} Index: sources/view/vtreatmentadjustmentultrafiltrationconfirm.h =================================================================== diff -u -r44a85c96ab55e424866ec4cca0270aa218355f82 -r7ed86349cdad43d311f776a69ed54c2023265e53 --- sources/view/vtreatmentadjustmentultrafiltrationconfirm.h (.../vtreatmentadjustmentultrafiltrationconfirm.h) (revision 44a85c96ab55e424866ec4cca0270aa218355f82) +++ sources/view/vtreatmentadjustmentultrafiltrationconfirm.h (.../vtreatmentadjustmentultrafiltrationconfirm.h) (revision 7ed86349cdad43d311f776a69ed54c2023265e53) @@ -34,7 +34,7 @@ // The property adjustment_Triggered has to be always true // and to always trigger the change event to work as a notifier for GUI // has been manually tested that it works perfectly fine - TRIGGER( bool , adjustment , 0) + TRIGGER( bool , adjustment , 0) // coco end // Treatment Ultrafiltration data Index: sources/view/vview.h =================================================================== diff -u -rd2035a8728794afeefaa244bf8d1597926d945f5 -r7ed86349cdad43d311f776a69ed54c2023265e53 --- sources/view/vview.h (.../vview.h) (revision d2035a8728794afeefaa244bf8d1597926d945f5) +++ sources/view/vview.h (.../vview.h) (revision 7ed86349cdad43d311f776a69ed54c2023265e53) @@ -102,6 +102,7 @@ REGISTER_TYPE( VTreatmentPressureOcclusion ) \ REGISTER_TYPE( VTreatmentTime ) \ REGISTER_TYPE( VTreatmentRanges ) \ + REGISTER_TYPE( VTreatmentSaline ) \ REGISTER_TYPE( VHDOperationMode ) \ \ REGISTER_TYPE( VDGDrainPump ) \ @@ -118,8 +119,8 @@ REGISTER_TYPE( VTreatmentAdjustmentFlows ) \ REGISTER_TYPE( VTreatmentAdjustmentUltrafiltrationState ) \ REGISTER_TYPE( VTreatmentAdjustmentUltrafiltrationEdit ) \ - REGISTER_TYPE( VTreatmentAdjustmentUltrafiltrationConfirm ) + REGISTER_TYPE( VTreatmentAdjustmentUltrafiltrationConfirm ) \ + REGISTER_TYPE( VTreatmentAdjustmentSaline ) \ - //--------------------------------------------------------------------------------//