Skip to content

Commit cf9e08a

Browse files
committed
making decimal/scale more clear
1 parent 0f2d52d commit cf9e08a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Maker/MakeEntity.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -349,10 +349,10 @@ private function askForNextField(ConsoleStyle $io, array $fields, string $entity
349349
$data['length'] = 255;
350350
} elseif ('decimal' === $type) {
351351
// 10 is the default value given in \Doctrine\DBAL\Schema\Column::$_precision
352-
$data['precision'] = $io->ask('Precision', 10, [Validator::class, 'validatePrecision']);
352+
$data['precision'] = $io->ask('Precision (total number of digits stored: 100.00 would be 5)', 10, [Validator::class, 'validatePrecision']);
353353

354354
// 0 is the default value given in \Doctrine\DBAL\Schema\Column::$_scale
355-
$data['precision'] = $io->ask('Scale', 0, [Validator::class, 'validateScale']);
355+
$data['precision'] = $io->ask('Scale (number of decimals to store: 100.00 would be 2)', 0, [Validator::class, 'validateScale']);
356356
}
357357

358358
if ($io->confirm('Can this field be null in the database (nullable)', false)) {

0 commit comments

Comments
 (0)