From 021ec32a095410d28d4552d7365ca64308494fa6 Mon Sep 17 00:00:00 2001
From: WINDOWS-F96JH03\Kain <MrTianDeLe@163.com>
Date: 星期二, 17 三月 2026 14:35:12 +0800
Subject: [PATCH] Merge branch 'master' of http://115.159.85.185:8098/r/RuiShiGe/LingPaoCheShenKu
---
项目代码/WCS/WCSServer/WIDESEAWCS_TaskInfoService/Partial/TaskService.cs | 14
项目代码/WCS/WCSServer/WIDESEAWCS_Model/Models/BasicInfo/Dt_StationManager.cs | 2
项目代码/WMS/WMSClient/src/router/tables.js | 7
项目代码/WMS/WMSServer/WIDESEA_IStorageBasicRepository/Stock/IStockInfoRepository.cs | 14
项目代码/WMS/WMSServer/WIDESEA_StorageTaskServices/AutoTask/BackgroundJob.cs | 50 -
项目代码/WMS/WMSServer/WIDESEA_StoragIntegrationServices/MES/Partial/PassPoint.cs | 2
项目代码/WCS/WCSServer/WIDESEAWCS_Tasks/ConveyorLineJob/CommonConveyorLineJob.cs | 29
项目代码/WCS/WCSServer/WIDESEAWCS_DTO/TaskInfo/WMSTaskDTO.cs | 2
项目代码/WMS/WMSServer/WIDESEA_Core/BaseModels/WebResponseContent.cs | 9
项目代码/WMS/WMSServer/WIDESEA_DTO/WMS/WMSTaskDTO.cs | 2
项目代码/WMS/WMSServer/WIDESEA_StorageBasicRepository/Stock/VV_MesLockInfoRepository.cs | 9
项目代码/WMS/WMSServer/WIDESEA_StoragIntegrationServices/WCS/Partial/RequestEmptyInboundRoadWayNo.cs | 100 ++++
项目代码/WMS/WMSServer/WIDESEA_Core/Enums/ManageEnum.cs | 38 -
项目代码/WMS/WMSServer/WIDESEA_Model/Models/Basic/Dt_Task.cs | 6
项目代码/WMS/WMSServer/WIDESEA_StoragIntegrationServices/MES/Partial/bindWorkOrder.cs | 2
项目代码/WMS/WMSServer/WIDESEA_StoragIntegrationServices/WCS/Partial/RequstCarBodyInfo.cs | 6
项目代码/WCS/WCSServer/WIDESEAWCS_Model/Models/TaskInfo/Dt_Task_Hty.cs | 9
项目代码/WCS/WCSServer/WIDESEAWCS_Common/Const/SysConfigKeyConst.cs | 2
项目代码/WMS/WMSServer/WIDESEA_IStorageBasicRepository/Stock/IVV_MesLockInfoRepository.cs | 6
项目代码/WMS/WMSServer/WIDESEA_StoragIntegrationServices/WCS/Partial/HZPassTZ.cs | 42 +
项目代码/WMS/WMSServer/WIDESEA_Model/Models/BasicModel/Stock/VV_StockInfo.cs | 19
项目代码/WMS/WMSClient/src/views/widesea_wms/stock/VV_MesLockInfo.vue | 95 ++++
项目代码/WMS/WMSServer/WIDESEA_StorageTaskServices/Task/Dt_TaskService.cs | 5
项目代码/WCS/WCSServer/WIDESEAWCS_Core/CodeGenerator/CodeGenertors.cs | 349 +++++++++++++++
项目代码/WMS/WMSServer/WIDESEA_StoragIntegrationServices/MES/Partial/issuedCharacter.cs | 4
项目代码/WMS/WMSServer/WIDESEA_StorageBasicServices/Stock/VV_MesLockInfoService.cs | 18
项目代码/WMS/WMSServer/WIDESEA_WMSServer/Controllers/Stock/VV_MesLockInfoController.cs | 14
项目代码/WMS/WMSServer/WIDESEA_WMSServer/Program.cs | 3
项目代码/WCS/WCSServer/WIDESEAWCS_Tasks/ConveyorLineJobTZ/CommonConveyorLineTZJob.cs | 4
项目代码/WMS/WMSServer/WIDESEA_Model/Models/BasicModel/Stock/VV_MesLockInfo.cs | 53 --
项目代码/WMS/WMSServer/WIDESEA_StoragIntegrationServices/WCS/Partial/RequestInboundRoadWayNo.cs | 12
项目代码/WCS/WCSServer/WIDESEAWCS_Tasks/SC/SCJob.cs | 4
项目代码/WMS/WMSServer/WIDESEA_StoragIntegrationServices/MES/Partial/removeWorkOrderInfo.cs | 2
项目代码/WMS/WMSServer/WIDESEA_StorageTaskServices/AutoTask/QuartzJobMildd.cs | 13
项目代码/WMS/WMSServer/WIDESEA_StorageTaskServices/Task/Partial/Dt_TaskService.cs | 17
项目代码/WMS/WMSClient/src/extension/widesea_wms/stock/VV_MesLockInfo.js | 60 ++
/dev/null | 6
项目代码/WCS/WCSServer/WIDESEAWCS_Server/Controllers/System/Sys_UserController.cs | 13
项目代码/WMS/WMSServer/WIDESEA_StoragIntegrationServices/WCS/Partial/TZPassZZ.cs | 2
项目代码/WCS/WCSServer/WIDESEAWCS_Model/Models/TaskInfo/Dt_Task.cs | 4
项目代码/WCS/WCSServer/WIDESEAWCS_TaskInfoService/TaskService.cs | 37 +
项目代码/WMS/WMSServer/WIDESEA_StorageTaskServices/AutoTask/WhiteCarAutoOutJob.cs | 186 ++++++++
项目代码/WMS/WMSServer/WIDESEA_IStorageBasicService/Stock/IVV_MesLockInfoService.cs | 5
43 files changed, 1,092 insertions(+), 184 deletions(-)
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Common/Const/SysConfigKeyConst.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Common/Const/SysConfigKeyConst.cs"
index 8f6427c..6f72559 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Common/Const/SysConfigKeyConst.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Common/Const/SysConfigKeyConst.cs"
@@ -62,6 +62,8 @@
public const string RequestWhiteBody = "RequestWhiteBody";
+ public const string RequestEmptyInboundRoadWayNo = "RequestEmptyInboundRoadWayNo";
+
/// <summary>
/// 妯Щ鏈哄彇鏂�
/// </summary>
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Core/CodeGenerator/CodeGenertors.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Core/CodeGenerator/CodeGenertors.cs"
new file mode 100644
index 0000000..43e3275
--- /dev/null
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Core/CodeGenerator/CodeGenertors.cs"
@@ -0,0 +1,349 @@
+锘縰sing System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Reflection;
+using System.Text;
+using System.Threading.Tasks;
+using SqlSugar;
+using WIDESEAWCS_Core.DB;
+using WIDESEAWCS_Core.Helper;
+
+namespace WIDESEAWCS_Core.CodeGenerator
+{
+ public class CodeGenertors
+ {
+ public static WebResponseContent CreateIRepository(string tableName, string module)
+ {
+ try
+ {
+ string startName = "WIDESEA";
+
+ string thisNameSpace = typeof(CodeGenertors).Namespace ?? "WIDESEA_";
+ int nameSpaceIndex = thisNameSpace.IndexOf("_");
+
+ if (nameSpaceIndex > -1)
+ {
+ startName = thisNameSpace.Substring(0, nameSpaceIndex);
+ }
+
+ List<Assembly> assemblies = App.Assemblies.ToList();
+ Assembly? assembly = assemblies.FirstOrDefault(x => x.GetName()?.Name?.Contains($"I{module}Repository") ?? false);
+ if (assembly == null)
+ {
+ return WebResponseContent.Instance.Error($"鏈壘鍒扮▼搴忛泦{startName}_I{module}Repository");
+ }
+
+ string? nameSpaceFullName = assembly.GetName()?.Name;
+ if (string.IsNullOrEmpty(nameSpaceFullName))
+ {
+ return WebResponseContent.Instance.Error($"{nameSpaceFullName} not found.");
+ }
+
+ int index = tableName.IndexOf("_");
+
+ string tableShortName = tableName;
+
+ if (index > -1)
+ {
+ tableShortName = tableName.Substring(index + 1);
+ }
+
+ string rootPath = App.WebHostEnvironment.WebRootPath;
+ string templatePath = Path.Combine(rootPath, $"CodeTemplate\\BaseIRepository.txt");
+
+ if (!File.Exists(templatePath))
+ {
+ return WebResponseContent.Instance.Error($"鏈壘鍒版ā鏉挎枃浠�");
+ }
+
+ string template = FileHelper.ReadFile(templatePath);
+
+ string classStr = template.Replace("[TableName]", tableName).Replace("[TableShortName]", tableShortName).Replace("[NameSpace]", nameSpaceFullName).Replace("[StartName]", startName).Replace("[Module]", module);
+
+ int rootPathIndex = App.HostEnvironment.ContentRootPath.LastIndexOf("\\");
+
+ string rootPaht = App.HostEnvironment.ContentRootPath.Substring(0, rootPathIndex - 1);
+
+ int rootPathIndex2 = rootPaht.LastIndexOf("\\");
+
+ string projectPath = Path.Combine(rootPaht.Substring(0, rootPathIndex2), nameSpaceFullName);
+
+ string filePath = Path.Combine(projectPath, $"I{tableShortName}Repository.cs");
+
+ FileHelper.WriteFileAndDelOldFile(filePath, classStr);
+
+ return WebResponseContent.Instance.OK();
+ }
+ catch (Exception ex)
+ {
+ return WebResponseContent.Instance.Error(ex.Message);
+ }
+ }
+
+ public static WebResponseContent CreateRepository(string tableName, string module)
+ {
+ try
+ {
+ string startName = "WIDESEA";
+
+ string thisNameSpace = typeof(CodeGenertors).Namespace ?? "WIDESEA_";
+ int nameSpaceIndex = thisNameSpace.IndexOf("_");
+
+ if (nameSpaceIndex > -1)
+ {
+ startName = thisNameSpace.Substring(0, nameSpaceIndex);
+ }
+
+ List<Assembly> assemblies = App.Assemblies.ToList();
+ Assembly? assembly = assemblies.FirstOrDefault(x => (x.GetName()?.Name?.Contains($"{module}Repository") ?? false) && (!x.GetName()?.Name?.Contains($"I{module}Repository") ?? false));
+ if (assembly == null)
+ {
+ return WebResponseContent.Instance.Error($"鏈壘鍒扮▼搴忛泦{startName}_{module}Repository");
+ }
+
+ string? nameSpaceFullName = assembly.GetName()?.Name;
+ if (string.IsNullOrEmpty(nameSpaceFullName))
+ {
+ return WebResponseContent.Instance.Error($"{nameSpaceFullName} not found.");
+ }
+
+ int index = tableName.IndexOf("_");
+
+ string tableShortName = tableName;
+
+ if (index > -1)
+ {
+ tableShortName = tableName.Substring(index + 1);
+ }
+
+ string rootPath = App.WebHostEnvironment.WebRootPath;
+ string templatePath = Path.Combine(rootPath, $"CodeTemplate\\BaseRepository.txt");
+
+ if (!File.Exists(templatePath))
+ {
+ return WebResponseContent.Instance.Error($"鏈壘鍒版ā鏉挎枃浠�");
+ }
+
+ string template = FileHelper.ReadFile(templatePath);
+
+ string classStr = template.Replace("[TableName]", tableName).Replace("[TableShortName]", tableShortName).Replace("[NameSpace]", nameSpaceFullName).Replace("[StartName]", startName).Replace("[Module]", module);
+
+ int rootPathIndex = App.HostEnvironment.ContentRootPath.LastIndexOf("\\");
+
+ string rootPaht = App.HostEnvironment.ContentRootPath.Substring(0, rootPathIndex - 1);
+
+ int rootPathIndex2 = rootPaht.LastIndexOf("\\");
+
+ string projectPath = Path.Combine(rootPaht.Substring(0, rootPathIndex2), nameSpaceFullName);
+
+ string filePath = Path.Combine(projectPath, $"{tableShortName}Repository.cs");
+
+ FileHelper.WriteFileAndDelOldFile(filePath, classStr);
+
+ return WebResponseContent.Instance.OK();
+ }
+ catch (Exception ex)
+ {
+ return WebResponseContent.Instance.Error(ex.Message);
+ }
+ }
+
+ public static WebResponseContent CreateIService(string tableName, string module)
+ {
+ try
+ {
+ string startName = "WIDESEA";
+
+ string thisNameSpace = typeof(CodeGenertors).Namespace ?? "WIDESEA_";
+ int nameSpaceIndex = thisNameSpace.IndexOf("_");
+
+ if (nameSpaceIndex > -1)
+ {
+ startName = thisNameSpace.Substring(0, nameSpaceIndex);
+ }
+
+ List<Assembly> assemblies = App.Assemblies.ToList();
+ Assembly? assembly = assemblies.FirstOrDefault(x => x.GetName()?.Name?.Contains($"I{module}Service") ?? false);
+ if (assembly == null)
+ {
+ return WebResponseContent.Instance.Error($"鏈壘鍒扮▼搴忛泦{startName}_I{module}Service");
+ }
+
+ string? nameSpaceFullName = assembly.GetName()?.Name;
+ if (string.IsNullOrEmpty(nameSpaceFullName))
+ {
+ return WebResponseContent.Instance.Error($"{nameSpaceFullName} not found.");
+ }
+
+ int index = tableName.IndexOf("_");
+
+ string tableShortName = tableName;
+
+ if (index > -1)
+ {
+ tableShortName = tableName.Substring(index + 1);
+ }
+
+ string rootPath = App.WebHostEnvironment.WebRootPath;
+ string templatePath = Path.Combine(rootPath, $"CodeTemplate\\BaseIService.txt");
+
+ if (!File.Exists(templatePath))
+ {
+ return WebResponseContent.Instance.Error($"鏈壘鍒版ā鏉挎枃浠�");
+ }
+
+ string template = FileHelper.ReadFile(templatePath);
+
+ string classStr = template.Replace("[TableName]", tableName).Replace("[TableShortName]", tableShortName).Replace("[NameSpace]", nameSpaceFullName).Replace("[StartName]", startName).Replace("[Module]", module);
+
+ int rootPathIndex = App.HostEnvironment.ContentRootPath.LastIndexOf("\\");
+
+ string rootPaht = App.HostEnvironment.ContentRootPath.Substring(0, rootPathIndex - 1);
+
+ int rootPathIndex2 = rootPaht.LastIndexOf("\\");
+
+ string projectPath = Path.Combine(rootPaht.Substring(0, rootPathIndex2), nameSpaceFullName);
+
+ string filePath = Path.Combine(projectPath, $"I{tableShortName}Service.cs");
+
+ FileHelper.WriteFileAndDelOldFile(filePath, classStr);
+
+ return WebResponseContent.Instance.OK();
+ }
+ catch (Exception ex)
+ {
+ return WebResponseContent.Instance.Error(ex.Message);
+ }
+ }
+
+ public static WebResponseContent CreateService(string tableName, string module)
+ {
+ try
+ {
+ string startName = "WIDESEA";
+
+ string thisNameSpace = typeof(CodeGenertors).Namespace ?? "WIDESEA_";
+ int nameSpaceIndex = thisNameSpace.IndexOf("_");
+
+ if (nameSpaceIndex > -1)
+ {
+ startName = thisNameSpace.Substring(0, nameSpaceIndex);
+ }
+
+ List<Assembly> assemblies = App.Assemblies.ToList();
+ Assembly? assembly = assemblies.FirstOrDefault(x => (x.GetName()?.Name?.Contains($"{module}Service") ?? false) && (!x.GetName()?.Name?.Contains($"I{module}Service") ?? false));
+ if (assembly == null)
+ {
+ return WebResponseContent.Instance.Error($"鏈壘鍒扮▼搴忛泦{startName}_{module}Service");
+ }
+
+ string? nameSpaceFullName = assembly.GetName()?.Name;
+ if (string.IsNullOrEmpty(nameSpaceFullName))
+ {
+ return WebResponseContent.Instance.Error($"{nameSpaceFullName} not found.");
+ }
+
+ int index = tableName.IndexOf("_");
+
+ string tableShortName = tableName;
+
+ if (index > -1)
+ {
+ tableShortName = tableName.Substring(index + 1);
+ }
+
+ string rootPath = App.WebHostEnvironment.WebRootPath;
+ string templatePath = Path.Combine(rootPath, $"CodeTemplate\\BaseService.txt");
+
+ if (!File.Exists(templatePath))
+ {
+ return WebResponseContent.Instance.Error($"鏈壘鍒版ā鏉挎枃浠�");
+ }
+
+ string template = FileHelper.ReadFile(templatePath);
+
+ string classStr = template.Replace("[TableName]", tableName).Replace("[TableShortName]", tableShortName).Replace("[NameSpace]", nameSpaceFullName).Replace("[StartName]", startName).Replace("[Module]", module);
+
+ int rootPathIndex = App.HostEnvironment.ContentRootPath.LastIndexOf("\\");
+
+ string rootPaht = App.HostEnvironment.ContentRootPath.Substring(0, rootPathIndex - 1);
+
+ int rootPathIndex2 = rootPaht.LastIndexOf("\\");
+
+ string projectPath = Path.Combine(rootPaht.Substring(0, rootPathIndex2), nameSpaceFullName);
+
+ string filePath = Path.Combine(projectPath, $"{tableShortName}Service.cs");
+
+ FileHelper.WriteFileAndDelOldFile(filePath, classStr);
+
+ return WebResponseContent.Instance.OK();
+ }
+ catch (Exception ex)
+ {
+ return WebResponseContent.Instance.Error(ex.Message);
+ }
+ }
+
+ public static WebResponseContent CreateController(string tableName, string module)
+ {
+ try
+ {
+ string startName = "WIDESEA";
+
+ string thisNameSpace = typeof(CodeGenertors).Namespace ?? "WIDESEA_";
+ int nameSpaceIndex = thisNameSpace.IndexOf("_");
+
+ if (nameSpaceIndex > -1)
+ {
+ startName = thisNameSpace.Substring(0, nameSpaceIndex);
+ }
+
+ List<Assembly> assemblies = App.Assemblies.ToList();
+ Assembly? assembly = assemblies.FirstOrDefault(x => (x.GetName()?.Name?.Contains($"{module}Service") ?? false) && (!x.GetName()?.Name?.Contains($"I{module}Service") ?? false));
+ if (assembly == null)
+ {
+ return WebResponseContent.Instance.Error($"鏈壘鍒扮▼搴忛泦{startName}_{module}Service");
+ }
+
+ string? nameSpaceFullName = assembly.GetName()?.Name;
+ if (string.IsNullOrEmpty(nameSpaceFullName))
+ {
+ return WebResponseContent.Instance.Error($"{nameSpaceFullName} not found.");
+ }
+
+ int index = tableName.IndexOf("_");
+
+ string tableShortName = tableName;
+
+ if (index > -1)
+ {
+ tableShortName = tableName.Substring(index + 1);
+ }
+
+ string rootPath = App.WebHostEnvironment.WebRootPath;
+ string templatePath = Path.Combine(rootPath, $"CodeTemplate\\BaseController.txt");
+
+ if (!File.Exists(templatePath))
+ {
+ return WebResponseContent.Instance.Error($"鏈壘鍒版ā鏉挎枃浠�");
+ }
+
+ string template = FileHelper.ReadFile(templatePath);
+
+ string classStr = template.Replace("[TableName]", tableName).Replace("[TableShortName]", tableShortName).Replace("[NameSpace]", nameSpaceFullName).Replace("[StartName]", startName).Replace("[Module]", module);
+
+ string projectPath = Path.Combine(App.HostEnvironment.ContentRootPath , $"Controllers\\{module}");
+
+ string filePath = Path.Combine(projectPath, $"{tableShortName}Controller.cs");
+
+ FileHelper.WriteFileAndDelOldFile(filePath, classStr);
+
+ return WebResponseContent.Instance.OK();
+ }
+ catch (Exception ex)
+ {
+ return WebResponseContent.Instance.Error(ex.Message);
+ }
+ }
+ }
+}
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_DTO/TaskInfo/WMSTaskDTO.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_DTO/TaskInfo/WMSTaskDTO.cs"
index 5fb8397..757089d 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_DTO/TaskInfo/WMSTaskDTO.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_DTO/TaskInfo/WMSTaskDTO.cs"
@@ -56,7 +56,7 @@
/// <summary>
/// 杞﹀瀷
/// </summary>
- public string CarType { get; set; }
+ public int CarType { get; set; }
public string PVI { get; set; }
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Model/Models/BasicInfo/Dt_StationManager.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Model/Models/BasicInfo/Dt_StationManager.cs"
index 4673c6c..fb3367c 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Model/Models/BasicInfo/Dt_StationManager.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Model/Models/BasicInfo/Dt_StationManager.cs"
@@ -33,7 +33,7 @@
public int stationID { get; set; }
/// <summary>
- /// 绔欏彴绫诲瀷 1-鍏ュ簱绔欏彴 2-鍑哄簱绔欏彴 3-寮傚父鎺掑嚭绔欏彴 4-杩囩偣绔欏彴 5-鎻愬崌鏈� 6-绌烘鍏ュ簱 7-绌烘鍑哄簱,8-鍏ュ簱绾夸綋鎵爜纭,9-鍏ュ簱绔欏彴纭
+ /// 绔欏彴绫诲瀷 1-鍏ュ簱绔欏彴 2-鍑哄簱绔欏彴 3-RB043绮炬帓杩囩偣 4-瑗夸晶妯Щ鏈� 5-鎻愬崌鏈� 6-绌烘鍏ュ簱 7-绌烘鍑哄簱,8-RB001鐧借溅韬帴杞� ,9-绌烘挰鍏ュ簱鍒ゆ柇 10-RB042绮炬帓鍒ゆ柇
/// </summary>
[ImporterHeader(Name = "绔欏彴绫诲瀷")]
[ExporterHeader(DisplayName = "绔欏彴绫诲瀷")]
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Model/Models/TaskInfo/Dt_Task.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Model/Models/TaskInfo/Dt_Task.cs"
index 3b412bc..a390978 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Model/Models/TaskInfo/Dt_Task.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Model/Models/TaskInfo/Dt_Task.cs"
@@ -152,8 +152,8 @@
/// <summary>
/// 杞﹀瀷
///</summary>
- [SugarColumn(ColumnName = "CarType", Length = 40, ColumnDescription = "杞﹀瀷")]
- public string CarType { get; set; }
+ [SugarColumn(ColumnName = "CarType", ColumnDescription = "杞﹀瀷")]
+ public int CarType { get; set; }
/// <summary>
/// 澶� 娉�:PVI鐮�
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Model/Models/TaskInfo/Dt_Task_Hty.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Model/Models/TaskInfo/Dt_Task_Hty.cs"
index 01aa968..4dd5490 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Model/Models/TaskInfo/Dt_Task_Hty.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Model/Models/TaskInfo/Dt_Task_Hty.cs"
@@ -150,14 +150,13 @@
public string Remark { get; set; }
/// <summary>
- /// 杞﹀瀷
+ /// 杞︾被鍨�
///</summary>
- [SugarColumn(ColumnName = "CarType", Length = 40, ColumnDescription = "杞﹀瀷")]
- public string CarType { get; set; }
+ [SugarColumn(ColumnName = "CarType", ColumnDescription = "杞︾被鍨�")]
+ public int CarType { get; set; }
/// <summary>
- /// 澶� 娉�:PVI鐮�
- /// 榛樿鍊�:
+ /// PVI鐮�
///</summary>
[SugarColumn(ColumnName = "PVI", Length = 30, IsNullable = true)]
public string PVI { get; set; }
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Server/Controllers/System/Sys_UserController.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Server/Controllers/System/Sys_UserController.cs"
index 4d1ac2b..5afd529 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Server/Controllers/System/Sys_UserController.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Server/Controllers/System/Sys_UserController.cs"
@@ -4,9 +4,11 @@
using Microsoft.AspNetCore.Mvc;
using Microsoft.Extensions.Caching.Memory;
using StackExchange.Profiling;
+using System.CodeDom.Compiler;
using WIDESEAWCS_Core;
using WIDESEAWCS_Core.Authorization;
using WIDESEAWCS_Core.BaseController;
+using WIDESEAWCS_Core.CodeGenerator;
using WIDESEAWCS_Core.Const;
using WIDESEAWCS_Core.Helper;
using WIDESEAWCS_Core.HttpContextUser;
@@ -90,5 +92,16 @@
}
}
+
+ [HttpPost, Route("CreateIRepository"), AllowAnonymous]
+ public WebResponseContent CreateIRepository(string tableName, string nameSpace)
+ {
+ CodeGenertors.CreateIRepository(tableName, nameSpace);
+ CodeGenertors.CreateRepository(tableName, nameSpace);
+ CodeGenertors.CreateIService(tableName, nameSpace);
+ CodeGenertors.CreateService(tableName, nameSpace);
+ CodeGenertors.CreateController(tableName, nameSpace);
+ return WebResponseContent.Instance.OK();
+ }
}
}
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_TaskInfoService/Partial/TaskService.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_TaskInfoService/Partial/TaskService.cs"
index f67b6cc..d5058ba 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_TaskInfoService/Partial/TaskService.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_TaskInfoService/Partial/TaskService.cs"
@@ -225,7 +225,19 @@
private async Task<WebResponseContent> RequestInRoadWayTask(string palletCode, string PVI, Dt_StationManager stationManager)
{
- var wmsIpAddrss = GetWmsIpAddress(SysConfigKeyConst.RequestInboundRoadWayNo);
+ var wmsIpAddrss = string.Empty;
+ if (stationManager.stationType == 5)
+ {
+ wmsIpAddrss = GetWmsIpAddress(SysConfigKeyConst.RequestInboundRoadWayNo);
+ }
+ else if (stationManager.stationType == 9)
+ {
+ wmsIpAddrss = GetWmsIpAddress(SysConfigKeyConst.RequestEmptyInboundRoadWayNo);
+ }
+
+ if (string.IsNullOrEmpty(wmsIpAddrss)) throw new Exception("鏈厤缃甒MS璇锋眰鍦板潃");
+
+ //var wmsIpAddrss = GetWmsIpAddress(SysConfigKeyConst.RequestInboundRoadWayNo);
var result = await HttpHelper.PostAsync(wmsIpAddrss, new { palletCode = palletCode, Roadways = stationManager.Roadway, area = stationManager.stationArea, Position = stationManager.stationChildCode, PVI = PVI }.ToJsonString());
return JsonConvert.DeserializeObject<WebResponseContent>(result);
}
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_TaskInfoService/TaskService.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_TaskInfoService/TaskService.cs"
index c2a3cde..cd6c629 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_TaskInfoService/TaskService.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_TaskInfoService/TaskService.cs"
@@ -105,7 +105,6 @@
List<Dt_Router> routers = _routerService.QueryNextRoutes(item.RoadWay, item.TargetAddress);
if (routers.Count > 0)
{
-
// 璁剧疆浠诲姟鐘舵�佷负鍑哄簱鏂板缓
task.TaskState = (int)TaskOutStatusEnum.OutNew;
// 璁剧疆褰撳墠鍦板潃涓烘簮鍦板潃
@@ -131,7 +130,6 @@
// 鍒ゆ柇浠诲姟绫诲瀷鏄惁涓哄叆搴撲换鍔�
else if (task.TaskType.GetTaskTypeGroup() == TaskTypeGroup.InboundGroup)
{
-
// 鏌ヨ浠庢簮鍦板潃鍒扮洰鏍囧湴鍧�鐨勮矾鐢�
List<Dt_Router> routers = _routerService.QueryNextRoutes(item.SourceAddress, item.TargetAddress);
if (routers.Count > 0)
@@ -667,18 +665,33 @@
if (task.TaskType.GetTaskTypeGroup() == TaskTypeGroup.OutbondGroup && task.TaskState == (int)TaskOutStatusEnum.SC_OutExecuting)
{
- var routers = _routerService.QueryNextRoutes(task.NextAddress, task.TargetAddress);
- if (!routers.Any()) return WebResponseContent.Instance.Error($"鏈壘鍒拌澶囪矾鐢变俊鎭�");
+ if(task.NextAddress == task.TargetAddress)
+ {
+ int nextStatus = task.TaskState.GetNextNotCompletedStatus<TaskOutStatusEnum>();
+ task.TaskState = nextStatus;
+ task.CurrentAddress = task.NextAddress;
+ task.NextAddress = task.NextAddress;
+ task.ModifyDate = DateTime.Now;
+ task.Modifier = "System";
- int nextStatus = task.TaskState.GetNextNotCompletedStatus<TaskOutStatusEnum>();
- task.TaskState = nextStatus;
- task.CurrentAddress = task.NextAddress;
- task.NextAddress = routers.FirstOrDefault().ChildPosi;
- task.ModifyDate = DateTime.Now;
- task.Modifier = "System";
- BaseDal.UpdateData(task);
+ }
+ else
+ {
- _taskExecuteDetailService.AddTaskExecuteDetail(task.TaskId, $"鍫嗗灈鏈哄嚭搴撳畬鎴�");
+ var routers = _routerService.QueryNextRoutes(task.NextAddress, task.TargetAddress);
+ if (!routers.Any()) return WebResponseContent.Instance.Error($"鏈壘鍒拌澶囪矾鐢变俊鎭�");
+
+ int nextStatus = task.TaskState.GetNextNotCompletedStatus<TaskOutStatusEnum>();
+ task.TaskState = nextStatus;
+ task.CurrentAddress = task.NextAddress;
+ task.NextAddress = routers.FirstOrDefault().ChildPosi;
+ task.ModifyDate = DateTime.Now;
+ task.Modifier = "System";
+ BaseDal.UpdateData(task);
+
+ _taskExecuteDetailService.AddTaskExecuteDetail(task.TaskId, $"鍫嗗灈鏈哄嚭搴撳畬鎴�");
+ }
+
//鏆備笉鑰冭檻澶氫釜鍑哄簱鍙�
}
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Tasks/ConveyorLineJob/CommonConveyorLineJob.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Tasks/ConveyorLineJob/CommonConveyorLineJob.cs"
index 30adf7f..6486ac6 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Tasks/ConveyorLineJob/CommonConveyorLineJob.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Tasks/ConveyorLineJob/CommonConveyorLineJob.cs"
@@ -115,19 +115,28 @@
var palletcode = conveyorLine.GetValue<ConveyorLineDBName, Int16>(ConveyorLineDBName.SkidNo, station.stationChildCode);
var pvi = conveyorLine.GetValue<ConveyorLineDBName, string>(ConveyorLineDBName.PVI, station.stationChildCode);
- WebResponseContent response = _taskService.RequestRoadWayTask(palletcode.ToString(), pvi, station).Result;
- if (response.Status)
+ if (station.stationModel == "1") //鐩撮�氭ā寮�
{
- var task = _taskService.QueryBarCodeConveyorLineTask(palletcode.ToString(), station.stationChildCode);
- if (task != null)
+ //todo BDC02杩囩偣 鐒婃秱缁戝畾
+ conveyorLine.SetValue<ConveyorLineDBName, Int16>(ConveyorLineDBName.Spare6, 2, station.stationChildCode);
+ conveyorLine.SetValue<ConveyorLineDBName, Int16>(ConveyorLineDBName.AllowRelease, 1, station.stationChildCode);
+ }
+ else //鍏ュ簱妯″紡
+ {
+ WebResponseContent response = _taskService.RequestRoadWayTask(palletcode.ToString(), pvi, station).Result;
+ if (response.Status)
{
- var stationInfo = _stationManagerRepository.QueryFirst(x => x.stationChildCode == task.NextAddress);
- conveyorLine.SetValue<ConveyorLineDBName, Int16>(ConveyorLineDBName.Spare6, 3, station.stationChildCode);
- Thread.Sleep(300);
- conveyorLine.SetValue<ConveyorLineDBName, Int16>(ConveyorLineDBName.Spare5, Convert.ToInt16(stationInfo.stationTCLocation), station.stationChildCode);
- conveyorLine.SetValue<ConveyorLineDBName, Int16>(ConveyorLineDBName.AllowRelease, 1, station.stationChildCode);
+ var task = _taskService.QueryBarCodeConveyorLineTask(palletcode.ToString(), station.stationChildCode);
+ if (task != null)
+ {
+ var stationInfo = _stationManagerRepository.QueryFirst(x => x.stationChildCode == task.NextAddress);
+ conveyorLine.SetValue<ConveyorLineDBName, Int16>(ConveyorLineDBName.Spare6, 3, station.stationChildCode);
+ Thread.Sleep(300);
+ conveyorLine.SetValue<ConveyorLineDBName, Int16>(ConveyorLineDBName.Spare5, Convert.ToInt16(stationInfo.stationTCLocation), station.stationChildCode);
+ conveyorLine.SetValue<ConveyorLineDBName, Int16>(ConveyorLineDBName.AllowRelease, 1, station.stationChildCode);
- _taskService.UpdateTaskStatusToNext(task);
+ _taskService.UpdateTaskStatusToNext(task);
+ }
}
}
}
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Tasks/ConveyorLineJobTZ/CommonConveyorLineTZJob.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Tasks/ConveyorLineJobTZ/CommonConveyorLineTZJob.cs"
index c7ecc34..6961bb9 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Tasks/ConveyorLineJobTZ/CommonConveyorLineTZJob.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Tasks/ConveyorLineJobTZ/CommonConveyorLineTZJob.cs"
@@ -233,7 +233,7 @@
}
}
- if (station.stationType == 6) // 绌烘粦姗囧叆搴�
+ if (station.stationType == 9) // 绌烘粦姗囧叆搴�
{
var requestInbound = conveyorLine.GetValue<ConveyorLineDBName, bool>(ConveyorLineDBName.EntApply, station.stationChildCode);
if (requestInbound)
@@ -241,7 +241,7 @@
var palletcode = conveyorLine.GetValue<ConveyorLineDBName, Int16>(ConveyorLineDBName.SkidNo, station.stationChildCode);
//var pvi = conveyorLine.GetValue<ConveyorLineDBName, string>(ConveyorLineDBName.PVI, station.stationChildCode);
- WebResponseContent response = _taskService.RequestTask(palletcode.ToString(), palletcode.ToString(), station).Result;
+ WebResponseContent response = _taskService.RequestRoadWayTask(palletcode.ToString(), palletcode.ToString(), station).Result;
if (!response.Status)
{
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Tasks/SC/SCJob.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Tasks/SC/SCJob.cs"
index 4bca260..48ff77f 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Tasks/SC/SCJob.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WCSServer/WIDESEAWCS_Tasks/SC/SCJob.cs"
@@ -69,9 +69,7 @@
List<string> childCodes = commonStackerCrane.DeviceProDTOs.GroupBy(d => d.DeviceChildCode).Select(g => g.Key).ToList();
Parallel.For(0, childCodes.Count, (i, state) =>
{
-
//ConsoleHelper.WriteColorLine($"銆恵childCodes[i]}銆戞椂闂淬�恵DateTime.Now}銆戙�戙�恵Thread.CurrentThread.ManagedThreadId}銆�", ConsoleColor.Magenta);
-
if (commonStackerCrane.GetValue<StackerCraneDBName, Int16>(StackerCraneDBName.TaskState, childCodes[i]) == 2)
{
int taskNum = commonStackerCrane.GetValue<StackerCraneDBName, int>(StackerCraneDBName.TaskNum, childCodes[i]);
@@ -144,8 +142,6 @@
//StackerExecutor.SendStackerTask(commonStackerCrane, task, childCodes[i]);
//bool sendFlag = commonStackerCrane.SendCommand(stackerCraneTaskCommand, childCodes[i]);
//commonStackerCrane.LastTaskType = task.TaskType;
-
-
}
//}
}
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSClient/src/extension/widesea_wms/stock/VV_MesLockInfo.js" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSClient/src/extension/widesea_wms/stock/VV_MesLockInfo.js"
new file mode 100644
index 0000000..be9d735
--- /dev/null
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSClient/src/extension/widesea_wms/stock/VV_MesLockInfo.js"
@@ -0,0 +1,60 @@
+
+let extension = {
+ components: {
+ //鏌ヨ鐣岄潰鎵╁睍缁勪欢
+ gridHeader: '',
+ gridBody: '',
+ gridFooter: '',
+ //鏂板缓銆佺紪杈戝脊鍑烘鎵╁睍缁勪欢
+ modelHeader: '',
+ modelBody: '',
+ modelFooter: ''
+ },
+ tableAction: '', //鎸囧畾鏌愬紶琛ㄧ殑鏉冮檺(杩欓噷濉啓琛ㄥ悕,榛樿涓嶇敤濉啓)
+ buttons: { view: [], box: [], detail: [] }, //鎵╁睍鐨勬寜閽�
+ methods: {
+ //涓嬮潰杩欎簺鏂规硶鍙互淇濈暀涔熷彲浠ュ垹闄�
+ onInit() {
+ //妗嗘灦鍒濆鍖栭厤缃墠锛�
+ //璁剧疆鏌ヨ鐣岄潰寮瑰嚭妗嗙殑label瀹藉害
+ },
+ onInited() {
+ //妗嗘灦鍒濆鍖栭厤缃悗
+ //濡傛灉瑕侀厤缃槑缁嗚〃,鍦ㄦ鏂规硶鎿嶄綔
+ //this.detailOptions.columns.forEach(column=>{ });
+ },
+ searchBefore(param) {
+ //鐣岄潰鏌ヨ鍓�,鍙互缁檖aram.wheres娣诲姞鏌ヨ鍙傛暟
+ //杩斿洖false锛屽垯涓嶄細鎵ц鏌ヨ
+ return true;
+ },
+ searchAfter(result) {
+ //鏌ヨ鍚庯紝result杩斿洖鐨勬煡璇㈡暟鎹�,鍙互鍦ㄦ樉绀哄埌琛ㄦ牸鍓嶅鐞嗚〃鏍肩殑鍊�
+ return true;
+ },
+ addBefore(formData) {
+ //鏂板缓淇濆瓨鍓峟ormData涓哄璞★紝鍖呮嫭鏄庣粏琛紝鍙互缁欑粰琛ㄥ崟璁剧疆鍊硷紝鑷繁杈撳嚭鐪媐ormData鐨勫��
+ return true;
+ },
+ updateBefore(formData) {
+ //缂栬緫淇濆瓨鍓峟ormData涓哄璞★紝鍖呮嫭鏄庣粏琛ㄣ�佸垹闄よ鐨処d
+ return true;
+ },
+ addrow() {
+ return true;
+ },
+ rowClick({ row, column, event }) {
+ //鏌ヨ鐣岄潰鐐瑰嚮琛屼簨浠�
+ //this.$refs.table.$refs.table.toggleRowSelection(row); //鍗曞嚮琛屾椂閫変腑褰撳墠琛�;
+ },
+ modelOpenAfter(row) {
+ //鐐瑰嚮缂栬緫銆佹柊寤烘寜閽脊鍑烘鍚庯紝鍙互鍦ㄦ澶勫啓閫昏緫锛屽锛屼粠鍚庡彴鑾峰彇鏁版嵁
+ //(1)鍒ゆ柇鏄紪杈戣繕鏄柊寤烘搷浣滐細 this.currentAction=='Add';
+ //(2)缁欏脊鍑烘璁剧疆榛樿鍊�
+ //(3)this.editFormFields.瀛楁='xxx';
+ //濡傛灉闇�瑕佺粰涓嬫媺妗嗚缃粯璁ゅ�硷紝璇烽亶鍘唗his.editFormOptions鎵惧埌瀛楁閰嶇疆瀵瑰簲data灞炴�х殑key鍊�
+ //鐪嬩笉鎳傚氨鎶婅緭鍑虹湅锛歝onsole.log(this.editFormOptions)
+ }
+ }
+};
+export default extension;
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSClient/src/router/tables.js" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSClient/src/router/tables.js"
index 15dabce..1dbbe34 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSClient/src/router/tables.js"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSClient/src/router/tables.js"
@@ -322,6 +322,13 @@
// meta: {
// keepAlive: true
// }
+ },{
+ path: '/VV_MesLockInfo',
+ name: 'VV_MesLockInfo',
+ component: () => import('@/views/widesea_wms/stock/VV_MesLockInfo.vue'),
+ // meta: {
+ // keepAlive: true
+ // }
},
]
export default tables
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSClient/src/views/widesea_wms/stock/VV_MesLockInfo.vue" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSClient/src/views/widesea_wms/stock/VV_MesLockInfo.vue"
new file mode 100644
index 0000000..9bbb147
--- /dev/null
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSClient/src/views/widesea_wms/stock/VV_MesLockInfo.vue"
@@ -0,0 +1,95 @@
+<!--
+*Author锛歫xx
+ *Contact锛�283591387@qq.com
+ *浠g爜鐢辨鏋剁敓鎴�,浠讳綍鏇存敼閮藉彲鑳藉鑷磋浠g爜鐢熸垚鍣ㄨ鐩�
+ *涓氬姟璇峰湪@/extension/widesea_wms/invoices/Dt_InboundOrder.js姝ゅ缂栧啓
+ -->
+<template>
+ <view-grid ref="grid" :columns="columns" :detail="detail" :editFormFields="editFormFields"
+ :editFormOptions="editFormOptions" :searchFormFields="searchFormFields" :searchFormOptions="searchFormOptions"
+ :table="table" :extend="extend">
+ </view-grid>
+</template>
+<script>
+import extend from "@/extension/widesea_wms/stock/VV_MesLockInfo.js";
+import { ref, defineComponent } from "vue";
+export default defineComponent({
+ setup() {
+ const table = ref({
+ key: 'id',
+ footer: "Foots",
+ cnName: '閿佽溅闃熷垪淇℃伅',
+ name: 'stock/VV_MesLockInfo',
+ url: "/VV_MesLockInfo/",
+ sortName: "id"
+ });
+ const editFormFields = ref({
+ });
+ const editFormOptions = ref([
+ ]);
+ const searchFormFields = ref({
+ locationCode: "",
+ palletCode: ""
+ });
+ const searchFormOptions = ref([
+ [
+ { "title": "婊戞﹪鍙�", "field": "palletCode", type: "text" },
+ { "title": "搴撲綅鍙�", "field": "locationCode", type: "text" },
+ { "title": "閿佸畾鐘舵��", "field": "stockStatus", type: "select", dataKey: "BodyStatus", data: [] },
+ { "title": "鎷夊姩閿佸畾", "field": "lockOrder", type: "select", dataKey: "LockStatus", data: [] },
+ ],
+ [
+ { "title": "杞﹁韩ID", "field": "carBodyID", type: "int" },
+ { "title": "PVI", "field": "pvi", type: "string" },
+ { "title": "宸烽亾鍙�", "field": "roadwayNo", type: "int" },
+ { "title": "浠诲姟鐘舵��", "field": "taskStatus", type: "select", dataKey: "TaskInfoStatus", data: [] },
+ ],
+ [
+ { "title": "杞﹁韩绫诲瀷", "field": "carType", type: "select", dataKey: "BodyType", data: [] },
+ { "title": "鐧借溅韬墿鏂欏彿", "field": "biwMaterialCode", type: "int" },
+ { "title": "褰╄溅韬墿鏂欏彿", "field": "pbMaterial", type: "string" },
+ ],
+ [
+ { "title": "杞﹁韩棰滆壊", "field": "carBodyCharacteristic", type: "string" },
+ { "title": "澶╃獥鐗瑰緛", "field": "skylightCharacteristic", type: "string" },
+ { "title": "杞﹀瀷", "field": "vehicleCharacteristic", type: "string" },
+ ]
+ ]);
+ const columns = ref([
+ { field: 'id', title: '涓婚敭ID', type: 'int', width: 110, readonly: true, hidden: true, require: true, align: 'left' },
+ { field: 'lockStatue', title: '鎷夊姩鐘舵��', type: 'string', width: 60, align: 'left' },
+ { field: 'tcLine', title: '妯Щ鏈轰骇绾�', type: 'int', width: 100, align: 'left' },
+ { field: 'sequenceNo', title: '椤哄簭鍙�', type: 'int', width: 120, align: 'left' },
+ { field: 'carBodyID', title: '杞﹁韩ID', type: 'string', width: 75, align: 'left' },
+ { field: 'pvi', title: 'PVI鐮�', type: 'int', width: 80, align: 'left' },
+ { field: 'palletCode', title: '婊戞﹪鍙�', type: 'string', width: 100, align: 'left' },
+ { field: 'vehicleCharacteristic', title: '杞﹀瀷', type: 'string', width: 75, align: 'left' },
+ { field: 'carType', title: '杞﹁韩绫诲瀷', type: 'string', width: 75, align: 'left' , bind: { key: "BodyType", data: [] } },
+ { field: 'workOrderType', title: '璁㈠崟鐘舵��', type: 'string', width: 110, align: 'left' },
+ { field: 'skylightCharacteristic', title: '澶╃獥鐗瑰緛', type: 'string', width: 110, align: 'left' },
+ { field: 'carBodyCharacteristic', title: '杞﹁韩棰滆壊', type: 'datetime', width: 130, align: 'left' },
+ { field: 'biwMaterialCode', title: '鐧借溅韬墿鏂欏彿', type: 'string', width: 80, align: 'left'},
+ { field: 'pbMaterial', title: '褰╄溅韬墿鏂欏彿', type: 'int', width: 75, align: 'left'},
+ { field: 'biwInPassTime', title: '鐒婅涓婄嚎鏃堕棿', type: 'string', width: 80, align: 'left' },
+ ]);
+
+ const detail = ref({
+ cnName: "#detailCnName",
+ table: "#detailTable",
+ columns: [],
+ sortName: "",
+ key: ""
+ });
+ return {
+ table,
+ extend,
+ editFormFields,
+ editFormOptions,
+ searchFormFields,
+ searchFormOptions,
+ columns,
+ detail,
+ };
+ },
+});
+</script>
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_Core/BaseModels/WebResponseContent.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_Core/BaseModels/WebResponseContent.cs"
index 6bf7b03..a44ce01 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_Core/BaseModels/WebResponseContent.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_Core/BaseModels/WebResponseContent.cs"
@@ -71,5 +71,14 @@
Data = data;
return this;
}
+
+ public WebResponseContent Error(int code, string message = null)
+ {
+ Status = false;
+ Message = message;
+ msg = message;
+ Code = code;
+ return this;
+ }
}
}
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_Core/Enums/ManageEnum.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_Core/Enums/ManageEnum.cs"
index d2322cc..aa5863c 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_Core/Enums/ManageEnum.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_Core/Enums/ManageEnum.cs"
@@ -147,18 +147,6 @@
/// </summary>
[Description("NG鍏ュ簱")]
InNG = 205,
-
- /// <summary>
- /// 杞﹁疆鍏ュ簱
- /// </summary>
- [Description("杞﹁疆鍏ュ簱")]
- InWheels = 206,
-
- /// <summary>
- /// 鍒跺姩鐩樺叆搴�
- /// </summary>
- [Description("鍒跺姩鐩樺叆搴�")]
- InBrake = 207,
}
public enum TaskOutboundTypeEnum
@@ -204,18 +192,6 @@
/// </summary>
[Description("鐩存帴鍑哄簱")]
InToOut = 106,
-
- /// <summary>
- /// 杞﹁疆鍑哄簱
- /// </summary>
- [Description("杞﹁疆鍏ュ簱")]
- OutWheels = 107,
-
- /// <summary>
- /// 鍒跺姩鐩樺嚭搴�
- /// </summary>
- [Description("鍒跺姩鐩樺嚭搴�")]
- OutBrake = 108,
}
public enum TaskRelocationTypeEnum
@@ -429,14 +405,14 @@
/// <summary>
/// 璁惧娴嬮噺涓�
/// </summary>
- [Description("璁惧娴嬮噺涓�")]
- Lien_Check = 150,
+ //[Description("璁惧娴嬮噺涓�")]
+ //Lien_Check = 150,
- /// <summary>
- /// 璁惧娴嬮噺瀹屾垚
- /// </summary>
- [Description("璁惧娴嬮噺瀹屾垚")]
- Lien_CheckFinish = 155,
+ ///// <summary>
+ ///// 璁惧娴嬮噺瀹屾垚
+ ///// </summary>
+ //[Description("璁惧娴嬮噺瀹屾垚")]
+ //Lien_CheckFinish = 155,
/// <summary>
/// 鍑哄簱浠诲姟瀹屾垚
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_DTO/WMS/WMSTaskDTO.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_DTO/WMS/WMSTaskDTO.cs"
index 1d25868..058e70f 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_DTO/WMS/WMSTaskDTO.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_DTO/WMS/WMSTaskDTO.cs"
@@ -55,6 +55,8 @@
public int Grade { get; set; }
public string pvi { get; set; }
+
+ public int CarType { get; set; }
public string NextAddress { get; set; }
}
}
\ No newline at end of file
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_IStorageBasicRepository/Stock/IStockInfoRepository - \345\244\215\345\210\266.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_IStorageBasicRepository/Stock/IStockInfoRepository - \345\244\215\345\210\266.cs"
deleted file mode 100644
index 23c73b4..0000000
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_IStorageBasicRepository/Stock/IStockInfoRepository - \345\244\215\345\210\266.cs"
+++ /dev/null
@@ -1,6 +0,0 @@
-锘縩amespace WIDESEA_IStorageBasicRepository
-{
- public interface IStockInfoRepository : IRepository<DtStockInfo>
- {
- }
-}
\ No newline at end of file
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_IStorageBasicRepository/Stock/IStockInfoRepository.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_IStorageBasicRepository/Stock/IStockInfoRepository.cs"
new file mode 100644
index 0000000..1d89c9c
--- /dev/null
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_IStorageBasicRepository/Stock/IStockInfoRepository.cs"
@@ -0,0 +1,14 @@
+锘縰sing System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+using WIDESEA_Core.BaseRepository;
+using WIDESEA_Model.Models;
+
+namespace WIDESEA_IStorageBasicRepository
+{
+ public interface IStockInfoRepository : IRepository<DtStockInfo>
+ {
+ }
+}
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_IStorageBasicRepository/Stock/IVV_MesLockInfoRepository.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_IStorageBasicRepository/Stock/IVV_MesLockInfoRepository.cs"
new file mode 100644
index 0000000..7918dfb
--- /dev/null
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_IStorageBasicRepository/Stock/IVV_MesLockInfoRepository.cs"
@@ -0,0 +1,6 @@
+锘縩amespace WIDESEA_IStorageBasicRepository
+{
+ public interface IVV_MesLockInfoRepository : IRepository<VV_MesLockInfo>
+ {
+ }
+}
\ No newline at end of file
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_IStorageBasicService/Stock/IVV_MesLockInfoService.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_IStorageBasicService/Stock/IVV_MesLockInfoService.cs"
new file mode 100644
index 0000000..00c5a6e
--- /dev/null
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_IStorageBasicService/Stock/IVV_MesLockInfoService.cs"
@@ -0,0 +1,5 @@
+锘縩amespace WIDESEA_IStorageBasicService;
+
+public interface IVV_MesLockInfoService : IService<VV_MesLockInfo>
+{
+}
\ No newline at end of file
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_Model/Models/Basic/Dt_Task.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_Model/Models/Basic/Dt_Task.cs"
index 3c821e6..63ee0aa 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_Model/Models/Basic/Dt_Task.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_Model/Models/Basic/Dt_Task.cs"
@@ -123,7 +123,11 @@
[SugarColumn(ColumnName = "ErrorMessage", Length = 100, IsNullable = true)]
public string? ErrorMessage { get; set; }
-
+ /// <summary>
+ /// 杞﹀瀷
+ ///</summary>
+ [SugarColumn(ColumnName = "CarType", ColumnDescription = "杞﹀瀷")]
+ public int CarType { get; set; }
/// <summary>
/// 浠诲姟鎵ц鏄庣粏
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_Model/Models/BasicModel/Stock/VV_MesLockInfo.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_Model/Models/BasicModel/Stock/VV_MesLockInfo.cs"
index 29d2e2d..91468ac 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_Model/Models/BasicModel/Stock/VV_MesLockInfo.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_Model/Models/BasicModel/Stock/VV_MesLockInfo.cs"
@@ -70,21 +70,6 @@
[SugarColumn(IsNullable = true, ColumnDescription = "椤哄簭鍙�")]
public int sequenceNo { get; set; }
- /// <summary>
- /// 鎵�灞炲贩閬�
- /// </summary>
- [ImporterHeader(Name = "鎵�灞炲贩閬�")]
- [ExporterHeader(DisplayName = "鎵�灞炲贩閬�")]
- [SugarColumn(IsNullable = true, Length = 20, ColumnDescription = "鎵�灞炲贩閬�")]
- public string RoadwayNo { get; set; }
-
- /// <summary>
- /// 璐т綅缂栧彿
- /// </summary>
- [ImporterHeader(Name = "璐т綅缂栧彿")]
- [ExporterHeader(DisplayName = "璐т綅缂栧彿")]
- [SugarColumn(IsNullable = true, Length = 20, ColumnDescription = "璐т綅缂栧彿")]
- public string LocationCode { get; set; }
/// <summary>
/// 杞﹁韩ID
@@ -118,7 +103,7 @@
public string vehicleCharacteristic { get; set; }
/// <summary>
- /// 杞﹁韩绫诲瀷 1-鐧� 2-褰� 3-绌烘粦姗� 4-绌烘挰缁�
+ /// 杞﹁韩绫诲瀷 1-鐧� 2-褰� 3-绌烘挰缁� 4-绌烘粦姗�
/// </summary>
[ImporterHeader(Name = "杞﹁韩绫诲瀷")]
[ExporterHeader(DisplayName = "杞﹁韩绫诲瀷")]
@@ -174,43 +159,15 @@
public DateTime? biwInPassTime { get; set; }
/// <summary>
- /// 閿佸畾鐘舵�� 0-鏈攣瀹� 1-閿佸畾
- /// </summary>
- [ImporterHeader(Name = "閿佸畾鐘舵��")]
- [ExporterHeader(DisplayName = "閿佸畾鐘舵��")]
- [SugarColumn(IsNullable = true, ColumnDescription = "閿佸畾鐘舵��")]
- public int StockStatus { get; set; }
-
- /// <summary>
- /// 鎷夊姩閿佸畾 0-鏈媺鍔� 1-鎷夊姩
- /// </summary>
- [ImporterHeader(Name = "鎷夊姩閿佸畾")]
- [ExporterHeader(DisplayName = "鎷夊姩閿佸畾")]
- [SugarColumn(IsNullable = true, ColumnDescription = "鎷夊姩閿佸畾")]
- public int LockOrder { get; set; }
-
- /// <summary>
- /// 浠诲姟鐘舵�� 0-鏃犱换鍔� 1-浠诲姟涓�
- /// </summary>
- [ImporterHeader(Name = "浠诲姟鐘舵��")]
- [ExporterHeader(DisplayName = "浠诲姟鐘舵��")]
- [SugarColumn(IsNullable = true, ColumnDescription = "浠诲姟鐘舵��")]
- public int TaskStatus { get; set; }
-
- /// <summary>
- /// 淇濈暀鐘舵��
- /// </summary>
- [ImporterHeader(Name = "淇濈暀鐘舵��")]
- [ExporterHeader(DisplayName = "淇濈暀鐘舵��")]
- [SugarColumn(IsNullable = true, ColumnDescription = "淇濈暀鐘舵��")]
- public int StayStatus { get; set; }
-
- /// <summary>
/// 鎵�灞炲伐鍗�(棰勭粦瀹�)
/// </summary>
//[ImporterHeader(Name = "鎵�灞炲伐鍗�")]
//[ExporterHeader(DisplayName = "鎵�灞炲伐鍗�")]
//[SugarColumn(IsNullable = true, Length = 20, ColumnDescription = "鎵�灞炲伐鍗�")]
//public string OrderID { get; set; }
+
+
+
+
}
}
\ No newline at end of file
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_Model/Models/BasicModel/Stock/VV_StockInfo.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_Model/Models/BasicModel/Stock/VV_StockInfo.cs"
index 59d38a5..0e195ff 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_Model/Models/BasicModel/Stock/VV_StockInfo.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_Model/Models/BasicModel/Stock/VV_StockInfo.cs"
@@ -68,7 +68,7 @@
public string vehicleCharacteristic { get; set; }
/// <summary>
- /// 杞﹁韩绫诲瀷 1-鐧� 2-褰� 3-绌烘粦姗� 4-绌烘挰缁�
+ /// 杞﹁韩绫诲瀷 1-鐧� 2-褰� 3-绌烘粦姗�
/// </summary>
[ImporterHeader(Name = "杞﹁韩绫诲瀷")]
[ExporterHeader(DisplayName = "杞﹁韩绫诲瀷")]
@@ -162,5 +162,22 @@
//[ExporterHeader(DisplayName = "鎵�灞炲伐鍗�")]
//[SugarColumn(IsNullable = true, Length = 20, ColumnDescription = "鎵�灞炲伐鍗�")]
//public string OrderID { get; set; }
+
+ /// <summary>
+ /// 鍒涘缓鑰�
+ /// </summary>
+ [ImporterHeader(Name = "鍒涘缓鑰�")]
+ [ExporterHeader(DisplayName = "鍒涘缓鑰�")]
+ [SugarColumn(IsNullable = false, IsOnlyIgnoreUpdate = true, ColumnDescription = "鍒涘缓鑰�")]
+ public string Creater { get; set; } = "Systeam";
+
+ /// <summary>
+ /// 鍒涘缓鏃堕棿
+ /// </summary>
+ [ImporterHeader(Name = "鍒涘缓鏃堕棿")]
+ [ExporterHeader(DisplayName = "鍒涘缓鏃堕棿")]
+ [SugarColumn(IsNullable = false, IsOnlyIgnoreUpdate = true, ColumnDescription = "鍒涘缓鏃堕棿")]
+ public DateTime CreateDate { get; set; } //= DateTime.Now;
+
}
}
\ No newline at end of file
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/MES/Partial/PassPoint.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/MES/Partial/PassPoint.cs"
index c5ede92..f116670 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/MES/Partial/PassPoint.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/MES/Partial/PassPoint.cs"
@@ -45,7 +45,7 @@
PassPointInfo passPoint = new PassPointInfo()
{
union_key = Guid.NewGuid().ToString(),
- line_code = stationInfo.stationEquipMES, //todo 闇�鏇挎崲鎴愮偣浣嶄俊鎭椂瀵瑰簲MES鐐逛綅
+ line_code = stationInfo.stationEquipMES,
message_time = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss"),
plant_code = "1052",
pvi = json.PVI,
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/MES/Partial/bindWorkOrder.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/MES/Partial/bindWorkOrder.cs"
index bec3d27..9d9d021 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/MES/Partial/bindWorkOrder.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/MES/Partial/bindWorkOrder.cs"
@@ -91,7 +91,7 @@
}
LogFactory.GetLog("BDC璇锋眰缁戝畾宸ュ崟淇℃伅").Info(true, $"\r\r--------------------------------------");
- LogFactory.GetLog("BDC璇锋眰缁戝畾宸ュ崟淇℃伅").Info(true, $"宸ヤ綅鍙�:{stationNo},RFID:{rfid}");
+ LogFactory.GetLog("BDC璇锋眰缁戝畾宸ュ崟淇℃伅").Info(true, $"宸ヤ綅鍙�:{stationNo},RFID:{rfid},鍝嶅簲淇℃伅锛歿webResponse.ToJson()}");
_unitOfWorkManage.CommitTran();
return content.OK();
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/MES/Partial/issuedCharacter.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/MES/Partial/issuedCharacter.cs"
index e48b6ee..2a955db 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/MES/Partial/issuedCharacter.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/MES/Partial/issuedCharacter.cs"
@@ -74,14 +74,14 @@
_carBodyRepository.AddData(CarBody);
LogFactory.GetLog("璇锋眰鐒婅鐗瑰緛淇℃伅").Info(true, $"\r\r--------------------------------------");
- LogFactory.GetLog("璇锋眰鐒婅鐗瑰緛淇℃伅").Info(true, $"宸ヤ綅鍙�:{stationNo},RFID:{rfidPrint}");
+ LogFactory.GetLog("璇锋眰鐒婅鐗瑰緛淇℃伅").Info(true, $"宸ヤ綅鍙�:{stationNo},RFID:{rfidPrint},鍝嶅簲淇℃伅:{webResponse.ToJson()}");
return content.OK("鑾峰彇鐒婅鐧借溅韬俊鎭垚鍔�");
}
catch (Exception ex)
{
- LogFactory.GetLog("璇锋眰鐒婅鐗瑰緛淇℃伅").Info(true, $"璇锋眰鐒婅鐗瑰緛淇℃伅寮傚父锛�:{ex.Message}");
+ LogFactory.GetLog("璇锋眰鐒婅鐗瑰緛淇℃伅").Info(true, $"璇锋眰鐒婅鐗瑰緛淇℃伅寮傚父RFID:{rfidPrint}寮傚父淇℃伅:{ex.Message}");
return content.Error($"璇锋眰鐒婅鐗瑰緛淇℃伅寮傚父锛�:{ex.Message}");
}
}
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/MES/Partial/removeWorkOrderInfo.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/MES/Partial/removeWorkOrderInfo.cs"
index 06f4032..846e291 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/MES/Partial/removeWorkOrderInfo.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/MES/Partial/removeWorkOrderInfo.cs"
@@ -45,7 +45,7 @@
var orderinfo = _assemblyOrderInfoRepository.QueryFirst(x => x.workOrderNo == item.workOrderNo && x.orderType == item.orderType);
if (orderinfo == null) throw new Exception($"鏈壘鍒板伐鍗曞彿{item.workOrderNo}宸ュ崟绫诲瀷涓簕item.orderType}鐨勬�昏宸ュ崟");
- if (!string.IsNullOrEmpty(orderinfo.pvi)) throw new Exception($"鎬昏宸ュ崟鍙穥item.workOrderNo}宸叉媺鍔ㄩ攣杞︾殑杞﹁韩宸ュ崟涓嶆敮鎸佹挙鎺�");
+ //if (!string.IsNullOrEmpty(orderinfo.pvi)) throw new Exception($"鎬昏宸ュ崟鍙穥item.workOrderNo}宸叉媺鍔ㄩ攣杞︾殑杞﹁韩宸ュ崟涓嶆敮鎸佹挙鎺�");
_assemblyOrderInfoRepository.DeleteData(orderinfo);
}
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/WCS/Partial/HZPassTZ.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/WCS/Partial/HZPassTZ.cs"
new file mode 100644
index 0000000..8f707ed
--- /dev/null
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/WCS/Partial/HZPassTZ.cs"
@@ -0,0 +1,42 @@
+锘縰sing System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Runtime.ConstrainedExecution;
+using System.Text;
+using System.Threading.Tasks;
+using WIDESEA_Common.MES;
+using WIDESEA_Core;
+using WIDESEA_DTO;
+
+namespace WIDESEA_StoragIntegrationServices
+{
+ public partial class WCSService
+ {
+ public WebResponseContent HZPassTZ(RequestTaskDto json)
+ {
+ WebResponseContent content = new WebResponseContent();
+ try
+ {
+ //var carInfo = _carBodyInfoRepository.QueryFirst(x => x.RFID == json.PVI); ///*x.PalletCode == json.PalletCode ||*/
+ //if (carInfo != null) throw new Exception($"娑傝鐩撮�氭�昏澶辫触:PVI{json.Rfid}宸插瓨鍦ㄣ��");
+
+ var station = _stationManagerRepository.QueryFirst(x => x.stationChildCode == json.Position);
+ if (station == null) throw new Exception("绔欏彴鏈壘鍒�");
+
+ WebResponseContent webResponse = _mesService.bindWorkOrder(json.Position, json.PVI);
+ if (!webResponse.Status) throw new Exception($"鐒婃秱缁戝畾澶辫触锛歿webResponse.msg}");
+
+ //杩囩偣淇℃伅 -BDC02
+ //json.Position = "EL01RB";
+ WebResponseContent BDC02 = _mesService.PassPoint(json);
+ if (!BDC02.Status) throw new Exception($"BDC02杩囩偣澶辫触锛歿BDC02.msg}");
+ content.OK();
+ }
+ catch (Exception ex)
+ {
+ content.Error(ex.Message);
+ }
+ return content;
+ }
+ }
+}
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/WCS/Partial/RequestEmptyInboundRoadWayNo.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/WCS/Partial/RequestEmptyInboundRoadWayNo.cs"
new file mode 100644
index 0000000..cbca152
--- /dev/null
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/WCS/Partial/RequestEmptyInboundRoadWayNo.cs"
@@ -0,0 +1,100 @@
+锘縰sing OfficeOpenXml.FormulaParsing.Excel.Functions.Math;
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Reflection.Metadata;
+using System.Security.Cryptography;
+using System.Text;
+using System.Threading.Tasks;
+using WIDESEA_Core;
+using WIDESEA_Core.Enums;
+using WIDESEA_DTO;
+using WIDESEA_Model.Models;
+using WIDESEA_Repository;
+using WIDESEAWCS_BasicInfoRepository;
+using WIDESEAWCS_Model.Models;
+
+namespace WIDESEA_StoragIntegrationServices
+{
+ public partial class WCSService
+ {
+ /// <summary>
+ /// 璇锋眰鍏ュ簱宸烽亾鍙�
+ /// </summary>
+ /// <param name="json"></param>
+ /// <returns></returns>
+ public WebResponseContent RequestEmptyInboundRoadWayNo(RequestTaskDto json)
+ {
+ WebResponseContent response = new WebResponseContent();
+ try
+ {
+ var carInfo = _carBodyInfoRepository.QueryFirst(x => x.RFID == json.PVI && x.PalletCode == json.PalletCode);
+
+ if (carInfo == null) throw new Exception("鏈煡绌烘挰淇℃伅,鏃犳硶鍏ュ簱");
+ //{
+ // Dt_CarBodyInfo _CarBodyInfo = new Dt_CarBodyInfo //娴嬭瘯
+ // {
+ // PVI = "J25000660",
+ // RFID = json.PVI,
+ // BodyStatus = 0,
+ // CarType = 1,
+ // };
+ //}
+
+ var maxGroup = _locationRepository.QueryData(x => x.LocationType == 3 && x.LocationStatus == (int)LocationEnum.Free && x.EnalbeStatus == (int)EnableEnum.Enable)
+ .GroupBy(x => x.RoadwayNo)
+ .OrderByDescending(g => g.Count()) // 鏍规嵁姣忎釜缁勭殑鍏冪礌鏁伴噺鎺掑簭
+ .ToList(); // 鍙栧嚭鏁伴噺鏈�澶氱殑缁�
+
+ Dictionary<string, int> result = new Dictionary<string, int>();
+ foreach (var item in maxGroup)
+ {
+ var number = _taskRepository.QueryData(x => x.TargetAddress == item.Key).Count();
+ if (item.Count() - number <= 0)
+ {
+ continue;
+ }
+ result.Add(item.Key, item.Count() - number);
+ }
+
+ string maxRoadwayNo = result.OrderByDescending(x => x.Value).FirstOrDefault().Key; // 鏁伴噺鏈�澶氱殑缁勭殑Key
+
+ var station = _stationManagerRepository.QueryFirst(x => x.RoadwayNo == maxRoadwayNo && x.stationArea == json.area && x.stationType == 6);
+
+ var newtask = new Dt_Task
+ {
+ CurrentAddress = json.Position,
+ Grade = 1,
+ Roadway = station.Roadway,
+ TargetAddress = station.Roadway,
+ //Dispatchertime = DateTime.Now,
+ NextAddress = station.stationChildCode,
+ OrderNo = null,
+ PalletCode = json.PalletCode,
+ SourceAddress = json.Position,
+ TaskState = (int)TaskInStatusEnum.InNew,
+ TaskType = (int)TaskInboundTypeEnum.InTray,
+ TaskNum = _taskRepository.GetTaskNo().Result,
+ Creater = "Systeam",
+ PVI = json.PVI,
+
+ };
+ _unitOfWorkManage.BeginTran();
+
+ _taskRepository.AddData(newtask);
+ //location.LocationStatus = (int)LocationEnum.InStockDisable;
+ //_locationRepository.UpdateData(location);
+ _unitOfWorkManage.CommitTran();
+
+ response.OK("绌烘挰鐢宠鍏ュ簱鎴愬姛", data: newtask);
+
+ //response.OK(data: maxRoadwayNo);
+ }
+ catch (Exception ex)
+ {
+ response.Error($"璇锋眰宸烽亾鍙峰け璐�:{ex.Message}");
+ }
+ return response;
+ }
+ }
+}
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/WCS/Partial/RequestInboundRoadWayNo.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/WCS/Partial/RequestInboundRoadWayNo.cs"
index 5f55914..bbb4868 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/WCS/Partial/RequestInboundRoadWayNo.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/WCS/Partial/RequestInboundRoadWayNo.cs"
@@ -29,7 +29,16 @@
try
{
//灞忚斀MES
- TZPassZZ(json);
+ if (json.Position == "EL01RB")
+ {
+ //鐒婅鎻愬崌鏈�
+ HZPassTZ(json);
+ }
+ else
+ {
+ ///娑傝鎻愬崌鏈�
+ TZPassZZ(json);
+ }
var carInfo = _carBodyInfoRepository.QueryFirst(x => x.RFID == json.PVI && x.PalletCode == json.PalletCode);
@@ -43,7 +52,6 @@
// CarType = 1,
// };
//}
-
List<Dt_RoadWay> roadWays = new List<Dt_RoadWay>();
if (carInfo.CarType == 1)
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/WCS/Partial/RequstCarBodyInfo.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/WCS/Partial/RequstCarBodyInfo.cs"
index 3531035..c0d83a4 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/WCS/Partial/RequstCarBodyInfo.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/WCS/Partial/RequstCarBodyInfo.cs"
@@ -20,16 +20,16 @@
WebResponseContent webResponseContent = new WebResponseContent();
try
{
- var carInfo = _carBodyInfoRepository.QueryFirst(x => x.PVI == json.PVI);
+ var carInfo = _carBodyInfoRepository.QueryFirst(x => x.RFID == json.PVI);
if (carInfo != null) throw new Exception($"PVI{json.PVI}杞﹁韩鏁版嵁宸插瓨鍦�");
///璇锋眰鐒婅杞﹁韩鐗瑰緛
WebResponseContent webResponse = _mesService.issuedCharacter(json.PVI, json.Position, json.PalletCode);
- if (webResponse.Status) throw new Exception($"{webResponse.Message}");
+ if (!webResponse.Status) throw new Exception($"{webResponse.Message}");
///BDC01 杩囩偣
WebResponseContent content = _mesService.PassPoint(json);
- if (content.Status) throw new Exception($"{content.Message}");
+ if (!content.Status) throw new Exception($"{content.Message}");
return webResponseContent.OK();
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/WCS/Partial/TZPassZZ.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/WCS/Partial/TZPassZZ.cs"
index 37d8417..4b9d3f5 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/WCS/Partial/TZPassZZ.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StoragIntegrationServices/WCS/Partial/TZPassZZ.cs"
@@ -33,7 +33,7 @@
if (!content1.Status) throw new Exception($"BDC02杩囩偣澶辫触锛歿content1.msg}");
WebResponseContent webResponse = _mesService.bindWorkOrder("EL01RB", json.PVI);
- if (!responseContent.Status) throw new Exception($"鐒婃秱缁戝畾澶辫触锛歿webResponse.msg}");
+ if (!webResponse.Status) throw new Exception($"鐒婃秱缁戝畾澶辫触锛歿webResponse.msg}");
//杩囩偣淇℃伅 -BDC02
json.Position = "EL01RB";
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StorageBasicRepository/Stock/VV_MesLockInfoRepository.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StorageBasicRepository/Stock/VV_MesLockInfoRepository.cs"
new file mode 100644
index 0000000..fea1464
--- /dev/null
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StorageBasicRepository/Stock/VV_MesLockInfoRepository.cs"
@@ -0,0 +1,9 @@
+锘縩amespace WIDESEA_StorageBasicRepository
+{
+ public class VV_MesLockInfoRepository : RepositoryBase<VV_MesLockInfo>, IVV_MesLockInfoRepository
+ {
+ public VV_MesLockInfoRepository(IUnitOfWorkManage unitOfWorkManage) : base(unitOfWorkManage)
+ {
+ }
+ }
+}
\ No newline at end of file
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StorageBasicServices/Stock/VV_MesLockInfoService.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StorageBasicServices/Stock/VV_MesLockInfoService.cs"
new file mode 100644
index 0000000..5d007f0
--- /dev/null
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StorageBasicServices/Stock/VV_MesLockInfoService.cs"
@@ -0,0 +1,18 @@
+锘縰sing AngleSharp.Dom;
+using Mapster;
+using Masuit.Tools;
+using SqlSugar;
+using System.Collections.Generic;
+using System.Drawing.Printing;
+using System.Linq.Expressions;
+using WIDESEA_Core;
+
+namespace WIDESEA_StorageBasicService;
+
+public class VV_MesLockInfoService : ServiceBase<VV_MesLockInfo, IVV_MesLockInfoRepository>, IVV_MesLockInfoService
+{
+ public VV_MesLockInfoService(IVV_MesLockInfoRepository BaseDal) : base(BaseDal)
+ {
+ }
+
+}
\ No newline at end of file
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StorageTaskServices/AutoTask/BackgroundJob.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StorageTaskServices/AutoTask/BackgroundJob.cs"
index 710ef80..4b58e56 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StorageTaskServices/AutoTask/BackgroundJob.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StorageTaskServices/AutoTask/BackgroundJob.cs"
@@ -47,23 +47,15 @@
{
try
{
- //var area = _areaInfoRepository.QueryFirst(x => x.AreaCode == "GWSC1");
+ //鎬昏涓嶇敓浜� 鍒欏仠姝㈡媺鍔ㄥ嚭搴�
+ var area = _areaInfoRepository.QueryFirst(x => x.AreaCode == "5");
+ if (area.AreaStatus != 1l) { return Task.CompletedTask; }
- //if (area == null) { return; }
-
- //IDictionary<string, DtStockInfo>? stockInfos = _simpleCacheService.HashGetAll<DtStockInfo>(WIDESEA_Cache.CacheConst.Cache_DtStockInfo);
- //List<DtStockInfo> stockInfoList = stockInfos.Values.ToList();
-
- //var stockInfo = stockInfoList.Where(x => x.AreaCode == area.AreaCode && x.OutboundTime < DateTime.Now && x.IsFull == true) // 杩囨护鏉′欢
- // .Where(x => x.LocationInfo != null && x.LocationInfo.LocationStatus == (int)LocationEnum.InStock && x.LocationInfo.AreaId == area.AreaID) // 杩囨护鏉′欢
- // .OrderBy(x => x.OutboundTime) // 鎺掑簭
- // .ToList(); // 鑾峰彇绗竴涓厓绱�
var lockInfo = _palletStockInfoRepository.Db.Queryable<Dt_MESLockInfo>()
//.Where(x => x.LockStatue == 0)
.Includes(x => x.CarBodyInfo)
.OrderBy(x => x.sequenceNo) // 鎺掑簭
.ToList(); // 鑾峰彇绗竴涓厓绱�
-
if (lockInfo.Where(x => x.LockStatue == 1).Count() > 10) return Task.CompletedTask;
if (lockInfo.Count == 0) return Task.CompletedTask;
@@ -132,6 +124,7 @@
Creater = "System",
CreateDate = DateTime.Now,
TaskId = 0,
+ CarType = stock.CarType,
};
// 鍒涘缓浠诲姟浼犺緭鐢ㄧ殑DTO瀵硅薄
@@ -160,6 +153,7 @@
_unitOfWorkManage.CommitTran();
}
+ #region 闆嗗悎
//foreach (var item in lockInfo)
//{
// var hasTask = _taskRepository.QueryFirst(x => x.PalletCode == item.CarBodyInfo.PalletCode);
@@ -251,7 +245,8 @@
// _palletStockInfoRepository.UpdateData(lockStock);
// _unitOfWorkManage.CommitTran();
// }
- //}
+ //}
+ #endregion
}
catch (Exception ex)
{
@@ -261,33 +256,8 @@
{
ConsoleHelper.WriteSuccessLine($"鎷夊姩閿佽溅锛�" + DateTime.Now.ToString());
}
-
- return Task.CompletedTask;
- }
- /// <summary>
- /// 鍒涘缓浠诲姟瀹炰緥
- /// </summary>
- private Dt_Task CreateTask(DtStockInfo stockInfo, string position, int tag)
- {
- return new Dt_Task
- {
- Grade = 1,
- Roadway = stockInfo.LocationInfo.RoadwayNo,
- TargetAddress = position,
- Dispatchertime = DateTime.Now,
- NextAddress = position,
- OrderNo = null,
- PalletCode = stockInfo.PalletCode,
- SourceAddress = stockInfo.LocationCode,
- CurrentAddress = stockInfo.LocationCode,
- TaskState = (int)TaskOutStatusEnum.OutNew,
- TaskType = tag,
- TaskNum = _taskRepository.GetTaskNo().Result,
- Creater = "System", // 淇鎷煎啓閿欒
- CreateDate = DateTime.Now,
- TaskId = 0,
- };
+ return Task.CompletedTask;
}
/// <summary>
@@ -307,8 +277,8 @@
Id = 0,
TaskType = task.TaskType,
pvi = task.PVI,
- NextAddress = task.NextAddress
-
+ NextAddress = task.NextAddress,
+ CarType = task.CarType
};
}
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StorageTaskServices/AutoTask/QuartzJobMildd.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StorageTaskServices/AutoTask/QuartzJobMildd.cs"
index 4801322..7e186dd 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StorageTaskServices/AutoTask/QuartzJobMildd.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StorageTaskServices/AutoTask/QuartzJobMildd.cs"
@@ -34,6 +34,19 @@
JobGroup = "WIDESEA_StorageTaskServices",
Name = "BackgroundJob",
TriggerType = 0
+ },
+ new TasksQz()
+ {
+ Id = 2,
+ AssemblyName = "WIDESEA_StorageTaskServices",
+ ClassName = "WhiteCarAutoOutJob",
+ CreateTime = DateTime.Now,
+ IntervalSecond = 15,
+ IsDeleted = false,
+ IsStart = false,
+ JobGroup = "AutoTask",
+ Name = "AutoTask",
+ TriggerType = 0
}
};
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StorageTaskServices/AutoTask/WhiteCarAutoOutJob.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StorageTaskServices/AutoTask/WhiteCarAutoOutJob.cs"
new file mode 100644
index 0000000..a023b44
--- /dev/null
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StorageTaskServices/AutoTask/WhiteCarAutoOutJob.cs"
@@ -0,0 +1,186 @@
+锘縰sing Masuit.Tools;
+using Microsoft.Extensions.Logging;
+using Quartz;
+using WIDESEA_Core.Const;
+using WIDESEA_DTO.WMS;
+using WIDESEA_IServices;
+using WIDESEAWCS_BasicInfoRepository;
+using WIDESEAWCS_Model.Models;
+
+namespace WIDESEA_StorageTaskServices
+{
+ [DisallowConcurrentExecution]
+ public class WhiteCarAutoOutJob : IJob
+ {
+ private ILogger<WhiteCarAutoOutJob> _logger;
+ private IDt_PalletStockInfoRepository _palletStockInfoRepository;
+ private IDt_AreaInfoRepository _areaInfoRepository; //鍖哄煙
+ private IDt_TaskRepository _taskRepository;
+ private IDt_StationManagerRepository _stationManagerRepository;
+ private ISys_ConfigService _configService;
+ private ILocationInfoRepository _locationRepository;
+ private IVV_StockInfoRepository _VVStockInfoRepository;
+ private IUnitOfWorkManage _unitOfWorkManage;
+
+ public WhiteCarAutoOutJob(ILogger<WhiteCarAutoOutJob> logger, IDt_PalletStockInfoRepository palletStockInfoRepository, IDt_AreaInfoRepository areaInfoRepository, IDt_TaskRepository taskRepository, IDt_StationManagerRepository stationManagerRepository, ISys_ConfigService configService, ILocationInfoRepository locationRepository, IVV_StockInfoRepository vVStockInfoRepository, IUnitOfWorkManage unitOfWorkManage)
+ {
+ _logger = logger;
+ _palletStockInfoRepository = palletStockInfoRepository;
+ _areaInfoRepository = areaInfoRepository;
+ _taskRepository = taskRepository;
+ _stationManagerRepository = stationManagerRepository;
+ _configService = configService;
+ _locationRepository = locationRepository;
+ _VVStockInfoRepository = vVStockInfoRepository;
+ _unitOfWorkManage = unitOfWorkManage;
+ }
+
+ public Task Execute(IJobExecutionContext context)
+ {
+ try
+ {
+ //娑傝涓嶇敓浜� 鍒欏仠姝㈡媺鍔ㄥ嚭搴�
+ var area = _areaInfoRepository.QueryFirst(x => x.AreaCode == "2");
+ if (area.AreaStatus != 1l) { return Task.CompletedTask; }
+
+ var stockInfo = _palletStockInfoRepository.Db.Queryable<Dt_PalletStockInfo>()
+ //.Where(x => x.LockStatue == 0)
+ .Includes(x => x.CarBodyInfo)
+ .Where(x => x.CarBodyInfo.CarType == 1 && x.TaskStatus == 0)
+ .OrderBy(x => x.CreateDate) // 鎺掑簭
+ .ToList(); // 鑾峰彇绗竴涓厓绱�
+
+ if (stockInfo.Where(x => x.TaskStatus == 1).Count() > 10) return Task.CompletedTask;
+ if (stockInfo.Count == 0) return Task.CompletedTask;
+
+ var OutCar = stockInfo.Where(x => x.TaskStatus == 0).FirstOrDefault();
+ if (OutCar == null) return Task.CompletedTask;
+ var hasTask = _taskRepository.QueryFirst(x => x.PalletCode == OutCar.CarBodyInfo.PalletCode);
+ if (hasTask != null)
+ {
+ Console.WriteLine("宸插瓨鍦ㄥ嚭搴撲换鍔�");
+ return Task.CompletedTask;
+ }
+
+ List<Dt_StationManager> stationLists = null;
+ if (OutCar.CarBodyInfo.CarType == 1)
+ {
+ stationLists = _stationManagerRepository.QueryData(x => x.RoadwayNo == OutCar.RoadwayNo && x.stationType == 2 && x.stationStatus == "1" && x.stationArea == "3");
+ }
+
+ var stock = _VVStockInfoRepository.QueryFirst(x => x.carBodyID == OutCar.carBodyID);
+ var lockStock = _palletStockInfoRepository.QueryFirst(x => x.carBodyID == OutCar.carBodyID);
+ var location = _locationRepository.QueryFirst(x => x.LocationCode == stock.LocationCode);
+ location.LocationStatus = (int)LocationEnum.InStockDisable;
+ lockStock.TaskStatus = 1;
+ if (stationLists == null || stationLists.Count == 0) throw new Exception("鍑哄簱绔欏彴鏈厤缃垨鏈惎鐢�");
+
+ Dt_StationManager Outstation = null;
+
+ //if (stationLists.Count > 1)
+ //{
+ // var Outtask = BaseDal.QueryData(x => x.Roadway == stationLists.FirstOrDefault().Roadway && x.TaskType == (int)TaskTypeEnum.Outbound).OrderByDescending(x => x.CreateDate).FirstOrDefault();
+ // if (Outtask != null) Outstation = stationLists.Where(x => x.stationChildCode != task.NextAddress && x.stationChildCode != Outtask.CurrentAddress).FirstOrDefault();
+ // else Outstation = stationLists.FirstOrDefault();
+ //}
+ //else
+ //{
+ Outstation = stationLists.FirstOrDefault();
+ //}
+ //var stationInfo = stationInfos.FirstOrDefault();
+
+ // 鍒涘缓骞舵坊鍔犱换鍔″埌鏁版嵁搴�
+ hasTask = new Dt_Task
+ {
+ Grade = 1,
+ Roadway = Outstation.Roadway,
+ TargetAddress = Outstation.stationChildCode,
+ Dispatchertime = DateTime.Now,
+ NextAddress = Outstation.stationChildCode,
+ OrderNo = null,
+ PalletCode = stock.PalletCode,
+ PVI = stock.PVI,
+ SourceAddress = stock.LocationCode,
+ CurrentAddress = stock.LocationCode,
+ TaskState = (int)TaskOutStatusEnum.OutNew,
+ TaskType = (int)TaskOutboundTypeEnum.Outbound,
+ TaskNum = _taskRepository.GetTaskNo().Result,
+ Creater = "System",
+ CreateDate = DateTime.Now,
+ TaskId = 0,
+ CarType = stock.CarType,
+ };
+
+ // 鍒涘缓浠诲姟浼犺緭鐢ㄧ殑DTO瀵硅薄
+ var taskDTO = CreateTaskDTO(hasTask);
+
+ // 鑾峰彇WMS IP鍦板潃鐢ㄤ簬鍙戦�佷换鍔¤姹�
+ var wmsIpAddress = GetWCSIpReceiveTask();
+ if (wmsIpAddress == null)
+ {
+ throw new InvalidOperationException("WMS IP 鏈厤缃�");
+ }
+
+ var tasks = new List<WMSTaskDTO>() { taskDTO };
+ // 鍙戦�佷换鍔¤姹傚埌WMS
+ var result = HttpHelper.PostAsync(wmsIpAddress, tasks.ToJsonString()).Result;
+ WebResponseContent content = JsonConvert.DeserializeObject<WebResponseContent>(result);
+ if (content.Status)
+ {
+ _unitOfWorkManage.BeginTran();
+ // 娣诲姞浠诲姟鍒版暟鎹簱
+ _taskRepository.AddData(hasTask);
+ // 鏇存柊搴撲綅浣嶇疆鐘舵�佷负涓嶅彲鐢�
+ _locationRepository.UpdateData(location);
+ _palletStockInfoRepository.UpdateData(lockStock);
+ _unitOfWorkManage.CommitTran();
+ }
+ }
+ catch (Exception ex)
+ {
+ ConsoleHelper.WriteErrorLine($"鐧借溅韬嚜鍔ㄥ嚭杞﹂敊璇俊鎭細" + ex.Message);
+ }
+ finally
+ {
+ ConsoleHelper.WriteSuccessLine($"鐧借溅韬嚜鍔ㄥ嚭杞︼細" + DateTime.Now.ToString());
+ }
+
+ return Task.CompletedTask;
+ }
+
+ /// <summary>
+ /// 鍒涘缓浠诲姟DTO
+ /// </summary>
+ private WMSTaskDTO CreateTaskDTO(Dt_Task task)
+ {
+ return new WMSTaskDTO
+ {
+ TaskNum = task.TaskNum.Value,
+ Grade = task.Grade.Value,
+ PalletCode = task.PalletCode,
+ RoadWay = task.Roadway,
+ SourceAddress = task.SourceAddress,
+ TargetAddress = task.TargetAddress,
+ TaskState = task.TaskState.Value,
+ Id = 0,
+ TaskType = task.TaskType,
+ pvi = task.PVI,
+ NextAddress = task.NextAddress,
+ CarType = task.CarType
+
+ };
+ }
+
+ private string GetWCSIpReceiveTask()
+ {
+ var configs = _configService.GetConfigsByCategory(CateGoryConst.CONFIG_SYS_IPAddress);
+ var wmsBase = configs.FirstOrDefault(x => x.ConfigKey == SysConfigConst.WCSIPAddress)?.ConfigValue;
+ var ipAddress = configs.FirstOrDefault(x => x.ConfigKey == SysConfigConst.ReceiveTask)?.ConfigValue;
+ if (wmsBase == null || ipAddress == null)
+ {
+ return null;
+ }
+ return wmsBase + ipAddress;
+ }
+ }
+}
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StorageTaskServices/Task/Dt_TaskService.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StorageTaskServices/Task/Dt_TaskService.cs"
index 28e3152..13f72e2 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StorageTaskServices/Task/Dt_TaskService.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StorageTaskServices/Task/Dt_TaskService.cs"
@@ -235,6 +235,7 @@
// 鏍规嵁浠诲姟绫诲瀷璋冪敤鐩稿簲鐨勫畬鎴愪换鍔℃柟娉�
switch (task.TaskType)
{
+ case (int)TaskInboundTypeEnum.InTray:
case (int)TaskInboundTypeEnum.Inbound:
LogFactory.GetLog("浠诲姟瀹屾垚").InfoFormat(true, "鍏ュ簱浠诲姟", "");
return await CompleteInboundTaskAsync(task);
@@ -769,8 +770,6 @@
#endregion
#region 浠诲姟璇锋眰鏂规硶
-
-
private static readonly SemaphoreSlim _semaphoreUpdate = new SemaphoreSlim(1, 1);
// 鏇存柊浠诲姟璐т綅
@@ -789,7 +788,7 @@
// 鍒涘缓WebResponseContent瀵硅薄
var content = new WebResponseContent();
- var carInfo = _carBodyRepository.QueryFirst(x => x.PalletCode == task.PalletCode);
+ var carInfo = _carBodyRepository.QueryFirst(x => x.PalletCode == task.PalletCode );
var stationInfo = _stationManagerRepository.QueryFirst(x => x.stationChildCode == input.Position);
// 鑾峰彇搴撲綅;
var location = RequestLocation(stationInfo.RoadwayNo, carInfo.CarType);
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StorageTaskServices/Task/Partial/Dt_TaskService.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StorageTaskServices/Task/Partial/Dt_TaskService.cs"
index c1dc994..bcd6cc6 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StorageTaskServices/Task/Partial/Dt_TaskService.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_StorageTaskServices/Task/Partial/Dt_TaskService.cs"
@@ -44,14 +44,23 @@
}
var carBody = _carBodyRepository.QueryFirst(x => x.PalletCode == input.PalletCode);
- if (carBody == null) throw new Exception($"杞﹁韩{input.PalletCode}淇℃伅涓嶅瓨鍦�");
+ if (carBody != null) throw new Exception($"绌烘挰{input.PalletCode}淇℃伅宸插瓨鍦�");
+
+ Dt_CarBodyInfo dt_CarBodyInfo = new Dt_CarBodyInfo
+ {
+ PalletCode = input.PalletCode,
+ CarType = 3,
+ PVI = input.PalletCode,
+ RFID = input.PalletCode,
+ BodyStatus = 0
+ };
//BDCManager bDCManager = new BDCManager(_bdcConfigurationService, _locationRepository, _roadWayInfoRepository);
//await bDCManager.AddToBDC(carBody);
// 鑾峰彇搴撲綅
- var location = RequestLocation(stationInfo.RoadwayNo, carBody.CarType);
+ var location = RequestLocation(stationInfo.RoadwayNo, 3);
if (location == null)
{
return content.Error("鏃犳硶鑾峰彇璐т綅淇℃伅鎴栧簱浣嶅凡婊�");
@@ -69,16 +78,16 @@
PalletCode = input.PalletCode,
SourceAddress = stationInfo.stationLocation,
TaskState = (int)TaskInStatusEnum.InNew,
- TaskType = (int)TaskInboundTypeEnum.Inbound,
+ TaskType = (int)TaskInboundTypeEnum.InTray,
TaskNum = await BaseDal.GetTaskNo(),
Creater = "Systeam",
PVI = input.PVI,
-
};
_unitOfWorkManage.BeginTran();
BaseDal.AddData(newtask);
+ _carBodyRepository.AddData(dt_CarBodyInfo);
location.LocationStatus = (int)LocationEnum.InStockDisable;
_locationRepository.UpdateData(location);
_unitOfWorkManage.CommitTran();
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_WMSServer/Controllers/Stock/VV_MesLockInfoController.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_WMSServer/Controllers/Stock/VV_MesLockInfoController.cs"
new file mode 100644
index 0000000..3f33943
--- /dev/null
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_WMSServer/Controllers/Stock/VV_MesLockInfoController.cs"
@@ -0,0 +1,14 @@
+锘縰sing WIDESEA_IStorageBasicService;
+using WIDESEA_StorageBasicService;
+
+namespace WIDESEA_WMSServer.Controllers;
+
+[Route("api/VV_MesLockInfo")]
+[ApiController]
+public class VV_MesLockInfoController : ApiBaseController<IVV_MesLockInfoService, VV_MesLockInfo>
+{
+ public VV_MesLockInfoController(IVV_MesLockInfoService service) : base(service)
+ {
+
+ }
+}
\ No newline at end of file
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_WMSServer/Program.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_WMSServer/Program.cs"
index 1572bd4..4a45b40 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_WMSServer/Program.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WMSServer/WIDESEA_WMSServer/Program.cs"
@@ -59,6 +59,7 @@
builder.Services.AddSingleton<IJobFactory, JobFactory>();
builder.Services.AddTransient<BackgroundJob>();//Job使用瞬时依赖注入
+builder.Services.AddTransient<WhiteCarAutoOutJob>();//Job使用瞬时依赖注入
builder.Services.AddSingleton<ISchedulerCenter, SchedulerCenterServer>();
builder.Services.AddHttpContextSetup();
@@ -116,7 +117,7 @@
});
//全自动出库
-builder.Services.AddHostedService<MyBackgroundService>();
+//builder.Services.AddHostedService<MyBackgroundService>();
var app = builder.Build();
--
Gitblit v1.9.3