? Success

User tests: Successful: Unsuccessful:

avatar dgt41
dgt41
4 Dec 2014

Corrects one of the two problems in com_menus #5304

The problem

Changes on the title and the position of any module in com_menus never actually reflected in the relative view.

Tests Instructions

First observe the problem:
Go to administrator-> Menus -> Select a menu
Select a menu item e.g. Home and go to edit screen
Go to Module Assignment (last tab) and click on any of the available modules
On the modal change either the position or the title (or both)
save and close the modal
Observe that title and position DOESN’T reflect on the changes you’ve made.

Apply this PR and repeat the same procedure. Observe the title and position.
Everything should work fine now

UPDATE : Also the access level and Display are now nicely updated, whenever a change is made.

Preview:

screen shot 2014-12-05 at 6 02 07

avatar dgt41 dgt41 - open - 4 Dec 2014
avatar jissues-bot jissues-bot - change - 4 Dec 2014
Labels Added: ?
avatar peterlose
peterlose - comment - 4 Dec 2014

Tested. Works! Could it be made possible to see changes made to display as well?

avatar dgt41
dgt41 - comment - 4 Dec 2014

@losedk hmmm can you enlighten me a bit? what is this all referring to?

avatar peterlose
peterlose - comment - 4 Dec 2014

The third column. Shows if a module is shown on the particular page, not on the page or on all pages.

avatar dgt41
dgt41 - comment - 4 Dec 2014

@losedk That was a good idea! I think now is complete

bb726ea 4 Dec 2014 avatar dgt41 text
avatar peterlose
peterlose - comment - 4 Dec 2014

All good! I was just going to write if you could remove the logging, but you beat me to it :)

avatar dgt41
dgt41 - comment - 4 Dec 2014

@losedk I am thinking that from a UX perspective also the checkbox for hiding stuff is not perfect. A button will be nicer

avatar peterlose
peterlose - comment - 4 Dec 2014

What about something like this?

skaermbillede 2014-12-04 kl 19 22 00

avatar dgt41
dgt41 - comment - 4 Dec 2014

One button is enough I think:
screen shot 2014-12-04 at 8 23 28

avatar peterlose
peterlose - comment - 4 Dec 2014

Yeah agree. But do we do that any place else? The show/hide is widely used and known to the users

avatar dgt41
dgt41 - comment - 4 Dec 2014

@losedk Probably you are right here, the yes/no is a better fit and is the joomla way...

avatar sovainfo
sovainfo - comment - 4 Dec 2014

It is the joomla way for settings, not for filters! Doesn't seem to be a standard for filters!

avatar peterlose
peterlose - comment - 4 Dec 2014

@sovainfo any better suggestion? And I don't agree with you, since users know the show/hide button as a filter from the showon function

avatar dgt41
dgt41 - comment - 4 Dec 2014

The problem for me right now is access levels, and here is what more is needed to get it to production level:
A call to #__usergroups to get an array of id and title
Convert php array to js
some logic to assign the right title to the id from the modal.

Any help is welcome!

avatar sovainfo
sovainfo - comment - 4 Dec 2014

Wouldn't mind any of the flavours for filters.

  • Filter on the left
  • Filter as search tool
  • Filter on the right (with ordering and pagelimit) Don't think administrators know about the showon function. Don't think you should confuse filters with settings.
avatar dgt41
dgt41 - comment - 5 Dec 2014

Now everything should nicely reflect any changes on the modal. Missing one string for access level…

Preview:
screen shot 2014-12-05 at 3 35 48

avatar dgt41 dgt41 - change - 5 Dec 2014
The description was changed
avatar smanzi
smanzi - comment - 5 Dec 2014

@dgt41 I think you should change something in the "Hide Unassigned Modules" button: once you have clicked it (and unassigned modules are hidden) it continues to say "Hide Unassigned Modules", while the wording should be "Show Unassigned Modules".

Personally I don't have anything against the other solution (Yes/No radio buttons) and I'll probably prefer it...

avatar smanzi
smanzi - comment - 5 Dec 2014

... I also think this will go nicely along with your #4661 and my #5087!

avatar dgt41
dgt41 - comment - 5 Dec 2014

@smanzi @losedk @sovainfo I think I am done here, can you give it a go?

Preview:
screen shot 2014-12-05 at 6 02 07

avatar peterlose
peterlose - comment - 5 Dec 2014

@dgt41 I'm happy! Successful test :)

avatar losedk losedk - test_item - 5 Dec 2014 - Tested successfully
avatar dgt41 dgt41 - change - 5 Dec 2014
The description was changed
avatar waader
waader - comment - 5 Dec 2014

@test works!

