| | |
| | | using System; |
| | | using Newtonsoft.Json.Linq; |
| | | using System; |
| | | using System.Collections.Generic; |
| | | using System.Data; |
| | | using System.Linq; |
| | |
| | | public class ProductionManagementBLL |
| | | { |
| | | #region[ERP订单查询] |
| | | public static ToMessage ErpOrderSearch(string erporderstus, string erpordercode, string partcode, string partname, string partspec, int startNum, string paydatestartdate, string paydateenddate, string paydatestartdate1, string paydateenddate2, string creatuser, int endNum, string prop, string order) |
| | | public static ToMessage ErpOrderSearch(string stu_torgcode,string stu_torgtypecode, string erporderstus, string erpordercode,string saleordercode, string partcode, string partname, string partspec, int startNum, string paydatestartdate, string paydateenddate, string paydatestartdate1, string paydateenddate2, string creatuser, int endNum, string prop, string order) |
| | | { |
| | | return ProductionManagementDAL.ErpOrderSearch(erporderstus, erpordercode, partcode, partname, partspec, startNum, paydatestartdate, paydateenddate, paydatestartdate1, paydateenddate2, creatuser, endNum, prop, order); |
| | | return ProductionManagementDAL.ErpOrderSearch(stu_torgcode, stu_torgtypecode,erporderstus, erpordercode, saleordercode, partcode, partname, partspec, startNum, paydatestartdate, paydateenddate, paydatestartdate1, paydateenddate2, creatuser, endNum, prop, order); |
| | | } |
| | | #endregion |
| | | |
| | | #region[ERP订单下达] |
| | | public static ToMessage MarkSaveErpOrder(string erporderid, string erpordercode, string partcode, string wkshopcode, string warehousecode, string erpqty, string markqty, string ordernum, string relse_qty,string saleOrderDeliveryDate, string username) |
| | | public static ToMessage MarkSaveErpOrder(string erporderid, string erpordercode,string saleordercode, string partcode, string wkshopcode, string warehousecode, string erpqty, string markqty, string ordernum, string relse_qty,string saleOrderDeliveryDate, string username) |
| | | { |
| | | return ProductionManagementDAL.MarkSaveErpOrder(erporderid,erpordercode, partcode, wkshopcode, warehousecode, erpqty, markqty, ordernum, relse_qty, saleOrderDeliveryDate,username); |
| | | return ProductionManagementDAL.MarkSaveErpOrder(erporderid,erpordercode, saleordercode, partcode, wkshopcode, warehousecode, erpqty, markqty, ordernum, relse_qty, saleOrderDeliveryDate,username); |
| | | } |
| | | #endregion |
| | | |
| | |
| | | } |
| | | #endregion |
| | | |
| | | #region[ERP订单删除] |
| | | public static ToMessage DeleteErpOrder(string erporderid, string erpordercode, string username) |
| | | { |
| | | return ProductionManagementDAL.DeleteErpOrder(erporderid, erpordercode, username); |
| | | } |
| | | #endregion |
| | | |
| | | |
| | | |
| | | #region[MES工单查询] |
| | | public static ToMessage MesOrderSearch(string mesorderstus, string mesordercode,string sourceorder,string ordertype, string partcode, string partname, string partspec, int startNum, string creatuser, string createdate, int endNum, string prop, string order) |
| | | public static ToMessage MesOrderSearch(string stu_torgcode,string stu_torgtypecode,string mesorderstus, string mesordercode,string saleordercode, string sourceorder,string ordertype, string partcode, string partname, string partspec, int startNum, string creatuser, string createdate, int endNum, string prop, string order) |
| | | { |
| | | return ProductionManagementDAL.MesOrderSearch(mesorderstus, mesordercode, sourceorder, ordertype, partcode, partname, partspec, startNum, creatuser, createdate, endNum, prop, order); |
| | | return ProductionManagementDAL.MesOrderSearch(stu_torgcode, stu_torgtypecode,mesorderstus, mesordercode, sourceorder, saleordercode, ordertype, partcode, partname, partspec, startNum, creatuser, createdate, endNum, prop, order); |
| | | } |
| | | #endregion |
| | | |
| | | #region[MES报废补单工单查询] |
| | | public static ToMessage MesBadOrderSearch(string mesordercode, string sourceorder,string saleordercode, string partcode, string partname, string partspec, int startNum, string creatuser, string createdate, int endNum, string prop, string order) |
| | | { |
| | | return ProductionManagementDAL.MesBadOrderSearch(mesordercode, sourceorder, saleordercode, partcode, partname, partspec, startNum, creatuser, createdate, endNum, prop, order); |
| | | } |
| | | #endregion |
| | | |
| | | #region[产品编码查找工艺路线下拉接口] |
| | | public static ToMessage PartSelectRoute(string partcode) |
| | | public static ToMessage PartSelectRoute(string partcode,string wkshopcode) |
| | | { |
| | | return ProductionManagementDAL.PartSelectRoute(partcode); |
| | | return ProductionManagementDAL.PartSelectRoute(partcode, wkshopcode); |
| | | } |
| | | #endregion |
| | | |
| | | #region[工艺路线查找车间下拉接口] |
| | | public static ToMessage RouteSelectWkshop(string partcode, string routecode) |
| | | public static ToMessage RouteSelectWkshop(string stu_torgcode,string stu_torgtypecode,string partcode) |
| | | { |
| | | return ProductionManagementDAL.RouteSelectWkshop(partcode,routecode); |
| | | return ProductionManagementDAL.RouteSelectWkshop(stu_torgcode, stu_torgtypecode, partcode); |
| | | } |
| | | #endregion |
| | | |
| | |
| | | public static ToMessage JobCreationSonAddVison(string partnumber) |
| | | { |
| | | return ProductionManagementDAL.JobCreationSonAddVison(partnumber); |
| | | } |
| | | #endregion |
| | | |
| | | #region[工单派发选择工艺路线或选择生产车间时判断绑定条件] |
| | | public static ToMessage SelectRouteOrWkshop(string partcode, string routecode, string wkshopcode,string is_steprice) |
| | | { |
| | | return ProductionManagementDAL.SelectRouteOrWkshop(partcode,routecode,wkshopcode, is_steprice); |
| | | } |
| | | #endregion |
| | | |
| | | #region[MES工单新增、获取工单号] |
| | | public static ToMessage AddMesOrderCodeSearch() |
| | | { |
| | | return ProductionManagementDAL.AddMesOrderCodeSearch(); |
| | | } |
| | | #endregion |
| | | |
| | |
| | | |
| | | |
| | | |
| | | #region[生产开报工扫码获取当前工序对应的设备(自制)] |
| | | public static ToMessage MesOrderStepEqpSearch(string orderstepqrcode) |
| | | { |
| | | return ProductionManagementDAL.MesOrderStepEqpSearch(orderstepqrcode); |
| | | } |
| | | #endregion |
| | | |
| | | #region[生产开报工扫码获取当前工序对应的供方(外协)] |
| | | public static ToMessage MesOrderWxStepEqpSearch(string orderstepqrcode) |
| | | { |
| | | return ProductionManagementDAL.MesOrderWxStepEqpSearch(orderstepqrcode); |
| | | } |
| | | #endregion |
| | | |
| | | #region[生产开报工扫码获取工单对应工序任务] |
| | | public static ToMessage MesOrderStepSearch(string orderstepqrcode, int startNum, int endNum, string prop, string order) |
| | | public static ToMessage MesOrderStepSearch(string stu_torgcode,string stu_torgtypecode, string orderstepqrcode, int startNum, int endNum, string prop, string order) |
| | | { |
| | | return ProductionManagementDAL.MesOrderStepSearch(orderstepqrcode, startNum, endNum, prop, order); |
| | | return ProductionManagementDAL.MesOrderStepSearch(stu_torgcode, stu_torgtypecode, orderstepqrcode, startNum, endNum, prop, order); |
| | | } |
| | | #endregion |
| | | |
| | | #region[生产开报工扫码获取工单对应工序任务(外协)] |
| | | public static ToMessage MesOrderWxStepSearch(string orderstepqrcode, int startNum, int endNum, string prop, string order) |
| | | public static ToMessage MesOrderWxStepSearch(string stu_torgcode,string stu_torgtypecode,string orderstepqrcode, int startNum, int endNum, string prop, string order) |
| | | { |
| | | return ProductionManagementDAL.MesOrderWxStepSearch(orderstepqrcode, startNum, endNum, prop, order); |
| | | return ProductionManagementDAL.MesOrderWxStepSearch(stu_torgcode, stu_torgtypecode,orderstepqrcode, startNum, endNum, prop, order); |
| | | } |
| | | #endregion |
| | | |
| | | #region[生产开报工扫码获取工单对应工序任务(不良)] |
| | | public static ToMessage MesOrderNgStepSearch(string orderstepqrcode, int startNum, int endNum, string prop, string order) |
| | | public static ToMessage MesOrderNgStepSearch(string stu_torgcode,string stu_torgtypecode,string orderstepqrcode, int startNum, int endNum, string prop, string order) |
| | | { |
| | | return ProductionManagementDAL.MesOrderNgStepSearch(orderstepqrcode, startNum, endNum, prop, order); |
| | | return ProductionManagementDAL.MesOrderNgStepSearch(stu_torgcode, stu_torgtypecode,orderstepqrcode, startNum, endNum, prop, order); |
| | | } |
| | | #endregion |
| | | |
| | |
| | | #endregion |
| | | |
| | | #region [生产开报工:开工(开始/报工)/外协发料时条件判断及数据返回接口] |
| | | public static ToMessage MesOrderStepStart(string OperType,string SelectType, string orderstepqrcode) |
| | | public static ToMessage MesOrderStepStart(string OperType,string stu_torgcode, string SelectType, string orderstepqrcode) |
| | | { |
| | | return ProductionManagementDAL.MesOrderStepStart(OperType, SelectType, orderstepqrcode); |
| | | return ProductionManagementDAL.MesOrderStepStart(OperType, stu_torgcode, SelectType, orderstepqrcode); |
| | | } |
| | | #endregion |
| | | |
| | |
| | | #endregion |
| | | |
| | | #region[生产开报工:报工时获取生产班组下拉框] |
| | | public static ToMessage MesOrderStepReportSelectUserGroup() |
| | | public static ToMessage MesOrderStepReportSelectUserGroup(string stu_torgcode,string stu_torgtypecode,string wkshopcode) |
| | | { |
| | | return ProductionManagementDAL.MesOrderStepReportSelectUserGroup(); |
| | | return ProductionManagementDAL.MesOrderStepReportSelectUserGroup(stu_torgcode, stu_torgtypecode,wkshopcode); |
| | | } |
| | | #endregion |
| | | |
| | | #region[生产开报工:根据生产班组查找人员列表] |
| | | public static ToMessage MesOrderGroupSelectUser(string usergroupcode) |
| | | public static ToMessage MesOrderGroupSelectUser(string stu_torgcode, string usergroupcode) |
| | | { |
| | | return ProductionManagementDAL.MesOrderGroupSelectUser(usergroupcode); |
| | | return ProductionManagementDAL.MesOrderGroupSelectUser(stu_torgcode,usergroupcode); |
| | | } |
| | | #endregion |
| | | |
| | |
| | | #endregion |
| | | |
| | | #region[生产开报工,报工提交] |
| | | public static ToMessage SavaMesOrderStepReport(string mesordercode, string partcode, string stepseq, string stepcode, string eqpcode,string reckway, string usergroupcode, string reportuser, string taskqty,string startqty, string reportqty,string ngqty, string badcode,string remarks, string username) |
| | | public static ToMessage SavaMesOrderStepReport(string mesordercode, string partcode, string stepseq, string stepcode, string eqpcode,string inbarcode, string reckway, string usergroupcode, string reportuser, string taskqty,string startqty, string reportqty, List<ReportDefectList> defectobjs, string remarks, string username) |
| | | { |
| | | return ProductionManagementDAL.SavaMesOrderStepReport(mesordercode, partcode, stepseq, stepcode, eqpcode, reckway,usergroupcode, reportuser, taskqty, startqty, reportqty, ngqty, badcode, remarks, username); |
| | | return ProductionManagementDAL.SavaMesOrderStepReport(mesordercode, partcode, stepseq, stepcode, eqpcode, inbarcode, reckway,usergroupcode, reportuser, taskqty, startqty, reportqty,defectobjs, remarks, username); |
| | | } |
| | | #endregion |
| | | |
| | |
| | | #endregion |
| | | |
| | | #region[生产开报工, 收料提交] |
| | | public static ToMessage SavaMesOrderStepIn(string mesordercode, string partcode, string stepseq, string stepcode, string wxcode, string inuser, string taskqty, string sqty, string ngqty, string badcode,string remarks, string username) |
| | | public static ToMessage SavaMesOrderStepIn(string mesordercode, string partcode, string stepseq, string stepcode, string wxcode,string inbarcode, string inuser, string taskqty, string sqty, List<ReportDefectList> defectobjs, string remarks, string username) |
| | | { |
| | | return ProductionManagementDAL.SavaMesOrderStepIn(mesordercode, partcode, stepseq, stepcode, wxcode, inuser, taskqty, sqty, ngqty, badcode, remarks, username); |
| | | return ProductionManagementDAL.SavaMesOrderStepIn(mesordercode, partcode, stepseq, stepcode, wxcode, inbarcode, inuser, taskqty, sqty,defectobjs, remarks, username); |
| | | } |
| | | #endregion |
| | | |
| | |
| | | } |
| | | #endregion |
| | | |
| | | #region[生产开报工,工序检验扫码获取任务信息] |
| | | public static ToMessage MesOrderStepCheckSearch(string orderstepqrcode) |
| | | |
| | | #region[工序检验扫码获取任务信息] |
| | | public static ToMessage MesOrderStepCheckSearch(string stu_torgcode,string orderstepqrcode,string checktype) |
| | | { |
| | | return ProductionManagementDAL.MesOrderStepCheckSearch(orderstepqrcode); |
| | | return ProductionManagementDAL.MesOrderStepCheckSearch(stu_torgcode,orderstepqrcode, checktype); |
| | | } |
| | | #endregion |
| | | |
| | | #region[生产开报工,工序检验获取检验标准下拉框数据] |
| | | public static ToMessage MesOrderStepCheckSelect() |
| | | { |
| | | return ProductionManagementDAL.MesOrderStepCheckSelect(); |
| | | } |
| | | #endregion |
| | | |
| | | #region[生产开报工,工序检验根据检验标准获取检验项目列表] |
| | | #region[工序检验根据选择的检验方案查找检验项目] |
| | | public static ToMessage MesOrderStepCheckItemList(string checkstandcode) |
| | | { |
| | | return ProductionManagementDAL.MesOrderStepCheckItemList(checkstandcode); |
| | | } |
| | | #endregion |
| | | |
| | | #region[生产开报工,工序检验提交保存] |
| | | public static ToMessage SaveMesOrderStepCheckItem(string mesordercode, string partcode, string stepcode, string checkstanedcode, string checkusercode, string checktypecode, string checkresult, string checkdescr,string checkqty, string username, List<StepCheck> json) |
| | | #region[工序检验,提交] |
| | | public static ToMessage SaveMesOrderStepCheckItem(string stu_torgcode, string wocode, string partcode, string stepcode, string checkstandcode, string check_type, string sampmethod, string qualitystatus, string labqty, string sampleqty, string goodqty, string ngqty, string checkitemcont, string username) |
| | | { |
| | | return ProductionManagementDAL.SaveMesOrderStepCheckItem(mesordercode, partcode, stepcode, checkstanedcode, checkusercode, checktypecode, checkresult, checkdescr, checkqty, username, json); |
| | | return ProductionManagementDAL.SaveMesOrderStepCheckItem(stu_torgcode,wocode, partcode, stepcode, checkstandcode, check_type, sampmethod, qualitystatus, labqty, sampleqty, goodqty, ngqty, checkitemcont, username); |
| | | } |
| | | #endregion |
| | | |
| | | |
| | | |
| | | #region[MES工单批量关闭查询] |
| | | public static ToMessage MesOrderBitchClosedSearch(string mesorderstus, string mesordercode, string sourceorder, string ordertype, string partcode, string partname, string partspec, int startNum, string creatuser, string createdate, int endNum, string prop, string order) |
| | | public static ToMessage MesOrderBitchClosedSearch(string stu_torgcode,string stu_torgtypecode, string mesorderstus, string mesordercode, string sourceorder, string ordertype, string partcode, string partname, string partspec, int startNum, string creatuser, string createdate, int endNum, string prop, string order) |
| | | { |
| | | return ProductionManagementDAL.MesOrderBitchClosedSearch(mesorderstus, mesordercode, sourceorder, ordertype, partcode, partname, partspec, startNum, creatuser, createdate, endNum, prop, order); |
| | | return ProductionManagementDAL.MesOrderBitchClosedSearch(stu_torgcode, stu_torgtypecode,mesorderstus, mesordercode, sourceorder, ordertype, partcode, partname, partspec, startNum, creatuser, createdate, endNum, prop, order); |
| | | } |
| | | #endregion |
| | | |
| | |
| | | } |
| | | #endregion |
| | | |
| | | #region[NEW排产设备信息] |
| | | public static List<AdvancedSchedulingDevice> NewOnclickAdvancedSchedulingDevice(List<ApsOrderSerch> json, ref ToMessage mes) |
| | | { |
| | | return ProductionManagementDAL.NewOnclickAdvancedSchedulingDevice(json, ref mes); |
| | | } |
| | | #endregion |
| | | |
| | | #region[NEW设备已排程信息] |
| | | public static List<DataTable> NewAlreadyScheduling(List<ApsOrderSerch> json) |
| | | { |
| | | return ProductionManagementDAL.NewAlreadyScheduling(json); |
| | | } |
| | | #endregion |
| | | |
| | | #region[排程数据提交] |
| | | public static ToMessage SubmitAlreadyScheduling(string username, string wocode, string botprocecode, List<AlreadyScheduling> objs) |
| | | { |
| | |
| | | } |
| | | #endregion |
| | | |
| | | |
| | | #region[生产入库条码补打] |
| | | public static ToMessage ProductInHouseLabCode(string ordercode) |
| | | { |
| | | return ProductionManagementDAL.ProductInHouseLabCode(ordercode); |
| | | } |
| | | #endregion |
| | | |
| | | #region[生产入库通过车间查找生产订单] |
| | | public static ToMessage ProductInHouseWkshopOrder(string ordertype, string wkshopcode) |
| | | { |
| | | return ProductionManagementDAL.ProductInHouseWkshopOrder(ordertype, wkshopcode); |
| | | } |
| | | #endregion |
| | | |
| | | #region[生产入库信息查询] |
| | | public static ToMessage ProductInHouseOrderSearch(string wkshopcode,string erpordercode, string mesordercode, string partcode, string partname, string partspec, string startorderdate, string endorderdate) |
| | | { |
| | | return ProductionManagementDAL.ProductInHouseOrderSearch(wkshopcode,erpordercode, mesordercode, partcode, partname, partspec, startorderdate, endorderdate); |
| | | } |
| | | #endregion |
| | | |
| | | #region[生产入库获取单据号] |
| | | public static ToMessage ProductInHouseOrderCodeSearch(string rightcode) |
| | | { |
| | | return ProductionManagementDAL.ProductInHouseOrderCodeSearch(rightcode); |
| | | } |
| | | #endregion |
| | | |
| | | #region[生产入库提交] |
| | | public static ToMessage ProductInHouseOrderSeave(string username, JObject obj) |
| | | { |
| | | return ProductionManagementDAL.ProductInHouseOrderSeave(username, obj); |
| | | } |
| | | #endregion |
| | | |
| | | |
| | | #region[App生产入库扫描条码] |
| | | public static ToMessage MesAppProductInHouseOrderBarCodeSearch(string labcode) |
| | | { |
| | | return ProductionManagementDAL.MesAppProductInHouseOrderBarCodeSearch(labcode); |
| | | } |
| | | #endregion |
| | | |
| | | } |
| | | } |