The dashboard page won't load after using a reportwidget with a property which uses the object list type. You get the message: ErrorException: substr() expects parameter 1 to be string, array given.
@SebastiaanKloos code example of the report widget that doesn't work please.
@LukeTowers You can add this property to the report widget
'filter' => [
'title' => 'Where',
'type' => 'objectList',
'titleProperty' => 'column',
'itemProperties' => [
[
'property' => 'column',
'title' => 'Column',
'type' => 'string',
],
[
'property' => 'type',
'title' => 'Type',
'type' => 'dropdown',
'default' => '=',
'options' => [
'=' => '=',
'!=' => '!=',
'null' => 'is null',
'notNull' => 'is not null',
],
],
[
'property' => 'value',
'title' => 'Value',
'type' => 'string',
],
],
],
@SebastiaanKloos could you add an example to the test plugin?
@LukeTowers, No problem. I鈥檒l add an example tomorrow
@LukeTowers I have added it to the test plugin
@w20k could you take a look when able?
@LukeTowers sure! Added to my Todo's.
Confirmed.
@LukeTowers found the cause:
https://github.com/octobercms/october/blob/4e92686c1a7de662840fa160b7348003f5ba817d/modules/backend/widgets/ReportContainer.php#L453
$widget->property return an array and Lang::get is waiting for a string.
Screenshot:

Minor note:
https://github.com/octobercms/october/blob/4e92686c1a7de662840fa160b7348003f5ba817d/modules/backend/widgets/ReportContainer.php#L433 - var name is overwritten (not a bug though, yet 馃槃 )
@w20k out of curiosity can you post a screenshot of what the widget's inspector looks like? I don't think I've used the objectList type before.
@LukeTowers was the first time for me to test this functionality. Haven't seen it yet.
Do you know is there an option to make Algolia on octobercms.com to parse those doc files as well - modules/system/assets/ui/docs? Or they're not visible at all? Not sure yet, how our docs system works)
Screenshots:


@w20k not sure about algolia, you'd have to talk to @daftspunk about it.
Most helpful comment
@LukeTowers, No problem. I鈥檒l add an example tomorrow