-
-
Notifications
You must be signed in to change notification settings - Fork 5.2k
[Workflow] Add documentation for the Workflow Component #6677
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
Comments
I can have a look at this at the beginning of August. If anyone is interested to start before that just write on this issue. I will write a comment when I actually begin. |
I've started on a PR now |
#6871 is merged now. However, there is some late feedback we may want to talk about. That's why I decided not to close here. |
Hi ! I noticed that there is no documentation about the the behavior of the workflow component when we do not set a When we take a look at @lyrixx demo (https://github.com/lyrixx/SFLive-Paris2016-Workflow), we can see that he do not set the Perhaps it will be good to add these default values in the doc ? I noticed another thing concerning the behavior of the workflow component with the If we take a look at this example: config.yml
RequestForOperation.php
The initial place seems to be On a RequestForOperation creation, is the |
If you do I.E: there is not magie in this component ;) |
Wouldn't it be silly to set the status to 'draft' in the
So the question is : how do you manage to make |
No. You really do how you want.
If there is not transition you don't need the workflow... Anyway, with Workflow::getMarking() for example. But it's not required at all. |
If you take a look at the workflow config that I provided, you will see that there are transitions, but not for initial place (i.e If I take a look at your example, the |
@rmasclef in the GitHub repository we only discuss about Symfony bugs and new features. For this kind of questions about using Symfony, please use any of the support alternatives shown in http://symfony.com/support Thanks! |
Sorry for that ... I will submit this question to the support as you suggested :) |
Hi again, I have take the time to give a closer look at the Workflow class and I noticed that there are much more events dispatched than the documentation talks about :) (By the way, I suggest you to launch a a little code-cs-fixer in order to have a much better documented code, but this is not the purpose of this discusion ...). So I suggest to complete the documentation with the different available events. At this time I have the following events:
I hope this can help you make a better documentation :D |
@lyrixx this is probably not an appropriate place for this discussion, but don't you think that event "enter" should go after setMarking? The way it is:
The way it seems to be more accurate:
|
Hello @samusenkoiv See this PR for the reason of this order. |
@lyrixx the PR is related to the announce event, which is triggered only in case there is some next transitions, but if there are not - the announce event will never be triggered. |
@samusenkoiv As what you are talking about is not related to the documentation of the Workflow component please use the main Symfony repository to discuss possible code changes. |
Closing it as fixed by #6871. |
Hi!
symfony/symfony#11882 is finally merged.
So the next step is to document this component + the integration into the FrameworkBundle.
But I'm really not good enough to achieve this task BUT I'm 100% available for helping anyone with that.
I created this little app to show how it works in action and there is also this french presentation.
The text was updated successfully, but these errors were encountered: