Blame view

uni_modules/uview-plus/libs/luch-request/core/defaults.js 578 Bytes
a2702f6d   刘淇   巡查计划
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
  /**
   * 默认的全局配置
   */
  
  export default {
      baseURL: '',
      header: {},
      method: 'GET',
      dataType: 'json',
      // #ifndef MP-ALIPAY
      responseType: 'text',
      // #endif
      custom: {},
      // #ifdef H5 || APP-PLUS || MP-ALIPAY || MP-WEIXIN
      timeout: 60000,
      // #endif
      // #ifdef APP-PLUS
      sslVerify: true,
      // #endif
      // #ifdef H5
      withCredentials: false,
      // #endif
      // #ifdef APP-PLUS
      firstIpv4: false,
      // #endif
      validateStatus: function validateStatus(status) {
          return status >= 200 && status < 300
      }
  }