zjh
2023-10-18 f66407b1a6383aa75060e3b9ecab6195bfbd271a
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
package com.ltkj.web.controller.api;
 
import com.ltkj.common.core.domain.AjaxResult;
import com.ltkj.web.config.wordUtil.ITableService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
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;
 
@Slf4j
@RestController
@RequestMapping("/api")
//@Api(tags = "AAAAAAAAAAAAAAA导出数据库")
public class TableController {
 
    @Autowired
    ITableService tableService;
 
    @GetMapping(value = "/tableToWord", produces = "application/json;charset=utf-8", name = "导出数据库表信息生成Word")
    //@ApiOperation(value = "导出数据库表信息生成Word", httpMethod = "GET", response = AjaxResult.class, notes = "导出数据库表信息生成Word")
    public AjaxResult tableToWord() {
        try {
            return AjaxResult.success("导出数据库表信息生成Word成功", tableService.getTableInfo());
        } catch (Exception e) {
            return AjaxResult.error(e.getMessage());
        }
    }
}