产线管理
This commit is contained in:
parent
515992a2ba
commit
9a9d443302
@ -112,5 +112,19 @@ namespace RIZO.Admin.WebApi.Controllers.Mes
|
||||
var response = _ProductionLineService.GetAllLine();
|
||||
return SUCCESS(response);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 停用产线管理基础信息表
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
[HttpPost("stop/{ids}")]
|
||||
[ActionPermissionFilter(Permission = "productionline:delete")]
|
||||
[Log(Title = "产线管理基础信息表", BusinessType = BusinessType.DELETE)]
|
||||
public IActionResult StopProductionLine([FromRoute] string ids)
|
||||
{
|
||||
var idArr = Tools.SplitAndConvert<long>(ids);
|
||||
return ToResponse(_ProductionLineService.Stop(idArr));
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
@ -26,7 +26,7 @@ namespace RIZO.Model.Mes.Dto.MasterData
|
||||
[Required(ErrorMessage = "产线名称不能为空")]
|
||||
public string LineName { get; set; }
|
||||
|
||||
[Required(ErrorMessage = "产线状态(0-在用,1-停用)不能为空")]
|
||||
//"产线状态(0-在用,1-停用)
|
||||
public int LineStatus { get; set; }
|
||||
|
||||
public string CreateBy { get; set; }
|
||||
|
||||
@ -17,5 +17,7 @@ namespace RIZO.Service.Mes.IMesService.MasterData
|
||||
int UpdateProductionLine(ProductionLine parm);
|
||||
|
||||
List<ProductionLinePullDownDto> GetAllLine();
|
||||
|
||||
int Stop(object id);
|
||||
}
|
||||
}
|
||||
|
||||
@ -91,7 +91,7 @@ namespace RIZO.Service.Mes.MasterData
|
||||
public List<ProductionLinePullDownDto> GetAllLine()
|
||||
{
|
||||
var lineOptions = Queryable()
|
||||
.Where(it => it.LineStatus == 0)
|
||||
.Where(it => it.LineStatus == 0)
|
||||
.Select(it => new ProductionLinePullDownDto
|
||||
{
|
||||
value = it.LineCode, // value绑定产线编码(唯一标识)
|
||||
@ -100,5 +100,16 @@ namespace RIZO.Service.Mes.MasterData
|
||||
.ToList(); // 执行查询并转换为列表
|
||||
return lineOptions;
|
||||
}
|
||||
|
||||
//停用产线
|
||||
public int Stop(object id)
|
||||
{
|
||||
int iResult = 0;
|
||||
if (id != null)
|
||||
{
|
||||
|
||||
}
|
||||
return iResult;
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -127,10 +127,15 @@ namespace RIZO.Service.Mes.Process
|
||||
List<ProcessInfoImport> processInfoImports = new List<ProcessInfoImport>();
|
||||
List<ProcessInfoImport> resultList = stream.Query<ProcessInfoImport>().ToList();
|
||||
List<string> porocessCodeList = new List<string>();
|
||||
List<string> lineCodeList = new List<string>();
|
||||
//从1开始循环,排除掉0行的标题行
|
||||
for(int i = 1;i<resultList.Count; i++)
|
||||
for (int i = 1;i<resultList.Count; i++)
|
||||
{
|
||||
ProcessInfoImport processInfoImport = resultList[i];
|
||||
if (lineCodeList.Any())
|
||||
{
|
||||
|
||||
}
|
||||
if (!processInfos.Any(p => p.ProcessCode == processInfoImport.ProcessCode))
|
||||
{
|
||||
ProcessInfo processInfo = new ProcessInfo();
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user