Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mancheng
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
mancheng
Commits
3961e0ad
Commit
3961e0ad
authored
Dec 07, 2021
by
root
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
招商驾驶舱
parent
dcddd7c9
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
7 additions
and
2 deletions
+7
-2
apps/__init__.py
+1
-1
apps/models.py
+0
-0
apps/view_attract/view.py
+4
-0
config.py
+2
-1
No files found.
apps/__init__.py
View file @
3961e0ad
...
...
@@ -19,7 +19,7 @@ redis_store = None # 创建变量避免导入错误,在函数中进行初始
# 配置日志信息
# 创建日志记录器,指明日志保存的路径、每个日志文件的最大大小、保存的日志文件个数上限
file_log_handler
=
RotatingFileHandler
(
"
../
logs/log"
,
maxBytes
=
1024
*
1024
*
100
,
backupCount
=
10
)
file_log_handler
=
RotatingFileHandler
(
"logs/log"
,
maxBytes
=
1024
*
1024
*
100
,
backupCount
=
10
)
stream_log_handler
=
logging
.
StreamHandler
()
# 创建日志记录的格式 日志等级 输入日志信息的文件名 行数 日志信息
formatter
=
logging
.
Formatter
(
'
%(levelname)
s
%(filename)
s:
%(lineno)
d
%(message)
s'
)
...
...
apps/models.py
View file @
3961e0ad
This diff is collapsed.
Click to expand it.
apps/view_attract/view.py
View file @
3961e0ad
...
...
@@ -38,6 +38,10 @@ def get_jjzb(district):
current_app
.
logger
.
error
(
e
)
return
jsonify
(
code
=
RET
.
DBERR
,
msg
=
"数据库错误"
)
@api_attract.route
(
"/index"
,
methods
=
[
"GET"
])
def
menu
():
return
'hello! 你好!'
# 左上角企业数量各资质统计、左上角获取经济指标数据、产业机构分布饼状图数据统计
@api_attract.route
(
"/menu"
,
methods
=
[
"POST"
])
def
menu
():
...
...
config.py
View file @
3961e0ad
...
...
@@ -18,7 +18,8 @@ class Config:
SQLALCHEMY_TRACK_MODIFICATIONS
=
False
# redis配置信息
REDIS_HOST
=
'127.0.0.1'
# REDIS_HOST = '127.0.0.1'
REDIS_HOST
=
'39.100.39.50'
REDIS_PORT
=
6379
# REDIS_PASS = "Mypwdty2020!" # TODO
REDIS_PASS
=
None
# TODO
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment