Pending

User tests: Successful: Unsuccessful:

avatar bertmert
bertmert
6 Apr 2017

Partial(!) pull request for Issue #15123
Fixes 2 error messages "Undefined index: assetgroup_id", Undefined index: language_id.

@izharaazmi
Could you please check this PR if it's a practicable solution

Summary of Changes

Clear batch_commands array for batch processes of admin menus

Testing Instructions

  • Create 2 administrator menus A and B.

  • Create an administrator menu item "abcde" in A.

  • Select menu item "abcde" in menu items list of menu A.

  • Click batch button and copy or move menu item "abcde" to menu B.

  • In the PHP error log:

Undefined index: assetgroup_id in \joomla-cms-staging\libraries\legacy\model\admin.php on line 258
Undefined index: language_id in \joomla-cms-staging\libraries\legacy\model\admin.php on line 258
  • Apply patch.

  • Try again.

avatar bertmert bertmert - open - 6 Apr 2017
avatar bertmert bertmert - change - 6 Apr 2017
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 6 Apr 2017
Category Administration com_menus
avatar bertmert bertmert - change - 6 Apr 2017
Title
Fix#1512[com_menus] Undefined index: assetgroup_id & Undefined index: language_id
Fix#1512 [com_menus] Undefined index: assetgroup_id & language_id
avatar bertmert bertmert - edited - 6 Apr 2017
avatar bertmert bertmert - edited - 6 Apr 2017
avatar Quy Quy - test_item - 6 Apr 2017 - Tested unsuccessfully
avatar Quy
Quy - comment - 6 Apr 2017

I have tested this item ? unsuccessfully on bbf2b4e

The undefined index warnings are fixed, however, this error persists:

Batch process failed with following error: exception 'UnexpectedValueException' with message '%ss::moveByReference() is trying to make record ID 489 a child of itself.' in C:\xampp\htdocs\joomla-cms-staging\libraries\joomla\table\nested.php:346<hr /><sub>This comment was created with the <a href="https://github.com/joomla/jissues">J!Tracker Application</a> at <a href="https://issues.joomla.org/tracker/joomla-cms/15132">issues.joomla.org/tracker/joomla-cms/15132</a>.
avatar bertmert
bertmert - comment - 6 Apr 2017

You're right. I didn't test the "move menu item to itself" issue. Just the index thing.

The first part of your issue ("Batch process failed with following error: exception 'UnexpectedValueException' with message...") seems to be another problem that is also present when you try to move SITE menu items (not only ADMINISTRATOR menu items! Should be solved in another PR.

I'll change the testing instructions in this PR here.

avatar bertmert bertmert - change - 6 Apr 2017
Title
Fix#1512 [com_menus] Undefined index: assetgroup_id & language_id
Partial fix#15123 [com_menus] Undefined index: assetgroup_id & language_id
avatar bertmert bertmert - edited - 6 Apr 2017
avatar bertmert bertmert - change - 6 Apr 2017
The description was changed
avatar bertmert bertmert - edited - 6 Apr 2017
avatar Quy Quy - test_item - 6 Apr 2017 - Tested successfully
avatar Quy
Quy - comment - 6 Apr 2017

I have tested this item successfully on bbf2b4e


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

avatar franz-wohlkoenig franz-wohlkoenig - test_item - 7 Apr 2017 - Tested successfully
avatar franz-wohlkoenig
franz-wohlkoenig - comment - 7 Apr 2017

I have tested this item successfully on bbf2b4e


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

avatar franz-wohlkoenig franz-wohlkoenig - change - 7 Apr 2017
Priority Medium Low
Status Pending Ready to Commit
Easy No Yes
avatar izharaazmi
izharaazmi - comment - 7 Apr 2017

@bertmert Sorry, I could not look at this earlier. I see your patch prevents the current error message, however it does not fix the real problem. I'll sent a patch for it soon.

avatar izharaazmi
izharaazmi - comment - 7 Apr 2017

Please remove RTC, this doesn't fix the issue.

avatar franz-wohlkoenig
franz-wohlkoenig - comment - 7 Apr 2017

@izharaazmi will remove RTC later, CDN isn't working right now.

avatar franz-wohlkoenig franz-wohlkoenig - change - 7 Apr 2017
Status Ready to Commit Pending
avatar mbabker
mbabker - comment - 7 Apr 2017

Umm, the CDN issue was fixed a while ago. I've cleared the tracker's local cache of those resources to force a refresh, otherwise everything should be normal.

avatar franz-wohlkoenig
franz-wohlkoenig - comment - 7 Apr 2017

works now, thanks @mbabker

avatar bertmert
bertmert - comment - 7 Apr 2017

Please see also my comment https://github.com/joomla/joomla-cms/pull/15152/files#r110400212

At the moment I don't understand why we needed several model specific arrays $batch_commands and PRs if we just can use a !empty in admin.php model.

avatar bertmert bertmert - change - 7 Apr 2017
Status Pending Closed
Closed_Date 0000-00-00 00:00:00 2017-04-07 14:46:16
Closed_By bertmert
avatar bertmert bertmert - close - 7 Apr 2017

Add a Comment

Login with GitHub to post a comment