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