| | |
| | | * @Author: shuishen 1109946754@qq.com |
| | | * @Date: 2022-07-29 15:19:13 |
| | | * @LastEditors: shuishen 1109946754@qq.com |
| | | * @LastEditTime: 2023-02-20 10:11:07 |
| | | * @LastEditTime: 2023-02-20 15:59:57 |
| | | * @FilePath: \srs-police-affairs\src\router\axios.js |
| | | * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE |
| | | */ |
| | |
| | | } |
| | | |
| | | //headers判断是否需要 |
| | | // const authorization = config.authorization === false |
| | | // if (!authorization) { |
| | | // config.headers["Authorization"] = `Basic ${Base64.encode("saber:saber_secret")}` |
| | | // } |
| | | const authorization = config.authorization === false |
| | | if (!authorization) { |
| | | config.headers["Authorization"] = `Basic ${Base64.encode("saber:saber_secret")}` |
| | | } |
| | | //让每个请求携带token |
| | | |
| | | //headers中配置text请求 |