|
|
@ -1,7 +1,9 @@ |
|
|
|
using BBWY.Server.Business; |
|
|
|
using BBWY.Common.Models; |
|
|
|
using BBWY.Server.Business; |
|
|
|
using BBWY.Server.Model.Dto; |
|
|
|
using Microsoft.AspNetCore.Http; |
|
|
|
using Microsoft.AspNetCore.Mvc; |
|
|
|
using Microsoft.Extensions.Primitives; |
|
|
|
using Newtonsoft.Json; |
|
|
|
using NLog; |
|
|
|
using System.Collections.Generic; |
|
|
@ -80,6 +82,10 @@ namespace BBWY.Server.API.Controllers |
|
|
|
[HttpGet] |
|
|
|
public IList<DepartmentResponse> GetDeparmentList() |
|
|
|
{ |
|
|
|
if (!Request.Headers.TryGetValue("bbwyTempKey", out StringValues sv)) |
|
|
|
throw new BusinessException("非法请求"); |
|
|
|
if (sv.ToString() != "21jfhayu27q") |
|
|
|
throw new BusinessException("非法请求"); |
|
|
|
return venderBusiness.GetDeparmentList(); |
|
|
|
} |
|
|
|
} |
|
|
|