params.push_back(SGCONF::API_ACTION::PARAM("period", "<period>", "\ttarification period (daily, monthly)"));
params.push_back(SGCONF::API_ACTION::PARAM("times", "<hh:mm-hh:mm, ...>", "coma-separated day time-spans for each direction"));
params.push_back(SGCONF::API_ACTION::PARAM("day-prices", "<price/price, ...>", "coma-separated day prices for each direction"));
-params.push_back(SGCONF::API_ACTION::PARAM("night-prices", "<price/price, ...>", "coma-separated day prices for each direction"));
+params.push_back(SGCONF::API_ACTION::PARAM("night-prices", "<price/price, ...>", "coma-separated night prices for each direction"));
params.push_back(SGCONF::API_ACTION::PARAM("thresholds", "<threshold, ...>", "coma-separated thresholds for each direction"));
return params;
}
{
STG::SERVCONF proto(config.server.data(),
config.port.data(),
+ config.localAddress.data(),
+ config.localPort.data(),
config.userName.data(),
config.userPass.data());
return proto.GetTariffs(GetTariffsCallback, NULL) == STG::st_ok;
{
STG::SERVCONF proto(config.server.data(),
config.port.data(),
+ config.localAddress.data(),
+ config.localPort.data(),
config.userName.data(),
config.userPass.data());
// STG currently doesn't support <GetTariff name="..."/>.
{
STG::SERVCONF proto(config.server.data(),
config.port.data(),
+ config.localAddress.data(),
+ config.localPort.data(),
config.userName.data(),
config.userPass.data());
return proto.DelTariff(arg, SimpleCallback, NULL) == STG::st_ok;
}
STG::SERVCONF proto(config.server.data(),
config.port.data(),
+ config.localAddress.data(),
+ config.localPort.data(),
config.userName.data(),
config.userPass.data());
return proto.AddTariff(arg, conf, SimpleCallback, NULL) == STG::st_ok;
}
STG::SERVCONF proto(config.server.data(),
config.port.data(),
+ config.localAddress.data(),
+ config.localPort.data(),
config.userName.data(),
config.userPass.data());
return proto.ChgTariff(conf, SimpleCallback, NULL) == STG::st_ok;