自定义排序导出
This commit is contained in:
@@ -146,7 +146,7 @@ let tableColumns: ColumnsType = [
|
||||
{
|
||||
title: t('views.faultManage.activeAlarm.origLevel'),
|
||||
align: 'left',
|
||||
dataIndex: 'origLevel',
|
||||
dataIndex: 'origSeverity',
|
||||
key: 'origSeverity',
|
||||
width: 5,
|
||||
},
|
||||
@@ -434,41 +434,13 @@ function fnExportAll() {
|
||||
onOk() {
|
||||
const key = 'exportAlarmHis';
|
||||
message.loading({ content: t('common.loading'), key });
|
||||
// 排序字段
|
||||
const sortData = {
|
||||
header: [
|
||||
'id',
|
||||
'neId',
|
||||
'neName',
|
||||
'neType',
|
||||
'ackState',
|
||||
'ackTime',
|
||||
'ackUser',
|
||||
'addInfo',
|
||||
'alarmCode',
|
||||
'alarmId',
|
||||
'alarmSeq',
|
||||
'alarmStatus',
|
||||
'alarmTitle',
|
||||
'alarmType',
|
||||
'clearTime',
|
||||
'clearType',
|
||||
'clearUser',
|
||||
'counter',
|
||||
'eventTime',
|
||||
'latestEventTime',
|
||||
'locationInfo',
|
||||
'objectName',
|
||||
'objectType',
|
||||
'objectUid',
|
||||
'origSeverity',
|
||||
'perceivedSeverity',
|
||||
'province',
|
||||
'pvFlag',
|
||||
'specificProblem',
|
||||
'specificProblemId',
|
||||
'timestamp',
|
||||
],
|
||||
let sortArr:any=[];
|
||||
tableColumnsDnd.value.forEach((item: any) => {
|
||||
if(item.dataIndex) sortArr.push(item.dataIndex);
|
||||
})
|
||||
// 排序字段
|
||||
const sortData = {
|
||||
header:sortArr,
|
||||
};
|
||||
exportAll(queryParams).then(res => {
|
||||
if (res.code === RESULT_CODE_SUCCESS) {
|
||||
|
||||
Reference in New Issue
Block a user