avatar waader waader - test_item - 5 Dec 2014 - Tested successfully
avatar smanzi
smanzi - comment - 5 Dec 2014

@test success!

Now, I know I'm being a douchebag with this, but... it doesn't perfectly works with one of my favorite extensions: Peter van Westen's (NoNumber) "Advanced Module Manager". The modal opens and everything is OK (I can make any modification I want), but they are not reflected into to the "calling" page.

Beside this (that is obviously not "required") everything is OK!

Thanks!

avatar smanzi smanzi - test_item - 5 Dec 2014 - Tested successfully
avatar dgt41
dgt41 - comment - 5 Dec 2014

@smanzi Sergio I am sorry for that. The main work here is done in the modules component, maybe you can invite Peter to take a look at the code, and why not include it in the Advanced Module Manager. After all it’s GPL ????

avatar smanzi
smanzi - comment - 5 Dec 2014

Good idea! Will do!! :+1:

avatar sovainfo
sovainfo - comment - 5 Dec 2014

Consider it bad UI design compared to other filter implementations.

avatar dgt41
dgt41 - comment - 5 Dec 2014

@sovainfo I thought this was the winning one...

avatar smanzi
smanzi - comment - 5 Dec 2014

actually... doing right now:

@nonumber Peter, sorry for calling you in, but can you give a look at this and see if anything can be done for a smoother integration with "Advanced Module Manager"?

avatar sovainfo
sovainfo - comment - 5 Dec 2014

@dgt41 Not to me, but I only point out the inconsistency. When overruled, no problem. It is not going to be the first mistake, won't be the last.

avatar smanzi
smanzi - comment - 5 Dec 2014

@sovainfo
I think you can wait for this to be merged (it has a lot of hard work behind, I guess) and then propose what you think can be a better design...

avatar nonumber
nonumber - comment - 5 Dec 2014

@smanzi Not sure how this affects Advanced Module Manager. This only concerns the module item assignments, which should be same for core module manager and AMM.

avatar smanzi
smanzi - comment - 5 Dec 2014

@nonumber
with this PR when you makes modification to a module (through the modal available in menu management) this modification is immediatly reflected in what is displayed in module manager: position / assigned

This doesn't happens when the default module management is Advanced Module Manager...

avatar dgt41
dgt41 - comment - 5 Dec 2014

@nonumber Some insights: There was nothing changed in the way modules or menus store their respective data. All I did was in the menu/views/item pass the current menu id, and the list of all the view levels and in modules/views/modal add some js to compare the data and do some changes in the parent window (the menu item).
Nothing that will break B/C here

But I guess @smanzi is asking if you can do the same in AMM...

avatar peterlose
peterlose - comment - 5 Dec 2014

@sovainfo you are not being overruled. Could you come up with some sort of idea? If you aren't pleased with the outcome

avatar nonumber
nonumber - comment - 5 Dec 2014

I keep changes to core com_modules in sync with AMM. So as soon as this is released, I will add the necessary changes to AMM too.

avatar smanzi
smanzi - comment - 5 Dec 2014

@nonumber that's perfect! Thanks! :+1:

avatar smanzi
smanzi - comment - 5 Dec 2014

@dgt41 the usage of the bootstrap modal.... you want to keep that separate? I guess yes...

avatar dgt41
dgt41 - comment - 5 Dec 2014

@smanzi I guess that will be 3.5. There is a PR from @phproberto and @wilsonge bringing lot of functionality to layouts that has to be merged first. Then is your PR that brings some sanity to bootstrap modals. And then I have to update/redo my PRs to accommodate these changes. Also the point here is to bring every modal to BS and as we speak this ain’t possible (without breaking B/C: the mootools modal got a css script, BS is depending on the template, change it now and see how many sites will break on the front end). With layouts this will pass very easily...
3.4 is almost beta (i guess) so I guess couple of months won’t hurt that much

avatar smanzi
smanzi - comment - 5 Dec 2014

no, it wont hurt. And yes, it does makes sense to treat all the modals at the same time... thanks! :beer:

avatar zero-24 zero-24 - change - 5 Dec 2014
Category Administration UI/UX
avatar zero-24 zero-24 - change - 5 Dec 2014
Status Pending Ready to Commit
avatar zero-24
zero-24 - comment - 5 Dec 2014

Moving to RTC as we have successful tests by @losedk, @smanzi and @waader Thanks @dgt41

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

avatar brianteeman brianteeman - change - 5 Dec 2014
Labels Added: ?
avatar dgt41
dgt41 - comment - 5 Dec 2014

@zero-24 @brianteeman Not yet RTC, there is a dispute on the button style and there is some code logic that is still buggy (display is not gracefully follows the changes)
Sorry about that!

