-
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
[4.0][workflow] - installation with sample_testing data #21681
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
This will not solve the issue for installing sample data via the sample data module. |
|
yes correct this is only about the install with sample data |
|
My POC forces the use of a hardcoded value in __workflows_associations because I want these articles Published. It came from the default stage id 2 for the workflow_id 1 (Joomla! Default). This PR here is also using a hardcoded value but it may work because we have only ONE default workflow at install time. (Not sure btw what has been decided with installing sample data at Joomla install time). |
|
Except that currently you can install sample data at anytime |
|
At install time there is and must be only 1 workflow the Joomla! Default one, one problem at the time please |
|
The sampledata and its SQL files are supposed to be removed from the installation. There should only be the module for installing sampledata and that is done after the installation from the control panel. So not sure if this PR is really needed. |
good to know just want to know where me/we (mere mortals) can read about this Breaking News |
|
In dont think that removing the ability to install sql files from th installer is likely to happen as they are used heavily made template developers in their quick start builds |
The one and single goal of the "Sample Data Module" was to be able to drop the sample data SQL files and the sample data step in the installation. Maintaining both the sample data plugin(s) and the SQL files would be quite stupid.
I'm not familiar with how exactly templates add SQLs to their builds. Was that done in the same sample data step? Can't they use a sample data plugin to set up their example settings? |
Adding the plugin enabled users who installed joomla through a script provided by their hosts the opportunity to get the sample data
Quite often yes - I know yootheme does. Basically in J3 if you drop an sql file into the installation/sql folder then the installer would pick it up
I guess so - but its quite hard to write isnt it (especially if you have a lot of data)? |
|
@Bakual Additionally the sample data plugin for testing sample data is now incompatible with Joomla! 4, see joomla-extensions/testing-sample-data#2. |
Ah, didn't know that was dynamically generated. If we need to still support that, it could be done so it only shows that step if there actually are any files and we remove the sample data ones? Never tried what happens if there are no files at all.
Depends what you want to achieve, It can be done very simple: You could make it applying still an SQL file. It gets complex once you want to support different languages and use entered data in a successive step like in the testing sampledata where an article refers to another article. |
Just needs someone who creates a PR and someone else who tests it and then someone else who merges it 😄 |
|
@Bakual I can test but needed changes in code are to hard for me to make 😄 |
|
It's hard to fix anyway as J4 is still a moving target. |
|
I know that but for me the namespacing part is hard. |
|
|
||
| try | ||
| { | ||
| $contents = $db->loadObjectList(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perhaps ->loadColumn() and act with the array alone?
|
I have tested this item ✅ successfully on 95c4c9e This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/21681. |
|
too much mess |
Pull Request for Issue #21564 .
Summary of Changes
populate the
#__workflow_associationstable with items from#__contenttableTesting Instructions
fresh install staging
Customize installation
skip languages &Install sample data
Expected result
all contents are visible on Articles Manager
Actual result
no content