hooj0 opened a new issue, #598: URL: https://github.com/apache/fesod/issues/598
### Search before asking - [x] I searched in the [issues](https://github.com/fast-excel/fastexcel/issues) and found nothing similar. ### Motivation 在写入excel文件时,准备好数据后,写入文件对数据进行二次转换或者简单业务逻辑处理。不想再循环进行处理。可以在数据写入单元格的时候进行二次转换或者简单业务逻辑处理,此时,业务可能需要依赖行级完整对象数据。 示例: ``` class Data { private int a; private int b; private int c; private String text; } ``` 在生成text单元格内容,可能需要结合数据a、b、c进行逻辑判断。 ### Solution 希望在converter(WriteConverterContext)或handler(CellWriteHandlerContext)中传入 oneRowData ``` Cell cell = WorkBookUtil.createCell(row, columnIndex); cellWriteHandlerContext.setCell(cell); WriteHandlerUtils.afterCellCreate(cellWriteHandlerContext); cellWriteHandlerContext.setOriginalRecord(oneRowData); // 传入当前行级数据 cellWriteHandlerContext.setOriginalValue(beanMap.get(name)); cellWriteHandlerContext.setOriginalFieldClass(head.getField().getType()); converterAndSet(cellWriteHandlerContext); WriteHandlerUtils.afterCellDispose(cellWriteHandlerContext); beanMapHandledSet.add(name); ``` ### Alternatives _No response_ ### Anything else? _No response_ ### Are you willing to submit a PR? - [x] I'm willing to submit a PR! -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
