Index: sources/gui/qml/pages/pretreatment/create/PreTreatmentCreatePatientPrescription.qml =================================================================== diff -u -raf80aaa1c114eab78444e973c86b3c42dd85ef52 -r4b86351821cd865f5d0383190a17b2137f79f9aa --- sources/gui/qml/pages/pretreatment/create/PreTreatmentCreatePatientPrescription.qml (.../PreTreatmentCreatePatientPrescription.qml) (revision af80aaa1c114eab78444e973c86b3c42dd85ef52) +++ sources/gui/qml/pages/pretreatment/create/PreTreatmentCreatePatientPrescription.qml (.../PreTreatmentCreatePatientPrescription.qml) (revision 4b86351821cd865f5d0383190a17b2137f79f9aa) @@ -12,9 +12,8 @@ readonly property int cellWidth : Variables.createRxLabelUnitContainerWidth readonly property int cellHeight : Variables.createRxLabelUnitContainerHeight readonly property bool heparinFeatured : vSettings.heparinSyringePump - readonly property string patientID : _pretreatmentPatientIDEntry.text property bool isHDFFeatured : vTreatmentCreate.treatmentModality === HeaderBar.Mode_HDF - property bool isHeparinOn : _heparinRxControl.value === PreTreatmentCreateTreatmentSettings.ON + property bool isHeparinOn : _heparinRxControl.value === PreTreatmentCreatePatientPrescription.ON property bool editingEnabled : true property int columnSpacing : 15 @@ -42,6 +41,29 @@ _heparinRx.reset() vTreatmentCreate.ufPreWeight = vTreatmentRanges.weightDef vTreatmentCreate.ufEstimatedTargetWeight = vTreatmentRanges.weightDef + + if ( _GuiView.dryDemoMode ) { + vTreatmentCreate.hdfTreatmentModeSet = true + vTreatmentCreate.substitutionFluidVolumeSet = true + vTreatmentCreate.bloodFlowRateSet = true + vTreatmentCreate.dialysateFlowRateSet = true + vTreatmentCreate.treatmentDurationSet = true + vTreatmentCreate.ultrafiltrationVolumeSet = true + vTreatmentCreate.acidConcentrateSet = true + vTreatmentCreate.dryBicarbCartSizeSet = true + vTreatmentCreate.dialyzerTypeSet = true + vTreatmentCreate.dialysateTempSet = true + vTreatmentCreate.heparinBolusVolumeSet = true + vTreatmentCreate.heparinDispensingRateSet = true + vTreatmentCreate.heparinDeliveryDurationSet = true + + vTreatmentCreate.substitutionFluidVolume = vTreatmentRanges.substitutionVolumeDef + vTreatmentCreate.bloodFlowRate = vTreatmentRanges.bloodFlowRateDef + vTreatmentCreate.dialysateFlowRate = vTreatmentRanges.dialysateFlowRateDef + vTreatmentCreate.treatmentDuration = vTreatmentRanges.treatmentDurationDef + vTreatmentCreate.ultrafiltrationVolume = vTreatmentRanges.ultrafiltrationVolumeDef + vTreatmentCreate.dialysateTemp = vTreatmentRanges.dialysateTempDef + } } function refreshAll () { @@ -56,7 +78,8 @@ } function clear () { - vTreatmentCreate.patientID = "" + vTreatmentCreate.patientID = "" + vTreatmentCreate.secondaryPatientID = "" _hdfTreatmentModeControl .clear() _subFluidVolume .clear() _bloodFlowRate .clear() @@ -71,7 +94,6 @@ } function ready () { - return (_root.isHDFFeatured ? _hdfTreatmentModeControl.isActive && _hdfTreatmentMode .valid && _subFluidVolume .isActive && _subFluidVolume .valid : true ) && _bloodFlowRate .isActive && _bloodFlowRate .valid && @@ -90,33 +112,15 @@ LabelUnitContainer { id: _patientID text : qsTr("Patient ID") - contentArea.anchors.leftMargin : 120 + showEdit : true + onEditClicked : _patientIdEntry.open() - contentItem : TextEntry { id: _pretreatmentPatientIDEntry - clip : true - textInput.width : parent.width - Variables.defaultMargin * 4 - text : vTreatmentCreate.patientID - anchors.centerIn : parent - textInput.maximumLength : 20 // LEAHI-PRS-236 - textInput.rightPadding : Variables.defaultMargin - textInput.leftPadding : Variables.defaultMargin * 14 - textInput.inputMethodHints : Qt.ImhPreferLowercase - textInput.echoMode : TextInput.Normal - textInput.validator : RegExpValidator { regExp: Variables.regExp_PatientID } - line.visible : false - enabled : _root.editingEnabled - onEditingFinished : vTreatmentCreate.patientID = text - - Text { id: _patientIDPlaceHolderText - text : Variables.emptyEntry - anchors.fill : parent - rightPadding : 125 - horizontalAlignment : Text.AlignRight - font.pixelSize : Fonts.fontPixelValueControl - color : Colors.offWhite - visible : _pretreatmentPatientIDEntry.textInput.text.length === 0 && - ! _pretreatmentPatientIDEntry.textInput.activeFocus - } + contentItem : Text { id: _patientIDText + anchors.centerIn : parent + horizontalAlignment : Text.AlignRight + font.pixelSize : Fonts.fontPixelValueControl + color : Colors.offWhite + text : vTreatmentCreate.patientID !== "" ? vTreatmentCreate.patientID : Variables.emptyEntry } } @@ -178,7 +182,7 @@ step : vTreatmentRanges.substitutionVolumeRes defaultValue : vTreatmentRanges.substitutionVolumeDef decimal : Variables.substitutionPrecision - value : vTreatmentCreate.substitutionFluidVolume + value : _root.isHDFFeatured ? vTreatmentCreate.substitutionFluidVolume : 0 isActive : vTreatmentCreate.substitutionFluidVolumeSet onDidActiveChange : function(vState) { vTreatmentCreate.substitutionFluidVolumeSet = vState } @@ -294,7 +298,7 @@ visible : _root.heparinFeatured showEdit : true needsAttention : ! _heparinRxAdjustment.confirmReady() - editEnabled : _heparinRxControl.value === PreTreatmentCreateTreatmentSettings.ON + editEnabled : _heparinRxControl.value === PreTreatmentCreatePatientPrescription.ON function reset() { vTreatmentCreate.heparinBolusVolume = 0 @@ -313,7 +317,7 @@ _heparinRxAdjustment.open() } else { - reset() + _heparinRx.reset() } } }