king
2022-05-11 823c72bc5918bf9d2fdd8415607908b68ebcd399
src/setupProxy.js
@@ -1,9 +1,9 @@
const proxy = require('http-proxy-middleware')
const host = 'http://qingqiumarket.cn'
const service = 'mkwms/'
// const proxy = require('http-proxy-middleware')
// const host = 'http://qingqiumarket.cn'
// const service = 'mkwms/'
// module.exports = function(app) {}
module.exports = function(app) {
module.exports = function(app) {}
// module.exports = function(app) {
  // app.use(proxy('/webapi', { 
  //   target: `${host}/${service}webapi`,
  //   secure: false,
@@ -41,15 +41,15 @@
  //   }
  // }))
  app.use(proxy('/trans', {
    target: `${host}/${service}`,
    secure: false,
    changeOrigin: true
  }))
//   app.use(proxy('/trans', {
//     target: `${host}/${service}`,
//     secure: false,
//     changeOrigin: true
//   }))
  app.use(proxy('/api', { // 旷视面板机接口测试
    target: `http://192.168.1.66:80`,
    secure: false,
    changeOrigin: true
  }))
}
//   app.use(proxy('/api', { // 旷视面板机接口测试
//     target: `http://192.168.1.66:80`,
//     secure: false,
//     changeOrigin: true
//   }))
// }