Commit d8f08b01 authored by Stephane Bouvry's avatar Stephane Bouvry
Browse files

- Up : La commande de recalcule des processus n'affiche une sortie que si elle fait des choses

parent 2ceb4135
Loading
Loading
Loading
Loading
+7 −10
Original line number Diff line number Diff line
@@ -26,12 +26,6 @@ class SignatureUpdateAllProcessesCommand extends SignatureCommandAbstract
        $headers = ['id', 'label', 'status', 'msg'];
        $rows = [];
        foreach ($this->getProcessService()->getProcesses() as $process)  {
            $msg = "Rien à faire";
            $row = [
                $process->getId(),
                $process->getLabel(),
                $process->getStatusText(),
            ];
            if( $process->isTriggerable() ){
                try {
                    $this->getProcessService()->trigger($process);
@@ -39,13 +33,16 @@ class SignatureUpdateAllProcessesCommand extends SignatureCommandAbstract
                } catch (\Exception $e) {
                    $msg = 'Error : ' . $e->getMessage();
                }
                $rows[] = [
                    $process->getId(),
                    $process->getLabel(),
                    $process->getStatusText(),
                ];
            }
            $row[] = $msg;
            $rows[] = $row;
        }
        if( count($rows) > 0 ){
            $io->table($headers, $rows);


        }
        return self::SUCCESS;
    }
}
 No newline at end of file