dengjunjie
2024-11-14 c827fe7b0c5b3b444d76ba0d96a2649c764630dd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
using Autofac.Core;
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Mvc;
using WIDESEA_BasicService;
using WIDESEA_Core;
using WIDESEA_Core.BaseController;
using WIDESEA_IBasicService;
using WIDESEA_Model.Models;
 
namespace WIDESEA_WMSServer.Controllers.Basic
{
    [Route("api/Warehouse")]
    [ApiController]
    public class WarehouseController : ApiBaseController<IWarehouseService, Dt_Warehouse>
    {
        readonly IWarehouseService _warehouseService;
        public WarehouseController(IWarehouseService service) : base(service)
        {
            _warehouseService = service;
        }
 
        /// <summary>
        /// 启用
        /// </summary>
        /// <param name="position"></param>
        /// <returns></returns>
        [HttpPost, AllowAnonymous, Route("WarehouseEnableStatus")]
        public WebResponseContent WarehouseEnableStatus(string keys)
        {
            return _warehouseService.WarehouseEnableStatus(Array.ConvertAll(keys.Split(","), int.Parse));
        }
 
        /// <summary>
        /// 禁用
        /// </summary>
        /// <param name="position"></param>
        /// <returns></returns>
        [HttpPost, AllowAnonymous, Route("WarehouseDisableStatus")]
        public WebResponseContent WarehouseDisableStatus(string keys)
        {
            return _warehouseService.WarehouseDisableStatus(Array.ConvertAll(keys.Split(","), int.Parse));
        }
    }
}