From be14322d1b20857082dd47aeb895bd976dca13e0 Mon Sep 17 00:00:00 2001
From: liuying <1427574514@qq.com>
Date: 周六, 30 11月 2024 17:40:50 +0800
Subject: [PATCH] Merge branch 'master' of http://222.71.245.114:9086/r/LA24030-LuLI_PackageLine
---
SDA/iWareSda/Devices/4-Station/StationService/StationService.cs | 256 ++++++++++++++++++++++++++++++++++++++++++++++++++
1 files changed, 252 insertions(+), 4 deletions(-)
diff --git a/SDA/iWareSda/Devices/4-Station/StationService/StationService.cs b/SDA/iWareSda/Devices/4-Station/StationService/StationService.cs
index b7eb1da..ccbba8c 100644
--- a/SDA/iWareSda/Devices/4-Station/StationService/StationService.cs
+++ b/SDA/iWareSda/Devices/4-Station/StationService/StationService.cs
@@ -444,7 +444,7 @@
/// <param name="deviceId"></param>
/// <param name="value"></param>
/// <returns></returns>
- public SdaResEntity InboundFinishConfirm(int deviceId, string stationCode)
+ public SdaResEntity InboundFinishConfirm(int deviceId, bool value, string stationCode)
{
SdaResEntity _SdaResEntity = new SdaResEntity();
try
@@ -457,7 +457,72 @@
var Station = StationResult.resData as StationEntity;
string msg = "";
- var result = Station.InboundFinishConfirm(stationCode, out msg);
+ var result = Station.InboundFinishConfirm(stationCode, value, out msg);
+ _SdaResEntity.result = result;
+ _SdaResEntity.resMsg = msg;
+ return _SdaResEntity;
+ }
+ catch (Exception ex)
+ {
+ _SdaResEntity.result = false;
+ _SdaResEntity.resMsg = ex.Message;
+ return _SdaResEntity;
+ }
+ }
+
+ /// <summary>
+ /// 鍑哄簱瀹屾垚宸茬‘璁�
+ /// </summary>
+ /// <param name="deviceId"></param>
+ /// <param name="value"></param>
+ /// <returns></returns>
+ public SdaResEntity OutboundFinishConfirm(int deviceId, bool value, string stationCode)
+ {
+ SdaResEntity _SdaResEntity = new SdaResEntity();
+ try
+ {
+ var StationResult = Station_CacheEntity.GetDeviceObj(deviceId);
+ if (!StationResult.result)
+ {
+ return StationResult;
+ }
+ var Station = StationResult.resData as StationEntity;
+
+ string msg = "";
+ var result = Station.OutboundFinishConfirm(stationCode, value, out msg);
+ _SdaResEntity.result = result;
+ _SdaResEntity.resMsg = msg;
+ return _SdaResEntity;
+ }
+ catch (Exception ex)
+ {
+ _SdaResEntity.result = false;
+ _SdaResEntity.resMsg = ex.Message;
+ return _SdaResEntity;
+ }
+ }
+
+ /// <summary>
+ /// 鍒囨崲妯″紡
+ /// </summary>
+ /// <param name="deviceId"></param>
+ /// <param name="value"></param>
+ /// <param name="stationCode"></param>
+ /// <returns></returns>
+ public SdaResEntity ChangeMode(int deviceId, int value, string stationCode)
+ {
+ SdaResEntity _SdaResEntity = new SdaResEntity();
+ try
+ {
+ var StationResult = Station_CacheEntity.GetDeviceObj(deviceId);
+ if (!StationResult.result)
+ {
+ return StationResult;
+ }
+ var Station = StationResult.resData as StationEntity;
+
+ string msg = "";
+ var result = Station.ChangeMode(stationCode, value, out msg);
_SdaResEntity.result = result;
_SdaResEntity.resMsg = msg;
return _SdaResEntity;
@@ -476,7 +541,7 @@
/// <param name="deviceId"></param>
/// <param name="value"></param>
/// <returns></returns>
- public SdaResEntity WriteInStoreTaskInfo(int deviceId, string stationCode, string toPlaceNo, short length, short width, short height)
+ public SdaResEntity WriteInStoreTaskInfo(int deviceId, string stationCode, string toPlaceNo, short length, short width, short height, int inbound_TaskID)
{
SdaResEntity _SdaResEntity = new SdaResEntity();
try
@@ -489,7 +554,190 @@
var Station = StationResult.resData as StationEntity;
string msg = "";
- var result = Station.WriteInStoreTaskInfo(stationCode, toPlaceNo, length, width, height, out msg);
+ var result = Station.WriteInStoreTaskInfo(stationCode, toPlaceNo, length, width, height, out msg, inbound_TaskID);
+ _SdaResEntity.result = result;
+ _SdaResEntity.resMsg = msg;
+ return _SdaResEntity;
+ }
+ catch (Exception ex)
+ {
+ _SdaResEntity.result = false;
+ _SdaResEntity.resMsg = ex.Message;
+ return _SdaResEntity;
+ }
+ }
+ /// <summary>
+ /// 鍐欏叆鐮佹澘浠诲姟淇℃伅
+ /// </summary>
+ /// <param name="deviceId"></param>
+ /// <param name="value"></param>
+ /// <returns></returns>
+ public SdaResEntity WritePalletizingTaskInfo(int deviceId, string stationCode,int taskID, short length, short width, short height,short rotate,short toplace,short placeX,short placeY, short placeZ,short lastnum)
+ {
+ SdaResEntity _SdaResEntity = new SdaResEntity();
+ try
+ {
+ var StationResult = Station_CacheEntity.GetDeviceObj(deviceId);
+ if (!StationResult.result)
+ {
+ return StationResult;
+ }
+ var Station = StationResult.resData as StationEntity;
+
+ string msg = "";
+ var result = Station.WritePalletizingTaskInfo(stationCode, taskID, length, width, height,rotate,toplace,placeX,placeY,placeZ,lastnum ,out msg);
+ _SdaResEntity.result = result;
+ _SdaResEntity.resMsg = msg;
+ return _SdaResEntity;
+ }
+ catch (Exception ex)
+ {
+ _SdaResEntity.result = false;
+ _SdaResEntity.resMsg = ex.Message;
+ return _SdaResEntity;
+ }
+ }
+ /// <summary>
+ /// 鐮佸灈瀹屾垚宸茬‘璁�
+ /// </summary>
+ /// <param name="deviceId"></param>
+ /// <param name="value"></param>
+ /// <returns></returns>
+ public SdaResEntity SetPalletizingTaskFinishAck(int deviceId, bool value, string stationCode)
+ {
+ SdaResEntity _SdaResEntity = new SdaResEntity();
+ try
+ {
+ var StationResult = Station_CacheEntity.GetDeviceObj(deviceId);
+ if (!StationResult.result)
+ {
+ return StationResult;
+ }
+ var Station = StationResult.resData as StationEntity;
+
+ string msg = "";
+ var result = Station.WriteStation_FinishACK(stationCode, value, out msg);
+ _SdaResEntity.result = result;
+ _SdaResEntity.resMsg = msg;
+ return _SdaResEntity;
+ }
+ catch (Exception ex)
+ {
+ _SdaResEntity.result = false;
+ _SdaResEntity.resMsg = ex.Message;
+ return _SdaResEntity;
+ }
+ }
+
+ /// <summary>
+ /// 鍐欏叆鍚堝寘浠诲姟淇℃伅
+ /// </summary>
+ /// <param name="deviceId"></param>
+ /// <param name="value"></param>
+ /// <returns></returns>
+ public SdaResEntity WriteSurroundTaskInfo(int deviceId, string stationCode, short taskID, short length, short width, short cartonhigh, short cartonwidth, short placex, short placey)
+ {
+ SdaResEntity _SdaResEntity = new SdaResEntity();
+ try
+ {
+ var StationResult = Station_CacheEntity.GetDeviceObj(deviceId);
+ if (!StationResult.result)
+ {
+ return StationResult;
+ }
+ var Station = StationResult.resData as StationEntity;
+
+ string msg = "";
+ var result = Station.WriteSurroundTaskInfo(stationCode, taskID, length, width, cartonhigh, cartonwidth, placex, placey, out msg);
+ _SdaResEntity.result = result;
+ _SdaResEntity.resMsg = msg;
+ return _SdaResEntity;
+ }
+ catch (Exception ex)
+ {
+ _SdaResEntity.result = false;
+ _SdaResEntity.resMsg = ex.Message;
+ return _SdaResEntity;
+ }
+ }
+ /// <summary>
+ /// 鍚堝寘瀹屾垚宸茬‘璁�
+ /// </summary>
+ /// <param name="deviceId"></param>
+ /// <param name="value"></param>
+ /// <returns></returns>
+ public SdaResEntity SetSurroundTaskFinishAck(int deviceId, bool value, string stationCode)
+ {
+ SdaResEntity _SdaResEntity = new SdaResEntity();
+ try
+ {
+ var StationResult = Station_CacheEntity.GetDeviceObj(deviceId);
+ if (!StationResult.result)
+ {
+ return StationResult;
+ }
+ var Station = StationResult.resData as StationEntity;
+
+ string msg = "";
+ var result = Station.WriteSurround_FinishACK(stationCode, value, out msg);
+ _SdaResEntity.result = result;
+ _SdaResEntity.resMsg = msg;
+ return _SdaResEntity;
+ }
+ catch (Exception ex)
+ {
+ _SdaResEntity.result = false;
+ _SdaResEntity.resMsg = ex.Message;
+ return _SdaResEntity;
+ }
+ }
+ public SdaResEntity WriteStation_ACK(int deviceId, bool value, string stationCode)
+ {
+ SdaResEntity _SdaResEntity = new SdaResEntity();
+ try
+ {
+ var StationResult = Station_CacheEntity.GetDeviceObj(deviceId);
+ if (!StationResult.result)
+ {
+ return StationResult;
+ }
+ var Station = StationResult.resData as StationEntity;
+
+ string msg = "";
+ var result = Station.WriteStation_ACK(stationCode, value, out msg);
+ _SdaResEntity.result = result;
+ _SdaResEntity.resMsg = msg;
+ return _SdaResEntity;
+ }
+ catch (Exception ex)
+ {
+ _SdaResEntity.result = false;
+ _SdaResEntity.resMsg = ex.Message;
+ return _SdaResEntity;
+ }
+ }
+ /// <summary>
+ /// 鍐欏叆鍑哄簱浠诲姟淇℃伅
+ /// </summary>
+ /// <param name="deviceId"></param>
+ /// <param name="stationCode"></param>
+ /// <param name="sourcePlaceNo"></param>
+ /// <param name="outbound_TaskID"></param>
+ /// <returns></returns>
+ public SdaResEntity WriteOutStoreTaskInfo(int deviceId, string stationCode, string sourcePlaceNo, int outbound_TaskID)
+ {
+ SdaResEntity _SdaResEntity = new SdaResEntity();
+ try
+ {
+ var StationResult = Station_CacheEntity.GetDeviceObj(deviceId);
+ if (!StationResult.result)
+ {
+ return StationResult;
+ }
+ var Station = StationResult.resData as StationEntity;
+
+ string msg = "";
+ var result = Station.WriteOutStoreTaskInfo(stationCode, sourcePlaceNo, out msg, outbound_TaskID);
_SdaResEntity.result = result;
_SdaResEntity.resMsg = msg;
return _SdaResEntity;
--
Gitblit v1.9.3