mirror of
https://github.com/PaiGramTeam/PamGram.git
synced 2024-11-22 06:17:54 +00:00
♻ 梅开二度之重命名核心模块路径
`apps` → `core`
This commit is contained in:
parent
d1876c4c77
commit
602ce67e41
@ -2,7 +2,7 @@ import datetime
|
||||
|
||||
from telegram.ext import CallbackContext, JobQueue
|
||||
|
||||
from apps.cookies.services import PublicCookiesService
|
||||
from core.cookies.services import PublicCookiesService
|
||||
from logger import Log
|
||||
from utils.job.manager import listener_jobs_class
|
||||
from utils.service.inject import inject
|
||||
|
@ -7,11 +7,11 @@ from telegram.constants import ParseMode
|
||||
from telegram.error import BadRequest, Forbidden
|
||||
from telegram.ext import CallbackContext, JobQueue
|
||||
|
||||
from apps.cookies import CookiesService
|
||||
from apps.sign.models import SignStatusEnum
|
||||
from apps.sign.services import SignServices
|
||||
from apps.user import UserService
|
||||
from config import config
|
||||
from core.cookies import CookiesService
|
||||
from core.sign.models import SignStatusEnum
|
||||
from core.sign.services import SignServices
|
||||
from core.user import UserService
|
||||
from logger import Log
|
||||
from utils.helpers import get_genshin_client
|
||||
from utils.job.manager import listener_jobs_class
|
||||
|
2
main.py
2
main.py
@ -38,7 +38,7 @@ def main() -> None:
|
||||
# 传入服务并启动
|
||||
Log.info("正在启动服务")
|
||||
services = ServicesManager(mysql, redis, browser)
|
||||
services.refresh_list("./apps/*")
|
||||
services.refresh_list("./core/*")
|
||||
services.import_module()
|
||||
services.add_service()
|
||||
|
||||
|
@ -3,10 +3,10 @@ from telegram import Update
|
||||
from telegram.constants import ChatAction
|
||||
from telegram.ext import CommandHandler, MessageHandler, filters, CallbackContext
|
||||
|
||||
from apps.cookies.services import CookiesService
|
||||
from apps.template.services import TemplateService
|
||||
from apps.user import UserService
|
||||
from apps.user.repositories import UserNotFoundError
|
||||
from core.cookies.services import CookiesService
|
||||
from core.template.services import TemplateService
|
||||
from core.user import UserService
|
||||
from core.user.repositories import UserNotFoundError
|
||||
from logger import Log
|
||||
from plugins.base import BasePlugins
|
||||
from utils.decorators.error import error_callable
|
||||
|
@ -7,10 +7,10 @@ from telegram import Update, ReplyKeyboardRemove, ReplyKeyboardMarkup, TelegramO
|
||||
from telegram.ext import CallbackContext, CommandHandler, MessageHandler, filters, ConversationHandler
|
||||
from telegram.helpers import escape_markdown
|
||||
|
||||
from apps.cookies.services import CookiesService
|
||||
from apps.user.models import User
|
||||
from apps.user.repositories import UserNotFoundError
|
||||
from apps.user.services import UserService
|
||||
from core.cookies.services import CookiesService
|
||||
from core.user.models import User
|
||||
from core.user.repositories import UserNotFoundError
|
||||
from core.user.services import UserService
|
||||
from logger import Log
|
||||
from models.base import RegionEnum
|
||||
from plugins.base import BasePlugins
|
||||
|
@ -2,7 +2,7 @@ from telegram import Update
|
||||
from telegram.error import BadRequest, Forbidden
|
||||
from telegram.ext import CallbackContext, CommandHandler
|
||||
|
||||
from apps.admin import BotAdminService
|
||||
from core.admin import BotAdminService
|
||||
from logger import Log
|
||||
from utils.decorators.admins import bot_admins_rights_check
|
||||
from utils.plugins.manager import listener_plugins_class
|
||||
|
@ -4,7 +4,7 @@ from telegram import Update, ReplyKeyboardRemove
|
||||
from telegram.error import BadRequest
|
||||
from telegram.ext import CallbackContext, ConversationHandler, filters
|
||||
|
||||
from apps.admin.services import BotAdminService
|
||||
from core.admin.services import BotAdminService
|
||||
from logger import Log
|
||||
from utils.service.inject import inject
|
||||
|
||||
|
@ -8,10 +8,10 @@ from telegram.constants import ChatAction
|
||||
from telegram.ext import CommandHandler, MessageHandler, ConversationHandler, filters, \
|
||||
CallbackContext
|
||||
|
||||
from apps.cookies.services import CookiesService
|
||||
from apps.template.services import TemplateService
|
||||
from apps.user.repositories import UserNotFoundError
|
||||
from apps.user.services import UserService
|
||||
from core.cookies.services import CookiesService
|
||||
from core.template.services import TemplateService
|
||||
from core.user.repositories import UserNotFoundError
|
||||
from core.user.services import UserService
|
||||
from logger import Log
|
||||
from plugins.base import BasePlugins
|
||||
from utils.decorators.error import error_callable
|
||||
|
@ -5,7 +5,7 @@ from telegram import Update
|
||||
from telegram.constants import ChatAction
|
||||
from telegram.ext import filters, CommandHandler, MessageHandler, CallbackContext
|
||||
|
||||
from apps.template import TemplateService
|
||||
from core.template import TemplateService
|
||||
from logger import Log
|
||||
from models.apihelper.gacha import GachaInfo
|
||||
from plugins.base import BasePlugins
|
||||
|
@ -3,8 +3,8 @@ from telegram.constants import ChatAction
|
||||
from telegram.error import BadRequest
|
||||
from telegram.ext import CommandHandler, CallbackContext
|
||||
|
||||
from apps.template.services import TemplateService
|
||||
from config import config
|
||||
from core.template.services import TemplateService
|
||||
from logger import Log
|
||||
from utils.decorators.error import error_callable
|
||||
from utils.decorators.restricts import restricts
|
||||
|
@ -6,7 +6,7 @@ from telegram.constants import ParseMode
|
||||
from telegram.error import BadRequest
|
||||
from telegram.ext import CallbackContext
|
||||
|
||||
from apps.wiki import WikiService
|
||||
from core.wiki import WikiService
|
||||
from logger import Log
|
||||
from utils.service.inject import inject
|
||||
|
||||
|
@ -8,10 +8,10 @@ from telegram import Update
|
||||
from telegram.constants import ChatAction
|
||||
from telegram.ext import CallbackContext, CommandHandler, MessageHandler, ConversationHandler, filters
|
||||
|
||||
from apps.cookies.services import CookiesService
|
||||
from apps.template.services import TemplateService
|
||||
from apps.user.repositories import UserNotFoundError
|
||||
from apps.user.services import UserService
|
||||
from core.cookies.services import CookiesService
|
||||
from core.template.services import TemplateService
|
||||
from core.user.repositories import UserNotFoundError
|
||||
from core.user.services import UserService
|
||||
from logger import Log
|
||||
from plugins.base import BasePlugins
|
||||
from utils.bot import get_all_args
|
||||
|
@ -5,11 +5,11 @@ from genshin import Game, GenshinException, AlreadyClaimed, Client
|
||||
from telegram import Update
|
||||
from telegram.ext import CommandHandler, MessageHandler, ConversationHandler, filters, CallbackContext
|
||||
|
||||
from apps.cookies.services import CookiesService
|
||||
from apps.sign.models import Sign as SignUser, SignStatusEnum
|
||||
from apps.sign.services import SignServices
|
||||
from apps.user.repositories import UserNotFoundError
|
||||
from apps.user.services import UserService
|
||||
from core.cookies.services import CookiesService
|
||||
from core.sign.models import Sign as SignUser, SignStatusEnum
|
||||
from core.sign.services import SignServices
|
||||
from core.user.repositories import UserNotFoundError
|
||||
from core.user.services import UserService
|
||||
from logger import Log
|
||||
from plugins.base import BasePlugins
|
||||
from utils.bot import get_all_args
|
||||
|
@ -2,7 +2,7 @@ from telegram import Update, InlineKeyboardButton, InlineKeyboardMarkup
|
||||
from telegram.constants import ChatAction, ParseMode
|
||||
from telegram.ext import filters, ConversationHandler, CommandHandler, MessageHandler, CallbackContext
|
||||
|
||||
from apps.game.services import GameStrategyService
|
||||
from core.game.services import GameStrategyService
|
||||
from logger import Log
|
||||
from plugins.base import BasePlugins
|
||||
from utils.bot import get_all_args
|
||||
|
@ -7,10 +7,10 @@ from telegram import Update
|
||||
from telegram.constants import ChatAction
|
||||
from telegram.ext import CallbackContext, CommandHandler, MessageHandler, ConversationHandler, filters
|
||||
|
||||
from apps.cookies.services import CookiesService
|
||||
from apps.template.services import TemplateService
|
||||
from apps.user.repositories import UserNotFoundError
|
||||
from apps.user.services import UserService
|
||||
from core.cookies.services import CookiesService
|
||||
from core.template.services import TemplateService
|
||||
from core.user.repositories import UserNotFoundError
|
||||
from core.user.services import UserService
|
||||
from logger import Log
|
||||
from plugins.base import BasePlugins
|
||||
from utils.decorators.error import error_callable
|
||||
|
@ -2,8 +2,8 @@ from telegram import Update, InlineKeyboardButton, InlineKeyboardMarkup
|
||||
from telegram.constants import ChatAction
|
||||
from telegram.ext import filters, CommandHandler, MessageHandler, CallbackContext
|
||||
|
||||
from apps.template.services import TemplateService
|
||||
from apps.wiki.services import WikiService
|
||||
from core.template.services import TemplateService
|
||||
from core.wiki.services import WikiService
|
||||
from logger import Log
|
||||
from metadata.shortname import weaponToName
|
||||
from plugins.base import BasePlugins
|
||||
|
@ -1,7 +1,7 @@
|
||||
from telegram import Update
|
||||
from telegram.ext import CommandHandler, CallbackContext
|
||||
|
||||
from apps.wiki.services import WikiService
|
||||
from core.wiki.services import WikiService
|
||||
from plugins.base import BasePlugins
|
||||
from utils.decorators.admins import bot_admins_rights_check
|
||||
from utils.decorators.error import error_callable
|
||||
|
@ -1,7 +1,7 @@
|
||||
from functools import wraps
|
||||
from typing import Callable
|
||||
|
||||
from apps.admin.services import BotAdminService
|
||||
from core.admin.services import BotAdminService
|
||||
from utils.service.inject import inject
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user