Skip to content
切换导航条
切换导航条
当前项目
正在载入...
登录
董杰
/
induction_shelf
转到一个项目
切换导航栏
切换导航栏固定状态
项目
群组
代码片段
帮助
项目
活动
版本库
流水线
图表
问题
0
合并请求
0
维基
网络
创建新的问题
作业
提交
问题看板
文件
提交
网络
比较
分支
标签
Commit b3b114b3
由
刘韬
编写于
2022-03-21 09:15:27 +0800
浏览文件
选项
浏览文件
标签
下载
电子邮件补丁
差异文件
1
1 个父辈
a3bcaa22
隐藏空白字符变更
内嵌
并排
正在显示
1 个修改的文件
包含
6 行增加
和
1 行删除
smartshelf/app/induction_test.py
smartshelf/app/induction_test.py
查看文件 @
b3b114b
...
@@ -32,6 +32,8 @@ basepath = os.path.dirname(__file__)
...
@@ -32,6 +32,8 @@ basepath = os.path.dirname(__file__)
uploads_path
=
basepath
+
Config
.
UPLOAD_FOLDER
uploads_path
=
basepath
+
Config
.
UPLOAD_FOLDER
COLORS
=
Config
.
COLORS
COLORS
=
Config
.
COLORS
@babel.localeselector
@babel.localeselector
def
get_locale
():
def
get_locale
():
# if the user has set up the language manually it will be stored in the session,
# if the user has set up the language manually it will be stored in the session,
...
@@ -104,7 +106,8 @@ def deal_allcommand(color):
...
@@ -104,7 +106,8 @@ def deal_allcommand(color):
# commands = []
# commands = []
addrs
=
read_addrs
()
addrs
=
read_addrs
()
addrs_string
=
addrs
.
split
(
'@'
)
addrs_string
=
addrs
.
split
(
'@'
)
addr_list
=
filter
(
None
,
list
(
map
(
remove_a
,
addrs
)))
#addr_list = filter(None,list(map(remove_a,addrs)))
addr_list
=
filter
(
None
,
list
(
map
(
remove_a
,
addrs_string
)))
# addr_list = list(filter(None, addr_list))
# addr_list = list(filter(None, addr_list))
for
addr
in
addr_list
:
for
addr
in
addr_list
:
color_index
=
color
[
0
]
color_index
=
color
[
0
]
...
@@ -140,6 +143,8 @@ def process_linetest(data):
...
@@ -140,6 +143,8 @@ def process_linetest(data):
texts
+=
str
(
json
.
dumps
(
text
))
+
'
\n
'
texts
+=
str
(
json
.
dumps
(
text
))
+
'
\n
'
return
texts
return
texts
data
=
{
'channel_num'
:
'all'
,
'channel_color'
:
'off'
}
texts
=
process_linetest
(
data
)
@app.route
(
'/indlineledon'
,
methods
=
[
'POST'
])
@app.route
(
'/indlineledon'
,
methods
=
[
'POST'
])
# @checkscan
# @checkscan
...
...
编写
预览
支持
Markdown
格式
附加文件
你添加了
0
人
到此讨论。请谨慎行事。
Finish editing this message first!
Cancel
请
注册
或
登录
后发表评论