Skip to content

Commit

Permalink
feat(kz_dash): api公用部分迁移
Browse files Browse the repository at this point in the history
  • Loading branch information
kingzeus committed Dec 20, 2024
1 parent 89fdcba commit b35ca6c
Show file tree
Hide file tree
Showing 8 changed files with 10 additions and 94 deletions.
10 changes: 5 additions & 5 deletions backend/__init__.py
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
from flask import Flask
from flask_restx import Api

from backend.apis.account import api as account_ns
from backend.apis.fund import api as fund_ns
from backend.apis.portfolio import api as portfolio_ns
from backend.apis.runtime import api as runtime_ns
from backend.apis.task import api as task_ns
from backend.api.account import api as account_ns
from backend.api.fund import api as fund_ns
from backend.api.portfolio import api as portfolio_ns
from kz_dash.backend.api.runtime import api as runtime_ns
from backend.api.task import api as task_ns
from config import API_CONFIG
from scheduler.job_manager import JobManager
from scheduler.tasks import init_tasks
Expand Down
2 changes: 1 addition & 1 deletion backend/apis/account.py → backend/api/account.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

from flask_restx import Namespace, Resource, fields

from backend.apis.common import create_list_response_model, create_response_model
from kz_dash.backend.api.common import create_list_response_model, create_response_model
from models.account import ModelAccount, update_account
from models.database import delete_record, get_record, get_record_list, update_record
from kz_dash.utility.response import format_response
Expand Down
2 changes: 1 addition & 1 deletion backend/apis/fund.py → backend/api/fund.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from flask_restx import Namespace, Resource, fields

from backend.apis.common import create_list_response_model, create_response_model
from kz_dash.backend.api.common import create_list_response_model, create_response_model
from models.database import (
add_fund_position,
delete_record,
Expand Down
2 changes: 1 addition & 1 deletion backend/apis/portfolio.py → backend/api/portfolio.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

from flask_restx import Namespace, Resource, fields

from backend.apis.common import create_list_response_model, create_response_model
from kz_dash.backend.api.common import create_list_response_model, create_response_model
from models.account import ModelPortfolio
from models.database import delete_record, get_record, get_record_list, update_record
from kz_dash.utility.response import format_response
Expand Down
2 changes: 1 addition & 1 deletion backend/apis/task.py → backend/api/task.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
from flask import request
from flask_restx import Namespace, Resource, fields

from backend.apis.common import create_list_response_model, create_response_model
from kz_dash.backend.api.common import create_list_response_model, create_response_model
from models.database import get_record_list
from models.task import ModelTask
from scheduler.job_manager import JobManager
Expand Down
27 changes: 0 additions & 27 deletions backend/apis/common.py

This file was deleted.

57 changes: 0 additions & 57 deletions backend/apis/runtime.py

This file was deleted.

2 changes: 1 addition & 1 deletion kz_dash
Submodule kz_dash updated from 3f3ef4 to 68038f

0 comments on commit b35ca6c

Please sign in to comment.