Schemas updated

This commit is contained in:
2025-04-02 18:53:33 +03:00
parent 27c48bb86a
commit 3583d178e9
38 changed files with 2672 additions and 28 deletions

35
Schemas/rules/rules.py Normal file
View File

@@ -0,0 +1,35 @@
from sqlalchemy import (
UUID,
String,
text,
)
from sqlalchemy.orm import (
Mapped,
mapped_column,
)
from Controllers.Postgres.mixin import CrudCollection
class EndpointRestriction(CrudCollection):
"""
Initialize Endpoint Restriction with default values
"""
__tablename__ = "endpoint_restriction"
__exclude__fields__ = []
endpoint_function: Mapped[str] = mapped_column(
String, server_default="", comment="Function name of the API endpoint"
)
endpoint_name: Mapped[str] = mapped_column(
String, server_default="", comment="Name of the API endpoint"
)
endpoint_method: Mapped[str] = mapped_column(
String, server_default="", comment="HTTP method used by the endpoint"
)
endpoint_desc: Mapped[str] = mapped_column(
String, server_default="", comment="Description of the endpoint"
)
endpoint_code: Mapped[str] = mapped_column(
String, server_default="", unique=True, comment="Unique code for the endpoint"
)