-
Notifications
You must be signed in to change notification settings - Fork 54
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
【特性讨论】数据写入能否按需设置横向 #307
Labels
Comments
可以再讨论,如果是横向的话那表头也得转向吧,感觉这个需求只需要将数据二次处理即可,N:1指的是什么呢?
… 在 2022年11月14日,10:40,2259289435 ***@***.***> 写道:
场景:使用 excel 打印,列头少情况下,经常采用数据合并,目的:一节省纸张,二数据量大
举例:
现在 excel 生成的格式为:
行一:跨列标题
行二:列1 列2
行三:数据1 数据1
行四:数据2 数据2
希望的格式为:两条数据合成一行
行一:跨列标题
行二:列1 列2 列1 列2
行三:数据1 数据1 数据2 数据2
行四:数据3 数据3 数据4 数据4
行五:数据5 数据5
现在通过编码去手动合并两行为一个对象显示可以实现,但底层还是数据与行 1 : 1,能否支持数据与行 N :1 ?
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you are subscribed to this thread.
|
能将使用场景具体化吗?原始数据是什么,最终效果是怎样,可以截图一个具体excel文件
… 在 2022年11月14日,10:40,2259289435 ***@***.***> 写道:
场景:使用 excel 打印,列头少情况下,经常采用数据合并,目的:一节省纸张,二数据量大
举例:
现在 excel 生成的格式为:
行一:跨列标题
行二:列1 列2
行三:数据1 数据1
行四:数据2 数据2
希望的格式为:两条数据合成一行
行一:跨列标题
行二:列1 列2 列1 列2
行三:数据1 数据1 数据2 数据2
行四:数据3 数据3 数据4 数据4
行五:数据5 数据5
现在通过编码去手动合并两行为一个对象显示可以实现,但底层还是数据与行 1 : 1,能否支持数据与行 N :1 ?
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you are subscribed to this thread.
|
数据与行 N : 1,比如上图就是数据与行 3 : 1,好处就是作业人员使用的时候可以一张纸看到尽可能多的数据,并且节省纸张。 现在确实可以通用listmap业务自行二次封装处理,但这种场景是比较通用的一种业务需求,所以想了解能否把这种数据与行自定义对应的能力封装到框架内。 |
感谢反馈,已了解使用场景,考虑添加扩展属性或注解以支持新特性 |
临时的你可以使用如下自定义WorksheetWriter实现该功能,原理很简单首先是表头需要特殊处理,将原来的表头复制n次,其次写行数据的时候判断是否需要写行头和行尾。需要注意写出时取消原有的斑马线,如果要实现斑马线需要使用
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
场景:使用 excel 打印,列头少情况下,经常采用数据合并,目的:一节省纸张,二数据量大
举例:
现在 excel 生成的格式为:
行一:跨列标题
行二:列1 列2
行三:数据1 数据1
行四:数据2 数据2
希望的格式为:两条数据合成一行
行一:跨列标题
行二:列1 列2 列1 列2
行三:数据1 数据1 数据2 数据2
行四:数据3 数据3 数据4 数据4
行五:数据5 数据5
现在通过编码去手动合并两行为一个对象显示可以实现,但底层还是数据与行 1 : 1,能否支持数据与行 N :1 ?
The text was updated successfully, but these errors were encountered: