1 | () | JROOT/libraries/src/Form/Form.php:1202
2 | Joomla\CMS\Form\Form->validate() | JROOT/libraries/src/MVC/Model/FormModel.php:199
3 | Joomla\CMS\MVC\Model\FormModel->validate() | JROOT/administrator/components/com_menus/Controller/ItemController.php:368
4 | Joomla\Component\Menus\Administrator\Controller\ItemController->save() | JROOT/libraries/src/MVC/Controller/BaseController.php:736
5 | Joomla\CMS\MVC\Controller\BaseController->execute() | JROOT/libraries/src/Dispatcher/ComponentDispatcher.php:146
6 | Joomla\CMS\Dispatcher\ComponentDispatcher->dispatch() | JROOT/libraries/src/Component/ComponentHelper.php:379
7 | Joomla\CMS\Component\ComponentHelper::renderComponent() | JROOT/libraries/src/Application/AdministratorApplication.php:116
8 | Joomla\CMS\Application\AdministratorApplication->dispatch() | JROOT/libraries/src/Application/AdministratorApplication.php:159
9 | Joomla\CMS\Application\AdministratorApplication->doExecute() | JROOT/libraries/src/Application/CMSApplication.php:232
10 | Joomla\CMS\Application\CMSApplication->execute() | JROOT/administrator/includes/app.php:63
11 | require_once() | JROOT/administrator/index.php:36
It looks like method loadField()
(https://github.com/joomla/joomla-cms/blob/4.0-dev/libraries/src/Form/Form.php#L1560) returns false
for field show_associations
Labels |
Added:
?
|
Title |
|
4.0-dev branch (NOT nightly)
I can't reproduce the issue here on non-multilingual site.
I also can't reproduce the issue on a multilingual site, associations set to Yes or NO in the language filter.
The issue has been reported in a german forum and I tested it afterwards and could confirm it with an updated older J4 version and a new online installation.
I've installed now the nightly build of today (Monday, 28 January 2019 03:00:50 UTC) from scratch on XAMPP727 without any additional steps, opened menu item "Home" in back-end, clicked on Save and have still the same issue.
This line https://github.com/joomla/joomla-cms/blob/4.0-dev/libraries/src/Form/Form.php#L1200 results in a $fieldObj === false
when field show_associations
is processed.
Hmm
I did a clean install of the dev branch and I confirm the error:
Call to a member function validate() on boolean
This happens when it is a menu item chosen from the Articles menu items.
This happens whether show_associations
is set or not in Articles Component config.
Can't confirm if show_associations
is the culprit.
Issue confirmed.
Nightly Build of Monday, 28 January 2019.
@joomdonation
I can confirm that adding lines
// Remove show_associations field if associations is not enabled
if (!Associations::isEnabled())
{
$form->removeField('show_associations', 'params');
}
before return $form;
in administrator\components\com_menus\Model\ItemModel.php
solves the issue. Tested in back-end only.
I'll create a pr.
@infograf768
I applied the patch 23700 with Joomla Patch Tester. When I "Revert Patch" then I have the same issue lkike before.
Status | New | ⇒ | Closed |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2019-01-28 13:16:17 |
Closed_By | ⇒ | ReLater |
There's a pr now that works with Joomla core: #23700
So I'm closing here but not happy. See concerns in #23700 (comment) and #23700 (comment)
Only "Site" menu items.