avatar nonumber
nonumber - comment - 5 Dec 2014

Just to interfere:
It shouldn't be:
Hide Unassigned Modules: Show / Hide
But:
Display Unassigned Modules: Show / Hide

Also check the description: "Hide all unassigned modules" => (something like) "Select whether to show or hide all unassigned modules"

Also the language string keys should reflect this. So not HIDE_UNASSIGNED but DISPLAY_UNASSIGNED_MODULES

avatar brianteeman brianteeman - change - 5 Dec 2014
Labels Removed: ?
avatar jissues-bot jissues-bot - change - 5 Dec 2014
Labels Added: ?
avatar brianteeman brianteeman - change - 5 Dec 2014
Status Ready to Commit Pending
avatar brianteeman brianteeman - change - 5 Dec 2014
Labels Removed: ?
avatar smanzi
smanzi - comment - 5 Dec 2014

... or just:

Unassigned Modules: Show/Hide

avatar sovainfo
sovainfo - comment - 6 Dec 2014

Agree with @smanzi on leaving out the show. It is very inconsistently used within Joomla configuration. Suggest to standardize to a format: <subject> Show(green) Hide(red), that is without the verb in the subject and the buttons in the order mentioned.

Maybe you can leave out the change to the filter completely and introduce a proper filter in separate PR. That filter should have the search field and ordering option and page limit.

avatar nonumber
nonumber - comment - 6 Dec 2014

Ageed.

avatar dgt41
dgt41 - comment - 6 Dec 2014

Are we OK with this?
screen shot 2014-12-06 at 3 25 21

avatar smanzi
smanzi - comment - 6 Dec 2014

:+1:

avatar nonumber
nonumber - comment - 6 Dec 2014

Also check the description: "Hide all unassigned modules" => (something like) "Select whether to show or hide all unassigned modules"

avatar dgt41
dgt41 - comment - 6 Dec 2014

So the new stings are:
COM_MENUS_HEADING_LEVELS="View level"
COM_MENUS_HEADING_POSITION="Position"
COM_MENUS_ITEM_FIELD_HIDE_UNASSIGNED_DESC="Shows or hides all unassigned modules"
COM_MENUS_ITEM_FIELD_HIDE_UNASSIGNED_LABEL="Unassigned Modules"

avatar smanzi
smanzi - comment - 6 Dec 2014

COM_MENUS_ITEM_FIELD_HIDE_UNASSIGNED_DESC="Shows or hide modules unassigned to this menu item"

avatar smanzi
smanzi - comment - 6 Dec 2014

Too late! :smile:

avatar dgt41
dgt41 - comment - 6 Dec 2014

@smanzi do a refresh on this page ????

avatar smanzi
smanzi - comment - 6 Dec 2014

Fixed last glitches?

avatar dgt41
dgt41 - comment - 6 Dec 2014

Should be ok for now. There is a todo for this: Get the actual menus in Module Assignment for the two cases
1. Only on the pages selected
2. On all pages except those selected

This has to be done with javascript in the iframe. There is a javascript file that is already loaded in the page and all we need is a call to the relative function, but didn’t had the time to test it (too many servers broken in one day)
Anyone feeling adventurous? https://github.com/joomla/joomla-cms/blob/staging/media/jui/js/treeselectmenu.jquery.js

avatar smanzi
smanzi - comment - 6 Dec 2014

don't look at me! :smile:

avatar smanzi
smanzi - comment - 6 Dec 2014

... was thinking: if you save (no need to close) the menu item, it refreshes the status even for those edge cases. Now I'm going to say a silly thing, but... can't you "simulate" a save? Just do the refresh part of it?

avatar smanzi
smanzi - comment - 6 Dec 2014

(probably you will loose edits done in other tabs...)

avatar dgt41
dgt41 - comment - 6 Dec 2014

We could do a refresh

location.reload();

BUT you are inside a form and is not a good idea, as data might exists and will be lost.
Also saving is another think to do, but then edge case: form doesn’t validate, what do you do?

avatar smanzi
smanzi - comment - 6 Dec 2014

Correct. Must be done "the hard way". No simple solution/shortcuts...

avatar dgt41
dgt41 - comment - 6 Dec 2014

The best way to go here is Ajaxify this part of the page...

avatar smanzi
smanzi - comment - 6 Dec 2014

OH YES!!

avatar dgt41
dgt41 - comment - 6 Dec 2014

When the com_menus is about for major redesign I will ask for that ????

avatar infograf768
infograf768 - comment - 6 Dec 2014

Looks like mainly working here. Glitch when changing between display or not: columns jump.

avatar smanzi
smanzi - comment - 6 Dec 2014

