- property.tariffName.Set(nextTariff, sysAdmin, login, store);
+ {
+ if (tariff->TariffChangeIsAllowed(*nt) == "")
+ {
+ property.tariffName.Set(nextTariff, sysAdmin, login, store);
+ }
+ else
+ {
+ std::string message = tariff->TariffChangeIsAllowed(*nt);
+ WriteServLog("Tariff change is prohibited for user %s. %s",
+ login.c_str(),
+ message.c_str());
+ }
+ }