Browse Source

添加refer1

hella_online_20240823
zhang_li 3 months ago
parent
commit
636a49b5dc
  1. 8
      src/api/httpRequest3.js

8
src/api/httpRequest3.js

@ -16,13 +16,17 @@ function service(options = {}) {
// }
var requestUrl = ""
requestUrl = import.meta.env.VITE_BASE_URL
// 获取当前页面路由
let pages = getCurrentPages(); // 获取所有页面栈的实例数组
let currentPage = pages[pages.length - 1]; // 获取最后一个页面的实例
let currentRoute = currentPage.route; // 获取当前页面的路由
options.header = {
"content-type": "application/json",
"Authorization": "Bearer " + token,
"dataType": "json",
"dataSource": "PDA",
"tenant-id": tenantId
"tenant-id": tenantId,
"referer1":currentPage.route
};
options.timeout = 300000

Loading…
Cancel
Save