catalogue operations, db migr and so on.
pre release version.
This commit is contained in:
@@ -2,6 +2,8 @@ from dataclasses import dataclass
|
||||
from enum import Enum
|
||||
from typing import Optional, Union
|
||||
|
||||
from aiogram.types import Message
|
||||
|
||||
from db.models import Category
|
||||
from db.models.products import Product
|
||||
|
||||
@@ -22,3 +24,17 @@ class CatalogueView:
|
||||
parent_id: Union[int, str, None] = None
|
||||
has_next: bool = False
|
||||
show_menu: bool = False
|
||||
|
||||
|
||||
@dataclass
|
||||
class NewCatalogueElement:
|
||||
msg: Message
|
||||
parent_id: Union[int, str]
|
||||
|
||||
|
||||
@dataclass
|
||||
class NewCategoryContext(NewCatalogueElement): ...
|
||||
|
||||
|
||||
@dataclass
|
||||
class NewProductContext(NewCatalogueElement): ...
|
||||
|
||||
Reference in New Issue
Block a user