修改半月报导出功能
This commit is contained in:
@@ -96,14 +96,14 @@ const tableStore = new TableStore({
|
|||||||
fixed: 'right',
|
fixed: 'right',
|
||||||
render: 'tag',
|
render: 'tag',
|
||||||
custom: {
|
custom: {
|
||||||
2: 'warning',
|
功能调试: 'warning',
|
||||||
3: 'warning',
|
出厂调试: 'warning',
|
||||||
4: 'success'
|
正式投运: 'success'
|
||||||
},
|
},
|
||||||
replaceValue: {
|
replaceValue: {
|
||||||
2: '功能调试',
|
功能调试: '功能调试',
|
||||||
3: '出厂调试',
|
出厂调试: '出厂调试',
|
||||||
4: '正式投运'
|
正式投运: '正式投运'
|
||||||
},
|
},
|
||||||
minWidth: 80
|
minWidth: 80
|
||||||
},
|
},
|
||||||
@@ -143,16 +143,16 @@ const tableStore = new TableStore({
|
|||||||
],
|
],
|
||||||
beforeSearchFun: () => {},
|
beforeSearchFun: () => {},
|
||||||
loadCallback: () => {
|
loadCallback: () => {
|
||||||
|
tableStore.table.data.forEach(item => {
|
||||||
|
item.process = item.process == 2 ? '功能调试' : item.process == 3 ? '出厂调试' : '正式投运'
|
||||||
|
})
|
||||||
|
|
||||||
let name = tableStore.table.params.name
|
let name = tableStore.table.params.name
|
||||||
let data = tableStore.table.copyData.filter(item => {
|
let data = tableStore.table.copyData.filter(item => {
|
||||||
// 处理latestTime默认值
|
// 处理latestTime默认值
|
||||||
item.latestTime = item.latestTime || '/'
|
item.latestTime = item.latestTime || '/'
|
||||||
// 需要检查的字段列表
|
// 需要检查的字段列表
|
||||||
const fieldsToCheck = ['projectName', 'engineeringName', 'mac', 'devName', 'lineName']
|
const fieldsToCheck = ['projectName', 'engineeringName', 'mac', 'devName', 'lineName']
|
||||||
console.log(
|
|
||||||
'🚀 ~ fieldsToCheck.some(field => item[field]?.includes(name)):',
|
|
||||||
fieldsToCheck.some(field => item[field]?.includes(name))
|
|
||||||
)
|
|
||||||
|
|
||||||
// 检查任何一个字段包含搜索名称
|
// 检查任何一个字段包含搜索名称
|
||||||
return fieldsToCheck.some(field => item[field]?.includes(name))
|
return fieldsToCheck.some(field => item[field]?.includes(name))
|
||||||
|
|||||||
Reference in New Issue
Block a user