<?php

namespace app\workerapi\controller;


use app\adminapi\logic\fault_code\FaultCodeLogic;
use app\adminapi\logic\fault_type\FaultTypeLogic;
use app\adminapi\validate\fault_code\FaultCodeValidate;
use app\workerapi\lists\FaultCodeLists;

class FaultCodeController extends BaseApiController
{
    public array $notNeedLogin = ['getTreeLists','detail'];
    public function getTreeLists()
    {
        $result = FaultTypeLogic::getAllData('api');
        return $this->data($result);
        //return $this->dataLists(new FaultCodeLists());
    }
    /**
     * @notes 获取详情
     * @return \think\response\Json
     * @author likeadmin
     * @date 2024/10/18 09:58
     */
    public function detail()
    {
        /*$params = (new FaultCodeValidate())->goCheck('detail');
        $result = FaultCodeLogic::detail($params);
        return $this->data($result);*/
        return $this->dataLists(new FaultCodeLists());
    }
}