Esempio n. 1
0
        public ActionResult Create([Bind(Include = "name,email,contact_number,password,Confirm_password")] patient patient)
        {
            if (ModelState.IsValid)
            {
                db.patients.Add(patient);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            return(View(patient));
        }
Esempio n. 2
0
        public ActionResult Create([Bind(Include = "clinic_start_time,hospital_start_time,clinic_end_time,hospital_end_time,is_avalible,Clinic_day,hospial_day,doctor_id")] doctor_scedule doctor_scedule)
        {
            if (ModelState.IsValid)
            {
                db.doctor_scedule.Add(doctor_scedule);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            return(View(doctor_scedule));
        }
Esempio n. 3
0
        public ActionResult Create([Bind(Include = "email,password")] admin admin)
        {
            if (ModelState.IsValid)
            {
                db.admins.Add(admin);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            return(View(admin));
        }
Esempio n. 4
0
        public ActionResult Create([Bind(Include = "doctor_id,name,date_of_birth,adress,phone,MBBS_Code,email,password,confirm_password,clinic_name,hospital_address,hospital_name,clinic_address,city,specialization,practising_years")] doctor doctor)
        {
            if (ModelState.IsValid)
            {
                db.doctors.Add(doctor);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            return(View(doctor));
        }