示例#1
0
        public AspoheaderPOHeaderRetrieveResponseAPI POHeaderRetrieve(Poheaderretrievecriteria poheaderretrievecriteria)
        {
            var result = new AspoheaderPOHeaderRetrieveResponseAPI();

            var pdspoheaderretrieve = new pdspoheaderretrieveDataSet();

            var pdspohdr = new pdspohdrDataSet();

            var pdswlstatus = new pdswlstatusDataSet();

            var pdsmessaging = new pdsmessagingDataSet();

            DataRow ttblpoheaderretrievecriteriaCriteria = pdspoheaderretrieve.ttblpoheaderretrievecriteria.NewttblpoheaderretrievecriteriaRow();

            Poheaderretrievecriteria.UpdateRowFromPoheaderretrievecriteria(ref ttblpoheaderretrievecriteriaCriteria, poheaderretrievecriteria);
            pdspoheaderretrieve.ttblpoheaderretrievecriteria.AddttblpoheaderretrievecriteriaRow((pdspoheaderretrieveDataSet.ttblpoheaderretrievecriteriaRow)ttblpoheaderretrievecriteriaCriteria);

            string cErrorMessage = string.Empty;


            NLogLoggerP.Trace("POHeaderRetrieve - Aspoheader - Before Call");
            StopwatchUtil.Time(
                () =>
            {
                using (var poAspoheaderproxy = this.proxyAppObject.CreatePO_aspoheaderproxy())
                {
                    this.SetRequiredContextParameters();
                    poAspoheaderproxy.POHeaderRetrieve(ref pdsContext, pdspoheaderretrieve, out pdspohdr, out pdswlstatus, out pdsmessaging, out cErrorMessage);
                }
            });
            NLogLoggerP.Info("POHeaderRetrieve - Aspoheader - After Call");


            this.ReportErrors(cErrorMessage);
            this.ReportErrors(this.pdsContext);
            this.ReportErrors(pdspoheaderretrieve);

            foreach (DataRow row in pdsmessaging.ttblmessaging)
            {
                result.messaging.Add(Messaging.BuildMessagingFromRow(row));
            }
            if (pdspohdr.ttblpohdr.Count > 0)
            {
                result.pohdr = Pohdr.BuildPohdrFromRow(pdspohdr.ttblpohdr[0]);
            }

            if (pdswlstatus.ttblwlstatus.Count > 0)
            {
                result.wlstatus = Wlstatus.BuildWlstatusFromRow(pdswlstatus.ttblwlstatus[0]);
            }


            return(result);
        }
示例#2
0
 public AspoheaderPOHeaderRetrieveResponseAPI POHeaderRetrieve(Poheaderretrievecriteria poheaderretrievecriteria)
 {
     return(this.repository.POHeaderRetrieve(poheaderretrievecriteria));
 }
示例#3
0
 public AspoheaderPOHeaderRetrieveResponseAPI POHeaderRetrieve(Poheaderretrievecriteria poheaderretrievecriteria)
 {
     return(this.adapter.POHeaderRetrieve(poheaderretrievecriteria));
 }