2018-06-07 00:45:47 +08:00
|
|
|
|
using Bootstrap.DataAccess;
|
|
|
|
|
using Microsoft.AspNetCore.Authorization;
|
|
|
|
|
using Microsoft.AspNetCore.Mvc;
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
|
|
|
|
|
namespace Bootstrap.Admin.Controllers.Api
|
|
|
|
|
{
|
2018-10-28 15:08:58 +08:00
|
|
|
|
/// <summary>
|
|
|
|
|
/// 数据字典分类
|
|
|
|
|
/// </summary>
|
2018-06-07 00:45:47 +08:00
|
|
|
|
[Route("api/[controller]")]
|
2018-11-24 15:12:44 +08:00
|
|
|
|
[ApiController]
|
|
|
|
|
public class CategoryController : ControllerBase
|
2018-06-07 00:45:47 +08:00
|
|
|
|
{
|
|
|
|
|
/// <summary>
|
2018-10-28 15:08:58 +08:00
|
|
|
|
/// 获取字典表中所有Category数据
|
2018-06-07 00:45:47 +08:00
|
|
|
|
/// </summary>
|
|
|
|
|
/// <returns></returns>
|
|
|
|
|
[HttpGet]
|
|
|
|
|
[AllowAnonymous]
|
2018-09-09 18:52:10 +08:00
|
|
|
|
public IEnumerable<string> Get()
|
2018-06-07 00:45:47 +08:00
|
|
|
|
{
|
|
|
|
|
return DictHelper.RetrieveCategories();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|