update annotate
This commit is contained in:
parent
f4637f0cd8
commit
80ad7feaef
12
coc.py
12
coc.py
@ -1,15 +1,17 @@
|
||||
# 引入文件夹中的文件
|
||||
from flask_cors import CORS #跨域访问
|
||||
import sys
|
||||
sys.path.append('./lib')
|
||||
# 引入处理函数
|
||||
from allFunction import manageLogin, managePhoto, manageAdd, manageDel, manageGet, manageDetail, manageComment
|
||||
|
||||
# 引入flask
|
||||
from flask import Flask, request, session
|
||||
|
||||
# 初始化app
|
||||
app = Flask(__name__)
|
||||
|
||||
#取消跨域访问限制,方便本地测试
|
||||
#CORS(app, resources=r'/*') # 注册CORS, "/*" 允许访问所有api
|
||||
# 引入跨域访问处理模块
|
||||
# from flask_cors import CORS
|
||||
# 取消跨域访问限制,方便本地测试 注册CORS, "/*" 允许访问所有api
|
||||
# CORS(app, resources=r'/*')
|
||||
|
||||
# 登录接口,前端提供cid和pwd,包装在data里边然后md5校验也就是data:{cid,pwd,sign}
|
||||
@app.route('/api/login',methods=['POST'])
|
||||
|
Loading…
x
Reference in New Issue
Block a user