22
schangxiang@126.com
2024-12-10 c733a6f12bc6f8e7f206ef8173e8991041248c36
22
已修改11个文件
200 ■■■■■ 文件已修改
CC/iWareCC_ASRS/Connected Services/StationService/Reference.cs 42 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
CC/iWareCC_ASRS/Connected Services/StationService/StationService.wsdl 19 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
CC/iWareCC_ASRS/Connected Services/StationService/item2.xsd 19 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
CC/iWareCC_ASRS/Connected Services/StationService/item4.xsd 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
CC/iWareCC_ASRS/ThreadService/04_BZ21(搬运整垛机器人)/2、DataProcess_BZ21_IssueTask.cs 10 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SDA/iWareSda/Devices/4-Station/StationModel/DB/Items/Write/StationDB2ObjForWriteComm.cs 7 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SDA/iWareSda/Devices/4-Station/StationModel/DB/Items/Write/StationDBForWriteComm.cs 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SDA/iWareSda/Devices/4-Station/StationModel/StationEntity.cs 42 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SDA/iWareSda/Devices/4-Station/StationModel/Station_CacheEntity.cs 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SDA/iWareSda/Devices/4-Station/StationService/IStationService.cs 14 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SDA/iWareSda/Devices/4-Station/StationService/StationService.cs 38 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
CC/iWareCC_ASRS/Connected Services/StationService/Reference.cs
@@ -1436,6 +1436,9 @@
        private short W_ModeField;
        
        [System.Runtime.Serialization.OptionalFieldAttribute()]
        private bool W_NgFlagField;
        [System.Runtime.Serialization.OptionalFieldAttribute()]
        private bool W_OutboundFinishConfirmField;
        
        [System.Runtime.Serialization.OptionalFieldAttribute()]
@@ -1703,6 +1706,19 @@
                if ((this.W_ModeField.Equals(value) != true)) {
                    this.W_ModeField = value;
                    this.RaisePropertyChanged("W_Mode");
                }
            }
        }
        [System.Runtime.Serialization.DataMemberAttribute()]
        public bool W_NgFlag {
            get {
                return this.W_NgFlagField;
            }
            set {
                if ((this.W_NgFlagField.Equals(value) != true)) {
                    this.W_NgFlagField = value;
                    this.RaisePropertyChanged("W_NgFlag");
                }
            }
        }
@@ -2115,10 +2131,10 @@
        System.Threading.Tasks.Task<iWareCC.StationService.SdaResEntity> SetPalletizingTaskFinishAckAsync(int deviceId, bool value, string stationCode);
        
        [System.ServiceModel.OperationContractAttribute(Action="http://tempuri.org/IStationService/WriteSurroundTaskInfo", ReplyAction="http://tempuri.org/IStationService/WriteSurroundTaskInfoResponse")]
        iWareCC.StationService.SdaResEntity WriteSurroundTaskInfo(int deviceId, string stationCode, short taskID, short length, short width, short cartonhigh, short cartonwidth, short placex, short placey);
        iWareCC.StationService.SdaResEntity WriteSurroundTaskInfo(int deviceId, string stationCode, short taskID, short length, short width, short cartonhigh, short cartonwidth, short placex, short placey, bool isNgFlag);
        
        [System.ServiceModel.OperationContractAttribute(Action="http://tempuri.org/IStationService/WriteSurroundTaskInfo", ReplyAction="http://tempuri.org/IStationService/WriteSurroundTaskInfoResponse")]
        System.Threading.Tasks.Task<iWareCC.StationService.SdaResEntity> WriteSurroundTaskInfoAsync(int deviceId, string stationCode, short taskID, short length, short width, short cartonhigh, short cartonwidth, short placex, short placey);
        System.Threading.Tasks.Task<iWareCC.StationService.SdaResEntity> WriteSurroundTaskInfoAsync(int deviceId, string stationCode, short taskID, short length, short width, short cartonhigh, short cartonwidth, short placex, short placey, bool isNgFlag);
        
        [System.ServiceModel.OperationContractAttribute(Action="http://tempuri.org/IStationService/SetSurroundTaskFinishAck", ReplyAction="http://tempuri.org/IStationService/SetSurroundTaskFinishAckResponse")]
        iWareCC.StationService.SdaResEntity SetSurroundTaskFinishAck(int deviceId, bool value, string stationCode);
