Ejemplo n.º 1
0
        private List<Contacts2> getContactList2(List<Contacts> contact)
        {
            List<Contacts2> conList = new List<Contacts2>();
            foreach (Contacts con in contact)
            {
                List<Contacts> contobj = db.ContactsList.ToList<Contacts>();
                Contacts contac = new Contacts();
                foreach (Contacts tempcontact in contobj)
                {
                    contac = tempcontact;
                }
                Contacts2 temp = new Contacts2();
                temp.Customer_Name = con.Customer_Name;
                temp.BaseNumber = con.AccountNo;
                // temp.BaseNumber = contact.AccountNo;
                temp.Customer_No = con.Customer_No;
                temp.Email_address1 = con.Email_address1;
                temp.Email_address2 = con.Email_address2;
                //report.Add(temp);

            }

            return conList;
        }
Ejemplo n.º 2
0
        private List<Contacts2> generatallcontacts(List<Contacts> cheqBkReports)
        {
            var report = new List<Contacts2>();

            foreach (Contacts chkBk in cheqBkReports)
            {

                var contactObj = _repository.Fetch<Contacts>().Where(p => p.contact_Id != 0).ToList();
                var UserRole = new Contacts();
                foreach (Contacts tempContact in contactObj)
                {
                    UserRole = tempContact;
                }

                var temp = new Contacts2();
                temp.Customer_Name = chkBk.Customer_Name;
                temp.Customer_No = chkBk.Customer_No;
                temp.BaseNumber = chkBk.AccountNo;
                temp.Email_address1 = chkBk.Email_address1;
                temp.Email_address2 = chkBk.Email_address2;
                temp.Address_Line1 = chkBk.Address_Line1;
                temp.Address_Line2 = chkBk.Address_Line2;

                report.Add(temp);
            }

            return report;
        }