Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

[FrameworkBundle] Add completion for workflow:dump#43848

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
fabpot merged 1 commit intosymfony:5.4fromStaffNowa:feature/workflow-dump
Nov 3, 2021
Merged

[FrameworkBundle] Add completion for workflow:dump#43848

fabpot merged 1 commit intosymfony:5.4fromStaffNowa:feature/workflow-dump
Nov 3, 2021

Conversation

@StaffNowa
Copy link
Contributor

@StaffNowaStaffNowa commentedOct 30, 2021
edited
Loading

QA
Branch?5.4
Bug fix?no
New feature?yes
Deprecations?no
Tickets#43594
LicenseMIT
Doc PR-

Add completion for workflow:dump
We do not have tests here at all


privatefunctiongetAvailableNameArguments():array
{
$names = [];
Copy link
Contributor

@noniagriconomienoniagriconomieNov 2, 2021
edited
Loading

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

why not inject them from theFrameworkExtension like inside theworkflow.registry?

doing this, we can remove the$container::has() from this class inside theexecute() method
we check if the passedname is inside the array of workflows (workflow+statemachine) injected

GromNaN and lyrixx reacted with thumbs up emoji
Copy link
ContributorAuthor

@StaffNowaStaffNowaNov 2, 2021
edited
Loading

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

I see container get definition but cannot inject into command 😢 do I need get configs or whole registry class 🤔

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Why?

Copy link
ContributorAuthor

@StaffNowaStaffNowaNov 2, 2021
edited
Loading

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

I think just do not know how. If good understand I need inject configuration to load this one

$config['workflows']

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

I think just do not know how. If good understand I need inject configuration to load this one

pass this (or a new array computed from this list) inside the command construct, then in the execute and the complete methods you can get those and handle the logic

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

@StaffNowa as discussed on slack, I've sent you an example you can pick then continue working on this :)


privatefunctiongetAvailableDumpFormatOptions():array
{
return ['puml','mermaid','dot'];
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

maybe create private consts? and refactor the switch/case above

Copy link
Member

@derrabusderrabus left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Please add a test.

@carsonbotcarsonbot changed the titleAdd completion for workflow:dump[FrameworkBundle] Add completion for workflow:dumpNov 2, 2021
Copy link
Member

@fabpotfabpot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

As we are not relying on the container anymore, it means that we could move the command to the component now instead of keeping it in the framework bundle. Might be great in a follow-up PR for 5.4.

@fabpot
Copy link
Member

Thank you@StaffNowa.

@fabpotfabpot merged commit6d4e4bd intosymfony:5.4Nov 3, 2021
This was referencedNov 5, 2021
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@fabpotfabpotfabpot approved these changes

@derrabusderrabusderrabus requested changes

@lyrixxlyrixxAwaiting requested review from lyrixxlyrixx is a code owner

+1 more reviewer

@noniagriconomienoniagriconomienoniagriconomie approved these changes

Reviewers whose approvals may not affect merge requirements

Assignees

No one assigned

Projects

None yet

Milestone

5.4

Development

Successfully merging this pull request may close these issues.

6 participants

@StaffNowa@fabpot@lyrixx@derrabus@noniagriconomie@carsonbot

[8]ページ先頭

©2009-2025 Movatter.jp