package com.lyms.cm.controller.sys;
import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;
import com.baomidou.mybatisplus.plugins.Page;
import com.lyms.cm.entity.sys.SysRegions;
import com.lyms.cm.service.sys.SysRegionsService;
import com.lyms.web.controller.BaseController;
/**
* <p>
* 省市区地址表 前端控制器
* </p>
*
* @author maliang
* @since 2017-03-08
*/
@RestController
@RequestMapping("/sysRegions")
public class SysRegionsController extends BaseController {
@Autowired
private SysRegionsService regionService;
/**
* <li>@Description:获取区域信息
* <li>@return
* <li>创建人:maliang
* <li>创建时间:2017年3月8日
* <li>修改人:
* <li>修改时间:
*
* @return
*/
@RequestMapping(value = "/find", method = RequestMethod.GET)
public Page<SysRegions> findRegions(String id) {
Page<SysRegions> page = getPage();
page.setSize(Integer.MAX_VALUE);
List<SysRegions> regions = regionService.selectRegions(id);
page.setRecords(regions);
return page;
}
}