? ? Pending

User tests: Successful: Unsuccessful:

avatar joomlabeat
joomlabeat
25 Feb 2017

Pull Request for Issue #14253

Summary of Changes

Line 605 changed from isset to !empty for $filters['access']

Steps to reproduce the issue

Set the global setting of default access level to any other View Level than the Public and click to create a new menu item. The new menu item won't use your default View Level as per the global setting. Likely it will still use the Public level.

Expected result

Creating new menu item should have access level preselected as defined in Global config.

Actual result

Creating new menu item won't have that access level.

System information (as much as possible)

Joomla 3.6.5

Additional comments

The problem is inside the loadFormData() method -(administrator/com_menus/models/item.php) ~ line #596
$data['access'] = (isset($filters['access']) ? $filters['access'] : JFactory::getConfig()->get('access'));

It currently checks if $filters['access'] is set - which it seems it is no matter what, so it always return true.
!empty should be used instead, to check if the access element has a value.

There is an issue with new menu items that won't obey to the global setting of default access level.
Currently they will use a default access level, if there is a filter previously in the menu items list, but otherwise they will default to the first menu item by viewlevel id.

A small update:
What I haven't test though, is if the checking of the other $filters that this method deals, would also need to be against a non empty value, instead of the var being set. But as far I recall, the case with the others filters is that there is not a global default that they need to retrieve anyways.

Documentation Changes Required

none

Votes

# of Users Experiencing Issue
0/1
Average Importance Score
1.00

avatar joomlabeat joomlabeat - open - 25 Feb 2017
avatar joomlabeat joomlabeat - change - 25 Feb 2017
Status New Pending
avatar joomlabeat joomlabeat - edited - 25 Feb 2017
avatar joomla-cms-bot joomla-cms-bot - change - 25 Feb 2017
Category Administration com_menus
avatar zero-24 zero-24 - change - 25 Feb 2017
The description was changed
avatar zero-24 zero-24 - edited - 25 Feb 2017
avatar zero-24
zero-24 - comment - 25 Feb 2017

@joomlabeat i have just copied the info form the issue into this here. Thanks.

avatar joomlabeat
joomlabeat - comment - 25 Feb 2017

@zero-24 sure thing!

avatar joomlabeat joomlabeat - change - 27 Feb 2017
The description was changed
avatar joomlabeat joomlabeat - edited - 27 Feb 2017
avatar Sieger66 Sieger66 - test_item - 28 Feb 2017 - Tested successfully
avatar Sieger66
Sieger66 - comment - 28 Feb 2017

I have tested this item successfully on 91bb1a1


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

avatar csthomas csthomas - test_item - 28 Feb 2017 - Tested successfully
avatar csthomas
csthomas - comment - 28 Feb 2017

I have tested this item successfully on 91bb1a1


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

avatar franz-wohlkoenig
franz-wohlkoenig - comment - 1 Mar 2017

RTC as there are 2 successfully Tests?

avatar jeckodevelopment jeckodevelopment - change - 5 Mar 2017
Status Pending Ready to Commit
avatar jeckodevelopment
jeckodevelopment - comment - 5 Mar 2017

RTC


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

avatar jeckodevelopment jeckodevelopment - edited - 5 Mar 2017
avatar rdeutz rdeutz - change - 6 Mar 2017
Status Ready to Commit Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 2017-03-06 12:05:16
Closed_By rdeutz
Labels Added: ? ?
avatar rdeutz rdeutz - close - 6 Mar 2017
avatar rdeutz rdeutz - merge - 6 Mar 2017

Add a Comment

Login with GitHub to post a comment