public ActionResult EditSocial(SocialMediaModel model)
        {
            CommonDataService cds = new CommonDataService();

            CommonModel cm = new CommonModel();

            cm = cds.GenerateCommonModel();
            Session["FaceBook"] = cm.FaceBook;
            Session["Twitter"] = cm.Twitter;
            Session["Youtube"] = cm.Youtube;
            Session["Instagram"] = cm.Instagram;
            Session["PhoneNumber"] = cm.PhoneNumber;
            Session["Email"] = cm.Email;
            Session["ShoppingHours"] = cm.ShoppingHours;
            ContactDataService dataService = new ContactDataService();
            try
            {
                string id = (string)Request.Form["id"];

                if (ModelState.IsValid)
                {
                    dataService.UpdateSocialMedia(int.Parse(id), model.SocialMediaUrl);

                    return RedirectToAction("Edit", "Contact");
                }
                else
                {

                    model = new SocialMediaModel();
                    model.SocialMediaId = int.Parse(id);
                    model.SocialMediaUrl = model.SocialMediaUrl;
                    return View(model);
                }
            }
            catch (Exception ex)
            {

                throw ex;
            }
            finally
            {
                dataService = null;

            }
        }
        public SocialMediaModel GenerateSocialMediaModelById(int id)
        {
            try
            {

                SocialMediaModel model = new SocialMediaModel();
                using (VenturadaDataContext vdc = new VenturadaDataContext())
                {

                    var table = from p in vdc.SocialMedias.ToList()
                                where p.SocialMediaId == id
                                select p;

                    model = new SocialMediaModel();
                    model.SocialMediaId = table.FirstOrDefault().SocialMediaId;
                    model.SocialMediaType = table.FirstOrDefault().SocialMediaType;
                    model.SocialMediaUrl = table.FirstOrDefault().SocialMediaUrl;
                    return model;
                }

            }
            catch (Exception ex)
            {

                throw ex;
            }
        }
        public ActionResult EditSocial(int socialMediaId)
        {
            CommonDataService cds = new CommonDataService();

            CommonModel cm = new CommonModel();

            cm = cds.GenerateCommonModel();
            Session["FaceBook"] = cm.FaceBook;
            Session["Twitter"] = cm.Twitter;
            Session["Youtube"] = cm.Youtube;
            Session["Instagram"] = cm.Instagram;
            Session["PhoneNumber"] = cm.PhoneNumber;
            Session["Email"] = cm.Email;
            Session["ShoppingHours"] = cm.ShoppingHours;
            try
            {
                ContactDataService dataService = new ContactDataService();
                SocialMediaModel model = new SocialMediaModel();

                model = dataService.GenerateSocialMediaModelById(socialMediaId);
                return View(model);
            }
            catch (Exception ex)
            {

                throw ex;
            }
        }