These are chat archives for dandelion/dandelion-datatables

12th
Aug 2015
Rizzi
@RizziCR
Aug 12 2015 20:57
I found a issue on XlsExport.java. Line 69 (HSSFSheet sheet = workbook.createSheet(exportConf.getFileName());
)
if the filename exceed 31 characters, i throws an Exception because, the sheet name max length is 31
Thibault Duchateau
@tduchateau
Aug 12 2015 20:58
:-)
nice
Ready to PR?
Rizzi
@RizziCR
Aug 12 2015 21:00
start of next week.. no time currently.. friday 17:00 MET the projects goes live :)
and i have a lot to do before
Thibault Duchateau
@tduchateau
Aug 12 2015 21:00
sure, no problem
I'll open the issue
Rizzi
@RizziCR
Aug 12 2015 21:01
ok
bad time calculation of me :P
or to many changes from customer side
Thibault Duchateau
@tduchateau
Aug 12 2015 21:01
feel free to propose a PR when you have time, it's not a major one :-)
Rizzi
@RizziCR
Aug 12 2015 21:01
i don’t know ;)
yes.. i also have to check if its also in the current version.. this project build with 0.10.1 :)
but a question.. for what is pattern on the fillWithProperty method ?
fillWithProperty(String propertyName, String pattern, String defaultContent)
Thibault Duchateau
@tduchateau
Aug 12 2015 21:05
just if you need to a apply a MessageFormat on the value
Rizzi
@RizziCR
Aug 12 2015 21:06
ok.. and defaultContent is the content if the property is null ?
Thibault Duchateau
@tduchateau
Aug 12 2015 21:06
absolutely
Rizzi
@RizziCR
Aug 12 2015 21:06
good :D
no need to searching :)
set pattern to null, if i don’t need it ?
Thibault Duchateau
@tduchateau
Aug 12 2015 21:07
absolutely, or use the same method but with another signature (without pattrn)
Rizzi
@RizziCR
Aug 12 2015 21:07
the isn’t :)
propertyName
propertyName, pattern
propertyName, pattern, defaultContent
Thibault Duchateau
@tduchateau
Aug 12 2015 21:08
well, another reason for a PR ;-)
Rizzi
@RizziCR
Aug 12 2015 21:08
but hard to do..
only with another method name
Thibault Duchateau
@tduchateau
Aug 12 2015 21:10
let's discuss it when you have time to work on it
Rizzi
@RizziCR
Aug 12 2015 21:10
yep
Thibault Duchateau
@tduchateau
Aug 12 2015 21:10
(dandelion/dandelion-datatables#298)
Rizzi
@RizziCR
Aug 12 2015 21:10
thx
i don’t know why.. but i love this „last minute“ working :D
Thibault Duchateau
@tduchateau
Aug 12 2015 21:11
last minute? what do u mean?
Rizzi
@RizziCR
Aug 12 2015 21:11
2 days to finish and work for 2 weeks :D
Thibault Duchateau
@tduchateau
Aug 12 2015 21:12
let's call it "agile" ..
Rizzi
@RizziCR
Aug 12 2015 21:12
:)
Rizzi
@RizziCR
Aug 12 2015 21:24
nexts question
on export (xls, pdf) sometimes a null value is printed as empty string and sometimes as „null"
also on the same property
Thibault Duchateau
@tduchateau
Aug 12 2015 21:28
please provide a test case so that I can reproduce
or it will hard to fix
Rizzi
@RizziCR
Aug 12 2015 21:29
if there are for example 10 entities to export
5 of them have propery x null
the exported file have then 3 times an empty string and 2 times the string „null“ as value
Rizzi
@RizziCR
Aug 12 2015 21:42
and it’s equal if i set a default content or not.. there are no different
i have to check it later
thx
and the log message is not so useful :)
Something went wrong with the property {}. Check that an accessor method for this property exists in the bean.
Thibault Duchateau
@tduchateau
Aug 12 2015 21:52
Oh actually the log message is. All fillWithProperty(*) methods rely on http://commons.apache.org/proper/commons-beanutils/, which uses naming conventions on beans.
So if you call fillWithProperty("beanProperty"), you're supposed to have a getter in the corresponding Bean called getBeanProperty()
It's up to you to check for nulls when you call these getters
Rizzi
@RizziCR
Aug 12 2015 21:54
yes.. but on 45 properties its hard to find which on is wrong :D
i do some renaming of properties and have forgotten to change it in the export scripts ;)
Thibault Duchateau
@tduchateau
Aug 12 2015 21:55
wow
ok
Rizzi
@RizziCR
Aug 12 2015 21:55
but it’s my problem ;) stupid coder have to work longer :P
Thibault Duchateau
@tduchateau
Aug 12 2015 21:56
I'll have a look at more recent version. Maybe they now support strong-typed arguments..
Rizzi
@RizziCR
Aug 12 2015 21:57
thx
Rizzi
@RizziCR
Aug 12 2015 22:52
i think i can specify the „null“ problem.
if the nested property is null the output is an empty string and a null value is outputted as „null“
with nested property i mean: contact.contactData.country.name if contactData or country is null, the log message from above is shown and the output is an empty string.
if name is null, then the output is „null“ as string. And this is the same also if i declare a defaultContent of „“. the output is also „null"