1
This commit is contained in:
@ -1,31 +0,0 @@
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using WCS.BLL.Services.IService;
|
||||
using WCS.BLL.Services.Service;
|
||||
using WCS.Model;
|
||||
using WCS.Model.ApiModel;
|
||||
using WCS.Model.ApiModel.Stocktaking;
|
||||
using WCS.Model.ApiModel.User;
|
||||
using WCS.Model.WebSocketModel;
|
||||
|
||||
namespace WCS.WebApi.Controllers
|
||||
{
|
||||
/// <summary>
|
||||
/// 本地化Controller
|
||||
/// </summary>
|
||||
[ApiController]
|
||||
[Route("[controller]")]
|
||||
public class DIYController : ControllerBase
|
||||
{
|
||||
public DIYController()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
[Route("getStockTakingOrders")]
|
||||
[HttpPost(Name = "getStockTakingOrders")]
|
||||
public async Task<ResponseBase> getStockTakingOrders(GetStockTakingOrdersRequest request)
|
||||
{
|
||||
return await _stockTakingService.getStockTakingOrders(request);
|
||||
}
|
||||
}
|
||||
}
|
49
WCS.WebApi/Controllers/MXL4Controller.cs
Normal file
49
WCS.WebApi/Controllers/MXL4Controller.cs
Normal file
@ -0,0 +1,49 @@
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using WCS.BLL.Services.IService;
|
||||
using WCS.BLL.Services.Service;
|
||||
using WCS.Model;
|
||||
using WCS.Model.ApiModel;
|
||||
using WCS.Model.ApiModel.MXL4;
|
||||
using WCS.Model.ApiModel.SelfCheck;
|
||||
using WCS.Model.ApiModel.SingleLight;
|
||||
using WCS.Model.ApiModel.Stocktaking;
|
||||
using WCS.Model.ApiModel.User;
|
||||
using WCS.Model.WebSocketModel;
|
||||
|
||||
namespace WCS.WebApi.Controllers
|
||||
{
|
||||
/// <summary>
|
||||
/// 单灯单独控制亮灯接口 煤科院钻探分院项目
|
||||
/// </summary>
|
||||
[ApiController]
|
||||
[Route("[controller]")]
|
||||
public class MXL4Controller : ControllerBase
|
||||
{
|
||||
|
||||
public IMXL4Service _mxl4Service { get; set; }
|
||||
|
||||
public MXL4Controller(IMXL4Service mxl4Service)
|
||||
{
|
||||
_mxl4Service = mxl4Service;
|
||||
}
|
||||
|
||||
[Route("sysOrderMXL4")]
|
||||
[HttpPost(Name = "sysOrderMXL4")]
|
||||
public async Task<ResponseBase> sysOrderMXL4(SysOrderMXL4Request request)
|
||||
{
|
||||
try
|
||||
{
|
||||
return await _mxl4Service.sysOrderMXL4(request);
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
return new ResponseBase()
|
||||
{
|
||||
Code = 300,
|
||||
Message = "操作失败:" + ex.Message,
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
48
WCS.WebApi/Controllers/SingleLightController.cs
Normal file
48
WCS.WebApi/Controllers/SingleLightController.cs
Normal file
@ -0,0 +1,48 @@
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using WCS.BLL.Services.IService;
|
||||
using WCS.BLL.Services.Service;
|
||||
using WCS.Model;
|
||||
using WCS.Model.ApiModel;
|
||||
using WCS.Model.ApiModel.SelfCheck;
|
||||
using WCS.Model.ApiModel.SingleLight;
|
||||
using WCS.Model.ApiModel.Stocktaking;
|
||||
using WCS.Model.ApiModel.User;
|
||||
using WCS.Model.WebSocketModel;
|
||||
|
||||
namespace WCS.WebApi.Controllers
|
||||
{
|
||||
/// <summary>
|
||||
/// 单灯单独控制亮灯接口 煤科院钻探分院项目
|
||||
/// </summary>
|
||||
[ApiController]
|
||||
[Route("[controller]")]
|
||||
public class SingleLightController : ControllerBase
|
||||
{
|
||||
|
||||
public ISingleLightService _singleLightService { get; set; }
|
||||
|
||||
public SingleLightController(ISingleLightService singleLightService)
|
||||
{
|
||||
_singleLightService = singleLightService;
|
||||
}
|
||||
|
||||
[Route("singleLightControl")]
|
||||
[HttpPost(Name = "singleLightControl")]
|
||||
public async Task<ResponseBase> SingleLightControl(SingleLightControlRequest request)
|
||||
{
|
||||
try
|
||||
{
|
||||
return await _singleLightService.SingleLightControl(request);
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
return new ResponseBase()
|
||||
{
|
||||
Code = 300,
|
||||
Message = "操作失败:" + ex.Message,
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
68
WCS.WebApi/Controllers/UpLoadController.cs
Normal file
68
WCS.WebApi/Controllers/UpLoadController.cs
Normal file
@ -0,0 +1,68 @@
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using WCS.BLL.Services.IService;
|
||||
using WCS.BLL.Services.Service;
|
||||
using WCS.Model;
|
||||
using WCS.Model.ApiModel;
|
||||
using WCS.Model.ApiModel.SingleLight;
|
||||
using WCS.Model.ApiModel.Stocktaking;
|
||||
using WCS.Model.ApiModel.UpLoad;
|
||||
using WCS.Model.ApiModel.User;
|
||||
using WCS.Model.WebSocketModel;
|
||||
|
||||
namespace WCS.WebApi.Controllers
|
||||
{
|
||||
/// <summary>
|
||||
/// 本地化Controller 离线点料机上传数据
|
||||
/// </summary>
|
||||
[ApiController]
|
||||
[Route("[controller]")]
|
||||
public class UpLoadController : ControllerBase
|
||||
{
|
||||
public IUploadService _uploadService { get; set; }
|
||||
public UpLoadController(IUploadService uploadService)
|
||||
{
|
||||
_uploadService = uploadService;
|
||||
}
|
||||
|
||||
|
||||
[Route("uploadReelInfo")]
|
||||
[HttpPost(Name = "uploadReelInfo")]
|
||||
public async Task<ResponseBase> uploadReelInfo(UploadReelInfoRequest request)
|
||||
{
|
||||
try
|
||||
{
|
||||
var IPAdress = HttpContext?.Connection?.RemoteIpAddress?.ToString();
|
||||
request.IPAddress = IPAdress;
|
||||
|
||||
return await _uploadService.UploadReelInfo(request);
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
return new ResponseBase()
|
||||
{
|
||||
Code = 300,
|
||||
Message = "操作失败:" + ex.Message,
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
[Route("getReelInfo")]
|
||||
[HttpGet(Name = "getReelInfo")]
|
||||
public async Task<ResponseBase> getReelInfo(string MatSN)
|
||||
{
|
||||
try
|
||||
{
|
||||
return await _uploadService.GetReelInfo(MatSN);
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
return new ResponseBase()
|
||||
{
|
||||
Code = 300,
|
||||
Message = "操作失败:" + ex.Message,
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
@ -70,6 +70,11 @@ namespace WebApi
|
||||
builder.Services.AddScoped<ISelfCheckService, SelfCheckService>();
|
||||
builder.Services.AddScoped<IWarningService, WarningService>();
|
||||
builder.Services.AddScoped<IInOutRecordService, InOutRecordService>();
|
||||
builder.Services.AddScoped<IUploadService, UploadService>();
|
||||
|
||||
builder.Services.AddScoped<ISingleLightService, SingleLightService>();
|
||||
builder.Services.AddScoped<IMXL4Service, MXL4Service>();
|
||||
|
||||
//<2F><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>롢<EFBFBD><EBA1A2><EFBFBD>ɵ<EFBFBD><C9B5><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>õ<EFBFBD><C3B5><EFBFBD>ģʽ
|
||||
builder.Services.AddSingleton<IGenerateService, GenerateService>();
|
||||
|
||||
|
Reference in New Issue
Block a user