Publisher does not support the Fluid field type. Please do not contact asking when support will be available.

If you purchased an add-on from expressionengine.com, be sure to visit boldminded.com/claim to add the license to your account here on boldminded.com.

Ticket: Bug when adding grid data

Status Resolved
Add-on / Version Publisher 3.5
Severity
EE Version 6.2.4

Andreas Maier

Jan 28, 2022

I am trying to add entries in a grid (rows of data). When saving this error is displayed:
Result: Can not add data in channel entry.

Error Caught
Unknown named parameter $rows
ee/legacy/libraries/api/Api_channel_fields.php:377

Stack Trace: Please include when reporting this error
#0 ee/ExpressionEngine/Model/Content/FieldFacade.php(184): Api_channel_fields->apply()
#1 ee/ExpressionEngine/Model/Content/ContentModel.php(287): ExpressionEngine\Model\Content\FieldFacade->validate()
#2 ee/ExpressionEngine/Service/Validation/Validator.php(238): ExpressionEngine\Model\Content\ContentModel->validateCustomField()
#3 [internal function]: ExpressionEngine\Service\Validation\Validator->ExpressionEngine\Service\Validation\{closure}()
#4 ee/ExpressionEngine/Service/Validation/Rule/Callback.php(30): call_user_func()
#5 ee/ExpressionEngine/Service/Validation/Validator.php(180): ExpressionEngine\Service\Validation\Rule\Callback->validate()
#6 ee/ExpressionEngine/Service/Validation/Validator.php(143): ExpressionEngine\Service\Validation\Validator->_validate()
#7 ee/ExpressionEngine/Service/Model/Model.php(470): ExpressionEngine\Service\Validation\Validator->validatePartial()
#8 ee/ExpressionEngine/Model/Channel/ChannelEntry.php(214): ExpressionEngine\Service\Model\Model->validate()
#9 ee/ExpressionEngine/Controller/Publish/AbstractPublish.php(377): ExpressionEngine\Model\Channel\ChannelEntry->validate()
#10 ee/ExpressionEngine/Controller/Publish/Edit.php(479): ExpressionEngine\Controller\Publish\AbstractPublish->validateEntry()
#11 [internal function]: ExpressionEngine\Controller\Publish\Edit->entry()
#12 ee/ExpressionEngine/Core/Core.php(257): call_user_func_array()
#13 ee/ExpressionEngine/Core/Core.php(113): ExpressionEngine\Core\Core->runController()
#14 ee/ExpressionEngine/Boot/boot.php(161): ExpressionEngine\Core\Core->run()
#15 httpdocs/admin.php(144): require_once(’...’)
#15 httpdocs/admin.php(144): require_once(’...’)

#1

Andreas Maier

Just tried updating an older channel with grid data. Here I get the same error as printed above. How can we resolve this quickly. Kind of blocks work atm?

#2

BoldMinded (Brian)

Can you provide more info on what you were doing when the error occurred? Were you saving an entry in the default language, or non-default language? Saving as open/published or draft? I need to be able to replicate this locally in order to look into it.

#3

Andreas Maier

Hi, sure.

Default Language (EN), the channel was created before installing Publisher.

I tried with Draft enabled same, disabled draft mode also to see if it persists - but the same. I can provide you login credentials so you can see what happens.

#4

BoldMinded (Brian)

Is the grid field or any column in it set to required?

#5

Andreas Maier

No, no required column there… should i add one to test?

#6

Andreas Maier

tried to make one field required. Still the same.

#7

BoldMinded (Brian)

No, not necessary. Based on the error message that looks like it might have been related, but I just got the error locally. This is definitely something new, probably a change to EE’s core that I’ll have to look into.

#8

Andreas Maier

😊 Sorry to discover the bugs 😊

#9

BoldMinded (Brian)

What version of PHP are you using?

#10

Andreas Maier

8.1.2

#11

BoldMinded (Brian)

Comment has been marked private.

#12

Andreas Maier

Hi,

the error now is different:

TypeError Caught array_key_exists(): Argument #2 ($array) must be of type array, string given user/addons/publisher/Service/Handler/FieldHandler.php:213

Stack Trace: Please include when reporting this error

0 user/addons/publisher/Service/Handler/FieldHandler.php(213): array_key_exists()

1 user/addons/publisher/ext.publisher.php(402): BoldMinded\Publisher\Service\Handler\FieldHandler->modify()

2 ee/legacy/libraries/Extensions.php(203): Publisher_ext->custom_field_modify_data()

3 ee/legacy/libraries/Extensions.php(108): EE_Extensions->call_class()

4 ee/legacy/libraries/api/Api_channel_fields.php(1485): EE_Extensions->call()

5 ee/legacy/libraries/api/Api_channel_fields.php(374): Api_channel_fields->custom_field_data_hook()

6 ee/ExpressionEngine/Model/Content/FieldFacade.php(184): Api_channel_fields->apply()

7 ee/ExpressionEngine/Model/Content/ContentModel.php(287): ExpressionEngine\Model\Content\FieldFacade->validate()

8 ee/ExpressionEngine/Service/Validation/Validator.php(238): ExpressionEngine\Model\Content\ContentModel->validateCustomField()

9 [internal function]: ExpressionEngine\Service\Validation\Validator->ExpressionEngine\Service\Validation\{closure}()

10 ee/ExpressionEngine/Service/Validation/Rule/Callback.php(30): call_user_func()

11 ee/ExpressionEngine/Service/Validation/Validator.php(180): ExpressionEngine\Service\Validation\Rule\Callback->validate()

12 ee/ExpressionEngine/Service/Validation/Validator.php(143): ExpressionEngine\Service\Validation\Validator->_validate()

13 ee/ExpressionEngine/Service/Model/Model.php(470): ExpressionEngine\Service\Validation\Validator->validatePartial()

14 ee/ExpressionEngine/Model/Channel/ChannelEntry.php(214): ExpressionEngine\Service\Model\Model->validate()

15 ee/ExpressionEngine/Controller/Publish/AbstractPublish.php(377): ExpressionEngine\Model\Channel\ChannelEntry->validate()

16 ee/ExpressionEngine/Controller/Publish/Edit.php(479): ExpressionEngine\Controller\Publish\AbstractPublish->validateEntry()

17 [internal function]: ExpressionEngine\Controller\Publish\Edit->entry()

18 ee/ExpressionEngine/Core/Core.php(257): call_user_func_array()

19 ee/ExpressionEngine/Core/Core.php(113): ExpressionEngine\Core\Core->runController()

20 ee/ExpressionEngine/Boot/boot.php(161): ExpressionEngine\Core\Core->run()

21 httpdocs/admin.php(144): require_once(‘…’)

21 httpdocs/admin.php(144): require_once(‘…’)

#13

BoldMinded (Brian)

Comment has been marked private.

Login to reply