Ejemplo n.º 1
0
        public ActionResult CreateProducer(Models.Producer record)
        {
            DeltaXMapper <Models.Producer, Producer> mapobj = new DeltaXMapper <Models.Producer, Producer>();
            DeltaXRepository obj = new DeltaXRepository();

            obj.AddProducer(mapobj.Translate(record));
            return(RedirectToAction("CreateMovie"));
        }
Ejemplo n.º 2
0
        public JsonResult AjaxMethodAddProducers(string name, string sex, string dob, string bio)
        {
            DeltaXRepository obj = new DeltaXRepository();

            try
            {
                if (obj.AddProducer(name, sex, dob, bio))
                {
                    return(Json("Data is successfully added"));
                }
                else
                {
                    return(Json("Errror in adding Data"));
                }
            }
            catch
            {
                return(Json("Errror in adding Data"));
            }
        }