Exemple #1
0
        public Demographic AddDemo(Demographic demographic)
        {
            //var session = HttpContext.Current.Session;
            //if (session["NewPatient"] != null)
            //    physician.UserId = session["NewPatient"].ToString();
            Demographic demo = repository.AddDemo(demographic);

            return(demo);
        }
        public Demographic AddDemo(Demographic demographic)
        {
            Demographic demo = _Demographic.FindAll().OrderBy(p => p.DemoId).Last();

            demographic._id = ObjectId.GenerateNewId().ToString();
            Int32 demoid = demo.DemoId + 1;

            demographic.DemoId = demoid;

            _Demographic.Insert(demographic);
            return(demographic);
        }