No Code Attached Yet
avatar C-Lodder
C-Lodder
22 Jan 2019

Steps to reproduce the issue

  1. Install sample data via the backend
  2. refresh the page
  3. Attempt to install it again

Expected result

Either:

  1. Disable the "Install" button and change the text of it to "Installed"
  2. Completely hide the box
  3. Display a more appropriate message such as stating they've already installed it

Actual result

A red alert:

Step 1 Failed: Another category with the same parent category has the same alias (remember it may be a trashed item).

System information (as much as possible)

Additional comments

avatar C-Lodder C-Lodder - open - 22 Jan 2019
avatar joomla-cms-bot joomla-cms-bot - change - 22 Jan 2019
Labels Added: ?
avatar joomla-cms-bot joomla-cms-bot - labeled - 22 Jan 2019
avatar Bakual
Bakual - comment - 22 Jan 2019

Doesn't work because we have no way of tracking which sample data is installed. Even if we would track it (in a database), we wouldn't know if the installed sample data still is the original one or if it got deleted or whatever.

The only error we can get is that the category already exists, for whatever reason (sample data already installed or category manually created with same name). And that we do.

avatar C-Lodder
C-Lodder - comment - 22 Jan 2019

@Bakual The sample data derives from a plugin, so is it not possible to add custom field to each XML file, for example:

<field type="foo" name="blog_sample_data_installed" value="0">

and upon installing the sample data, that parameter value be updated to 1

avatar Bakual
Bakual - comment - 22 Jan 2019

And what happens if the user removes the sample data manually and wants to install it again?
Or wants to install it twice in different languages (which is perfectly fine and works).

avatar Bakual
Bakual - comment - 22 Jan 2019

Don't get me wrong. I don't want to shoot this down. But it was discussed already when we introduced this module and we didn't find a solution that would work.

avatar C-Lodder
C-Lodder - comment - 22 Jan 2019

@Bakual ah, I was not aware that is could be installed for different languages

avatar joomla-cms-bot joomla-cms-bot - change - 4 Mar 2019
Status New Closed
Closed_Date 0000-00-00 00:00:00 2019-03-04 08:53:11
Closed_By joomla-cms-bot
avatar franz-wohlkoenig franz-wohlkoenig - change - 4 Mar 2019
Closed_Date 2019-03-04 08:53:11 2019-03-04 08:53:12
Closed_By joomla-cms-bot franz-wohlkoenig
avatar joomla-cms-bot joomla-cms-bot - close - 4 Mar 2019
avatar joomla-cms-bot
joomla-cms-bot - comment - 4 Mar 2019
avatar franz-wohlkoenig
franz-wohlkoenig - comment - 4 Mar 2019

closed on Base of Comment above.


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

avatar wilsonge wilsonge - change - 28 Nov 2021
Status Closed New
Closed_Date 2019-03-04 08:53:12
Closed_By franz-wohlkoenig
Labels Added: No Code Attached Yet
Removed: ?
avatar wilsonge wilsonge - reopen - 28 Nov 2021
avatar chmst
chmst - comment - 15 Oct 2022

In J4 users get only blog sample data. If the user tries to install again, an appropriate message appears as requested.

Display a more appropriate message such as stating they've already installed it.

Hopefully we find a better solution for J5

avatar brianteeman
brianteeman - comment - 15 Oct 2022

Actually it is pretty easy to resolve
in the sample data add a step that unpublished the sample data plugin
or
Update the plugin code so that it can be disabled and still published then
in the sample data add a step that disables the install button of the sample data plugin

avatar Hackwar
Hackwar - comment - 14 Nov 2022

I did the modification Brian proposed in #39216. Since you can install blog and multilang sampledata multiple times, I only added this to the testing sampledata. Closing this issue since we have a PR.

avatar Hackwar Hackwar - change - 14 Nov 2022
Status New Closed
Closed_Date 0000-00-00 00:00:00 2022-11-14 20:21:14
Closed_By Hackwar
avatar Hackwar Hackwar - close - 14 Nov 2022

Add a Comment

Login with GitHub to post a comment