<?php
/**
 * Created by PhpStorm.
 * User: Administrator
 * Date: 2018/11/10
 * Time: 16:01
 */
namespace Modules\Base\Http\Controllers;

class HelpController
{
    public function showEnumList()
    {
        $class = request('class', false);
        if (!$class) {
            return 'CLASS参数缺少';
        }

        if (!class_exists($class)) {
            return 'Class不存在';
        }

        if (!method_exists($class, 'toArray')) {
            return '对应方法不存在';
        }

        return $class::toArray();
    }
}
