qianhao.xu c5c04db862 1
2024-07-23 13:09:34 +08:00

122 lines
3.3 KiB
C#
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

using Microsoft.AspNetCore.Mvc;
using DOAN.Admin.WebApi.Filters;
using DOAN.Service.JobKanban;
using DOAN.Service.JobKanban.IService;
using Aliyun.OSS;
using NPOI.SS.Formula.Functions;
//创建时间2024-07-08
namespace DOAN.Admin.WebApi.Controllers.JobKanban
{
/// <summary>
/// 客户信息
/// </summary>
[AllowAnonymous]
[Route("kanban/loginOrsetting")]
public class LoginOrSetController : BaseController
{
/// <summary>
/// 客户信息接口
/// </summary>
private readonly ILoginOrSetService _LoginOrSetService;
public LoginOrSetController(ILoginOrSetService LoginOrSetService)
{
_LoginOrSetService = LoginOrSetService;
}
/// <summary>
/// 获取组
/// </summary>
/// <returns></returns>
[HttpGet("get_group")]
public IActionResult GetGroupList()
{
var response = _LoginOrSetService.GetGroupList();
return SUCCESS(response);
}
/// <summary>
/// 获取组
/// </summary>
/// <returns></returns>
[HttpGet("get_route")]
public IActionResult GetRouteList()
{
var response = _LoginOrSetService.GetRouteList();
return SUCCESS(response);
}
/// <summary>
/// 工单
/// </summary>
/// <param name="today"></param>
/// <param name="LineCode"></param>
/// <returns></returns>
[HttpGet("get_workorder")]
public IActionResult GetWorkOrderList(DateTime today, string LineCode)
{
if (today == DateTime.MinValue || string.IsNullOrEmpty(LineCode))
{
return SUCCESS(null);
}
var response = _LoginOrSetService.GetWorkOrderList(today, LineCode);
return SUCCESS(response);
}
// 获取工单详情
[HttpGet("get_workorder_detail")]
public IActionResult GetWorkOrderDetail(string workorder)
{
if (string.IsNullOrEmpty(workorder))
{
return SUCCESS(null);
}
var response = _LoginOrSetService.GetWorkOrderDetail(workorder);
return SUCCESS(response);
}
/// <summary>
/// 开始完成 完成工单
/// </summary>
/// <param name="workorder"></param>
/// <param name="status">要改为的状态</param>
/// <returns></returns>
[HttpGet("change_workorder_status")]
public IActionResult ChangeWorkOrderStatus(string workorder, int status)
{
if (string.IsNullOrEmpty(workorder))
{
return SUCCESS(null);
}
var response = _LoginOrSetService.ChangeWorkOrderStatus(workorder, status);
return SUCCESS(response);
}
// 获取今日总任务数 ,剩余任务数
[HttpGet("get_num_list")]
public IActionResult GetKanbanNum(DateTime today, string LineCode)
{
if (today == DateTime.MinValue || string.IsNullOrEmpty(LineCode))
{
return SUCCESS(null);
}
var response = _LoginOrSetService.GetKanbanNum(today, LineCode);
return SUCCESS(response);
}
//报工
}
}