Merge pull request #2047 from joakim-hove/gconprod-item10

Blank string is default rate in GCONPROD
This commit is contained in:
Joakim Hove
2020-10-27 19:50:14 +01:00
committed by GitHub
2 changed files with 19 additions and 3 deletions

View File

@@ -345,9 +345,16 @@ namespace {
const bool apply_default_liquid_target = record.getItem("LIQUID_TARGET").defaultApplied(0);
const bool apply_default_resv_target = record.getItem("RESERVOIR_FLUID_TARGET").defaultApplied(0);
const std::optional<std::string> guide_rate_str = record.getItem("GUIDE_RATE_DEF").hasValue(0)
? std::optional<std::string>(record.getItem("GUIDE_RATE_DEF").getTrimmedString(0))
: std::nullopt;
std::optional<std::string> guide_rate_str;
{
const auto& item = record.getItem("GUIDE_RATE_DEF");
if (item.hasValue(0)) {
const auto& string_value = record.getItem("GUIDE_RATE_DEF").getTrimmedString(0);
if (string_value.size() > 0)
guide_rate_str = string_value;
}
}
for (const auto& group_name : group_names) {
const bool is_field { group_name == "FIELD" } ;

View File

@@ -565,6 +565,15 @@ GPMAINT
'PROD' 'NONE' /
/
TSTEP
10 /
GCONPROD
PROD ORAT 0 0 1* 0 RATE YES 1* ' ' 1* 1* 1* 1* 1* /
FIELD ORAT 71500 1* 1* 1* RATE YES 1* ' ' 1* 1* 1* 1* 1* /
/
)";
Opm::UnitSystem unitSystem = UnitSystem( UnitSystem::UnitType::UNIT_TYPE_METRIC );
const auto sched = create_schedule(input);