@@ -2155,6 +2171,12 @@
        
        [System.ServiceModel.OperationContractAttribute(Action="http://tempuri.org/IStationService/WriteStation_AllowIn", ReplyAction="http://tempuri.org/IStationService/WriteStation_AllowInResponse")]
        System.Threading.Tasks.Task<iWareCC.StationService.SdaResEntity> WriteStation_AllowInAsync(int deviceId, bool value, string stationCode);
        [System.ServiceModel.OperationContractAttribute(Action="http://tempuri.org/IStationService/WriteStation_NgFlag", ReplyAction="http://tempuri.org/IStationService/WriteStation_NgFlagResponse")]
        iWareCC.StationService.SdaResEntity WriteStation_NgFlag(int deviceId, bool value, string stationCode);
        [System.ServiceModel.OperationContractAttribute(Action="http://tempuri.org/IStationService/WriteStation_NgFlag", ReplyAction="http://tempuri.org/IStationService/WriteStation_NgFlagResponse")]
        System.Threading.Tasks.Task<iWareCC.StationService.SdaResEntity> WriteStation_NgFlagAsync(int deviceId, bool value, string stationCode);
        
        [System.ServiceModel.OperationContractAttribute(Action="http://tempuri.org/IStationService/WriteStation_PersonAllow", ReplyAction="http://tempuri.org/IStationService/WriteStation_PersonAllowResponse")]
        iWareCC.StationService.SdaResEntity WriteStation_PersonAllow(int deviceId, bool value, string stationCode);
