提交 e77c2307 authored 作者: 钟是志's avatar 钟是志

28106 退寝管理-》待退寝学生中新增导出按钮

上级 f9b5a909
...@@ -244,7 +244,7 @@ export default class Index extends Component { ...@@ -244,7 +244,7 @@ export default class Index extends Component {
width, width,
height, height,
} = this.props; } = this.props;
console.log(this.props); // console.log(this.props);
const { url } = this.state; const { url } = this.state;
if (url) { if (url) {
return <div className={styles.webSign}> return <div className={styles.webSign}>
......
...@@ -344,6 +344,15 @@ export function getHeaders(url = '') { ...@@ -344,6 +344,15 @@ export function getHeaders(url = '') {
const currentInfo = getCurrentUser(); const currentInfo = getCurrentUser();
const timestamp = window.serviceCurrentDate || new Date().getTime(); const timestamp = window.serviceCurrentDate || new Date().getTime();
const secretString = token + currentInfo.userid + currentInfo.typeString + timestamp; const secretString = token + currentInfo.userid + currentInfo.typeString + timestamp;
const res = {
headers: {
Authorization: `bearer ${token}`,
},
};
if(getIsBei_Dian() && currentInfo?.userid){
res.headers.auto = Md5(secretString);
res.headers.timestamp = timestamp;
if (isTest) { if (isTest) {
console.log( console.log(
{ {
...@@ -355,13 +364,8 @@ export function getHeaders(url = '') { ...@@ -355,13 +364,8 @@ export function getHeaders(url = '') {
}, },
); );
} }
return { }
headers: { return res;
Authorization: `bearer ${token}`,
auth: Md5(secretString),
timestamp,
},
};
} }
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论