From ce8f204db035e6fb7147edb4440591502f5c8567 Mon Sep 17 00:00:00 2001
From: huangxiaoqiang <huangxiaoqiang@hnkhzn.com>
Date: 星期四, 10 七月 2025 15:01:32 +0800
Subject: [PATCH] 1
---
Code Management/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/ConveyorLineJob_GW/GWTask/RequestInbound.cs | 62 ++++++++------
Code Management/WMS/WIDESEA_WMSServer/WIDESEA_IStorageBasicRepository/Location/ILocationErrorRepository.cs | 5 +
Code Management/WMS/WIDESEA_WMSServer/WIDESEA_StorageTaskServices/Task/Dt_TaskService.cs | 30 ++++---
Code Management/WMS/WIDESEA_WMSServer/WIDESEA_StorageBasicServices/Location/LocationErrorService.cs | 60 +++++++++++++++
Code Management/WMS/WIDESEA_WMSServer/WIDESEA_WMSServer/Controllers/Basic/StockInfoHtyController.cs | 12 +++
Code Management/WMS/WIDESEA_WMSClient/src/views/widesea_wms/basicinfo/Dt_LocationInfo.vue | 4
Code Management/WCS/WIDESEAWCS_Server/WIDESEAWCS_TaskInfoService/TaskService.cs | 2
Code Management/WCS/WIDESEAWCS_Server/WIDESEAWCS_TaskInfoService/Partial/TaskService.cs | 2
Code Management/WMS/WIDESEA_WMSClient/src/views/widesea_wms/stock/Dt_OutTime.vue | 8 +-
Code Management/WMS/WIDESEA_WMSServer/WIDESEA_IStorageBasicService/Location/ILocationErrorService.cs | 8 ++
Code Management/WMS/WIDESEA_WMSServer/WIDESEA_StorageBasicServices/Stock/StockInfoHtyService.cs | 1
Code Management/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/ConveyorLineJob/Task/RequestInbound.cs | 16 ++++
Code Management/WMS/WIDESEA_WMSServer/WIDESEA_WMSServer/Controllers/Basic/LocationErrorController.cs | 15 +++
Code Management/WMS/WIDESEA_WMSServer/WIDESEA_StorageBasicRepository/Location/LocationErrorRepository.cs | 9 ++
Code Management/WMS/WIDESEA_WMSClient/src/api/http.js | 2
Code Management/WMS/WIDESEA_WMSClient/src/views/widesea_wms/basicinfo/Dt_LocationStatus.vue | 2
Code Management/WMS/WIDESEA_WMSClient/src/router/tables.js | 2
17 files changed, 189 insertions(+), 51 deletions(-)
diff --git a/Code Management/WCS/WIDESEAWCS_Server/WIDESEAWCS_TaskInfoService/Partial/TaskService.cs b/Code Management/WCS/WIDESEAWCS_Server/WIDESEAWCS_TaskInfoService/Partial/TaskService.cs
index df41df0..00395f2 100644
--- a/Code Management/WCS/WIDESEAWCS_Server/WIDESEAWCS_TaskInfoService/Partial/TaskService.cs
+++ b/Code Management/WCS/WIDESEAWCS_Server/WIDESEAWCS_TaskInfoService/Partial/TaskService.cs
@@ -676,7 +676,7 @@
catch (Exception ex)
{
content = WebResponseContent.Instance.Error($"浠诲姟瀹屾垚寮傚父,浠诲姟鍙�:銆恵taskNum}銆�");
- QuartzLogger.WriteLogToFile($"Info_鍒嗗浠诲姟瀹屾垚", $"浠诲姟瀹屾垚寮傚父,浠诲姟鍙�:銆恵taskNum}銆戝紓甯镐俊鎭�恵ex.StackTrace}銆憑Environment.NewLine}{Environment.NewLine}");
+ QuartzLogger.WriteLogToFile($"Info_鍒嗗浠诲姟瀹屾垚", $"浠诲姟瀹屾垚寮傚父,浠诲姟鍙�:銆恵taskNum}銆戝紓甯镐俊鎭�恵ex.Message}銆憑Environment.NewLine}寮傚父淇℃伅銆恵ex.StackTrace}銆憑Environment.NewLine}");
}
QuartzLogger.WriteLogToFile($"Info_鍒嗗浠诲姟瀹屾垚", $"浠诲姟瀹屾垚,浠诲姟鍙�:銆恵taskNum}銆戣繑鍥炲弬鏁般�恵JsonConvert.SerializeObject(content)}銆憑Environment.NewLine}{Environment.NewLine}");
return content;
diff --git a/Code Management/WCS/WIDESEAWCS_Server/WIDESEAWCS_TaskInfoService/TaskService.cs b/Code Management/WCS/WIDESEAWCS_Server/WIDESEAWCS_TaskInfoService/TaskService.cs
index 409077d..372ef2a 100644
--- a/Code Management/WCS/WIDESEAWCS_Server/WIDESEAWCS_TaskInfoService/TaskService.cs
+++ b/Code Management/WCS/WIDESEAWCS_Server/WIDESEAWCS_TaskInfoService/TaskService.cs
@@ -826,7 +826,7 @@
catch (Exception ex)
{
content = WebResponseContent.Instance.Error($"浠诲姟瀹屾垚寮傚父,浠诲姟鍙�:銆恵taskNum}銆�");
- QuartzLogger.WriteLogToFile($"Info_浠诲姟瀹屾垚", $"浠诲姟瀹屾垚寮傚父,浠诲姟鍙�:銆恵taskNum}銆戝紓甯镐俊鎭�恵ex.StackTrace}銆憑Environment.NewLine}{Environment.NewLine}");
+ QuartzLogger.WriteLogToFile($"Info_浠诲姟瀹屾垚", $"浠诲姟瀹屾垚寮傚父,浠诲姟鍙�:銆恵taskNum}銆戝紓甯镐俊鎭�恵ex.Message}銆憑Environment.NewLine}寮傚父淇℃伅銆恵ex.StackTrace}銆憑Environment.NewLine}");
}
QuartzLogger.WriteLogToFile($"Info_浠诲姟瀹屾垚", $"浠诲姟瀹屾垚,浠诲姟鍙�:銆恵taskNum}銆戣繑鍥炲弬鏁般�恵JsonConvert.SerializeObject(content)}銆憑Environment.NewLine}{Environment.NewLine}");
return content;
diff --git a/Code Management/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/ConveyorLineJob/Task/RequestInbound.cs b/Code Management/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/ConveyorLineJob/Task/RequestInbound.cs
index c7d82c7..a2dad0d 100644
--- a/Code Management/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/ConveyorLineJob/Task/RequestInbound.cs
+++ b/Code Management/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/ConveyorLineJob/Task/RequestInbound.cs
@@ -146,6 +146,22 @@
if (_taskRepository.QueryFirst(x => x.PalletCode == taskDTO.PalletCode) != null)
{
+ if (_taskRepository.QueryFirst(x => x.PalletCode == command.Barcode) != null)
+ {
+
+ var taskExecuting = _taskRepository.QueryFirst(x => x.PalletCode == command.Barcode && (x.TaskState == (int)TaskOutStatusEnum.Line_OutExecuting|| x.TaskState == (int)TaskOutStatusEnum.SC_OutFinish));
+
+ if (taskExecuting != null)
+ {
+ taskExecuting.ExceptionMessage = "鏈帴鏀跺埌绾夸綋瀹屾垚淇″彿绯荤粺鍐呴儴鑷姩瀹屾垚";
+ _taskService.Delete(taskExecuting);
+ }
+
+ ConsoleHelper.WriteErrorLine($"褰撳墠鎵樼洏瀛樺湪浠诲姟锛氥�恵command.Barcode}銆�");
+
+ WriteInfo(conveyorLine.DeviceName, $"褰撳墠鎵樼洏瀛樺湪浠诲姟{command.Barcode}");
+
+ }
WriteInfo(conveyorLine.DeviceName, "褰撳墠鎵樼洏瀛樺湪浠诲姟");
}
diff --git a/Code Management/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/ConveyorLineJob_GW/GWTask/RequestInbound.cs b/Code Management/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/ConveyorLineJob_GW/GWTask/RequestInbound.cs
index 8ab0147..5e28fa3 100644
--- a/Code Management/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/ConveyorLineJob_GW/GWTask/RequestInbound.cs
+++ b/Code Management/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/ConveyorLineJob_GW/GWTask/RequestInbound.cs
@@ -315,43 +315,51 @@
/// </summary>
private async void RequestWmsTask(CommonConveyorLine_GW conveyorLine, ConveyorLineTaskCommand_After command, string childDeviceCode, Dt_StationManager stationManager)
{
- if (command.ConveyorLineBarcode.IsNullOrEmpty()) return;
- var content = await _taskService.RequestWMSTask(command.ConveyorLineBarcode, childDeviceCode);
- if (content.Status)
+ try
{
- var task = _taskService.QueryBarCodeConveyorLineTask(command.ConveyorLineBarcode, childDeviceCode);
- if (task != null)
+ if (command.ConveyorLineBarcode.IsNullOrEmpty()) return;
+ var content = await _taskService.RequestWMSTask(command.ConveyorLineBarcode, childDeviceCode);
+ if (content.Status)
{
- var GWTask = _taskRepository.QueryData(x => x.Roadway.Contains("GWSC2") && x.SourceAddress == "1039" && (x.TaskState == (int)TaskInStatusEnum.Line_InExecuting || x.TaskState == (int)TaskInStatusEnum.Line_InFinish)).ToList();
- if (GWTask.Count >= 2 && childDeviceCode == "1039" && task.Roadway.Contains("GWSC2"))
+ var task = _taskService.QueryBarCodeConveyorLineTask(command.ConveyorLineBarcode, childDeviceCode);
+ if (task != null)
{
- ConsoleHelper.WriteErrorLine($"鎵樼洏鍙凤細銆恵command.ConveyorLineBarcode}銆戦珮娓╀簩宸插瓨鍦ㄣ�恵GWTask.Count}銆戜釜浠诲姟澶т簬2涓换鍔′笉鍙笅鍙�");
- return;
- }
- ConveyorLineTaskCommand_After taskCommand = _mapper.Map<ConveyorLineTaskCommand_After>(task);
- //conveyorLine.SendCommand(taskCommand, childDeviceCode);
+ var GWTask = _taskRepository.QueryData(x => x.Roadway.Contains("GWSC2") && x.SourceAddress == "1039" && (x.TaskState == (int)TaskInStatusEnum.Line_InExecuting || x.TaskState == (int)TaskInStatusEnum.Line_InFinish)).ToList();
+ if (GWTask.Count >= 2 && childDeviceCode == "1039" && task.Roadway.Contains("GWSC2"))
+ {
+ ConsoleHelper.WriteErrorLine($"鎵樼洏鍙凤細銆恵command.ConveyorLineBarcode}銆戦珮娓╀簩宸插瓨鍦ㄣ�恵GWTask.Count}銆戜釜浠诲姟澶т簬2涓换鍔′笉鍙笅鍙�");
+ return;
+ }
+ ConveyorLineTaskCommand_After taskCommand = _mapper.Map<ConveyorLineTaskCommand_After>(task);
+ //conveyorLine.SendCommand(taskCommand, childDeviceCode);
- bool sendFlag = SendCommand(taskCommand, conveyorLine, childDeviceCode);
- if (sendFlag)
+ bool sendFlag = SendCommand(taskCommand, conveyorLine, childDeviceCode);
+ if (sendFlag)
+ {
+ conveyorLine.SetValue(ConveyorLineDBName_After.ResponState, Convert.ToInt16(1), childDeviceCode);
+
+ _taskService.UpdateTaskStatusToNext(task);
+ }
+ }
+ }
+ else
+ {
+ if (content.Message != "璇锋眰杩囦簬棰戠箒锛岃绋嶅悗鍐嶈瘯" || content.Message != "鏃犳硶鑾峰彇鐩爣鍦板潃")
{
+ WriteInfo(conveyorLine.DeviceName, content.Message);
+ conveyorLine.SetValue(ConveyorLineDBName_After.ConveyorLineTargetAddress, stationManager.stationNGChildCode, childDeviceCode);
conveyorLine.SetValue(ConveyorLineDBName_After.ResponState, Convert.ToInt16(1), childDeviceCode);
-
- _taskService.UpdateTaskStatusToNext(task);
+ ConsoleHelper.WriteErrorLine($"銆恵conveyorLine.DeviceName}銆戞墭鐩樺彿锛氥�恵command.ConveyorLineBarcode}銆戣姹傜偣浣嶏細銆恵childDeviceCode}銆戝紓甯镐俊鎭�恵content.Message}銆�");
+ WriteInfo(conveyorLine.DeviceName, $"銆恵conveyorLine.DeviceName}銆戞墭鐩樺彿锛氥�恵command.ConveyorLineBarcode}銆戣姹傜偣浣嶏細銆恵childDeviceCode}銆戝紓甯镐俊鎭�恵content.Message}銆�");
}
- }
- }
- else
- {
- if (content.Message != "璇锋眰杩囦簬棰戠箒锛岃绋嶅悗鍐嶈瘯" || content.Message != "鏃犳硶鑾峰彇鐩爣鍦板潃")
- {
- WriteInfo(conveyorLine.DeviceName, content.Message);
- conveyorLine.SetValue(ConveyorLineDBName_After.ConveyorLineTargetAddress, stationManager.stationNGChildCode, childDeviceCode);
- conveyorLine.SetValue(ConveyorLineDBName_After.ResponState, Convert.ToInt16(1), childDeviceCode);
ConsoleHelper.WriteErrorLine($"銆恵conveyorLine.DeviceName}銆戞墭鐩樺彿锛氥�恵command.ConveyorLineBarcode}銆戣姹傜偣浣嶏細銆恵childDeviceCode}銆戝紓甯镐俊鎭�恵content.Message}銆�");
- WriteInfo(conveyorLine.DeviceName, $"銆恵conveyorLine.DeviceName}銆戞墭鐩樺彿锛氥�恵command.ConveyorLineBarcode}銆戣姹傜偣浣嶏細銆恵childDeviceCode}銆戝紓甯镐俊鎭�恵content.Message}銆�");
}
- ConsoleHelper.WriteErrorLine($"銆恵conveyorLine.DeviceName}銆戞墭鐩樺彿锛氥�恵command.ConveyorLineBarcode}銆戣姹傜偣浣嶏細銆恵childDeviceCode}銆戝紓甯镐俊鎭�恵content.Message}銆�");
}
+ catch (Exception ex)
+ {
+ WriteInfo(conveyorLine.DeviceName, $"銆恵conveyorLine.DeviceName}銆戞墭鐩樺彿锛氥�恵command.ConveyorLineBarcode}銆戣姹傜偣浣嶏細銆恵childDeviceCode}銆戝紓甯镐俊鎭�恵ex.Message}銆戝紓甯歌銆恵ex.StackTrace}銆�");
+ }
+
}
/// <summary>
diff --git a/Code Management/WMS/WIDESEA_WMSClient/src/api/http.js b/Code Management/WMS/WIDESEA_WMSClient/src/api/http.js
index 0b61bce..1dcbe7f 100644
--- a/Code Management/WMS/WIDESEA_WMSClient/src/api/http.js
+++ b/Code Management/WMS/WIDESEA_WMSClient/src/api/http.js
@@ -12,7 +12,7 @@
let loadingStatus = false
if (process.env.NODE_ENV == 'development') {
axios.defaults.baseURL = 'http://localhost:5000/';
- // axios.defaults.baseURL = 'http://192.168.20.253:5000/';
+ // axios.defaults.baseURL = 'http://192.168.15.253:5000/';
}
else if (process.env.NODE_ENV == 'debug') {
axios.defaults.baseURL = 'http://192.168.15.253:5000/';
diff --git a/Code Management/WMS/WIDESEA_WMSClient/src/router/tables.js b/Code Management/WMS/WIDESEA_WMSClient/src/router/tables.js
index c6c6ac0..7dc9640 100644
--- a/Code Management/WMS/WIDESEA_WMSClient/src/router/tables.js
+++ b/Code Management/WMS/WIDESEA_WMSClient/src/router/tables.js
@@ -31,7 +31,7 @@
{
path: '/Dt_LocationStatus',
name: 'Dt_LocationStatus',
- component: () => import('@/views/widesea_wms/basicinfo/LocationStatusChange.vue'),
+ component: () => import('@/views/widesea_wms/basicinfo/Dt_LocationStatus.vue'),
meta: {
}
diff --git a/Code Management/WMS/WIDESEA_WMSClient/src/views/widesea_wms/basicinfo/Dt_LocationInfo.vue b/Code Management/WMS/WIDESEA_WMSClient/src/views/widesea_wms/basicinfo/Dt_LocationInfo.vue
index d70940b..fa53e7f 100644
--- a/Code Management/WMS/WIDESEA_WMSClient/src/views/widesea_wms/basicinfo/Dt_LocationInfo.vue
+++ b/Code Management/WMS/WIDESEA_WMSClient/src/views/widesea_wms/basicinfo/Dt_LocationInfo.vue
@@ -35,7 +35,9 @@
[
{ "title": "璐т綅缂栧彿", "field": "locationCode", type: "text" },
{ "title": "璐т綅鐘舵��", "field": "locationStatus", "type": "select", dataKey: "LocationState", data: [] },
- { "title": "宸烽亾缂栧彿", "field": "roadWayNO", type: "text" },
+ { "title": "宸烽亾缂栧彿", "field": "roadWayNO", type: "text" },
+ { "title": "鍚敤鐘舵��", "field": "enalbeStatus", "type": "select", dataKey: "EnalbeStatus", data: [] },
+
],
[
{ "title": "琛�", "field": "row", type: "text" },
diff --git a/Code Management/WMS/WIDESEA_WMSClient/src/views/widesea_wms/basicinfo/Dt_LocationStatus.vue b/Code Management/WMS/WIDESEA_WMSClient/src/views/widesea_wms/basicinfo/Dt_LocationStatus.vue
index bd071e5..eb37a6e 100644
--- a/Code Management/WMS/WIDESEA_WMSClient/src/views/widesea_wms/basicinfo/Dt_LocationStatus.vue
+++ b/Code Management/WMS/WIDESEA_WMSClient/src/views/widesea_wms/basicinfo/Dt_LocationStatus.vue
@@ -20,7 +20,7 @@
footer: "Foots",
cnName: '璐т綅淇℃伅',
name: '/api',
- url: "/Task/LocationStatus",
+ url: "/LocationError/",
sortName: "id"
});
const editFormFields = ref({ "locationStatus": "" });
diff --git a/Code Management/WMS/WIDESEA_WMSClient/src/views/widesea_wms/stock/Dt_OutTime.vue b/Code Management/WMS/WIDESEA_WMSClient/src/views/widesea_wms/stock/Dt_OutTime.vue
index 000f539..a4d6ae0 100644
--- a/Code Management/WMS/WIDESEA_WMSClient/src/views/widesea_wms/stock/Dt_OutTime.vue
+++ b/Code Management/WMS/WIDESEA_WMSClient/src/views/widesea_wms/stock/Dt_OutTime.vue
@@ -12,16 +12,16 @@
</view-grid>
</template>
<script>
-import extend from "@/extension/widesea_wms/stock/Dt_OutTime.jsx";
+import extend from "@/extension/widesea_wms/stock/Dt_BillGroupStock.jsx";
import { ref, defineComponent } from "vue";
export default defineComponent({
setup() {
const table = ref({
key: 'id',
footer: "Foots",
- cnName: '瓒呮椂搴撳瓨淇℃伅',
- name: 'stock/StockInfoTimeout',
- url: "/StockInfo/",
+ cnName: '搴撳瓨淇℃伅',
+ name: 'stock/Dt_BillGroupStock',
+ url: "/StockInfoTimeout/",
sortName: "createDate"
});
const editFormFields = ref({
diff --git a/Code Management/WMS/WIDESEA_WMSServer/WIDESEA_IStorageBasicRepository/Location/ILocationErrorRepository.cs b/Code Management/WMS/WIDESEA_WMSServer/WIDESEA_IStorageBasicRepository/Location/ILocationErrorRepository.cs
new file mode 100644
index 0000000..ab7bcac
--- /dev/null
+++ b/Code Management/WMS/WIDESEA_WMSServer/WIDESEA_IStorageBasicRepository/Location/ILocationErrorRepository.cs
@@ -0,0 +1,5 @@
+锘縩amespace WIDESEA_IStorageBasicRepository;
+
+public interface ILocationErrorRepository : IRepository<DtLocationInfo>
+{
+}
\ No newline at end of file
diff --git a/Code Management/WMS/WIDESEA_WMSServer/WIDESEA_IStorageBasicService/Location/ILocationErrorService.cs b/Code Management/WMS/WIDESEA_WMSServer/WIDESEA_IStorageBasicService/Location/ILocationErrorService.cs
new file mode 100644
index 0000000..831dd49
--- /dev/null
+++ b/Code Management/WMS/WIDESEA_WMSServer/WIDESEA_IStorageBasicService/Location/ILocationErrorService.cs
@@ -0,0 +1,8 @@
+锘縰sing WIDESEA_DTO;
+
+namespace WIDESEA_IStorageBasicService;
+
+public interface ILocationErrorService : IService<DtLocationInfo>
+{
+
+}
\ No newline at end of file
diff --git a/Code Management/WMS/WIDESEA_WMSServer/WIDESEA_StorageBasicRepository/Location/LocationErrorRepository.cs b/Code Management/WMS/WIDESEA_WMSServer/WIDESEA_StorageBasicRepository/Location/LocationErrorRepository.cs
new file mode 100644
index 0000000..ef475f9
--- /dev/null
+++ b/Code Management/WMS/WIDESEA_WMSServer/WIDESEA_StorageBasicRepository/Location/LocationErrorRepository.cs
@@ -0,0 +1,9 @@
+锘縩amespace WIDESEA_StorageBasicRepository
+{
+ public class LocationErrorRepository : RepositoryBase<DtLocationInfo>, ILocationErrorRepository
+ {
+ public LocationErrorRepository(IUnitOfWorkManage unitOfWorkManage) : base(unitOfWorkManage)
+ {
+ }
+ }
+}
\ No newline at end of file
diff --git a/Code Management/WMS/WIDESEA_WMSServer/WIDESEA_StorageBasicServices/Location/LocationErrorService.cs b/Code Management/WMS/WIDESEA_WMSServer/WIDESEA_StorageBasicServices/Location/LocationErrorService.cs
new file mode 100644
index 0000000..3c1496b
--- /dev/null
+++ b/Code Management/WMS/WIDESEA_WMSServer/WIDESEA_StorageBasicServices/Location/LocationErrorService.cs
@@ -0,0 +1,60 @@
+锘縰sing AngleSharp.Dom;
+using Mapster;
+using SqlSugar;
+using System.Threading.Tasks;
+using WIDESEA_Common;
+using WIDESEA_Core;
+using WIDESEA_DTO;
+using WIDESEA_Model.Models;
+
+namespace WIDESEA_StorageBasicService;
+
+public class LocationErrorService : ServiceBase<DtLocationInfo, ILocationErrorRepository>, ILocationErrorService
+{
+ private readonly IMapper _mapper;
+
+ public LocationErrorService(ILocationErrorRepository BaseDal,IMapper mapper,IDt_TaskService taskService) : base(BaseDal)
+ {
+ _mapper = mapper;
+ }
+ public override PageGridData<DtLocationInfo> GetPageData(PageDataOptions options)
+ {
+ string wheres = ValidatePageOptions(options);
+ //鑾峰彇鎺掑簭瀛楁
+ Dictionary<string, SqlSugar.OrderByType> orderbyDic = GetPageDataSort(options, TProperties);
+ List<OrderByModel> orderByModels = new List<OrderByModel>();
+ foreach (var item in orderbyDic)
+ {
+ OrderByModel orderByModel = new()
+ {
+ FieldName = item.Key,
+ OrderByType = item.Value
+ };
+ orderByModels.Add(orderByModel);
+ }
+
+
+ int totalCount = 0;
+ List<SearchParameters> searchParametersList = new List<SearchParameters>();
+ if (!string.IsNullOrEmpty(options.Wheres))
+ {
+ try
+ {
+ searchParametersList = options.Wheres.DeserializeObject<List<SearchParameters>>();
+ options.Filter = searchParametersList;
+ }
+ catch { }
+ }
+
+ var now = DateTime.Now;
+ // 浣跨敤Subtract鏂规硶
+ var threeHoursAgo = now.Subtract(TimeSpan.FromHours(3));
+
+ var data = BaseDal.Db.Queryable<DtLocationInfo>()
+ .Where(x => x.LocationStatus != 2 && x.LocationStatus != 0)
+ .WhereIF(!wheres.IsNullOrEmpty(), wheres)
+ .OrderBy(orderByModels)
+ .ToPageList(options.Page, options.Rows, ref totalCount);
+ return new PageGridData<DtLocationInfo>(totalCount, data);
+ }
+}
\ No newline at end of file
diff --git a/Code Management/WMS/WIDESEA_WMSServer/WIDESEA_StorageBasicServices/Stock/StockInfoHtyService.cs b/Code Management/WMS/WIDESEA_WMSServer/WIDESEA_StorageBasicServices/Stock/StockInfoHtyService.cs
index d234d42..a15349b 100644
--- a/Code Management/WMS/WIDESEA_WMSServer/WIDESEA_StorageBasicServices/Stock/StockInfoHtyService.cs
+++ b/Code Management/WMS/WIDESEA_WMSServer/WIDESEA_StorageBasicServices/Stock/StockInfoHtyService.cs
@@ -80,6 +80,7 @@
var data = BaseDal.Db.Queryable<DtStockInfo_Hty>()
.Includes(x => x.StockInfoDetails)
.Includes(x => x.LocationInfo)
+ .Where(x=>x.CreateDate>DateTime.Now.AddMonths(-1))
.WhereIF(!wheres.IsNullOrEmpty(), wheres)
.WhereIF(locationStatus != null, locationStatus)
.WhereIF(roadwayNo != null, roadwayNo)
diff --git a/Code Management/WMS/WIDESEA_WMSServer/WIDESEA_StorageTaskServices/Task/Dt_TaskService.cs b/Code Management/WMS/WIDESEA_WMSServer/WIDESEA_StorageTaskServices/Task/Dt_TaskService.cs
index 20b5236..55978af 100644
--- a/Code Management/WMS/WIDESEA_WMSServer/WIDESEA_StorageTaskServices/Task/Dt_TaskService.cs
+++ b/Code Management/WMS/WIDESEA_WMSServer/WIDESEA_StorageTaskServices/Task/Dt_TaskService.cs
@@ -1,5 +1,6 @@
锘縰sing Mapster;
using Masuit.Tools;
+using SixLabors.Fonts.Tables.AdvancedTypographic;
using SqlSugar;
using System.Text.RegularExpressions;
using System.Threading.Tasks;
@@ -776,6 +777,7 @@
// 鏇磋缁嗙殑寮傚父澶勭悊锛屽彲浠ユ牴鎹紓甯哥被鍨嬭褰曚笉鍚岀殑閿欒鏃ュ織绛�
content.Error(err.Message);
Console.WriteLine(err.Message);
+ LogFactory.GetLog($"璇锋眰鍏ュ簱寮傚父").Info(true, $"寮傚父淇℃伅銆恵err.Message}銆戝紓甯歌銆恵err.StackTrace}銆�");
}
return content;
@@ -976,6 +978,8 @@
WebResponseContent content = new WebResponseContent();
try
{
+ // 璁板綍寮傚父淇℃伅骞舵姏鍑�
+ LogFactory.GetLog($"{position}璇锋眰{productionLine}浠诲姟").Info(true, $"{position}-{tag}-{areaCode}-{JsonConvert.SerializeObject(areaCodes)}-{productionLine}");
// 鏍规嵁鎵樼洏绫诲瀷鏌ヨ搴撳瓨淇℃伅
DtStockInfo stockInfo = tag == (int)TaskOutboundTypeEnum.Outbound
? areaCode != "CWSC1" ? await QueryStockInfoForRealTrayAsync(areaCode, areaCodes, productionLine) : await QueryStockInfoForRealTrayCWAsync(areaCodes, productionLine)
@@ -1738,21 +1742,20 @@
// 鍒涘缓鍘嗗彶浠诲姟瀹炰緥妯″瀷
try
{
- Dt_Task task = BaseDal.QueryFirst(x => x.TaskId == Convert.ToInt32(key[0]));
- if (task == null)
+ foreach (var item in key)
{
- return content.Error("鏈壘鍒颁换鍔′俊鎭�!");
+ Dt_Task task = BaseDal.QueryFirst(x => x.TaskId == Convert.ToInt32(key));
+ if (task == null)
+ {
+ return content.Error("鏈壘鍒颁换鍔′俊鎭�!");
+ }
+ var taskHtyNG = CreateHistoricalTask(task, true);
+ // 娣诲姞鍘嗗彶浠诲姟
+ var isTaskHtyAdd = _task_HtyRepository.AddData(taskHtyNG) > 0;
+
+ // 鍒犻櫎浠诲姟鏁版嵁
+ var isTaskDelete = BaseDal.Delete(task.TaskId);
}
- var taskHtyNG = CreateHistoricalTask(task, true);
-
- // 鎵ц鏁版嵁搴撲簨鍔�
-
- // 娣诲姞鍘嗗彶浠诲姟
- var isTaskHtyAdd = _task_HtyRepository.AddData(taskHtyNG) > 0;
-
- // 鍒犻櫎浠诲姟鏁版嵁
- var isTaskDelete = BaseDal.Delete(task.TaskId);
-
return content.OK("鍒犻櫎鎴愬姛!");
}
catch (Exception ex)
@@ -1886,7 +1889,6 @@
{
taskHty.Creater = App.User.UserName != null ? App.User.UserName : "System";
}
- taskHty.TaskState = task.TaskType > 199 ? (int)TaskInStatusEnum.InFinish : (int)TaskOutStatusEnum.OutFinish;
return taskHty;
}
diff --git a/Code Management/WMS/WIDESEA_WMSServer/WIDESEA_WMSServer/Controllers/Basic/LocationErrorController.cs b/Code Management/WMS/WIDESEA_WMSServer/WIDESEA_WMSServer/Controllers/Basic/LocationErrorController.cs
new file mode 100644
index 0000000..4c7abbd
--- /dev/null
+++ b/Code Management/WMS/WIDESEA_WMSServer/WIDESEA_WMSServer/Controllers/Basic/LocationErrorController.cs
@@ -0,0 +1,15 @@
+锘縰sing Masuit.Tools.Models;
+using WIDESEA_DTO;
+
+namespace WIDESEA_WMSServer.Controllers;
+
+[Route("api/LocationError")]
+[ApiController]
+public class LocationErrorController : ApiBaseController<ILocationErrorService, DtLocationInfo>
+{
+ public LocationErrorController(ILocationErrorService service) : base(service)
+ {
+ }
+
+
+}
\ No newline at end of file
diff --git a/Code Management/WMS/WIDESEA_WMSServer/WIDESEA_WMSServer/Controllers/Basic/StockInfoHtyController.cs b/Code Management/WMS/WIDESEA_WMSServer/WIDESEA_WMSServer/Controllers/Basic/StockInfoHtyController.cs
new file mode 100644
index 0000000..3696c9c
--- /dev/null
+++ b/Code Management/WMS/WIDESEA_WMSServer/WIDESEA_WMSServer/Controllers/Basic/StockInfoHtyController.cs
@@ -0,0 +1,12 @@
+锘縰sing WIDESEA_IStorageBasicService;
+
+namespace WIDESEA_WMSServer.Controllers;
+
+[Route("api/StockInfoHty")]
+[ApiController]
+public class StockInfoHtyController : ApiBaseController<IStockInfoHtyService, DtStockInfo_Hty>
+{
+ public StockInfoHtyController(IStockInfoHtyService service) : base(service)
+ {
+ }
+}
\ No newline at end of file
--
Gitblit v1.9.3