From 1abaf2acb024b12985825a96831b22a0fcf7045a Mon Sep 17 00:00:00 2001 From: Mathieu Jaumotte Date: Wed, 10 May 2023 10:28:36 +0200 Subject: [PATCH] DX: add help and description to use ImportSocialWorkMetadata command --- .../Command/ImportSocialWorkMetadata.php | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/Bundle/ChillPersonBundle/Command/ImportSocialWorkMetadata.php b/src/Bundle/ChillPersonBundle/Command/ImportSocialWorkMetadata.php index 91615935c..8085732ba 100644 --- a/src/Bundle/ChillPersonBundle/Command/ImportSocialWorkMetadata.php +++ b/src/Bundle/ChillPersonBundle/Command/ImportSocialWorkMetadata.php @@ -42,10 +42,18 @@ final class ImportSocialWorkMetadata extends Command protected function configure() { + $description = 'Imports a structured table containing social issues, social actions, objectives, results and evaluations.'; + $help = 'File to csv format, no headers, semi-colon as delimiter, datas sorted by alphabetical order, column after column.'. PHP_EOL + . 'Columns are: social issues parent, social issues child, social actions parent, social actions child, goals, results, evaluations.'. PHP_EOL + . PHP_EOL + . 'See social_work_metadata.csv as example.'. PHP_EOL; + $this ->setName('chill:person:import-socialwork') ->addOption('filepath', 'f', InputOption::VALUE_REQUIRED, 'The file to import.') - ->addOption('language', 'l', InputOption::VALUE_OPTIONAL, 'The default language'); + ->addOption('language', 'l', InputOption::VALUE_OPTIONAL, 'The default language') + ->setDescription($description) + ->setHelp($help); } protected function execute(InputInterface $input, OutputInterface $output)