package com.ruoyi.web.work.api;

import com.ruoyi.common.core.controller.BaseController;
import com.ruoyi.common.core.domain.AjaxResult;
import com.ruoyi.web.work.service.IKnowledgeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 知识库管理
 *
 * @author lsw
 * @date 2024-07-10
 */
@RestController
@RequestMapping("/app/home")
public class Api_HomeController extends BaseController {
    @Autowired
    private IKnowledgeService knowledgeService;

    @GetMapping("/index")
    public AjaxResult index() {
        AjaxResult result = new AjaxResult();
        result.put("knowledgeList", knowledgeService.indexList());
        return AjaxResult.success(result);
    }

}
