protected virtual void RaiseResponseEvent(DataReciver.AlohaResponse e) { if (ResponseEvent != null) { ResponseEvent(e); } }
void OA_ResponseEvent(object sender, DataReciver.AlohaResponse e) { if (e.ResultId == 0) { MessageBox.Show(e.Err); } else { MessageBox.Show(e.AlohaTableNum.ToString()); } ((OrderToAloha.OrderToAloha)sender).CloseConnection(); }
void RC_DataRecive(object Fi) { try { DataReciver.STCommand InCommand = (DataReciver.STCommand)Fi; //Utils.ToCardLog("RC_DataRecive тип " + InCommand.CommandType); if (InCommand.Ansver) { DataReciver.AlohaResponse resp = new DataReciver.AlohaResponse(); resp.OrderId = InCommand.sendOrderToAlohaRequest.OrderId; resp.CommandType = InCommand.CommandType; resp.Err = InCommand.ExeptionMessage; resp.port = InCommand.SenderPort; resp.ResultId = InCommand.ResultId; if (InCommand.CommandType == DataReciver.STCommandType.AddOrder) { resp.AlohaCheckId = InCommand.sendOrderToAlohaRequest.AlohaCheckId; resp.AlohaTableNum = InCommand.sendOrderToAlohaRequest.AlohaTableNum; } else if (InCommand.CommandType == DataReciver.STCommandType.DeleteOrder) { } RaiseResponseEvent(resp); } else { } } catch (Exception e) { Utils.ToLog(e.Message); } }
void RL_ResponseEvent(DataReciver.AlohaResponse e) { RaiseResponseEvent(e); }