代码拉取完成,页面将自动刷新
"""
:copyright: © 2020 by the Lin team.
:license: MIT, see LICENSE for more details.
"""
from app import create_app
from app.config.code_message import MESSAGE
from app.config.http_status_desc import DESC
from app.model.lin import (
Group,
GroupPermission,
Permission,
User,
UserGroup,
UserIdentity,
)
app = create_app(
group_model=Group,
user_model=User,
group_permission_model=GroupPermission,
permission_model=Permission,
identity_model=UserIdentity,
user_group_model=UserGroup,
config_MESSAGE=MESSAGE,
config_DESC=DESC,
)
if app.config.get("ENV") != "production":
@app.route("/")
def slogan():
return """
<style type="text/css">
* {
padding: 0;
margin: 0;
}
div {
padding: 4px 48px;
}
a {
color: black;
cursor: pointer;
text-decoration: none
}
a:hover {
text-decoration: None;
}
body {
background: #fff;
font-family:
"Century Gothic", "Microsoft yahei";
color: #333;
font-size: 18px;
}
h1 {
font-size: 100px;
font-weight: normal;
margin-bottom: 12px;
}
p {
line-height: 1.6em;
font-size: 42px
}
</style>
<div style="padding: 24px 48px;">
<p>
<a href="https://www.talelin.com" target="_Blank">Lin</a>
<br />
<span style="font-size:30px">
<a href="/apidoc/redoc">心上无垢</a>,<a href="/apidoc/swagger">林间有风</a>。
</span>
</p>
</div>
"""
if __name__ == "__main__":
app.logger.warning(
"""
----------------------------
| app.run() => flask run |
----------------------------
"""
)
app.run()
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。