52 lines
1.4 KiB
C#
52 lines
1.4 KiB
C#
|
|
using BLL;
|
||
|
|
using System;
|
||
|
|
using System.Web.Http;
|
||
|
|
|
||
|
|
namespace WebAPI.Controllers.HJGL.WeldingManage
|
||
|
|
{
|
||
|
|
/// <summary>
|
||
|
|
/// 管道下料检查接口。
|
||
|
|
/// </summary>
|
||
|
|
public class PreWeldCuttingCheckController : ApiController
|
||
|
|
{
|
||
|
|
/// <summary>
|
||
|
|
/// 根据焊口ID获取当前焊口的所有下料检查记录。
|
||
|
|
/// </summary>
|
||
|
|
public Model.ResponeData GetRecordsByWeldJointId(string weldJointId)
|
||
|
|
{
|
||
|
|
var responeData = new Model.ResponeData();
|
||
|
|
try
|
||
|
|
{
|
||
|
|
responeData.data = APIPreWeldInspectionService.GetCuttingChecksByWeldJointId(weldJointId);
|
||
|
|
}
|
||
|
|
catch (Exception ex)
|
||
|
|
{
|
||
|
|
responeData.code = 0;
|
||
|
|
responeData.message = ex.Message;
|
||
|
|
}
|
||
|
|
|
||
|
|
return responeData;
|
||
|
|
}
|
||
|
|
|
||
|
|
/// <summary>
|
||
|
|
/// 保存一条管道下料检查记录。
|
||
|
|
/// </summary>
|
||
|
|
[HttpPost]
|
||
|
|
public Model.ResponeData SaveRecord([FromBody] Model.PreWeldCuttingCheckInput item)
|
||
|
|
{
|
||
|
|
var responeData = new Model.ResponeData();
|
||
|
|
try
|
||
|
|
{
|
||
|
|
responeData.data = APIPreWeldInspectionService.SaveCuttingCheck(item);
|
||
|
|
}
|
||
|
|
catch (Exception ex)
|
||
|
|
{
|
||
|
|
responeData.code = 0;
|
||
|
|
responeData.message = ex.Message;
|
||
|
|
}
|
||
|
|
|
||
|
|
return responeData;
|
||
|
|
}
|
||
|
|
}
|
||
|
|
}
|