疯狂的狮子li
2021-05-10 98624e66e583a9722205de485a41d79188b952af
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
package com.ruoyi.demo.controller;
 
import com.ruoyi.common.core.domain.AjaxResult;
import com.ruoyi.demo.feign.FeignTestService;
import lombok.RequiredArgsConstructor;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
 
/**
 * feign测试controller
 *
 * @author Lion Li
 */
@RequiredArgsConstructor(onConstructor_ = @Autowired)
@RestController
@RequestMapping("/feign/test")
public class FeignTestController {
 
    private final FeignTestService feignTestService;
 
    @GetMapping("/search/{wd}")
    public AjaxResult search(@PathVariable String wd) {
        String search = feignTestService.search(wd);
        return AjaxResult.success("操作成功",search);
    }
}