? ? Pending

User tests: Successful: Unsuccessful:

avatar infograf768
infograf768
31 Jul 2018

Pull Request for Issue #21250

Summary of Changes

This adds a "Propagate" button in the Associations tab when editing a contact, category, article, menu item, newsfeed.
This button will display when an association is selected in a Content Language field, offering the option to Propagate the associations defined for that item to the other Content Languages.

The button will display ONLY when there are more than 2 Content Languages defined for the site.
A message will display with the results obtained.

It is B/C as it will not break anything and one is totally free to choose or not to use the button, thus keeping the possibility to Clear/Select/Create any associations as before.

Using it prevents breaking existing associations when the wrong items are chosen for some fields.

A big thank you to Robbie Jackson for the long work to get this new functionality.
Target Milestone: 3.9.0

Testing Instructions

Create a Multilingual site with 3 or more languages.
Create items in each type: (contact, category, article, menu item, newsfeed) for 2 of these languages and associate them in each case.

Create a new item for each type, select another language than the ones which are already associated.
Save (NOT save and close) this item.
Display the Association tab.

You will see, as usual (here for 4 Content Languages)

screen shot 2018-07-31 at 11 13 04

I do have already associations set for English and French.

I select for English the item which I know is associated.

The button displays (Better tip welcome)

screen shot 2018-07-31 at 11 17 17

Clicking on the button will give

screen shot 2018-07-31 at 11 18 22

Result: the already associated category in French is added in the French field.
As we have no association set for Spanish, the field remains empty.
The message displays (it is the same in all cases except if there is an Ajax error)
All existing associations have been set. If some are missing you may have to select or create them manually.

If we have already associated all fields, clicking on Propagate will just display the message.

If we change an association in one of the fields and click Propagate, it is the associations from that language item that will be propagated and therefore replace the ones existing.

Documentation Changes Required

Yes

avatar infograf768 infograf768 - open - 31 Jul 2018
avatar infograf768 infograf768 - change - 31 Jul 2018
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 31 Jul 2018
Category Administration com_categories com_contact com_content com_menus com_newsfeeds Language & Strings JavaScript
avatar infograf768
infograf768 - comment - 31 Jul 2018

the json files need corrections for cs. Can be tested and commented nevertheless. ;)

df482b4 31 Jul 2018 avatar infograf768 cs
avatar infograf768 infograf768 - change - 31 Jul 2018
Labels Added: ? ?
avatar brianteeman
brianteeman - comment - 31 Jul 2018

Testing this and my only issue is with the messages

The propagate button says

Propagate this items existing associations

But you always get this message

All existing associations have been set. If some are missing you may have to select or create them manually.

The code should check to see if there any associations to propagate and if not then the message should be

No associations exist to propagate

And if there are associations to propagate then the message should be

All existing associations have been set.

avatar infograf768
infograf768 - comment - 31 Jul 2018

We will now get 3 types of messages:
JGLOBAL_ASSOCIATIONS_PROPAGATE_MESSAGE_ALL="All existing associations have been set."
JGLOBAL_ASSOCIATIONS_PROPAGATE_MESSAGE_NONE="No associations exist to propagate."
JGLOBAL_ASSOCIATIONS_PROPAGATE_MESSAGE_SOME="Some associations have been set: %s"

JGLOBAL_ASSOCIATIONS_PROPAGATE_MESSAGE_SOME will also display the language(s) where associations have been added.

Example. Here I selected an article for English. It added the French existing association, but as the Spanish one did not exist, it is that message which is used displaying which association was set.
screen shot 2018-07-31 at 16 34 41

avatar infograf768
infograf768 - comment - 31 Jul 2018

Restarted drone who failed on js.

avatar brianteeman
brianteeman - comment - 31 Jul 2018

Much better now.

I am also getting a missing string JGLOBAL_ASSOCIATIONS_PROPAGATE_TIP

avatar infograf768
infograf768 - comment - 31 Jul 2018

done

avatar jreys jreys - test_item - 1 Aug 2018 - Tested successfully
avatar jreys
jreys - comment - 1 Aug 2018

I have tested this item successfully on eabc256


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

avatar infograf768
infograf768 - comment - 1 Aug 2018

One more tester.

avatar infograf768
infograf768 - comment - 1 Aug 2018

@Quy
All done. Thanks.

avatar infograf768 infograf768 - alter_testresult - 1 Aug 2018 - jreys: Tested successfully
avatar infograf768
infograf768 - comment - 1 Aug 2018

@Quy @franz-wohlkoenig @brianteeman
Please add your tests.

avatar franz-wohlkoenig
franz-wohlkoenig - comment - 1 Aug 2018

@infograf768 have read Instructions a few Times but didn't understand really what is to test. So i need Time.

avatar franz-wohlkoenig franz-wohlkoenig - test_item - 2 Aug 2018 - Tested successfully
avatar franz-wohlkoenig
franz-wohlkoenig - comment - 2 Aug 2018

I have tested this item successfully on b902d37


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

avatar franz-wohlkoenig franz-wohlkoenig - change - 2 Aug 2018
Status Pending Ready to Commit
avatar franz-wohlkoenig
franz-wohlkoenig - comment - 2 Aug 2018

Ready to Commit after two successful tests.

avatar infograf768
infograf768 - comment - 2 Aug 2018

@mbabker
I have tagged this to 3.9. Can you merge?

avatar infograf768 infograf768 - change - 2 Aug 2018
Labels Added: ?
avatar infograf768
infograf768 - comment - 2 Aug 2018

@mbabker
Do we need new tests?

avatar infograf768
infograf768 - comment - 3 Aug 2018

@dgrammatiko
Modified the new js functions name as required.
We can't obviously normalize the others as it would not be B/C.

@franz-wohlkoenig @jreys
Please test again. :)

avatar franz-wohlkoenig franz-wohlkoenig - change - 4 Aug 2018
Status Ready to Commit Pending
avatar franz-wohlkoenig franz-wohlkoenig - test_item - 4 Aug 2018 - Tested successfully
avatar franz-wohlkoenig
franz-wohlkoenig - comment - 4 Aug 2018

I have tested this item successfully on 888a280


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

avatar infograf768
infograf768 - comment - 4 Aug 2018

@mbabker Can you now merge?

avatar mbabker mbabker - change - 4 Aug 2018
Status Pending Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 2018-08-04 15:29:51
Closed_By mbabker
Labels Removed: ?
avatar mbabker mbabker - close - 4 Aug 2018
avatar mbabker mbabker - merge - 4 Aug 2018
avatar infograf768
infograf768 - comment - 4 Aug 2018

@mbabker
As it is a new feature, shall not it be merged in 3.9.0 ?

avatar mbabker
mbabker - comment - 4 Aug 2018

💩

avatar mbabker
mbabker - comment - 4 Aug 2018

Branch merged to 3.9-dev via 11153f7

avatar infograf768
infograf768 - comment - 4 Aug 2018

Thanks.

Add a Comment

Login with GitHub to post a comment