From e91c6bd089743aa58862971e5d359fc42c2ab384 Mon Sep 17 00:00:00 2001 From: ITQ Date: Wed, 19 Feb 2025 14:37:45 +0300 Subject: [PATCH] feat(telegram_bot): added states folder --- .../services/telegram_bot/states/__init__.py | 0 solution/services/telegram_bot/states/auth.py | 5 +++++ .../services/telegram_bot/states/campaign.py | 16 ++++++++++++++++ .../services/telegram_bot/states/campaigns.py | 6 ++++++ solution/services/telegram_bot/states/start.py | 5 +++++ 5 files changed, 32 insertions(+) create mode 100644 solution/services/telegram_bot/states/__init__.py create mode 100644 solution/services/telegram_bot/states/auth.py create mode 100644 solution/services/telegram_bot/states/campaign.py create mode 100644 solution/services/telegram_bot/states/campaigns.py create mode 100644 solution/services/telegram_bot/states/start.py diff --git a/solution/services/telegram_bot/states/__init__.py b/solution/services/telegram_bot/states/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/solution/services/telegram_bot/states/auth.py b/solution/services/telegram_bot/states/auth.py new file mode 100644 index 0000000..68935a6 --- /dev/null +++ b/solution/services/telegram_bot/states/auth.py @@ -0,0 +1,5 @@ +from aiogram.fsm.state import State, StatesGroup + + +class AuthState(StatesGroup): + advertiser_id = State() diff --git a/solution/services/telegram_bot/states/campaign.py b/solution/services/telegram_bot/states/campaign.py new file mode 100644 index 0000000..af4aacf --- /dev/null +++ b/solution/services/telegram_bot/states/campaign.py @@ -0,0 +1,16 @@ +from aiogram.fsm.state import State, StatesGroup + + +class CampaignState(StatesGroup): + ad_title = State() + ad_text = State() + impressions_limit = State() + clicks_limit = State() + cost_per_impression = State() + cost_per_click = State() + start_date = State() + end_date = State() + gender = State() + age_from = State() + age_to = State() + location = State() diff --git a/solution/services/telegram_bot/states/campaigns.py b/solution/services/telegram_bot/states/campaigns.py new file mode 100644 index 0000000..6c439f1 --- /dev/null +++ b/solution/services/telegram_bot/states/campaigns.py @@ -0,0 +1,6 @@ +from aiogram.fsm.state import State, StatesGroup + + +class CampaignsDailogState(StatesGroup): + campaigns = State() + campaign = State() diff --git a/solution/services/telegram_bot/states/start.py b/solution/services/telegram_bot/states/start.py new file mode 100644 index 0000000..f87cdd9 --- /dev/null +++ b/solution/services/telegram_bot/states/start.py @@ -0,0 +1,5 @@ +from aiogram.fsm.state import State, StatesGroup + + +class StartDialogState(StatesGroup): + start = State()