using Microsoft.AspNetCore.Authorization;
|
using Microsoft.AspNetCore.Http;
|
using Microsoft.AspNetCore.Mvc;
|
using WIDESEAWCS_Core;
|
using WIDESEAWCS_Core.BaseController;
|
using WIDESEAWCS_ITelescopicService;
|
using WIDESEAWCS_IWMSPart;
|
using WIDESEAWCS_Model.Models;
|
|
namespace WIDESEAWCS_Server.Controllers.Telescopic
|
{
|
[Route("api/[controller]")]
|
[ApiController]
|
public class ParametersController : ApiBaseController<IParametersService, Dt_Parameters>
|
{
|
public ParametersController(IParametersService service) : base(service)
|
{
|
|
}
|
/// <summary>
|
/// 手动控制,伸缩杆的缩回和伸出速度
|
/// </summary>
|
/// <param name="position">伸缩杆的位置(左右)</param>
|
/// <param name="ExtendedState">伸/缩状态</param>
|
/// <returns></returns>
|
///
|
[HttpPost,Route("ManualOperation")]
|
public WebResponseContent ManualOperation(string position, string ExtendedState, int DeptId)
|
{
|
return Service.ManualOperation(position, ExtendedState, DeptId);
|
}
|
|
/// <summary>
|
/// 自动控制伸缩杆的伸出和缩回速度
|
/// </summary>
|
/// <param name="ExtendedState">伸/出状态</param>
|
/// <returns></returns>
|
|
[HttpPost,Route("automation")]
|
public WebResponseContent automation(string ExtendedState)
|
{
|
return Service.automation(ExtendedState);
|
}
|
|
|
|
/// <summary>
|
///当自动伸出需要暂停时,暂停按钮
|
/// </summary>
|
/// <returns></returns>
|
[HttpPost, Route("PauseButton")]
|
public WebResponseContent PauseButton(int deptid)
|
{
|
|
return Service.PauseButton(deptid);
|
}
|
|
|
/// <summary>
|
/// 伸缩杆当前位置
|
/// <param name="deptid">轨道站号</param>
|
/// <returns></returns>
|
[HttpPost, Route("CurrentLocation")]
|
public WebResponseContent CurrentLocation(int deptid)
|
{
|
return Service.CurrentLocation(deptid);
|
}
|
}
|
}
|