| | |
| | | [ApiExplorerSettings(GroupName = "工单管理")] |
| | | [ApiController] |
| | | [Route("api/[controller]")] |
| | | //[ChannelActionFilter] |
| | | [ChannelActionFilter] |
| | | public class WorkOrderController : Controller |
| | | { |
| | | //定义全局信息返回变量 |
| | |
| | | /// </summary> |
| | | /// <param name="wkshopcode">车间编码</param> |
| | | /// <param name="wocode">工单号</param> |
| | | /// <param name="orderno">订单号</param> |
| | | /// <param name="partcode">产品编码</param> |
| | | /// <param name="partname">产品名称</param> |
| | | /// <param name="partspec">规格型号</param> |
| | |
| | | /// <returns></returns> |
| | | [Route(template: "MesOrderStepSearch")] |
| | | [HttpGet] |
| | | public JsonResult MesOrderStepSearch(string wkshopcode=null, string wocode = null, string partcode = null, string partname = null, string partspec = null, int page = 0, int rows = 0, string prop = null, string order = null) |
| | | public JsonResult MesOrderStepSearch(string wkshopcode=null, string wocode = null,string orderno = null, string partcode = null, string partname = null, string partspec = null, int page = 0, int rows = 0, string prop = null, string order = null) |
| | | { |
| | | var token = HttpContext.Request.Headers["Token"].ToString(); |
| | | User us = JwtTools.Denocode(token.ToString()); |
| | | int startNum = rows * (page - 1) + 1; //起始记录rowNum |
| | | int endNum = rows * page; //结束记录 rowNum |
| | | mes = WorkOrderBLL.MesOrderStepSearch(wkshopcode,wocode, partcode, partname, partspec, startNum, endNum, prop, order); |
| | | mes = WorkOrderBLL.MesOrderStepSearch(wkshopcode,wocode, orderno, partcode, partname, partspec, startNum, endNum, prop, order); |
| | | return Json(mes); |
| | | } |
| | | #endregion |
| | |
| | | /// </summary> |
| | | /// <param name="wkshopcode">车间编码</param> |
| | | /// <param name="wocode">工单号</param> |
| | | /// <param name="orderno">订单号</param> |
| | | /// <param name="partcode">产品编码</param> |
| | | /// <param name="partname">产品名称</param> |
| | | /// <param name="partspec">规格型号</param> |
| | |
| | | /// <returns></returns> |
| | | [Route(template: "MesOrderWxStepSearch")] |
| | | [HttpGet] |
| | | public JsonResult MesOrderWxStepSearch(string wkshopcode, string wocode = null, string partcode = null, string partname = null, string partspec = null, int page = 0, int rows = 0, string prop = null, string order = null) |
| | | public JsonResult MesOrderWxStepSearch(string wkshopcode, string wocode = null, string orderno = null, string partcode = null, string partname = null, string partspec = null, int page = 0, int rows = 0, string prop = null, string order = null) |
| | | { |
| | | var token = HttpContext.Request.Headers["Token"].ToString(); |
| | | User us = JwtTools.Denocode(token.ToString()); |
| | | int startNum = rows * (page - 1) + 1; //起始记录rowNum |
| | | int endNum = rows * page; //结束记录 rowNum |
| | | mes = WorkOrderBLL.MesOrderWxStepSearch(wkshopcode,wocode, partcode, partname, partspec, startNum, endNum, prop, order); |
| | | mes = WorkOrderBLL.MesOrderWxStepSearch(wkshopcode,wocode, orderno, partcode, partname, partspec, startNum, endNum, prop, order); |
| | | return Json(mes); |
| | | } |
| | | #endregion |
| | |
| | | /// </summary> |
| | | /// <param name="wkshopcode">车间编码</param> |
| | | /// <param name="wocode">工单号</param> |
| | | /// <param name="orderno">订单号</param> |
| | | /// <param name="partcode">产品编码</param> |
| | | /// <param name="partname">产品名称</param> |
| | | /// <param name="partspec">规格型号</param> |
| | |
| | | /// <returns></returns> |
| | | [Route(template: "MesOrderNgStepSearch")] |
| | | [HttpGet] |
| | | public JsonResult MesOrderNgStepSearch(string wkshopcode=null, string wocode = null, string partcode = null, string partname = null, string partspec = null, int page = 0, int rows = 0, string prop = null, string order = null) |
| | | public JsonResult MesOrderNgStepSearch(string wkshopcode=null, string wocode = null, string orderno = null, string partcode = null, string partname = null, string partspec = null, int page = 0, int rows = 0, string prop = null, string order = null) |
| | | { |
| | | var token = HttpContext.Request.Headers["Token"].ToString(); |
| | | User us = JwtTools.Denocode(token.ToString()); |
| | | int startNum = rows * (page - 1) + 1; //起始记录rowNum |
| | | int endNum = rows * page; //结束记录 rowNum |
| | | mes = WorkOrderBLL.MesOrderNgStepSearch(wkshopcode,wocode, partcode, partname, partspec, startNum, endNum, prop, order); |
| | | mes = WorkOrderBLL.MesOrderNgStepSearch(wkshopcode,wocode, orderno, partcode, partname, partspec, startNum, endNum, prop, order); |
| | | return Json(mes); |
| | | } |
| | | #endregion |
| | |
| | | /// </summary> |
| | | /// <param name="wkshopcode">车间编码</param> |
| | | /// <param name="wo_code">工单编号</param> |
| | | /// <param name="orderno">订单号</param> |
| | | /// <param name="partnumber">产品编码</param> |
| | | /// <param name="partname">产品名称</param> |
| | | /// <param name="partspec">产品规格</param> |
| | | /// <param name="stepcode">工序编码</param> |
| | | /// <param name="reportuser">报工人员</param> |
| | | /// <param name="reportdate">报工时间</param> |
| | | /// <param name="page">页码</param> |
| | |
| | | /// <returns></returns> |
| | | [Route(template: "MesOrderStepVerifySearch")] |
| | | [HttpGet] |
| | | public JsonResult MesOrderStepVerifySearch(string wkshopcode=null, string wo_code = null, string partnumber = null, string partname = null, string partspec = null, string reportuser = null, string reportdate = null, int page = 0, int rows = 0, string prop = null, string order = null) |
| | | public JsonResult MesOrderStepVerifySearch(string wkshopcode=null, string wo_code = null,string orderno=null, string partnumber = null, string partname = null, string partspec = null,string stepcode=null, string reportuser = null, string reportdate = null, int page = 0, int rows = 0, string prop = null, string order = null) |
| | | { |
| | | string reportdateopendate = ""; //报工开始时间 |
| | | string reportdateclosedate = ""; //报工结束时间 |
| | |
| | | } |
| | | int startNum = rows * (page - 1) + 1; //起始记录rowNum |
| | | int endNum = rows * page; //结束记录 rowNum |
| | | mes = WorkOrderBLL.MesOrderStepVerifySearch(wkshopcode,wo_code, partnumber, partname, partspec, reportuser, reportdateopendate, reportdateclosedate, startNum, endNum, prop, order); |
| | | mes = WorkOrderBLL.MesOrderStepVerifySearch(wkshopcode,wo_code, orderno, partnumber, partname, partspec, stepcode, reportuser, reportdateopendate, reportdateclosedate, startNum, endNum, prop, order); |
| | | return Json(mes); |
| | | } |
| | | #endregion |
| | |
| | | } |
| | | #endregion |
| | | |
| | | #region[生产执行,报工调整批量改价数据提交] |
| | | /// <summary> |
| | | /// 生产执行,报工调整批量改价数据提交 |
| | | /// </summary> |
| | | /// <param name="json">提交数据</param> |
| | | /// <returns></returns> |
| | | [Route(template: "MesOrderStepPriceBatchUpdateSeave")] |
| | | [HttpPost] |
| | | public JsonResult MesOrderStepPriceBatchUpdateSeave(List<BatchPrice> json) |
| | | { |
| | | var token = HttpContext.Request.Headers["Token"].ToString(); |
| | | User us = JwtTools.Denocode(token.ToString()); |
| | | mes = WorkOrderBLL.MesOrderStepPriceBatchUpdateSeave(us, json); |
| | | return Json(mes); |
| | | } |
| | | #endregion |
| | | |
| | | |
| | | |
| | | #region[生产执行,报工审核列表数据查询接口] |
| | |
| | | /// <param name="reviewstatus">审核状态</param> |
| | | /// <param name="wkshopcode">车间编码</param> |
| | | /// <param name="wo_code">工单编号</param> |
| | | /// <param name="orderno">订单号</param> |
| | | /// <param name="partnumber">产品编码</param> |
| | | /// <param name="partname">产品名称</param> |
| | | /// <param name="partspec">产品规格</param> |
| | |
| | | /// <returns></returns> |
| | | [Route(template: "MesOrderStepReportVerifySearch")] |
| | | [HttpGet] |
| | | public JsonResult MesOrderStepReportVerifySearch(string reviewstatus=null, string wkshopcode=null, string wo_code = null, string partnumber = null, string partname = null, string partspec = null,string stepname=null, string reportuser = null, string reportdate = null, int page = 0, int rows = 0, string prop = null, string order = null) |
| | | public JsonResult MesOrderStepReportVerifySearch(string reviewstatus=null, string wkshopcode=null, string wo_code = null,string orderno=null, string partnumber = null, string partname = null, string partspec = null,string stepname=null, string reportuser = null, string reportdate = null, int page = 0, int rows = 0, string prop = null, string order = null) |
| | | { |
| | | string reportdateopendate = ""; //报工开始时间 |
| | | string reportdateclosedate = ""; //报工结束时间 |
| | |
| | | } |
| | | int startNum = rows * (page - 1) + 1; //起始记录rowNum |
| | | int endNum = rows * page; //结束记录 rowNum |
| | | mes = WorkOrderBLL.MesOrderStepReportVerifySearch(reviewstatus,wkshopcode, wo_code, partnumber, partname, partspec,stepname,reportuser, reportdateopendate, reportdateclosedate, startNum, endNum, prop, order); |
| | | mes = WorkOrderBLL.MesOrderStepReportVerifySearch(reviewstatus,wkshopcode, wo_code, orderno, partnumber, partname, partspec,stepname,reportuser, reportdateopendate, reportdateclosedate, startNum, endNum, prop, order); |
| | | return Json(mes); |
| | | } |
| | | #endregion |
| | |
| | | /// <summary> |
| | | /// 生产入库信息查询 |
| | | /// </summary> |
| | | /// <param name="issouceorder">是否源单(Y/N)</param> |
| | | /// <param name="deptno">部门编码(T8使用)</param> |
| | | /// <param name="saleordercode">销售单号</param> |
| | | /// <param name="wkshopcode">车间编码</param> |
| | |
| | | /// <returns></returns> |
| | | [Route(template: "ProductInHouseOrderSearch")] |
| | | [HttpGet] |
| | | public JsonResult ProductInHouseOrderSearch(string deptno, string saleordercode, string wkshopcode, string erpordercode = null, string mesordercode = null, string partcode = null, string partname = null, string partspec = null) |
| | | public JsonResult ProductInHouseOrderSearch(string issouceorder, string deptno, string saleordercode, string wkshopcode, string erpordercode = null, string mesordercode = null, string partcode = null, string partname = null, string partspec = null) |
| | | { |
| | | mes = WorkOrderBLL.ProductInHouseOrderSearch(deptno, saleordercode, wkshopcode, erpordercode, mesordercode, partcode, partname, partspec); |
| | | mes = WorkOrderBLL.ProductInHouseOrderSearch(issouceorder,deptno, saleordercode, wkshopcode, erpordercode, mesordercode, partcode, partname, partspec); |
| | | return Json(mes); |
| | | } |
| | | #endregion |