? Pending

User tests: Successful: Unsuccessful:

avatar infograf768
infograf768
2 Oct 2018

The issue

admin mod_menu parameters are not used

screen shot 2018-10-02 at 18 17 16

Showing or not the Help Menu.
Displaying in the view the link to the Custom Support Forum Help when it exists.

Also, in the view displayed by the Help menu: administrator/index.php?option=com_cpanel&view=help, the Official Language Forums has no url.

Hint: the Official Languages Forum label and link depend on 2 strings in mod_menu ini files:
for en-GB

; Enter in the string below the # of the specific language forum in https://forum.joomla.org/ (example: 19 for French). Default is '511' which is the section for all languages forums.
MOD_MENU_HELP_SUPPORT_OFFICIAL_LANGUAGE_FORUM_VALUE="511"
; If you have chosen to display in the string above the section for all languages, translate the string below.
; If you have displayed the specific language forum, use something like "Official French Forum" in your language.
MOD_MENU_HELP_SUPPORT_OFFICIAL_LANGUAGE_FORUM="Official Language Forums"

The link should be to the general International section of the forum.

for fr-FR

; Enter in the string below the # of the specific language forum in https://forum.joomla.org/ (example: 19 for French). If left empty, it will use '511' which is the section for all languages forums.
MOD_MENU_HELP_SUPPORT_OFFICIAL_LANGUAGE_FORUM_VALUE="19"
; If you have chosen to display in the string above the section for all languages, translate the string below. 
; If you have displayed the specific language forum, use something like "Official French Forum" in your language. 
MOD_MENU_HELP_SUPPORT_OFFICIAL_LANGUAGE_FORUM="Forum officiel français"

The link should be to the specific French language forum.

Summary of Changes

There were some drastic changes in 4.0. concerning the help view which render obsolete some remaining 3.x code. The view is now in com_cpanel and not anymore in com_admin
For example: langforum.php is not used anymore, although the file is still present

Therefore I have modified the view to change the links as should. Added in default.php the code to deal with empty Custom Forum field.
Also I added the mod_menu params in CSSMenu.php to display or not the Help menu item.

Before patch

Choosing to display or not the help menu in the module does not work.

Links to Custom Support Forum and Official Language Forum (the last one can be customised to a specific Official Language Forum, see above) does not work.
The Custom Forum Support label still displays when the param is not set.

After patch

These links work as should.
The Custom Forum Support label is not displayed if the param is not set.
Test using en-GB and fr-FR to get the French Language Official forum.

en-GB
screen shot 2018-10-02 at 18 54 09

fr-FR
screen shot 2018-10-02 at 18 55 16

If the Custom Forum Support field was left empty:

screen shot 2018-10-02 at 18 58 36

If Help Menu is set to Hide.
screen shot 2018-10-02 at 19 04 30

Is this PR complete?

No.
As stated above, we have some remaining code from 3.x which has to get out.
Concerning displaying the Help menu display or not, we still have part of a line which does not work because the help scope does not exist (help items are displayed now as a list in its own page).
We do have some code in the MenuHelper and CSSMenu which is also not used at all.
Also some fields concerning forums help in joomla.xml and modern.xml have unused code, not only scope.

EDIT: I did not correct these as some of them may be necessary when we refactor the code to get back a correct behaviour when creating custom admin menus.

This PR may be considered as a bandaid until someone finds a better way to solve these issues.
I guess moving the help in cpanel was a considered decision as well as using the $links [ code in the view.

avatar infograf768 infograf768 - open - 2 Oct 2018
avatar infograf768 infograf768 - change - 2 Oct 2018
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 2 Oct 2018
Category Administration com_cpanel Modules
avatar infograf768
infograf768 - comment - 2 Oct 2018

This does not need npm to test.

266e598 2 Oct 2018 avatar infograf768 cs
avatar infograf768 infograf768 - change - 2 Oct 2018
Labels Added: ?
avatar infograf768 infograf768 - change - 3 Oct 2018
The description was changed
avatar infograf768 infograf768 - edited - 3 Oct 2018
avatar laoneo laoneo - change - 5 Oct 2018
Status Pending Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 2018-10-05 06:13:22
Closed_By laoneo
avatar laoneo laoneo - close - 5 Oct 2018
avatar laoneo laoneo - merge - 5 Oct 2018
avatar laoneo
laoneo - comment - 5 Oct 2018

Thanks

Add a Comment

Login with GitHub to post a comment