|
|
@ -59,8 +59,8 @@ const TableData = ({ alarmDataGroup, route, dispatch, actions, collectData, setS |
|
|
|
case 'videoAbnormal': |
|
|
|
dispatch(problem.getAlarmVideoList({ ...search.current, pepProjectId: pepProjectId })).then((res) => { |
|
|
|
if (res.success) { |
|
|
|
let tableDatas = res.payload.data?.map(v => ({ |
|
|
|
key: v.alarmId, |
|
|
|
let tableDatas = res.payload.data?.map((v, index) => ({ |
|
|
|
key: v.AlarmId + index, |
|
|
|
id: v.alarmId, |
|
|
|
StructureName: v.struc, |
|
|
|
projectName: v.pomsProject?.map(r => (r.name ? { id: r.id, name: r.name, state: 'PMOS' } : { |
|
|
@ -93,13 +93,13 @@ const TableData = ({ alarmDataGroup, route, dispatch, actions, collectData, setS |
|
|
|
if (genre?.length > 0 && (route === 'dataAbnormal' ? typeId?.length > 0 : true)) { |
|
|
|
dispatch(problem.getAlarmDataList({ |
|
|
|
...(route === 'dataLnterrupt' ? { timestamps: true } : {}), |
|
|
|
...(route === 'dataAbnormal' ? { groupUnitId: typeId?.length > 0 ? typeId?.join(',') : "", } : {}), |
|
|
|
...query, ...(api.current?.getValues() || {}), groupId: groupId.current.map(v => v.id).join(), pepProjectId: pepProjectId, |
|
|
|
...query, ...(search.current || {}), groupId: groupId.current.map(v => v.id).join(), pepProjectId: pepProjectId, |
|
|
|
...((route === 'dataAbnormal' && !search.current?.groupUnitId?.length) ? { groupUnitId: typeId?.length > 0 ? typeId?.join(',') : "", } : {}), |
|
|
|
})).then((res) => { |
|
|
|
if (res.success) { |
|
|
|
setCount(res.payload.data?.count || 0) |
|
|
|
let tableDatas = res.payload.data?.rows?.map(v => ({ |
|
|
|
key: v.AlarmId, |
|
|
|
let tableDatas = res.payload.data?.rows?.map((v, index) => ({ |
|
|
|
key: v.AlarmId + index, |
|
|
|
id: v.AlarmId, |
|
|
|
StructureName: v.StructureName, |
|
|
|
projectName: v.pomsProject?.map(r => (r.name ? { id: r.id, name: r.name, state: 'PMOS' } : { |
|
|
|