0
0
mirror of https://gitflic.ru/project/maks1ms/ocab.git synced 2024-12-24 00:33:05 +03:00

Изменение наименования db_api

This commit is contained in:
Armatik 2024-04-25 15:55:23 +03:00
parent b7fdd75458
commit fb6da3d627
6 changed files with 9 additions and 6 deletions

View File

@ -1,6 +1,6 @@
from src.modules.standard.config.config import get_config from src.modules.standard.config.config import get_config
from src.modules.standard.database.models.base import database from src.modules.standard.database.models.base import database
from src.modules.standard.database.api import connect_database from src.modules.standard.database.db_api import connect_database
from asyncio import run from asyncio import run
from aiogram import Bot, Dispatcher from aiogram import Bot, Dispatcher

View File

@ -22,4 +22,7 @@ def get_yandexgpt_catalog_id() -> str:
def get_yandexgpt_prompt() -> str: def get_yandexgpt_prompt() -> str:
return get_config()["YANDEX_GPT_PROMPT"] return get_config()["YANDEX_GPT_PROMPT"]
def get_access_rights() -> dict:
return get_config()["ACCESS_RIGHTS"]

View File

@ -1 +1 @@
from . import api, models from . import db_api, models

View File

@ -1,7 +1,7 @@
import unittest import unittest
import os import os
from ..api import * from ..db_api import *
from ...exceptions.module_exceptions import MissingModuleName, NotExpectedModuleName from ...exceptions.module_exceptions import MissingModuleName, NotExpectedModuleName

View File

@ -1,4 +1,4 @@
from ..database.api import get_user_role from ..database.db_api import get_user_role
from ..config.config import get_config from ..config.config import get_config
yaml_load = get_config() yaml_load = get_config()

View File

@ -1,7 +1,7 @@
import os import os
import unittest import unittest
from ...database.api import create_tables, connect_database, add_user from ...database.db_api import create_tables, connect_database, add_user
from ..api import Roles from ..roles import Roles
class TestRoles(unittest.IsolatedAsyncioTestCase): class TestRoles(unittest.IsolatedAsyncioTestCase):