package com.zcloud.controller.xgf; import java.util.HashMap; import java.util.Map; import org.springframework.beans.factory.annotation.Value; import org.springframework.stereotype.Controller; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.ResponseBody; import com.zcloud.controller.base.BaseController; import com.zcloud.entity.PageData; import com.zcloud.util.HttpClientService; /** * @作者 zyh * @日期 2023/5/12 10:36 */ @Controller @RequestMapping("/xgf/dictionaries") public class XgfDictionariesController extends BaseController { @Value("${preventionxgf.api.url}") private String url; /** * 字典 * @return * @throws Exception */ @RequestMapping(value="/getLevels") @ResponseBody public Object getLevels() throws Exception{ Map map = new HashMap(); String errInfo = "success"; PageData pd = new PageData(); pd = this.getPageData(); Map result = HttpClientService.doPost(url + "/api/dictionaries/getLevels", pd); return result; } /** * 属地字典 * @return * @throws Exception */ @RequestMapping(value="/getAreaLevels") @ResponseBody public Object getAreaLevels() throws Exception{ Map map = new HashMap(); String errInfo = "success"; PageData pd = new PageData(); pd = this.getPageData(); Map result = HttpClientService.doPost(url + "/api/dictionaries/getAreaLevels", pd); return result; } /** * 字典 * @return * @throws Exception */ @RequestMapping(value="/listSelectTree") @ResponseBody public Object listSelectTree() throws Exception{ Map map = new HashMap(); String errInfo = "success"; PageData pd = new PageData(); pd = this.getPageData(); Map result = HttpClientService.doPost(url + "/api/dictionaries/listSelectTree", pd); return result; } }