dev add tariff endpoints
Test Workflow / test (push) Successful in 4s

This commit is contained in:
vladp
2026-02-02 15:00:18 +07:00
parent 4395654b0d
commit 22b487da22
9 changed files with 184 additions and 31 deletions
@@ -88,13 +88,6 @@ public class TariffInitializationService {
if (existingTariffs.isEmpty()) {
createDefaultTariffs();
} else {
Map<TariffType, Boolean> existingTypes = new HashMap<>();
existingTariffs.forEach(tariff -> existingTypes.put(TariffType.valueOf(tariff.getType()), true));
Arrays.stream(TariffType.values())
.filter(type -> !existingTypes.containsKey(type))
.forEach(this::createDefaultTariff);
}
}