__init__.py
2.5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
# coding=utf-8
#author: 4N
#createtime: 2021/3/1
#email: nheweijun@sina.com
from flasgger import swag_from
from flask import Blueprint
from app.util import BlueprintApi
from . import field_edit
from . import table_list
from . import field_list
from . import table_edit
from . import table_info
from . import table_refresh
from . import table_delete
from . import table_view
from . import table_vacuate
class DataManager(BlueprintApi):
bp = Blueprint("DataManager", __name__, url_prefix="/API/Manager")
@staticmethod
@bp.route('/FieldEdit', methods=['POST'])
@swag_from(field_edit.Api.api_doc)
def field_edit():
"""
修改属性别名
"""
return field_edit.Api().result
@staticmethod
@bp.route('/FieldList', methods=['POST'])
@swag_from(field_list.Api.api_doc)
def field_list():
"""
属性列表
"""
return field_list.Api().result
@staticmethod
@bp.route('/TableList', methods=['POST'])
@swag_from(table_list.Api.api_doc)
def table_list():
"""
数据列表
"""
return table_list.Api().result
@staticmethod
@bp.route('/TableEdit', methods=['POST'])
@swag_from(table_edit.Api.api_doc)
def table_edit():
"""
修改数据
"""
return table_edit.Api().result
@staticmethod
@bp.route('/TableDelete', methods=['POST'])
@swag_from(table_delete.Api.api_doc)
def table_delete():
"""
删除数据
"""
return table_delete.Api().result
@staticmethod
@bp.route('/TableInfo', methods=['POST'])
@swag_from(table_info.Api.api_doc)
def table_info():
"""
数据信息
"""
return table_info.Api().result
@staticmethod
@bp.route('/TableRefresh', methods=['POST'])
@swag_from(table_refresh.Api.api_doc)
def table_refresh():
"""
刷新数据
"""
return table_refresh.Api().result
@staticmethod
@bp.route('/TableView', methods=['POST'])
@swag_from(table_view.Api.api_doc)
def table_view():
"""
数据浏览
"""
return table_view.Api().result
@staticmethod
@bp.route('/TableVacuate', methods=['POST'])
@swag_from(table_vacuate.Api.api_doc)
def table_vacuate():
"""
数据抽稀
"""
return table_vacuate.Api().result