public ActionResult Create(EMPLOYEE employee)
        {
            ViewData["Action"] = "Create";

            try
            {
                if (ModelState.IsValid)
                {
                    using (var dc = new db_ultramedicaDataContext(Helper.ConnectionString()))
                    {
                        dc.EMPLOYEEs.InsertOnSubmit(employee);
                        dc.SubmitChanges();
                    }
                    // TODO: Add insert logic here
                    return RedirectToAction("Index");
                }
                return View();
            }
            catch (Exception ex)
            {
                ViewData["ErrorMessage"] = ex.Message;
                return View(employee);
            }
        }
		private void detach_EMPLOYEEs(EMPLOYEE entity)
		{
			this.SendPropertyChanging();
			entity.COMPANY = null;
		}
		private void attach_EMPLOYEEs(EMPLOYEE entity)
		{
			this.SendPropertyChanging();
			entity.COMPANY = this;
		}
 partial void DeleteEMPLOYEE(EMPLOYEE instance);
 partial void UpdateEMPLOYEE(EMPLOYEE instance);
 partial void InsertEMPLOYEE(EMPLOYEE instance);
        public ActionResult Edit(EMPLOYEE employee)
        {
            ViewData["Action"] = "Edit";

            try
            {
                using (var dc = new db_ultramedicaDataContext(Helper.ConnectionString()))
                {
                    var employeedb = dc.EMPLOYEEs.SingleOrDefault(o => o.EMPLOYEE_ID.Equals(employee.EMPLOYEE_ID));

                    if (employeedb != null)
                    {
                        if (ModelState.IsValid)
                        {
                            employeedb.NAME = employee.NAME;
                            employeedb.COMPANY_ID = employee.COMPANY_ID;
                            employeedb.DISTRICT = employee.DISTRICT;
                            employeedb.AGE = employee.AGE;
                            employeedb.DEPARTMENT = employee.DEPARTMENT;
                            employeedb.MESS_STATUS = employee.MESS_STATUS;
                            employeedb.POSITION = employee.POSITION;
                            employeedb.SEX = employee.SEX;
                            employeedb.STATUS = employee.STATUS;
                            dc.SubmitChanges();
                        }
                    }

                }
                return RedirectToAction("Index");
            }
            catch (Exception ex)
            {
                ViewData["ErrorMessage"] = ex.Message;
                return View(employee);
            }
        }
        public ActionResult Edit(string employeeId)
        {
            if (Session["user"] != null)
            {
                InitializeSession();
                ViewData["Action"] = "Edit";
                EMPLOYEE employee = new EMPLOYEE();
                try
                {
                    ViewData["ErrorMessage"] = "";

                    // TODO: Add insert logic here
                    using (var dc = new db_ultramedicaDataContext(Helper.ConnectionString()))
                    {
                        employee = dc.EMPLOYEEs.SingleOrDefault(o => o.EMPLOYEE_ID.Equals(employeeId));
                    }
                    return View(employee);
                }
                catch (Exception ex)
                {
                    ViewData["ErrorMessage"] = ex.Message;
                    return View(employee);
                }
            }
            return RedirectToAction("LogOut", "Account");
        }