Index: sources/view/td/data/VTreatmentRanges.cpp =================================================================== diff -u -r863906f104a18dbe6020b939b739214679d49d8a -r56381aae237db191956aff493907cd1f0801216b --- sources/view/td/data/VTreatmentRanges.cpp (.../VTreatmentRanges.cpp) (revision 863906f104a18dbe6020b939b739214679d49d8a) +++ sources/view/td/data/VTreatmentRanges.cpp (.../VTreatmentRanges.cpp) (revision 56381aae237db191956aff493907cd1f0801216b) @@ -28,6 +28,11 @@ ACTION_VIEW_CONNECTION(SettingsData); ACTION_VIEW_CONNECTION(InstitutionalRecordResponseData); + _acidConcentrateModel.setRoleNames( { + { eRole_Key , "key" }, + { eRole_Value , "value" }, + }); + // since we do not have access to this object because it is created in QML. // Connection to the GuiController made here // It should be defined in the class which wants to connect to signal. @@ -246,7 +251,26 @@ hdfTreatmentModeOptions ( _Settings.keys(mCategory , "HDF Treatment Mode" )); dryBicabCartridgeSizeOptions ( _Settings.keys(mCategory , "Dry Bicarb Cartridge Size" )); waterSampleTestResultRequired ( _Settings.keys(mCategory , "Water Sample Test Result Required" )); + QVariantList mAcidConcentrateValues = _Settings.values(mCategory , "Acid Concentrate Options" ); +// for (int i = 0; i < _acidConcentrateValues.size(); ++i) { +// bool ok = false; +// _acidConcentrateValues[i] = _Settings.value(mCategory, "Acid Concentrate Options" , _acidConcentrateOptions[i] ).toFloat(&ok); +// isConfigsOk = isConfigsOk && ok; +// } + + + for (int i = 0; i < _acidConcentrateOptions.size(); ++i) { + bool ok = false; +// _acidConcentrateValues[i] = _Settings.value(mCategory, "Acid Concentrate Options" , _acidConcentrateOptions[i] ).toFloat(&ok); + _acidConcentrateModel.insertRow( i, {{ eRole_Key, _acidConcentrateOptions[i]}, { eRole_Value, mAcidConcentrateValues[i].toFloat(&ok) }}); + + + + isConfigsOk = isConfigsOk && ok; + + } + isConfigsOk = isConfigsOk && !_heparinTypeOptions .isEmpty(); if ( _heparinTypeOptions.isEmpty() ) { heparinTypeOptions({"-- --"}); } isConfigsOk = isConfigsOk && !_acidConcentrateOptions .isEmpty();