private void add_lines(DocumentInDTO doc, IEnumerable<DocumentLineItemEntity> lines)
 {
     var val = lines.Where(l => l.DocumentInDTO.ControlNumber == doc.ControlNumber);
     if (val != null)
     {
         val.ToList().ForEach(l => doc.AddLineItem(l.LineIdentifier, l.ResponseElements));
     }
 }
        private static IEnumerable<DocumentInDTO> get_save_info()
        {
            var doc1 = new DocumentInDTO
            {
                ISAControlNumber = 234,
                ControlNumber = 60001,
                DateSent = DateTime.Today,
                PartnerNumber = BusinessPartner.Initech.Number
            };
            doc1.AddResponseElement("19", "23432", "19");
            doc1.AddResponseElement("REF02", "CAD36", "ZZ");
            doc1.AddResponseElement("REF02", "001", "19");
            doc1.AddResponseElement("REF02", "3", "XE");
            doc1.AddLineItem("1", get_element_list());

            var doc2 = new DocumentInDTO
            {
                ControlNumber = 23443,
                ISAControlNumber = 234,
                DateSent = DateTime.Today,
                PartnerNumber = 1004
            };
            doc2.AddResponseElement("REF02", "23432", "ZZ");
            doc2.AddLineItem("1", get_element_list());

            return new List<DocumentInDTO> {doc1, doc2};
        }
        private static DocumentInDTO get_save_info()
        {
            var doc = new DocumentInDTO
                          {
                              ISAControlNumber = 234,
                              ControlNumber = 23443,
                              DateSent = DateTime.Today,
                              PartnerNumber = BusinessPartner.Initech.Number,

                          };
            doc.AddResponseElement("REF02", "23432", "ZZ");
            doc.AddLineItem("1", get_element_list());
            doc.AddLineItem("2", get_element_list());
            return doc;
        }
 private static DocumentInDTO get_save_info()
 {
     var doc = new DocumentInDTO
                   {
                       ControlNumber = 23444,
                       ISAControlNumber = 2300,
                       DateSent = DateTime.Today,
                       PartnerNumber = BusinessPartner.MicroCenter.Number
                   };
     doc.AddResponseElement("REF02", "23444", "ZZ");
     doc.AddLineItem("1", get_element_list());
     return doc;
 }
 private static DocumentInDTO get_save_info()
 {
     var doc = new DocumentInDTO
                   {
                       ISAControlNumber = 234,
                       ControlNumber = 60001,
                       DateSent = DateTime.Today,
                       PartnerNumber = BusinessPartner.MicroCenter.Number
                   };
     doc.AddResponseElement("19", "23432", "19");
     doc.AddResponseElement("REF02", "CAD36", "ZZ");
     doc.AddResponseElement("REF02", "001", "19");
     doc.AddResponseElement("REF02", "3", "XE");
     doc.AddLineItem("1", get_element_list());
     return doc;
 }