@infograf768 You mean when switching between show/hide unassigned modules? I don't see that... can you post two snapshots (Before/After)?

avatar smanzi
smanzi - comment - 6 Dec 2014

@dgt41 I can't help you on this (too difficult for me) but I was thinking this: would it be easier for you just to check if the module being edited is enabled for the current menu item (i.e. checking if it is enabled for: "All pages" / Related checkbox in "Only selected" / !"No pages" / !Related checkbox in "All except")? You will miss the possibility to display the "All" and "None" status and just have a boolean for this menu item, but I think this will be more than enough in this context...

avatar dgt41
dgt41 - comment - 6 Dec 2014

@smanzi Thanks I am almost there...

avatar smanzi
smanzi - comment - 6 Dec 2014

:+1:

avatar smanzi
smanzi - comment - 6 Dec 2014

Beware that Hannes is editing one of the same files you are editing in PR #5317...

avatar dgt41
dgt41 - comment - 6 Dec 2014

@smanzi Can you try to break it?
Test case:
Module Assignment for the two cases
1. Only on the pages selected (select current menu: yes/no, select all, select none)
2. On all pages except those selected (select current menu: yes/no, select all, select none)

avatar smanzi
smanzi - comment - 6 Dec 2014

I'm a specialist at breaking things... let me try! :smile:

avatar smanzi
smanzi - comment - 6 Dec 2014

... able to break it for the "All except selected pages"...
Beside that it's OK!

avatar smanzi
smanzi - comment - 6 Dec 2014

example:

  • start with a module assigned to another menu item (you have "No")
  • change it to "All except selected" and check none (a brain-dead way to say "on all pages"...): you still have "No"
avatar dgt41
dgt41 - comment - 6 Dec 2014

@smanzi wtf? I thought I tested every possible combination…
Anyways seems easy fix…

avatar smanzi
smanzi - comment - 6 Dec 2014

I told you I'm good at breaking things! :stuck_out_tongue_winking_eye:

avatar dgt41
dgt41 - comment - 6 Dec 2014

@smanzi Not anymore ???? Can you try it one more time to confirm that all cases are covered?

avatar smanzi
smanzi - comment - 6 Dec 2014

hold-on...

avatar smanzi
smanzi - comment - 6 Dec 2014

... I have the same issue as above...

avatar dgt41
dgt41 - comment - 6 Dec 2014

@smanzi Are you sure?

avatar smanzi
smanzi - comment - 6 Dec 2014

skype...

avatar smanzi
smanzi - comment - 6 Dec 2014

No, sorry, seems to be OK!!!

avatar dgt41
dgt41 - comment - 6 Dec 2014

One more test is needed here, anyone (@sovainfo @losedk @zero-24 @infograf768 @waader ) got some time?

avatar smanzi
smanzi - comment - 6 Dec 2014

@dgt41 now it is PERFECT!
@test success confirmed!

avatar Kubik-Rubik Kubik-Rubik - test_item - 7 Dec 2014 - Tested successfully
avatar Kubik-Rubik
Kubik-Rubik - comment - 7 Dec 2014

Tested successfully, thank you for the improvement!

Several good tests, I'll set it to RTC.

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

avatar Kubik-Rubik Kubik-Rubik - change - 7 Dec 2014
Status Pending Ready to Commit
avatar brianteeman brianteeman - change - 8 Dec 2014
Labels Added: ?
avatar infograf768
infograf768 - comment - 11 Dec 2014

Folks, this needs a bit more:
The module title, access and position are not translatable
No need for a JText there
screen shot 2014-12-11 at 18 46 31

avatar infograf768 infograf768 - change - 11 Dec 2014
Status Ready to Commit Pending
avatar infograf768 infograf768 - change - 11 Dec 2014
Labels Removed: ?
avatar infograf768
infograf768 - comment - 11 Dec 2014

Chnaged to pending

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

avatar dgt41
dgt41 - comment - 11 Dec 2014

@infograf768 Sorry about that…
Now should be fine:
screen shot 2014-12-11 at 8 05 50

avatar infograf768 infograf768 - close - 12 Dec 2014
avatar infograf768 infograf768 - close - 12 Dec 2014
avatar infograf768 infograf768 - change - 12 Dec 2014
Status Pending Closed
Closed_Date 0000-00-00 00:00:00 2014-12-12 10:57:34
avatar infograf768
infograf768 - comment - 12 Dec 2014

Thanks! Merged.

avatar infograf768 infograf768 - change - 12 Dec 2014
Milestone Added:
avatar dgt41 dgt41 - head_ref_deleted - 12 Dec 2014

Add a Comment

Login with GitHub to post a comment