package com.govmade.modules.system.controller;

import java.util.List;
import java.util.Map;

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 com.govmade.common.utils.R;
import com.govmade.modules.basic.controller.AbstractController;
import com.govmade.modules.system.entity.DictEntity;
import com.govmade.modules.system.service.DictService;

/**
 * 系统管理 - 字典设置
 * 
 * @author Fred
 * @email fangtaosh@qq.com
 * @date 2018年8月7日
 */
@RestController
@RequestMapping("/system/dict")
public class DictController extends AbstractController {

	@Autowired
	private DictService dictService;


	/**
	 * 用户列表
	 */
	@GetMapping("/list")
	public R list(Map<String, Object> params) {
		
		List<DictEntity> dictList = dictService.queryChilds("city_level");
		
		return R.ok().put("childs", dictList);
	}

}