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

Commitf9bb412

Browse files
authored
minor tweaks
1 parent8c540ce commitf9bb412

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

‎workflow/usage.rst‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -171,8 +171,9 @@ you can get the workflow by injecting the Workflow registry service::
171171
// ...
172172
use Symfony\Component\Workflow\Registry;
173173
use App\Entity\BlogPost;
174+
use Symfony\Bundle\FrameworkBundle\Controller\Controller;
174175

175-
class BlogController
176+
class BlogController extends Controller
176177
{
177178
public function edit(Registry $workflows)
178179
{
@@ -190,7 +191,7 @@ you can get the workflow by injecting the Workflow registry service::
190191
try {
191192
$workflow->apply($post, 'to_review');
192193
} catch (LogicException $e) {
193-
// ...
194+
// ... if the transition is not allowed
194195
}
195196

196197
// See all the available transitions for the post in the current state

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp