| | |
| | | [Column(TypeName = "nvarchar(50)")] |
| | | public string heatNumber { get; set; } |
| | | |
| | | /// <summary> |
| | | ///æçç±»å |
| | | /// </summary> |
| | | [Display(Name = "æçç±»å")] |
| | | [MaxLength(100)] |
| | | [Column(TypeName = "nvarchar(100)")] |
| | | public string tray_type { get; set; } |
| | | } |
| | | } |
| | |
| | | if (!Request) continue; |
| | | |
| | | var Stations = stationinfoRepository.Find(x => x.area == PipelineJob.area_code(name)); |
| | | foreach (var station in Stations) |
| | | { |
| | | if (!station.enable) |
| | | client.WriteByOrder("W_Enabl_Load", false, name);//ä¿¡å·ä¸ºfalseæ¡æ¶åæ¢è¿å
¥ |
| | | } |
| | | |
| | | var NGStation = "X01001003"; |
| | | if (name == "2åå
䏿åº") NGStation = "X02001003"; |
| | | if (name == "3åå
䏿åº") NGStation = "X03001002"; |
| | | var Wheel_Type = (Int32)DBExtension.Read(details.Where(x => x.plcdetail_name == "R_Wheel_Type").First(), client);//车轮类å |
| | | var Wheel_id = DBExtension.Read(details.Where(x => x.plcdetail_name == "R_Wheel_id").First(), client).ToString();//车轮SNå· |
| | | foreach (var station in Stations) |
| | | { |
| | | if (!station.enable || station.location_state == LocationStateEnum.Empty.ToString()) |
| | | client.WriteByOrder("W_Enabl_Load", false, name);//ä¿¡å·ä¸ºfalseæ¡æ¶åæ¢è¿å
¥ |
| | | } |
| | | var Wheel_Type = DBExtension.Read(details.Where(x => x.plcdetail_name == "R_Wheel_Type").First(), client);//车轮类å |
| | | var Wheel_id = client.ReadByOrder<string>("R_Wheel_id", name);//车轮SNå· |
| | | //var Wheel_id = DBExtension.Read(details.Where(x => x.plcdetail_name == "R_Wheel_id").First(), client).ToString(); |
| | | |
| | | var mes_Detail = mes_DetailRepository.FindFirst(x => x.SN == Wheel_id); |
| | | var mes_Head = mes_HeadRepository.FindFirst(x => x.jobID == mes_Detail.jobID); |
| | | var wheel = PipelineJob.QueryMateriel(mes_Head.drawingNo); |
| | | |
| | | var PartStatus = (Int32)DBExtension.Read(details.Where(x => x.plcdetail_name == "R_PartStatus").First(), client);//1:ok;2:nok |
| | | if (PartStatus == 1) |
| | | var PartStatus = DBExtension.Read(details.Where(x => x.plcdetail_name == "R_PartStatus").First(), client);//1:ok;2:nok |
| | | if ((Int16)PartStatus == 1) |
| | | { |
| | | var Stationinfo = Stations |
| | | .Where(x => x.enable |
| | | && x.stationCode != NGStation |
| | | && x.location_state == LocationStateEnum.Stroge.ToString() |
| | | && x.quantity < 5 |
| | | && x.stationType == PipelineJob.QueryMateriel(Wheel_Type) |
| | | && x.stationType == mes_Head.drawingNo |
| | | && x.tray_type == (wheel.e < 1100 ? "SmallTray" : "LargeTray") |
| | | && x.Number == mes_Detail.jobID |
| | | && x.heatNumber == mes_Detail.heatID).FirstOrDefault(); |
| | | && x.heatNumber == mes_Detail.heatID) |
| | | .OrderByDescending(x => x.quantity) |
| | | .FirstOrDefault(); |
| | | if (Stationinfo == null) |
| | | Stationinfo = Stations.Where(x => x.enable && x.stationCode != NGStation && x.location_state == LocationStateEnum.Stroge.ToString() && x.quantity == 0).FirstOrDefault(); |
| | | if (Stationinfo != null) |
| | | { |
| | | var Pipelinedetails = plcRepository.Find(x => x.plcdetail_iotype == Pipelineplc.plcinfo_iotyep && x.plcdetail_number == Stationinfo.stationCode).ToList(); |
| | | var PalletSignal = (Int16)DBExtension.Read(Pipelinedetails.Where(x => x.plcdetail_name == "R_PalletSignal").First(), client);//读åæçä¿¡å·:1:æ,2æ |
| | | var PalletSignal = (Int16)DBExtension.Read(Pipelinedetails.Where(x => x.plcdetail_name == "R_PalletSignal").First(), Pipeline_client);//读åæçä¿¡å·:1:æ,2æ |
| | | //var Wheel_id = client.ReadByOrder<string>("R_Wheel_id", name); |
| | | if (PalletSignal == 1) |
| | | { |
| | | var SNS = Stationinfo.bindSN.Split(","); |
| | |
| | | } |
| | | var area = Convert.ToInt16(Stationinfo.stationCode.Substring(Stationinfo.stationCode.Length - 1, 1)); |
| | | client.WriteByOrder("W_AreaNr", (Int16)area, name);//åºåè´§ä½å· |
| | | client.WriteByOrder("W_IndexNr", (Int16)Stationinfo.quantity + 1, name);//æçä¸ç第å 个车轮 |
| | | client.WriteByOrder("W_IndexNr", (Int16)(Stationinfo.quantity + 1), name);//æçä¸ç第å 个车轮 |
| | | client.WriteByOrder("W_Storage_Type", (Int16)1, name);//æçç±»å1-横æ¾;2-ç«æ¾(ææ¶åªææ¨ªæ¾æç) |
| | | client.WriteByOrder("W_Enabl_Load", true, name);//æ¯å¦å
许 |
| | | return; |
| | | } |
| | | } |
| | | } |
| | | else if (PartStatus == 2) |
| | | else if ((Int16)PartStatus == 2) |
| | | { |
| | | var Stationinfo = Stations |
| | | .Where(x => x.enable |
| | | && x.stationCode == NGStation |
| | | && x.location_state == LocationStateEnum.Stroge.ToString() |
| | | && x.quantity < 5 |
| | | && x.stationType == PipelineJob.QueryMateriel(Wheel_Type) |
| | | && x.stationType == mes_Head.drawingNo |
| | | && x.tray_type == (wheel.e < 1100 ? "SmallTray" : "LargeTray") |
| | | && x.Number == mes_Detail.jobID |
| | | && x.heatNumber == mes_Detail.heatID).FirstOrDefault(); |
| | | if (Stationinfo != null) |
| | |
| | | } |
| | | var area = Convert.ToInt16(Stationinfo.stationCode.Substring(Stationinfo.stationCode.Length - 1, 1)); |
| | | client.WriteByOrder("W_AreaNr", (Int16)area, name);//åºåè´§ä½å· |
| | | client.WriteByOrder("W_IndexNr", (Int16)Stationinfo.quantity + 1, name);//æçä¸ç第å 个车轮 |
| | | client.WriteByOrder("W_IndexNr", (Int16)(Stationinfo.quantity + 1), name);//æçä¸ç第å 个车轮 |
| | | client.WriteByOrder("W_Storage_Type", (Int16)1, name);//æçç±»å1-横æ¾;2-ç«æ¾(ææ¶åªææ¨ªæ¾æç) |
| | | client.WriteByOrder("W_Enabl_Load", true, name);//æ¯å¦å
许 |
| | | return; |
| | |
| | | station.bindSN = station.bindSN == string.Empty ? Wheel_id : station.bindSN + "," + Wheel_id; |
| | | if (station.quantity == 0) |
| | | { |
| | | station.stationType = Wheel_id; |
| | | station.Number = Wheel_id; |
| | | station.heatNumber = Wheel_id; |
| | | station.stationType = mes_Head.drawingNo; |
| | | station.Number = mes_Head.jobID; |
| | | station.heatNumber = mes_Detail.heatID; |
| | | } |
| | | var count = stationinfoRepository.Update(station); |
| | | if (count < 1) |
| | |
| | | //Creation.HCJCreation(); |
| | | //Creation.PLCinfodetail(); |
| | | |
| | | StationTask.CreateTask(); |
| | | //StationTask.CreateTask(); |
| | | //OutboundTask.CreateOutboundTask(); |
| | | |
| | | } |
| | | } |
| | |
| | | Gantry_client.WriteByOrder("W_AreaNr", (Int16)area, number);//åºåè´§ä½å· |
| | | Gantry_client.WriteByOrder("W_IndexNr", (Int16)SNS.Length, number);//æçä¸ç第å 个车轮 |
| | | Gantry_client.WriteByOrder("W_Storage_Type", (Int16)1, number); //æçç±»å1-横æ¾;2-ç«æ¾ |
| | | Gantry_client.WriteByOrder("W_Wheel_Type", (Int16)Convert.ToInt16(QueryMateriel(Station.stationType)), number);//车轮类å |
| | | Gantry_client.WriteByOrder("W_Wheel_Type", (Int16)Convert.ToInt16(QueryMateriel(Station.stationType).TypeId), number);//车轮类å |
| | | Gantry_client.WriteByOrder("W_Wheel_id", SNS[SNS.Length - 1], number);//车轮SNå· |
| | | Gantry_client.WriteByOrder("W_RequestUnload", true, number); |
| | | } |
| | |
| | | |
| | | return Newsn; |
| | | } |
| | | private int QueryMateriel(string type) |
| | | { |
| | | public static dt_geometry_data QueryMateriel(string type) |
| | | { |
| | | VOLContext Context = new VOLContext(); |
| | | Idt_geometry_dataRepository dataRepository = new dt_geometry_dataRepository(Context); |
| | | var materielinfo = dataRepository.FindFirst(x => x.Description == type); |
| | | return materielinfo.TypeId; |
| | | return materielinfo; |
| | | } |
| | | public static string QueryMateriel(int typeId) |
| | | { |
¶Ô±ÈÐÂÎļþ |
| | |
| | | using System; |
| | | using System.Collections.Generic; |
| | | using System.Linq; |
| | | using System.Security.Cryptography.Xml; |
| | | using System.Text; |
| | | using System.Threading.Tasks; |
| | | using WIDESEA_Comm; |
| | | using WIDESEA_Comm.TaskNo; |
| | | using WIDESEA_Core.EFDbContext; |
| | | using WIDESEA_Core.FreeDB; |
| | | using WIDESEA_Entity.DomainModels; |
| | | using WIDESEA_WCS.IRepositories; |
| | | using WIDESEA_WCS.Repositories; |
| | | using static FreeSql.Internal.GlobalFilter; |
| | | using static System.Collections.Specialized.BitVector32; |
| | | |
| | | namespace WIDESEA_WCS.JobsPart.Common |
| | | { |
| | | public class OutboundTask |
| | | { |
| | | static FreeDB freeDB = new FreeDB(); |
| | | /// <summary> |
| | | /// å建åºåºä»»å¡ |
| | | /// </summary> |
| | | public static void CreateOutboundTask() |
| | | { |
| | | try |
| | | { |
| | | VOLContext context = new VOLContext(); |
| | | Idt_stationinfoRepository stationinfoRepository = new dt_stationinfoRepository(context); |
| | | var mes_heads = freeDB.Select<dt_mes_head>().Where(x => x.processCode == "28").OrderBy(x => x.expectedStartTime).ToList(); |
| | | foreach (var mes_head in mes_heads) |
| | | { |
| | | //var inventorys = freeDB.Select<dt_inventory>().Where(x => x.FigureNumber == mes_head.drawingNo).OrderBy.ToList(); |
| | | var station = stationinfoRepository.Find(x => x.stationType == mes_head.drawingNo && x.line != x.line).OrderBy(x => x.line).ThenByDescending(x => x.column).FirstOrDefault(); |
| | | bool ok = false; |
| | | List<string> list = new List<string>(); |
| | | if (station != null && station.location_state == LocationStateEnum.Stroge.ToString() && station.enable) |
| | | { |
| | | var SNS = station.bindSN.Split(","); |
| | | foreach (var SN in SNS) |
| | | { |
| | | if (!string.IsNullOrEmpty(SN)) |
| | | list.Add(SN); |
| | | } |
| | | } |
| | | foreach (var SN in list) |
| | | { |
| | | if (ok = freeDB.Select<dt_mes_detail>().Where(x => x.jobID == mes_head.jobID && x.SN == SN).Any()) continue; |
| | | } |
| | | if (ok) |
| | | { |
| | | dt_agvtask agvtask = new dt_agvtask() |
| | | { |
| | | agv_fromaddress = station.stationCode, |
| | | agv_id = Guid.NewGuid(), |
| | | agv_tasknum = IdenxManager.GetTaskNo("KH-", "WMS"), |
| | | agv_grade = 1, |
| | | agv_createtime = DateTime.Now, |
| | | agv_taskstate = "Queue", |
| | | agv_materielid = station.stationType, |
| | | agv_qty = station.quantity, |
| | | agv_tasktype = "TaskType_Outbound", |
| | | agv_toaddress = "", |
| | | agv_userid = "ç³»ç»", |
| | | bindSN = station.bindSN, |
| | | agv_worktype = Convert.ToInt32(mes_head.processCode), |
| | | agv_materbarcode = mes_head.materialCode, |
| | | agv_barcode = station.tray_type |
| | | }; |
| | | dt_stationinfo TargetLocation = GetEmptyLocation(stationinfoRepository); |
| | | if (TargetLocation != null) |
| | | { |
| | | agvtask.agv_taskstate = "Create"; |
| | | agvtask.agv_toaddress = TargetLocation.stationCode; |
| | | TargetLocation.location_state = LocationStateEnum.Busy.ToString(); |
| | | freeDB.Update(TargetLocation); |
| | | } |
| | | freeDB.Add(agvtask); |
| | | } |
| | | } |
| | | } |
| | | catch (Exception) |
| | | { |
| | | |
| | | throw; |
| | | } |
| | | } |
| | | private static dt_stationinfo GetEmptyLocation(Idt_stationinfoRepository stationinfoRepository) |
| | | { |
| | | dt_stationinfo TargetLocation = null; |
| | | var stations = stationinfoRepository.Find(x => x.stationCode.Contains("S01001")); |
| | | foreach (var station in stations) |
| | | { |
| | | TargetLocation = stationinfoRepository.FindFirst(x => x.stationCode == station.stationCode && x.location_state == LocationStateEnum.Empty.ToString() && x.enable); |
| | | if (TargetLocation != null) continue; |
| | | } |
| | | |
| | | if (TargetLocation == null) |
| | | { |
| | | throw new Exception("æ£æµçº¿ä¸æä½å·²æ»¡"); |
| | | } |
| | | return TargetLocation; |
| | | } |
| | | } |
| | | } |
| | |
| | | using WIDESEA_Entity.DomainModels; |
| | | using WIDESEA_Comm; |
| | | using static System.Collections.Specialized.BitVector32; |
| | | using WIDESEA_Comm.TaskNo; |
| | | |
| | | namespace WIDESEA_WCS.JobsPart.Common |
| | | { |
| | |
| | | { |
| | | |
| | | static FreeDB freeDB = new FreeDB(); |
| | | /// <summary> |
| | | /// å建å
¥åºä»»å¡ |
| | | /// </summary> |
| | | public static void CreateTask() |
| | | { |
| | | VOLContext context = new VOLContext(); |
| | | Idt_stationinfoRepository stationinfoRepository = new dt_stationinfoRepository(context); |
| | | Idt_WorkinfoRepository workinfoRepository = new dt_WorkinfoRepository(context); |
| | | |
| | | List<dt_stationinfo> stationinfos = stationinfoRepository.Find(x => x.stationCode.Contains('X')); |
| | | |
| | | foreach (var item in stationinfos) |
| | | try |
| | | { |
| | | //æ ¹æ®ä¸æå£çç»å®ä¿¡æ¯æ¥è¯¢å¯¹åºå·¥åï¼æ£æµæ¤å·¥åæ¯å¦å·²å®æ 宿å³å¯å°å
¶éå
¥åº |
| | | VOLContext context = new VOLContext(); |
| | | Idt_stationinfoRepository stationinfoRepository = new dt_stationinfoRepository(context); |
| | | Idt_WorkinfoRepository workinfoRepository = new dt_WorkinfoRepository(context); |
| | | |
| | | dt_mes_head mesinfo = freeDB.Select<dt_mes_head>().Where(x => x.jobID == item.Number).First(); |
| | | dt_geometry_data dt_Geometry_Data = freeDB.Select<dt_geometry_data>().Where(x => x.Description == mesinfo.drawingNo).First(); |
| | | int CompeletedNum = Convert.ToInt32(mesinfo.quantity) - Convert.ToInt32(mesinfo.finishNum); |
| | | List<dt_stationinfo> stationinfos = stationinfoRepository.Find(x => x.stationCode.Contains('X')); |
| | | |
| | | |
| | | //å¤å®ä»»å¡æ¯å¦å·²å建//å¦å·²åå¨ |
| | | if (freeDB.Select<dt_agvtask>().Where(x => x.agv_fromaddress == item.stationCode).Count() > 0) |
| | | continue; |
| | | |
| | | if (item.quantity == 5 || CompeletedNum == 0) //循ç¯è¯»å车轮æ°ä¸º5æè
订å已宿æ°éçä¸æå£ âå·¥å人工å
³éçå·¥å |
| | | foreach (var item in stationinfos) |
| | | { |
| | | //æ ¹æ®ä¸æå£çç»å®ä¿¡æ¯æ¥è¯¢å¯¹åºå·¥åï¼æ£æµæ¤å·¥åæ¯å¦å·²å®æ 宿å³å¯å°å
¶éå
¥åº |
| | | |
| | | dt_mes_head mesinfo = freeDB.Select<dt_mes_head>().Where(x => x.jobID == item.Number).First(); |
| | | dt_geometry_data dt_Geometry_Data = freeDB.Select<dt_geometry_data>().Where(x => x.Description == mesinfo.drawingNo).First(); |
| | | int CompeletedNum = Convert.ToInt32(mesinfo.quantity) - Convert.ToInt32(mesinfo.finishNum); |
| | | |
| | | |
| | | if (mesinfo.quantity <= 50 || item.stationCode.Contains("3")) //å°äº50ä»¶ç´æ¥åºåº |
| | | //å¤å®ä»»å¡æ¯å¦å·²å建//å¦å·²åå¨ |
| | | if (freeDB.Select<dt_agvtask>().Where(x => x.agv_fromaddress == item.stationCode).Count() > 0) |
| | | continue; |
| | | |
| | | if (item.quantity == 5 || CompeletedNum == 0) //循ç¯è¯»å车轮æ°ä¸º5æè
订å已宿æ°éçä¸æå£ âå·¥å人工å
³éçå·¥å |
| | | { |
| | | //var station = |
| | | //todo 寻æ¾å¯æ¾è´§å¤åæ¾è´§å° |
| | | dt_agvtask agvtask = new dt_agvtask() |
| | | { |
| | | agv_fromaddress = item.stationCode, |
| | | agv_id = Guid.NewGuid(), |
| | | agv_grade = 0, |
| | | agv_barcode = "", |
| | | agv_createtime = DateTime.Now, |
| | | agv_taskstate = TaskStatus.Created.ToString(), |
| | | //agv_toaddress = , |
| | | |
| | | }; |
| | | freeDB.Add(agvtask); |
| | | } |
| | | else |
| | | { |
| | | dt_stationinfo TargetLocation = GetEmptyLocation(stationinfoRepository, mesinfo, item, CompeletedNum, dt_Geometry_Data.e); |
| | | |
| | | if (TargetLocation != null) |
| | | if (mesinfo.quantity <= 50 || item.stationCode.Contains("3")) //å°äº50ä»¶ç´æ¥åºåº |
| | | { |
| | | //todo: è°ç¨WMSæ¥å£åå»ºä»»å¡ |
| | | dt_agvtask agvtask = new dt_agvtask() |
| | | dt_stationinfo TargetLocation = GetEmptyLocation(stationinfoRepository); |
| | | //todo 寻æ¾å¯æ¾è´§å¤åæ¾è´§å° |
| | | if (TargetLocation != null) |
| | | { |
| | | agv_fromaddress = item.stationCode, |
| | | agv_id = Guid.NewGuid(), |
| | | agv_grade = 0, |
| | | agv_barcode = "", |
| | | agv_createtime = DateTime.Now, |
| | | agv_taskstate = TaskStatus.Created.ToString(), |
| | | agv_toaddress = TargetLocation.stationCode, |
| | | }; |
| | | dt_agvtask agvtask = new dt_agvtask() |
| | | { |
| | | agv_fromaddress = item.stationCode, |
| | | agv_id = Guid.NewGuid(), |
| | | agv_tasknum = IdenxManager.GetTaskNo("KH-", "WMS"), |
| | | agv_grade = 1, |
| | | agv_createtime = DateTime.Now, |
| | | agv_taskstate = "Create", |
| | | agv_materielid = item.stationType, |
| | | agv_qty = item.quantity, |
| | | agv_tasktype = "TaskType_OutsourceInbound", |
| | | agv_toaddress = TargetLocation.stationCode, |
| | | agv_userid = "ç³»ç»", |
| | | bindSN = item.bindSN, |
| | | agv_worktype = Convert.ToInt32(mesinfo.processCode), |
| | | agv_materbarcode = mesinfo.materialCode, |
| | | agv_barcode=item.tray_type |
| | | }; |
| | | |
| | | freeDB.Add(agvtask); |
| | | TargetLocation.location_state = LocationStateEnum.Busy.ToString(); |
| | | freeDB.Update(TargetLocation); |
| | | freeDB.Add(agvtask); |
| | | TargetLocation.location_state = LocationStateEnum.Busy.ToString(); |
| | | freeDB.Update(TargetLocation); |
| | | } |
| | | } |
| | | else |
| | | { |
| | | dt_stationinfo TargetLocation = GetEmptyLocation(stationinfoRepository, mesinfo, item, CompeletedNum, dt_Geometry_Data.e); |
| | | |
| | | if (TargetLocation != null) |
| | | { |
| | | //todo: è°ç¨WMSæ¥å£åå»ºä»»å¡ |
| | | dt_agvtask agvtask = new dt_agvtask() |
| | | { |
| | | agv_fromaddress = item.stationCode, |
| | | agv_id = Guid.NewGuid(), |
| | | agv_tasknum = IdenxManager.GetTaskNo("KH-", "WMS"), |
| | | agv_grade = 1, |
| | | agv_createtime = DateTime.Now, |
| | | agv_taskstate = "Create", |
| | | agv_materielid = item.stationType, |
| | | agv_qty = item.quantity, |
| | | agv_tasktype = "TaskType_Inbound", |
| | | agv_toaddress = TargetLocation.stationCode, |
| | | agv_userid = "ç³»ç»", |
| | | bindSN = item.bindSN, |
| | | agv_worktype = Convert.ToInt32(mesinfo.processCode), |
| | | agv_materbarcode = mesinfo.materialCode, |
| | | agv_barcode=item.tray_type |
| | | }; |
| | | |
| | | freeDB.Add(agvtask); |
| | | TargetLocation.location_state = LocationStateEnum.Busy.ToString(); |
| | | freeDB.Update(TargetLocation); |
| | | } |
| | | } |
| | | } |
| | | } |
| | | } |
| | | catch (Exception ex) |
| | | { |
| | | |
| | | } |
| | | |
| | | } |
| | | |
| | | /// <summary> |
| | |
| | | return TargetLocation; |
| | | } |
| | | |
| | | private static dt_stationinfo GetEmptyLocation(Idt_stationinfoRepository stationinfoRepository) |
| | | { |
| | | dt_stationinfo TargetLocation = null; |
| | | List<string> target = new List<string>() { "W01001001", "W01001002", "W01001003" }; |
| | | foreach (var item in target) |
| | | { |
| | | TargetLocation = stationinfoRepository.FindFirst(x => x.stationCode == item && x.location_state == LocationStateEnum.Empty.ToString() && x.enable); |
| | | if (TargetLocation != null) continue; |
| | | } |
| | | |
| | | if (TargetLocation == null) |
| | | { |
| | | throw new Exception("å¤åå
¥åºå£å·²æ»¡"); |
| | | } |
| | | return TargetLocation; |
| | | } |
| | | /// <summary> |
| | | /// æ ¹æ®è®¢åæ°éè¿ååºåº(ææ¶å¼ç¨) //æ´æ¢ä¸ºåºä½ç±»åå¹é
|
| | | /// </summary> |
| | |
| | | const columns = ref([{field:'SN',title:'车轮SNå·',type:'string',width:220,align:'left',sort:true}, |
| | | {field:'Name',title:'产ååç§°',type:'string',width:220,align:'left'}, |
| | | {field:'FigureNumber',title:'产åå¾å·',type:'string',width:220,align:'left'}, |
| | | {field:'HearthNumber',title:'çç¼çå·',type:'string',width:220,align:'left'}, |
| | | {field:'area',title:'åºå代ç ',type:'string',width:220,align:'left'}, |
| | | {field:'HeatNumber',title:'ç代å·',type:'string',width:110,align:'left'}, |
| | | {field:'BilletNumber',title:'é¢å¯å·',type:'int',width:110,align:'left'}, |
| | | {field:'OnlineTime',title:'å
¥åºæ¶é´',type:'datetime',width:150,align:'left',sort:true}, |
| | |
| | | [{"title":"å¾å·","field":"stationType"}], |
| | | [{"dataKey":"location_states","data":[],"title":"è´§ä½ç¶æ","field":"location_state","type":"select"}], |
| | | [{"title":"车轮SNå·","field":"bindSN"}], |
| | | [{"dataKey":"tray_status","data":[],"title":"æçç¶æ","field":"tray_status","type":"select"}], |
| | | [{"dataKey":"tray_types","data":[],"title":"æçç±»å","field":"tray_type","type":"select"}], |
| | | [{"title":"å·¥åç¼å·","field":"Number"}], |
| | | [{"title":"çå·","field":"heatNumber","type":"text"}], |
| | | [{"title":"夿³¨","field":"remark"}]]); |
| | |
| | | // {field:'lastUpdateTime',title:'æåç¶ææ¹åæ¶é´',type:'datetime',width:150,align:'left',sort:true}, |
| | | {field:'quantity',title:'车轮æ°é',type:'int',width:80,align:'left'}, |
| | | {field:'bindSN',title:'车轮SNå·',type:'string',width:220,align:'left'}, |
| | | {field:'tray_status',title:'æçç±»å',type:'string',bind:{ key:'tray_status',data:[]},width:110,align:'left'}, |
| | | {field:'tray_status',title:'æçç¶æ',type:'string',bind:{ key:'tray_status',data:[]},width:110,align:'left'}, |
| | | {field:'tray_type',title:'æçç±»å',type:'string',bind:{ key:'tray_types',data:[]},width:110,align:'left'}, |
| | | // {field:'line',title:'è¡',type:'int',width:80,align:'left'}, |
| | | // {field:'column',title:'å',type:'int',width:80,align:'left'}, |
| | | {field:'heatNumber',title:'çå·',type:'int',width:80,align:'left'}, |
| | |
| | | [Column(TypeName = "nvarchar(50)")] |
| | | public string heatNumber { get; set; } |
| | | |
| | | |
| | | /// <summary> |
| | | ///æçç±»å |
| | | /// </summary> |
| | | [Display(Name = "æçç±»å")] |
| | | [MaxLength(100)] |
| | | [Column(TypeName = "nvarchar(100)")] |
| | | public string tray_type { get; set; } |
| | | } |
| | | } |
| | |
| | | /// <returns></returns> |
| | | public static dt_geometry_data QueryMateriel(string type) |
| | | { |
| | | var materielinfo = freeDB.Select<dt_geometry_data>().Where(x => x.Description.ToString() == type).First(); |
| | | var materielinfo = freeDB.Select<dt_geometry_data>().Where(x => x.Description == type).First(); |
| | | return materielinfo; |
| | | } |
| | | /// <summary> |
| | |
| | | station.heatNumber = saveModel.MainData["heatNumber"].ToString(); |
| | | station.Number = saveModel.MainData["Number"].ToString(); |
| | | station.remark = saveModel.MainData["remark"].ToString(); |
| | | station.tray_status= saveModel.MainData["tray_status"].ToString(); |
| | | station.tray_type = saveModel.MainData["tray_type"].ToString(); |
| | | if (list.Count == 0) |
| | | { |
| | | //station.tray_status = "EmptyTray"; |
| | | station.stationType = string.Empty; |
| | | station.heatNumber = string.Empty; |
| | | station.Number = string.Empty; |
| | | } |
| | | station.tray_status = list.Count == 0 ? "EmptyTray" : "StrogeTray"; |
| | | if (station.location_state == "Empty") |
| | | { |
| | | station.stationType = string.Empty; |
| | | station.heatNumber = string.Empty; |
| | | station.Number = string.Empty; |
| | | station.tray_status = string.Empty; |
| | | station.bindSN = string.Empty; |
| | | station.quantity = 0; |
| | | station.tray_type=string.Empty; |
| | | } |
| | | var count = _repository.Update(station, true); |
| | | if (count > 0) |
| | | webResponse.OK(); |