<?php

namespace Application\Service\Extension\FormPreview;

/**
 * @property-read CMForm $CMForm
 */
class PreviewApp
{
    /**
     * 预览CM列表详情
     */
    const SCENARIO_CM_LIST_VIEW = 'CM_LIST_VIEW';

    public static function getConfig(int $formId, bool $debugMode = false)
    {
        return (new BaseForm())->getConfig();
    }

    public function __get($name)
    {
        $class = '\\Application\\Service\\Extension\\FormPreview\\' . $name;
        return new $class();
    }
}