feiyu02
2022-08-10 43a0780edd2db8e841325cb73032e819716c3595
service/baserequest.js
@@ -11,10 +11,11 @@
const originProperties = ['url', 'data', 'header', 'method', 'success', 'fail', 'complete'];
// const baseUrl = "http://127.0.0.1:8080"
const baseUrl = "http://192.168.0.116:8080"
// const baseUrl = "https://fyami.com.cn:447/"
const basePicUrl = baseUrl + "images/"
const baseFileUrl = baseUrl + "meeting/file/"
const baseUrl = "http://192.168.1.106:8080"
// const baseUrl = "https://fyami.com.cn:447"
// const basePicUrl = baseUrl + "/images/"
const basePicUrl = "https://fyami.com.cn:447/images/"
const baseFileUrl = baseUrl + "/meeting/file/"
function request(fun) { 
  if (fun.params != undefined) {
@@ -50,11 +51,15 @@
    // }
  }
  fun1.fail = function (error) {
    console.log("--------------请求错误----------------" + fun.url);
    console.log(error);
    wx.showToast({
      title: '网络连接失败',
      icon: 'none'
    })
    fun.fail(error)
    if (fun.fail) {
      fun.fail(error)
    }
  }
  fun1.complete = fun.complete
  wx.request(fun1)