Open mlewis-everley opened 4 years ago
Thank you for reporting this. In terms of getting this resolved in a timely manner, just letting you know that the team at Silverstripe Ltd set bugfix priorities based on the impact of the bug with critical being the highest, so at this stage we cannot say when we’ll get a chance to look at this further.
If other people are experiencing this same issue then we'd encourage them to share their experiences here, which can help raise the priority on getting this issue resolved. Please follow the guide about what is useful when making bug reports.
Community help creating a pull-request for this is most welcome, so perhaps this is something that you could do? Read more about contributing code.
Yep, just found myself in the same situation. Exact same scenario, export fields had non key value fields and were different from summary fields. That resulted in the non key value fields being blank in the export file. If updating summary fields to the same as the export, the values would be displayed. Updating export fields to all have key => value, export file also had values as expected.
Affected Version
SilverStripe 4.3+
Description
If I create a
DataObject
and give it differentsummary_fields
andexport_fields
, but use a simple sequential array forexport_fields
, then the export field values are blank.Steps to Reproduce
Create a
DataObject
like the following:Now add a simple
ModelAdmin
to manage these items, add some and try to export. All fields (other thanImagesList
) arenull
.This issue appears to be related to #9244 , but the fix mentioned doesn't fix this issue. I am not sure if this is expected functionality, but in my mind,
export_fields
should work likesummary_fields
and fall back to using$record->fieldLabel()
.