GConSump/sale: add does not rewrite groups.
This commit is contained in:
@@ -53,7 +53,6 @@ GConSale::MaxProcedure GConSale::stringToProcedure(const std::string& str_proc)
|
||||
}
|
||||
|
||||
void GConSale::add(const std::string& name, const UDAValue& sales_target, const UDAValue& max_rate, const UDAValue& min_rate, const std::string& procedure) {
|
||||
groups[name] = GCONSALEGroup();
|
||||
GConSale::GCONSALEGroup& group = groups[name];
|
||||
group.sales_target = sales_target;
|
||||
group.max_sales_rate = max_rate;
|
||||
|
||||
@@ -37,8 +37,9 @@ const GConSump::GCONSUMPGroup& GConSump::get(const std::string& name) const {
|
||||
|
||||
|
||||
void GConSump::add(const std::string& name, const UDAValue& consumption_rate, const UDAValue& import_rate, const std::string network_node) {
|
||||
groups[name] = GCONSUMPGroup();
|
||||
|
||||
GConSump::GCONSUMPGroup& group = groups[name];
|
||||
|
||||
group.consumption_rate = consumption_rate;
|
||||
group.import_rate = import_rate;
|
||||
group.network_node = network_node;
|
||||
|
||||
Reference in New Issue
Block a user