<?php

namespace app\api\controller;

use app\api\service\Category as CategoryService;

/**
 * @package app\api\controller
 * @class Category
 * @author xzncit 2024/3/19
 */
class Category extends \app\Controller {

    /**
     * 分类
     * @return \think\response\Json
     * @throws \think\db\exception\DataNotFoundException
     * @throws \think\db\exception\DbException
     * @throws \think\db\exception\ModelNotFoundException
     */
    public function index() {
        return returnAjax("msg:ok",1,CategoryService::getList());
    }

}