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

北电科 安全漏洞 解决 getSqlData 接口参数的问题

上级 9a9bf1e2
...@@ -388,6 +388,7 @@ export default class ZdyTable extends Component { ...@@ -388,6 +388,7 @@ export default class ZdyTable extends Component {
} }
const data = datas[tr.key]; const data = datas[tr.key];
const all = []; const all = [];
if(data && data.item){
for (var i = 0; i < data.items.length; i++) { for (var i = 0; i < data.items.length; i++) {
const row = data.items[i]; const row = data.items[i];
const r = []; const r = [];
...@@ -401,6 +402,8 @@ export default class ZdyTable extends Component { ...@@ -401,6 +402,8 @@ export default class ZdyTable extends Component {
} }
all.push(r); all.push(r);
} }
}
sheetData[tr.title] = all; sheetData[tr.title] = all;
}; };
......
...@@ -861,11 +861,22 @@ export default class TableCom extends Component { ...@@ -861,11 +861,22 @@ export default class TableCom extends Component {
return 'norefeshxxxxxxxxxxxxxxxxxxxx'; return 'norefeshxxxxxxxxxxxxxxxxxxxx';
}; };
sqlUtil = (base52, json, orgCallback, sqlKey, params, callback, options = {}) => { sqlUtil = (base52, json, orgCallback, sqlKey, params, callback, options = {}) => {
let otherParams = {};
if(params && params.otherParams){
otherParams = {
...params.otherParams,
}
}
// console.log({ // console.log({
// base52, json, orgCallback, sqlKey, params, callback, options // base52, json, orgCallback, sqlKey, params, callback, options
// }) // })
//查缓存 //查缓存
// console.log(params && params.otherParams, JSON.stringify(params));
var isChange = false; var isChange = false;
const { sqlKeys } = this.state; const { sqlKeys } = this.state;
...@@ -968,10 +979,13 @@ export default class TableCom extends Component { ...@@ -968,10 +979,13 @@ export default class TableCom extends Component {
...this.props.defaultValues[this.props.formKey], ...this.props.defaultValues[this.props.formKey],
...options, ...options,
}); });
let pp = { let pp = {
sqlKey, sqlKey,
params, params,
allValues, allValues,
...otherParams,
}; };
if (getToken() != null) { if (getToken() != null) {
pp.token = getToken(); pp.token = getToken();
......
差异被折叠。
...@@ -129,11 +129,7 @@ const getUrl = url => (url.startsWith('/') ? url : '/' + url); ...@@ -129,11 +129,7 @@ const getUrl = url => (url.startsWith('/') ? url : '/' + url);
export const request = (url, data, options = {}) => { export const request = (url, data, options = {}) => {
if (url && url.indexOf('getSqlData') > -1) { if (url && url.indexOf('getSqlData') > -1) {
console.log({ console.log(data);
url,
data,
options,
});
} }
return giveBase16EnCode(data, url) return giveBase16EnCode(data, url)
.then((newData) => { .then((newData) => {
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论