Added setting for max steam offer count

This commit is contained in:
2023-11-04 23:37:07 +01:00
parent e6165caed9
commit dcbb481b10
20 changed files with 106 additions and 9 deletions

View File

@@ -4,6 +4,7 @@ type TechnicianConfig implements TableWithHistoryQuery {
waitForRestart: Int
waitForShutdown: Int
cacheMaxMessages: Int
maxSteamOfferCount: Int
featureFlagCount: Int
featureFlags: [FeatureFlag]
pingURLs: [String]
@@ -23,6 +24,7 @@ type TechnicianConfigHistory implements HistoryTableQuery {
waitForRestart: Int
waitForShutdown: Int
cacheMaxMessages: Int
maxSteamOfferCount: Int
featureFlagCount: Int
featureFlags: [FeatureFlag]
@@ -59,6 +61,7 @@ input TechnicianConfigInput {
waitForRestart: Int
waitForShutdown: Int
cacheMaxMessages: Int
maxSteamOfferCount: Int
featureFlags: [FeatureFlagInput]
pingURLs: [String]
technicianIds: [String]

View File

@@ -59,6 +59,9 @@ class TechnicianConfigMutation(QueryABC):
technician_config.cache_max_messages = (
input["cacheMaxMessages"] if "cacheMaxMessages" in input else technician_config.cache_max_messages
)
technician_config.max_steam_offer_count = (
input["maxSteamOfferCount"] if "maxSteamOfferCount" in input else technician_config.max_steam_offer_count
)
old_feature_flags = technician_config.feature_flags
technician_config.feature_flags = (
dict(

View File

@@ -14,6 +14,7 @@ class TechnicianConfigHistoryQuery(HistoryQueryABC):
self.set_field("waitForRestart", lambda config, *_: config.wait_for_restart)
self.set_field("waitForShutdown", lambda config, *_: config.wait_for_shutdown)
self.set_field("cacheMaxMessages", lambda config, *_: config.cache_max_messages)
self.set_field("maxSteamOfferCount", lambda config, *_: config.max_steam_offer_count)
self.add_collection(
"featureFlag",
lambda config, *_: List(

View File

@@ -27,6 +27,7 @@ class TechnicianConfigQuery(DataQueryWithHistoryABC):
self.set_field("waitForRestart", lambda config, *_: config.wait_for_restart)
self.set_field("waitForShutdown", lambda config, *_: config.wait_for_shutdown)
self.set_field("cacheMaxMessages", lambda config, *_: config.cache_max_messages)
self.set_field("maxSteamOfferCount", lambda config, *_: config.max_steam_offer_count)
self.add_collection(
"featureFlag",
lambda config, *_: List(