Set pop_business_hours when parsing json-tariff-file.

This commit is contained in:
Gerhard Hoffmann 2023-12-12 10:34:39 +01:00
parent 15f552a973
commit d11cffb8bd

View File

@ -78,7 +78,7 @@ bool Configuration::ParseJson(Configuration* cfg, const char* json)
ATBWeekDaysWorktime WeekDaysWorktime;
ATBPaymentOption PaymentOption;
ATBPeriodYear YearPeriod;
MemberType mb_type;
MemberType mb_type = MemberType::UnknownType;
// Get all JSON object members
// This code should run only once (to load JSON variables into memory)
@ -169,6 +169,7 @@ bool Configuration::ParseJson(Configuration* cfg, const char* json)
else if (strcmp(inner_obj_name, "pop_min_price") == 0) PaymentOption.pop_min_price = k->value.GetDouble();
else if (strcmp(inner_obj_name, "pop_carry_over") == 0) PaymentOption.pop_carry_over = k->value.GetInt();
else if (strcmp(inner_obj_name, "pop_daily_card_price") == 0) PaymentOption.pop_daily_card_price = k->value.GetInt();
else if (strcmp(inner_obj_name, "pop_business_hours") == 0) PaymentOption.pop_business_hours = k->value.GetInt();
this->currentPaymentOptions = PaymentOption;
break;
case MemberType::DurationType: