Skip to content

Commit d227e2f

Browse files
committed
chore: format:整理代码import
1 parent c968156 commit d227e2f

14 files changed

Lines changed: 15 additions & 29 deletions

File tree

app/api/__init__.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,8 @@
33
:license: MIT, see LICENSE for more details.
44
"""
55

6-
from spectree import SecurityScheme
7-
86
from lin import SpecTree
7+
from spectree import SecurityScheme
98

109
api = SpecTree(
1110
backend_name="flask",

app/api/v1/book.py

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
"""
77

88
from flask import Blueprint, g
9+
from lin import DocResponse, Success, group_required, login_required, permission_meta
910

1011
from app.api import AuthorizationBearerSecurity, api
1112
from app.api.v1.exception import BookNotFound
@@ -16,13 +17,6 @@
1617
BookQuerySearchSchema,
1718
BookSchemaList,
1819
)
19-
from lin import (
20-
DocResponse,
21-
Success,
22-
group_required,
23-
login_required,
24-
permission_meta,
25-
)
2620

2721
book_api = Blueprint("book", __name__)
2822

app/api/v1/model/book.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,8 @@
33
:license: MIT, see LICENSE for more details.
44
"""
55

6-
from sqlalchemy import Column, Integer, String
7-
86
from lin import InfoCrud as Base
7+
from sqlalchemy import Column, Integer, String
98

109

1110
class Book(Base):

app/cli/db/fake.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,10 @@
33
:license: MIT, see LICENSE for more details.
44
"""
55

6-
from app.api.v1.model.book import Book
76
from lin import db
87

8+
from app.api.v1.model.book import Book
9+
910

1011
def fake():
1112
with db.auto_commit():

app/extension/file/file.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
1-
from sqlalchemy import Column, Index, Integer, String, func, text
2-
31
from lin import InfoCrud, db
2+
from sqlalchemy import Column, Index, Integer, String, func, text
43

54

65
class File(InfoCrud):

app/extension/file/local_uploader.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
11
import os
22

33
from flask import current_app
4-
from werkzeug.utils import secure_filename
5-
64
from lin import Uploader
5+
from werkzeug.utils import secure_filename
76

87
from .file import File
98

app/plugin/oss/app/controller.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22

33
import oss2
44
from flask import jsonify, request
5-
65
from lin import (
76
Failed,
87
ParameterError,

app/plugin/oss/app/model.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
1-
from sqlalchemy import Column, Integer, String
2-
31
from lin import BaseCrud
2+
from sqlalchemy import Column, Integer, String
43

54

65
class OSS(BaseCrud):

app/plugin/poem/app/__init__.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,10 @@
77

88

99
def initial_data():
10-
from app import create_app
1110
from lin import db
1211

12+
from app import create_app
13+
1314
app = create_app()
1415
with app.app_context():
1516
data = Poem.query.limit(1).all()

app/plugin/poem/app/controller.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
from flask import jsonify
2-
32
from lin import Redprint
3+
44
from app.plugin.poem.app.form import PoemListForm, PoemSearchForm
55

66
from .model import Poem

0 commit comments

Comments
 (0)