1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
package cn.flightfeather.supervision.business.report.cols
 
import cn.flightfeather.supervision.business.report.BaseCols
import cn.flightfeather.supervision.business.report.DataSource
import cn.flightfeather.supervision.common.utils.ExcelUtil
 
//场景名称及类型
class ColSceneName(chooseIndexList: List<Int> = emptyList()) : BaseCols(chooseIndexList) {
    override fun onHeads(dataSource: DataSource): MutableList<MutableList<ExcelUtil.MyCell>> {
        return mutableListOf(
            mutableListOf(
                ExcelUtil.MyCell("表单编号"),
                ExcelUtil.MyCell("唯一序号"),
                ExcelUtil.MyCell("场景类型"),
                ExcelUtil.MyCell("场景名称")
            )
        )
    }
 
    override fun onOneRow(rowData: DataSource.RowData): List<Any> {
//        return listOf(rowData.scene?.index ?: -99, rowData.scene?.extension2 ?: "", rowData.scene?.name ?: "")
        return listOf(
            rowData.index + 1,
            rowData.scene?.index ?: -99,
            rowData.scene?.type ?: "",
            rowData.scene?.name ?: ""
        )
    }
}