package com.nb.system.controller; import cn.dev33.satoken.annotation.SaCheckPermission; import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import com.nb.common.annotation.Log; import com.nb.common.result.R; import com.nb.system.common.dto.SysAreaQueryDTO; import com.nb.system.service.ISysAreaService; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RestController; import javax.annotation.Resource; /** *

* 行政区域 前端控制器 *

* * @author Kevin * @since 2021-08-08 */ @RestController @RequestMapping("/system/sysArea") @Api(description="区域管理") public class SysAreaController { @Resource private ISysAreaService sysAreaService; /** * 分页查询 */ @GetMapping("/page") @SaCheckPermission("system:sysArea:page") @Log(title = "行政区域分页查询") @ApiOperation(value="行政区域分页查询") public R page(Page reqPage, SysAreaQueryDTO req) { return R.success(sysAreaService.page(reqPage, req)); } /** * 查询区域树 */ @GetMapping("/listAreaTree") @ApiOperation(value="行政区域树") public R listAreaTree() { return R.success(sysAreaService.listAreaTree()); } }