@@ -2342,12 +2364,12 @@
            return base.Channel.SetPalletizingTaskFinishAckAsync(deviceId, value, stationCode);
        }
        
        public iWareCC.StationService.SdaResEntity WriteSurroundTaskInfo(int deviceId, string stationCode, short taskID, short length, short width, short cartonhigh, short cartonwidth, short placex, short placey) {
            return base.Channel.WriteSurroundTaskInfo(deviceId, stationCode, taskID, length, width, cartonhigh, cartonwidth, placex, placey);
        public iWareCC.StationService.SdaResEntity WriteSurroundTaskInfo(int deviceId, string stationCode, short taskID, short length, short width, short cartonhigh, short cartonwidth, short placex, short placey, bool isNgFlag) {
            return base.Channel.WriteSurroundTaskInfo(deviceId, stationCode, taskID, length, width, cartonhigh, cartonwidth, placex, placey, isNgFlag);
        }
        
        public System.Threading.Tasks.Task<iWareCC.StationService.SdaResEntity> WriteSurroundTaskInfoAsync(int deviceId, string stationCode, short taskID, short length, short width, short cartonhigh, short cartonwidth, short placex, short placey) {
            return base.Channel.WriteSurroundTaskInfoAsync(deviceId, stationCode, taskID, length, width, cartonhigh, cartonwidth, placex, placey);
        public System.Threading.Tasks.Task<iWareCC.StationService.SdaResEntity> WriteSurroundTaskInfoAsync(int deviceId, string stationCode, short taskID, short length, short width, short cartonhigh, short cartonwidth, short placex, short placey, bool isNgFlag) {
            return base.Channel.WriteSurroundTaskInfoAsync(deviceId, stationCode, taskID, length, width, cartonhigh, cartonwidth, placex, placey, isNgFlag);
        }
        
        public iWareCC.StationService.SdaResEntity SetSurroundTaskFinishAck(int deviceId, bool value, string stationCode) {
@@ -2398,6 +2420,14 @@
            return base.Channel.WriteStation_AllowInAsync(deviceId, value, stationCode);
        }
        
        public iWareCC.StationService.SdaResEntity WriteStation_NgFlag(int deviceId, bool value, string stationCode) {
            return base.Channel.WriteStation_NgFlag(deviceId, value, stationCode);
        }
        public System.Threading.Tasks.Task<iWareCC.StationService.SdaResEntity> WriteStation_NgFlagAsync(int deviceId, bool value, string stationCode) {
            return base.Channel.WriteStation_NgFlagAsync(deviceId, value, stationCode);
        }
        public iWareCC.StationService.SdaResEntity WriteStation_PersonAllow(int deviceId, bool value, string stationCode) {
            return base.Channel.WriteStation_PersonAllow(deviceId, value, stationCode);
        }
CC/iWareCC_ASRS/Connected Services/StationService/StationService.wsdl
@@ -164,6 +164,12 @@
  <wsdl:message name="IStationService_WriteStation_AllowIn_OutputMessage">
    <wsdl:part name="parameters" element="tns:WriteStation_AllowInResponse" />
  </wsdl:message>
  <wsdl:message name="IStationService_WriteStation_NgFlag_InputMessage">
    <wsdl:part name="parameters" element="tns:WriteStation_NgFlag" />
  </wsdl:message>
  <wsdl:message name="IStationService_WriteStation_NgFlag_OutputMessage">
    <wsdl:part name="parameters" element="tns:WriteStation_NgFlagResponse" />
  </wsdl:message>
  <wsdl:message name="IStationService_WriteStation_PersonAllow_InputMessage">
    <wsdl:part name="parameters" element="tns:WriteStation_PersonAllow" />
  </wsdl:message>
@@ -274,6 +280,10 @@
    <wsdl:operation name="WriteStation_AllowIn">
      <wsdl:input wsaw:Action="http://tempuri.org/IStationService/WriteStation_AllowIn" message="tns:IStationService_WriteStation_AllowIn_InputMessage" />
      <wsdl:output wsaw:Action="http://tempuri.org/IStationService/WriteStation_AllowInResponse" message="tns:IStationService_WriteStation_AllowIn_OutputMessage" />
    </wsdl:operation>
    <wsdl:operation name="WriteStation_NgFlag">
      <wsdl:input wsaw:Action="http://tempuri.org/IStationService/WriteStation_NgFlag" message="tns:IStationService_WriteStation_NgFlag_InputMessage" />
      <wsdl:output wsaw:Action="http://tempuri.org/IStationService/WriteStation_NgFlagResponse" message="tns:IStationService_WriteStation_NgFlag_OutputMessage" />
    </wsdl:operation>
    <wsdl:operation name="WriteStation_PersonAllow">
      <wsdl:input wsaw:Action="http://tempuri.org/IStationService/WriteStation_PersonAllow" message="tns:IStationService_WriteStation_PersonAllow_InputMessage" />
@@ -516,6 +526,15 @@
        <soap:body use="literal" />
      </wsdl:output>
    </wsdl:operation>
    <wsdl:operation name="WriteStation_NgFlag">
      <soap:operation soapAction="http://tempuri.org/IStationService/WriteStation_NgFlag" style="document" />
      <wsdl:input>
        <soap:body use="literal" />
      </wsdl:input>
      <wsdl:output>
        <soap:body use="literal" />
      </wsdl:output>
    </wsdl:operation>
    <wsdl:operation name="WriteStation_PersonAllow">
      <soap:operation soapAction="http://tempuri.org/IStationService/WriteStation_PersonAllow" style="document" />
      <wsdl:input>
CC/iWareCC_ASRS/Connected Services/StationService/item2.xsd
@@ -327,6 +327,7 @@
        <xs:element minOccurs="0" name="cartonwidth" type="xs:short" />
        <xs:element minOccurs="0" name="placex" type="xs:short" />
        <xs:element minOccurs="0" name="placey" type="xs:short" />
        <xs:element minOccurs="0" name="isNgFlag" type="xs:boolean" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
@@ -437,6 +438,22 @@
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="WriteStation_NgFlag">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="deviceId" type="xs:int" />
        <xs:element minOccurs="0" name="value" type="xs:boolean" />
        <xs:element minOccurs="0" name="stationCode" nillable="true" type="xs:string" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="WriteStation_NgFlagResponse">
    <xs:complexType>
      <xs:sequence>
        <xs:element xmlns:q28="http://schemas.datacontract.org/2004/07/iWareSda" minOccurs="0" name="WriteStation_NgFlagResult" nillable="true" type="q28:SdaResEntity" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="WriteStation_PersonAllow">
    <xs:complexType>
      <xs:sequence>
@@ -449,7 +466,7 @@
  <xs:element name="WriteStation_PersonAllowResponse">
    <xs:complexType>
      <xs:sequence>
        <xs:element xmlns:q28="http://schemas.datacontract.org/2004/07/iWareSda" minOccurs="0" name="WriteStation_PersonAllowResult" nillable="true" type="q28:SdaResEntity" />
        <xs:element xmlns:q29="http://schemas.datacontract.org/2004/07/iWareSda" minOccurs="0" name="WriteStation_PersonAllowResult" nillable="true" type="q29:SdaResEntity" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
CC/iWareCC_ASRS/Connected Services/StationService/item4.xsd
@@ -131,6 +131,7 @@
      <xs:element minOccurs="0" name="W_KittingInfo" type="xs:short" />
      <xs:element minOccurs="0" name="W_Length" type="xs:short" />
      <xs:element minOccurs="0" name="W_Mode" type="xs:short" />
      <xs:element minOccurs="0" name="W_NgFlag" type="xs:boolean" />
      <xs:element minOccurs="0" name="W_OutboundFinishConfirm" type="xs:boolean" />
      <xs:element minOccurs="0" name="W_Outbound_TaskID" type="xs:short" />
      <xs:element minOccurs="0" name="W_PackageLength" type="xs:short" />
CC/iWareCC_ASRS/ThreadService/04_BZ21£¨°áÔËÕû¶â»úÆ÷ÈË£©/2¡¢DataProcess_BZ21_IssueTask.cs
@@ -78,12 +78,20 @@
                            cartonhigh = (short)upiObj.Info3;
                            cartonwidth = (short)upiObj.Info2;
                            var ngFlag = false;
                            var queryFlag = (int)UpiFlagEnum.NG;
                            var ngCount = upilist.Count(x => x.UpiFlag == queryFlag);
                            if (ngCount > 0)
                            {
                                ngFlag = true;
                            }
                            //这里下发 ä»»åŠ¡
                            using (StationServiceClient client = new StationServiceClient())
                            {
                                var plcres = client.WriteSurroundTaskInfo((int)EDevice.Station, rgvLocation, short.Parse(task.TaskNo),
                                      (short)upilength, (short)upiwidth, cartonhigh, cartonwidth, 0, 0);
                                      (short)upilength, (short)upiwidth, cartonhigh, cartonwidth, 0, 0, ngFlag);
                                if (!plcres.result)
                                {
                                    SystemWarningMsg._lbl_Alert_DataProcess_BZ21_IssueTask = $"{rgvLocation.ToString()}-下发入库任务 å¤±è´¥,WriteInStoreTaskInfoAsync è¿”回:{plcres.resMsg}";
SDA/iWareSda/Devices/4-Station/StationModel/DB/Items/Write/StationDB2ObjForWriteComm.cs
@@ -21,6 +21,13 @@
        //[Description("人工放行")]
        //public bool W_PersonAllow { get; set; }
        /// <summary>
        /// NG包标记
        /// </summary>
        [Description("NG包标记")]
        public bool W_NgFlag { get; set; }
        /// <summary>
        /// è¡¥æ¿å·¥ä½å…è®¸è¿›æ¿
        /// </summary>
SDA/iWareSda/Devices/4-Station/StationModel/DB/Items/Write/StationDBForWriteComm.cs
@@ -25,6 +25,12 @@
        //public string W_PersonAllow { get; set; }
        /// <summary>
        /// NG包标记
        /// </summary>
        [Description("NG包标记")]
        public string W_NgFlag { get; set; }
        /// <summary>
        /// è¡¥æ¿å·¥ä½å…è®¸è¿›æ¿
        /// </summary>
        [Description("补板工位允许进板")]
SDA/iWareSda/Devices/4-Station/StationModel/StationEntity.cs
@@ -592,7 +592,8 @@
        /// <param name="placey"></param>
        /// <param name="msg"></param>
        /// <returns></returns>
        public bool WriteSurroundTaskInfo(string stationCode, short taskID, short length, short width, short cartonhigh, short cartonwidth, short placex, short placey, out string msg)
        public bool WriteSurroundTaskInfo(string stationCode, short taskID, short length, short width, short cartonhigh, short cartonwidth,
            short placex, short placey, out string msg, bool isNgFlag)
        {
            try
            {
@@ -661,6 +662,17 @@
                    return false;
                }
                //增加写入NG标记
                if (isNgFlag)
                {
                    b2 = this.plcService.WriteValuePoint(stationObj.W_NgFlag, true, view_stationObj.W_NgFlag);
                    if (!b2.result)
                    {
                        msg = string.Format("向Station地址{0} å†™ NG包标记 " + true + "失败,返回结果:" + b2.resMsg,
                           stationObj.W_NgFlag);
                        return false;
                    }
                }
                return true;
            }
@@ -779,6 +791,34 @@
            }
        }
        public bool WriteStation_NgFlag(string stationCode, bool value, out string msg)
        {
            try
            {
                msg = "";
                var stationObj = this.DBBlockForWrite.W_StationForWriteCommList.Where(x => x.StationCode == stationCode).FirstOrDefault();
                var view_stationObj = this.View.W_StationForWriteCommList.Where(x => x.StationCode == stationCode).FirstOrDefault();
                MessageModel b2 = this.plcService.WriteValuePoint(stationObj.W_NgFlag, value, view_stationObj.W_NgFlag);
                if (!b2.result)
                {
                    msg = string.Format("向Station" + stationCode + " å†™å…¥ NG包标记 åœ°å€{0} å†™  " + value + "失败,返回结果:" + b2.resMsg,
                        stationObj.W_OutboundFinishConfirm);
                    return false;
                }
                return true;
            }
            catch (Exception ex)
            {
                msg = ex.Message;
                var logcontext = string.Format("向Statio NG包标记 å‡ºçް异叏:" + JsonConvert.SerializeObject(ex),
                        "");
                Log4NetHelper.WriteErrorLog(Station_CacheEntity.curLogType, logcontext, ex);
                return false;
            }
        }
        /// <summary>
        /// å†™å…¥ äººå·¥æ”¾è¡Œ
        /// </summary>
SDA/iWareSda/Devices/4-Station/StationModel/Station_CacheEntity.cs
@@ -219,6 +219,8 @@
            {
                StationCode = StationLocationEnum.BZ21.ToString(),
                W_NgFlag = W_DBHeaderWithSeparate_BZ21 + "0.2",
                W_DataFinish = W_DBHeaderWithSeparate_BZ21 + "0.0",
                W_SurroundTaskFinish = W_DBHeaderWithSeparate_BZ21 + "0.1",
                W_X_Offset = W_DBHeaderWithSeparate_BZ21 + "10.0",
SDA/iWareSda/Devices/4-Station/StationService/IStationService.cs
@@ -179,7 +179,8 @@
        SdaResEntity SetPalletizingTaskFinishAck(int deviceId, bool value, string stationCode);
        [OperationContract]
        SdaResEntity WriteSurroundTaskInfo(int deviceId, string stationCode, short taskID, short length, short width, short cartonhigh, short cartonwidth, short placex, short placey);
        SdaResEntity WriteSurroundTaskInfo(int deviceId, string stationCode, short taskID, short length, short width,
            short cartonhigh, short cartonwidth, short placex, short placey, bool isNgFlag);
        [OperationContract]
        SdaResEntity SetSurroundTaskFinishAck(int deviceId, bool value, string stationCode);
@@ -240,6 +241,17 @@
        /// <summary>
        /// å†™å…¥NG包标记
        /// </summary>
        /// <param name="deviceId"></param>
        /// <param name="value"></param>
        /// <param name="stationCode"></param>
        /// <returns></returns>
        [OperationContract]
        SdaResEntity WriteStation_NgFlag(int deviceId, bool value, string stationCode);
        /// <summary>
        /// å†™å…¥ äººå·¥æ”¾è¡Œ
        /// </summary>
        /// <param name="deviceId"></param>
SDA/iWareSda/Devices/4-Station/StationService/StationService.cs
@@ -684,7 +684,8 @@
        /// <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)
        public SdaResEntity WriteSurroundTaskInfo(int deviceId, string stationCode, short taskID, short length, short width,
            short cartonhigh, short cartonwidth, short placex, short placey, bool isNgFlag)
        {
            SdaResEntity _SdaResEntity = new SdaResEntity();
            try
@@ -697,7 +698,7 @@
                var Station = StationResult.resData as StationEntity;
                string msg = "";
                var result = Station.WriteSurroundTaskInfo(stationCode, taskID, length, width, cartonhigh, cartonwidth, placex, placey, out msg);
                var result = Station.WriteSurroundTaskInfo(stationCode, taskID, length, width, cartonhigh, cartonwidth, placex, placey, out msg, isNgFlag);
                _SdaResEntity.result = result;
                _SdaResEntity.resMsg = msg;
                return _SdaResEntity;
@@ -800,6 +801,39 @@
        }
        /// <summary>
        /// å†™å…¥NG包标记
        /// </summary>
        /// <param name="deviceId"></param>
        /// <param name="value"></param>
        /// <param name="stationCode"></param>
        /// <returns></returns>
        public SdaResEntity WriteStation_NgFlag(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_NgFlag(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>