User tests: Successful: Unsuccessful:
Pull Request for Issue # .
Apply this PR
Go to System -> Manage -> Guided Tours
Test 1 - Checking identifier creation
Create a tour. Do not enter data in the identifier field.
Save the tour and check the identifier.
If you are on a local server, the identifier should look something like localhost-the-tour-name.
Test 2 - Checking identifier uniqueness
Try creating a tour with an identifier that exists for another tour.
The identifier should have a -X number attached to its name if it has been in use already.
Test 3 - Duplicating a tour.
In the Tours view, select a tour and select 'duplicate' from the actions.
The tour language keys and step language keys should not be translated until a proper language file matches the identifier. If the tour identifier is localhost-articles
then the language files must be guidedtours.localhost_articles.ini
and guidedtours.localhost_articles_steps.ini
(language files are located in administrator/language).
Note that in tours view, the language keys may be translated because identical to languages loaded from another tour.
Test 4 - Launching a tour from any location
Create a custom module in the cpanel dashboard and add this HTML to it
<button class="button-start-guidedtour btn btn-primary" type="button" data-gt-uid="joomla-articles"> How to create articles? </button> <button class="btn btn-secondary button-start-guidedtour" type="button" data-gt-uid="joomla-contacts">How to create contacts?</button>
Then view the tour by clicking the link in the module (which uses the identifier, not the id of the tour).
Test 5 - Making sure language files are properly used
Change the translation in the files
No tour alias, no way to run a tour other than using the tour module that lists all tours.
Language strings are loaded in the dashboard for all tours, on every page where the tour module is present.
Tours can be triggered in other places than from the tour module.
Only languages keys that are needed are loaded.
Warning:
Third-party multilingual tours will lose their translations through this PR (the language keys are moved out of extension's language files and new language files need to follow the new naming conventions). Plan is to alert third-party developers of the change once this PR is merged so they can update their tour's language files accordingly.
Please select:
Documentation link for docs.joomla.org: New or Edit a Tour - this needs updating to cover language file naming and locations
No documentation changes for docs.joomla.org needed
Pull Request link for manual.joomla.org:
No documentation changes for manual.joomla.org needed
Category | ⇒ | SQL Administration com_admin Postgresql Language & Strings Modules JavaScript Repository NPM Change Installation Front End Plugins |
Status | New | ⇒ | Pending |
Title |
|
Title |
|
Labels |
Added:
Language Change
NPM Resource Changed
PR-5.0-dev
|
Category | SQL Administration com_admin Postgresql Language & Strings Modules JavaScript Repository NPM Change Installation Front End Plugins | ⇒ | SQL Administration com_admin Postgresql Language & Strings Modules JavaScript Repository NPM Change Installation Front End Plugins Templates (site) |
Category | SQL Administration com_admin Postgresql Language & Strings Modules JavaScript Repository NPM Change Installation Front End Plugins Templates (site) | ⇒ | SQL Administration com_admin Postgresql Language & Strings Modules JavaScript Repository NPM Change Installation Front End Plugins |
@obuisard My last 2 core review suggestions should fix PHPCS in drone. Maybe you can commit them if @GeraintEdwards is not available.
I have now split the language files and load both in the tourmodel, stepmodel and stepsmodel - but ONLY the title in the getItems method of the toursmodel.
The module gets its items from the toursmodel so I have removed loading the language files there.
One last question - in the admin module we currently load the component language file. I propose we remove this or push it into the model files instead. I can see that loading the component file could eliminate some duplicate language strings but I think its cleaner NOT to rely on language strings from the component language file.
One last question - in the admin module we currently load the component language file. I propose we remove this or push it into the model files instead. I can see that loading the component file could eliminate some duplicate language strings but I think its cleaner NOT to rely on language strings from the component language file.
Yes, in this case the language file of the component is no longer necessary.
One last question - in the admin module we currently load the component language file. I propose we remove this or push it into the model files instead. I can see that loading the component file could eliminate some duplicate language strings but I think its cleaner NOT to rely on language strings from the component language file.
Yes, in this case the language file of the component is no longer necessary.
I'll remove it then
Category | SQL Administration com_admin Postgresql Language & Strings Modules JavaScript Repository NPM Change Installation Front End Plugins | ⇒ | SQL Administration com_admin Postgresql Language & Strings |
Labels |
Removed:
NPM Resource Changed
|
Creating a tour with a blank alias does not create a unique alias as intended (test #3) and is blank instead.
I just tested this a new unique alias is created
As for test #4, creating a tour with the same alias as another tour results in the alias being the same for both tours and does not create a unique alias as intended.
I just tested this using the same alias an existing tour and adds an incremental identified to the alias provided.
Can you tell me which web browser you are using?
What version of PHP?
Are you running on localhost or a named domain?
Do you have unicode aliases enabled in Joomla?
If you are able to help debug this could you add some diagnostic messages into administrator/com_guidedtours/src/Model/TourModel.php - perhaps adding
var_dump($data);exit();
just before
if (empty($data['alias'])) {
at line 84 and then saving a new tour with a blank alias. Does it show $data['alias'] as empty??
A fresh install results in one of the default tours being improperly named.
Edit: The auto-generated alias for that tour is incorrect. The alias 'joomla_guidedtourssteps' should be 'joomla_guidedtoursteps' for the correct name and description to appear.
On a side note, changing any alias in a pre-created tour causes the tour name and description (not sure if other things as well) to immediately be changed to language keys. Ignore if this is by design
Geraint @GeraintEdwards, I have noticed that step views do not load the language files, therefore the strings are not translated.
The language strings talk about a tour identifier but there is no such thing
The language strings talk about a tour identifier but there is no such thing
This has been the source of some debate. We are using a unique identifier for a tour to determine the language file name - this, strictly speaking, needs to be unique across all websites where the tour could be installed so avoid a clash of language file names. This is why we started with the name 'tour identifier'.
It shares some characteristics with the regular Joomla alias (hyphenation/appearance, position in edit page, the code that avoids duplicate when saved) hence the push to use 'alias'. But it is not used for generating URLs or routing in the way that aliases are elsewhere in Joomla.
Personally I think that 'tour identifier' is better than alias but other people think 'alias'.
What is your view?
My view is that whatever it is there should be just one name for it
After much thought, I do agree Geraint @GeraintEdwards, to keep 'Identifier'.
The tour identifier has all the characteristics of an alias but at the same time we 'highly suggest' how it should be formatted, not as free form as an alias, since it 'shapes' how the language files are named, if there are any.
When tours are duplicated in a batch, they are missing the tour identifier. Duplicated tours are orphan of an identifier, until modified. This will create issues until the tours are saved (our code moving forward assumes a tour identifier is always present).
When tours are duplicated in a batch, they are missing the tour identifier. Duplicated tours are orphan of an identifier, until modified. This will create issues until the tours are saved (our code moving forward assumes a tour identifier is always present).
Resolved
I have tested this item ✅ successfully on 0cd24e3
Category | SQL Administration com_admin Postgresql Language & Strings | ⇒ | SQL Administration com_admin Postgresql Language & Strings Modules JavaScript Repository NPM Change Installation Front End Plugins |
As we meanwhile have update SQL scripts "5.0.0-2023-08-28.sql", the update SQL scripts "5.0.0-2023-06-22.sql" of this PR here need to be renamed to something newer, otherwise they will not run when updating from a previous 5.0 alpha.
I suggest to use "5.0.0-2023-06-30.sql".
Labels |
Added:
NPM Resource Changed
|
As we meanwhile have update SQL scripts "5.0.0-2023-08-28.sql", the update SQL scripts "5.0.0-2023-06-22.sql" of this PR here need to be renamed to something newer, otherwise they will not run when updating from a previous 5.0 alpha.
I suggest to use "5.0.0-2023-06-30.sql".
I went for 5.0.0-2023-08-29.sql rather that 5.0.0-2023-08-30.sql in case someone else creates a new file today
Category | SQL Administration com_admin Postgresql Language & Strings Modules JavaScript Repository NPM Change Installation Front End Plugins | ⇒ | SQL Administration com_admin Postgresql Language & Strings |
I have tested this item ✅ successfully on 0cd24e3
Labels |
Removed:
NPM Resource Changed
|
I have tested this item ✅ successfully on 0cd24e3
Status | Pending | ⇒ | Ready to Commit |
RTC
Labels |
Added:
?
|
Language files match this alias naming convention - for example: com_guidedtours_joomla_articles.ini and the steps in com_guidedtours_joomla_articles_steps.ini
That is not what is in this PR
com_guidedtours.joomla_articles.ini
com_guidedtours.joomla_articles_steps.ini
as the alias is actually an identifier and something different to the usual usage of the word alias would it not be better to avoid confusion and rename the field in the db from alias to identifier?
@brianteeman - the column is now renamed to uid
I have tested this item ✅ successfully on 0cd24e3
I have tested this item ✅ successfully on 0cd24e3
Status | Ready to Commit | ⇒ | Fixed in Code Base |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2023-09-03 03:23:26 |
Closed_By | ⇒ | sdwjoomla |
Thanks @GeraintEdwards. Thank you @Quy , @brianteeman ., @HLeithner , @richard67 , and @obuisard for feedback, consultation and input into improving this PR. Thanks to everyone else who help to test and document.
Will remove the stray built files.
@obuisard i suggest that I spilt the tour and step language files to reduce furst pass l Ioad, what do you think?