package com.ruoyi.system.controller;
|
|
import com.ruoyi.system.api.domain.Region;
|
import com.ruoyi.system.service.RegionService;
|
import io.swagger.v3.oas.annotations.tags.Tag;
|
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;
|
import java.util.List;
|
|
@RestController
|
@RequestMapping("/region")
|
@Tag(name = "区域管理")
|
public class RegionController {
|
|
@Autowired
|
private RegionService regionService;
|
|
@GetMapping("/tree")
|
@Tag(name = "获取区域树")
|
public List<Region> getRegionTree() {
|
return regionService.getRegionTree();
|
}
|
}
|