Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[4.0] Fix: Saving menu item fails. Call to a member function validate() on bool. Field "show_associations" #23716

Merged
merged 3 commits into from
Feb 6, 2019

Conversation

wilsonge
Copy link
Contributor

Pull Request for Issue #23696

Related and already merged fix: #23501

I think this is a better alternative fix to #23700 ?

Testing Instructions

Install a J4 nightly build of today (Monday, 28 January 2019) or update an older J4 with that package

Go to menu items manager in back-end.

Open Home menu item (type "Articles > Featured Articles")

Save it.

Error like described in #23696 (comment)

Apply patch

Try again to save the menu item.

Should be successful.

@SharkyKZ
Copy link
Contributor

Need the same in filter().

libraries/src/Form/Form.php Outdated Show resolved Hide resolved
@wilsonge
Copy link
Contributor Author

@SharkyKZ fixed :)

@ReLater
Copy link
Contributor

ReLater commented Jan 30, 2019

I have tested this item ✅ successfully on c1e7e3b

Saving of articles works, too. After reverting pr #23501


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/23716.

@infograf768
Copy link
Member

Saving of articles works, too. After reverting pr #23501

How is that? We still miss merging #23638
here I get

Error
Save failed with the following error: Incorrect integer value: '' for column 'hits' at row 1

why revert #23501 ?

@infograf768
Copy link
Member

I have tested this item ✅ successfully on 2102697


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/23716.

@infograf768
Copy link
Member

@ReLater
Why reverting #23501 ? I tested here after disabling languagefilter and therefore show_associations not displaying when editing article Options grace to #23501 and it works fine.

@ReLater
Copy link
Contributor

ReLater commented Jan 30, 2019

@infograf768

why revert #23501 ?

Because I could create/save Articles, too, after reverting ONLY these lines of #23501:

// Remove show_associations field if associations is not enabled
		if (!$assoc)
		{
			$form->removeField('show_associations', 'attribs');
		}

So, I think that we don't need the additional fix in 23501 anymore with this pr here. Wasn't that one of the purposes of the discussion about "hardcoded field names"?

@ReLater
Copy link
Contributor

ReLater commented Jan 30, 2019

And the show_associations field is not displayed in a mono-lang page in article edit form.

@infograf768
Copy link
Member

@ReLater
Yep, you are right. We can now delete the lines you quote above as the AssocField take care of that.
@wilsonge
Can you add that to your PR?

@wilsonge
Copy link
Contributor Author

wilsonge commented Feb 4, 2019

PR Amended

@infograf768
Copy link
Member

I have tested this item ✅ successfully on b2eca8e


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/23716.

@alikon
Copy link
Contributor

alikon commented Feb 5, 2019

I have tested this item ✅ successfully on 4a69575


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/23716.

@infograf768
Copy link
Member

RTC


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/23716.

@joomla-cms-bot joomla-cms-bot added the RTC This Pull Request is Ready To Commit label Feb 5, 2019
@Bakual Bakual merged commit 50ed6e9 into joomla:4.0-dev Feb 6, 2019
@joomla-cms-bot joomla-cms-bot removed the RTC This Pull Request is Ready To Commit label Feb 6, 2019
@Bakual Bakual added this to the Joomla 4.0 milestone Feb 6, 2019
@wilsonge wilsonge deleted the fix_assocations branch February 6, 2019 14:23
wilsonge added a commit to wilsonge/joomla-cms that referenced this pull request Dec 22, 2023
Fixes hardening measure introduced in joomla#23716
wilsonge added a commit to wilsonge/joomla-cms that referenced this pull request Dec 22, 2023
Fixes hardening measure introduced in joomla#23716
MacJoom pushed a commit that referenced this pull request Dec 23, 2023
Fixes hardening measure introduced in #23716
Razzo1987 added a commit that referenced this pull request Jan 4, 2024
* Fix link and button colors in header footer (#42504)

* [4.x] add php 8.3 to tests (#42545)

* Update the signature for #42545 (#42552)

* [4.4] Joomlaupdate remove br tag from language strings - follow up to PR 42489 (#42550)

* Better English (1)

* Better English (2)

* Remove br html element from language strings

* Fixes to form validation process (#42560)

Fixes hardening measure introduced in #23716

* [4][com_actionlogs] missed load plugin languages (#42562)

* load lang

* test-4-dupkey

* Better message on package uninstallation (#42570)

* Better message on package uninstallation when an extension from that package is missing. Fixes issue #42537 .

* backport #41865 (#42088)

* backport [5] update from nightly to latest nightly build #41865

* [5] harmonize naming task types (#42574)

* [5.0] colour contrast in media manager file list [a11y] (#42544)

* [5.0] Update phpseclib to 3.0.34 (#42469)

* Fix `function` parameter lost during redirect (#42315)

* Fix `function` parameter lost during redirect

* Move function parameter to form url

* Remove hidden input

* [4.4] Fix SQL error "1104 The SELECT would examine more than MAX_JOIN_SIZE rows" when checking for core updates (#42576)

* Use concat of columns for getting core extensions

* Fix PHPCS

* Remove wrong quotes

* Revert min version in drone (#42583)

* Joomla! 5.0.2 Release Candidate 1

* Revert to dev

* [4][com_templates] cast to int for pgsql (#42569)

* cast to int for pgsql

* yet-another

* patch article tags (#42486)

* Joomla 5.0.2 Release Candidate 2

* Reset to dev

* Update signature HMAC in .drone.yml

---------

Co-authored-by: Rick Spaan <rick@r2h.nl>
Co-authored-by: Christian Heel <66922325+heelc29@users.noreply.github.com>
Co-authored-by: Allon Moritz <allon.moritz@digital-peak.com>
Co-authored-by: Richard Fath <richard67@users.noreply.github.com>
Co-authored-by: Brian Teeman <brian@teeman.net>
Co-authored-by: George Wilson <georgejameswilson@googlemail.com>
Co-authored-by: Nicola Galgano <optimus4joomla@gmail.com>
Co-authored-by: Benjamin Trenkle <benjamin.trenkle@wicked-software.de>
Co-authored-by: Benjamin Trenkle <bembelimen@users.noreply.github.com>
Co-authored-by: David Jardin <d.jardin@djumla.de>
Co-authored-by: janschoenherr <jan@yootheme.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

8 participants