Esempio n. 1
0
        public List<sp_VendContact_DM> ListVendContacts(Guid? vendorid, Guid? contactid)
        {
            List<sp_VendContact_DM> list = new List<sp_VendContact_DM>();
            try
            {
                using (VolTeerEntities context = new VolTeerEntities())
                {
                    list = (from result in context.sp_Vend_Contact_Select(vendorid, contactid)
                            select new sp_VendContact_DM
                            {
                                VendorID = result.VendorID,
                                ContactID = result.ContactID,
                                PrimaryContact = result.PrimaryContact
                            }).ToList();
                }
            }
            catch (Exception ex)
            {
                throw (ex);
            }

            return list;
        }