Skip to content

Commit 037424e

Browse files
author
Shuo
committed
feat: command
1 parent c0a1152 commit 037424e

2 files changed

Lines changed: 3 additions & 1 deletion

File tree

src/Command/AdminCommand.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@
3737
/**
3838
* @Command
3939
*/
40+
#[Command]
4041
class AdminCommand extends GeneratorCommand
4142
{
4243

src/Command/ValidateCommand.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@
3939
/**
4040
* @Command
4141
*/
42+
#[Command]
4243
class ValidateCommand extends GeneratorCommand
4344
{
4445

@@ -114,7 +115,7 @@ public function execute(InputInterface $input, OutputInterface $output)
114115
$scene['update'] = $sceneTmp;
115116
$scene['delete'] = 'id';
116117
$scene['list'] = ['limit', 'page'];
117-
$class_name = convert_underline($class_name) . 'Validate';
118+
$class_name = Str::studly($class_name) . 'Validate';
118119
$namespacePath = $namespaceInput ?? $this->getValidateNamespace();
119120
$namespace = new PhpNamespace($namespacePath);
120121
$namespace->addUse('HPlus\Validate\Validate');

0 commit comments

Comments
 (0)