public function actionReport()
    {
        $hasErrors = false;
        foreach ($this->getAuditManager()->getReport() as $modelName => $result) {
            if (is_string($result) || !$result['enabled']) {
                $color = Console::FG_GREY;
            } elseif ($result['valid'] === false) {
                $hasErrors = false;
                $color = Console::FG_RED;
            } else {
                $color = Console::FG_GREEN;
            }
            $this->stdout('    '.str_pad(is_string($result) ? $result : $modelName.' ', 40, '.').' ', $color);
            if (is_array($result)) {
                $this->stdout($result['enabled'] ? '+' : '-', $color);
                $this->stdout($result['valid'] === false ? '!' : '', $color);
            }
            $this->stdout("\n");
        }
        return $hasErrors ? self::EXIT_CODE_ERROR : self::EXIT_CODE_NORMAL;
    }
public function actionReport()
    {
        $hasErrors = false;
        foreach ($this->getAuditManager()->getReport() as $modelName => $result) {
            if (is_string($result) || !$result['enabled']) {
                $color = Console::FG_GREY;
            } elseif ($result['valid'] === false) {
                $hasErrors = false;
                $color = Console::FG_RED;
            } else {
                $color = Console::FG_GREEN;
            }
            $this->stdout('    '.str_pad(is_string($result) ? $result : $modelName.' ', 40, '.').' ', $color);
            if (is_array($result)) {
                $this->stdout($result['enabled'] ? '+' : '-', $color);
                $this->stdout($result['valid'] === false ? '!' : '', $color);
            }
            $this->stdout("\n");
        }
        return $hasErrors ? self::EXIT_CODE_ERROR : self::EXIT_CODE_NORMAL;
    }
public function actionReport ( ) { $ hasErrors = false ; foreach ( $ this -> getAuditManager ( ) -> getReport ( ) as $ modelName => $ result ) { if ( is_string ( $ result ) || ! $ result [ 'enabled' ] ) { $ color = Console :: FG_GREY ; } elseif ( $ result [ 'valid' ] === false ) { $ hasErrors = false ; $ color = Console :: FG_RED ; } else { $ color = Console :: FG_GREEN ; } $ this -> stdout ( '    ' . str_pad ( is_string ( $ result ) ? $ result : $ modelName . ' ' , 40 , '.' ) . ' ' , $ color ) ; if ( is_array ( $ result ) ) { $ this -> stdout ( $ result [ 'enabled' ] ? '+' : '-' , $ color ) ; $ this -> stdout ( $ result [ 'valid' ] === false ? '!' : '' , $ color ) ; } $ this -> stdout ( "\n" ) ; } return $ hasErrors ? self :: EXIT_CODE_ERROR : self :: EXIT_CODE_NORMAL ; }
Displays a list of all models from every module and its audits status.
@return int
Displays a list of all models from every module and its audits status .