| | |
| | | { |
| | | [RoutePrefix(prefix: "api/ProductionManagement")] |
| | | [ControllerGroup("生产管理", "在线接口")] |
| | | //[ChannelActionFilter] |
| | | [ChannelActionFilter] |
| | | public class ProductionManagementController : ApiController |
| | | { |
| | | //定义全局信息返回变量 |
| | |
| | | } |
| | | #endregion |
| | | |
| | | #region[工单派发选择工艺路线或选择生产车间时判断绑定条件] |
| | | /// <summary> |
| | | /// 工单派发选择工艺路线或选择生产车间时判断绑定条件 |
| | | /// </summary> |
| | | /// <param name="partcode">产品编码</param> |
| | | /// <param name="routecode">工艺路线编码</param> |
| | | /// <param name="wkshopcode">车间编码</param> |
| | | /// <returns></returns> |
| | | [Route(template: "SelectRouteOrWkshop")] |
| | | [HttpGet] |
| | | public HttpResponseMessage SelectRouteOrWkshop(string partcode, string routecode, string wkshopcode) |
| | | { |
| | | mes = ProductionManagementBLL.SelectRouteOrWkshop(partcode, routecode, wkshopcode); |
| | | return TJson.toJson(mes); |
| | | } |
| | | #endregion |
| | | |
| | | #region[MES工单新增、编辑提交] |
| | | /// <summary> |
| | | /// MES工单新增、编辑提交 |
| | |
| | | string planstartdate = obj["planstartdate"].ToString(); //计划开始时间 |
| | | string planenddate = obj["planenddate"].ToString(); //计划完成时间 |
| | | string orderlev = obj["orderlev"].ToString(); //工单等级 |
| | | string is_aps = obj["is_aps"].ToString(); //是否排产 |
| | | string opertype = obj["OperType"].ToString(); //操作类型 |
| | | var username = HttpContext.Current.Request.Cookies["admin"].Value.ToString(); //操作人员 |
| | | mes = ProductionManagementBLL.AddUpdateMesOrder(mesorderstus, sourceorder, ordertype, mesordercode, partcode, mesqty, routecode, wkshopcode, planstartdate, planenddate, orderlev, username, opertype, is_aps); |
| | | mes = ProductionManagementBLL.AddUpdateMesOrder(mesorderstus, sourceorder, ordertype, mesordercode, partcode, mesqty, routecode, wkshopcode, planstartdate, planenddate, orderlev, username, opertype); |
| | | return TJson.toJson(mes); |
| | | } |
| | | #endregion |