Commit 6b3bcfa0 by 王昆

gsb

parent 0ae035b6
...@@ -30,6 +30,7 @@ module.exports = function (app) { ...@@ -30,6 +30,7 @@ module.exports = function (app) {
res.header('Access-Control-Allow-Headers', 'Content-Type, Content-Length, Authorization, Accept, X-Requested-With , yourHeaderFeild, xggsaamerchantsid'); res.header('Access-Control-Allow-Headers', 'Content-Type, Content-Length, Authorization, Accept, X-Requested-With , yourHeaderFeild, xggsaamerchantsid');
res.header('Access-Control-Allow-Methods', 'PUT, POST, GET, DELETE, OPTIONS'); res.header('Access-Control-Allow-Methods', 'PUT, POST, GET, DELETE, OPTIONS');
// res.header('Access-Control-Allow-Credentials', 'true'); // res.header('Access-Control-Allow-Credentials', 'true');
res.header('content-type', 'text/html;charset=UTF-8');
if (req.method == 'OPTIONS') { if (req.method == 'OPTIONS') {
res.send(200); //让options请求快速返回/ res.send(200); //让options请求快速返回/
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment