using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Xml.Serialization; namespace RGDWCSServices.WCS { public class startBoxInvTask : HouseBase { /// /// 入参定义 /// [Serializable] public class PARA { private string _wh_id; private string _equip_type; private string _task_no; private List _loc_list; /// /// 库房编号 /// public string WH_ID { get { return this._wh_id; } set { this._wh_id = value; } } /// /// 任务号 /// public string TASK_NO { get { return this._task_no; } set { this._task_no = value; } } [XmlArrayItem(ElementName = "LOC")] public List LOC_LIST { get { return this._loc_list; } set { this._loc_list = value; } } } /// /// 出参定义 /// [Serializable] public class DATA : Base.OutPara { } /// /// 入参实体 /// private PARA _inPara; /// /// 出参实体 /// private DATA _outPara; /// /// 构造函数 /// public startBoxInvTask() { this._outPara = new DATA(); } /// /// 通知 /// /// 入参 /// 出参 /// 执行结果 public bool Notify(string sXmlIn, out string sXmlOut) { bool bResult = true; string sResult = string.Empty; sXmlOut = string.Empty; try { this._inPara = this.DeSerialize(sXmlIn); bResult = null != this._inPara; if (!bResult) { sResult = string.Format("入参错误(格式错误)"); return bResult; } bResult = this.START_BOXINVTASK("6000001378", _inPara.TASK_NO, _inPara.LOC_LIST, sXmlIn, out sResult); //bResult = this.START_BOXINVTASK(_inPara.WH_ID, _inPara.TASK_NO, _inPara.LOC_LIST, sXmlIn, out sResult); } catch (Exception ex) { bResult = false; sResult = string.Format(ex.Message); } finally { if (bResult) { this._outPara.RESULT_FLAG = Enum.RESULT_FLAG.Success.ToString("d"); } else { this._outPara.RESULT_FLAG = Enum.RESULT_FLAG.Fail.ToString("d"); } this._outPara.ERROR_INFO = sResult; sXmlOut = this.Serializer(this._outPara); } return bResult; } } }