public string Editemployee(tbl_MCE_Employee mce_Employee) { DynamicParameters param = new DynamicParameters(); param.Add("@P_CHRACTION", "EMPLOYEEUPDATE"); param.Add("@P_intID", mce_Employee.intID); param.Add("@P_vchEmployeeCode", mce_Employee.vchEmployeeCode); param.Add("@P_vchName", mce_Employee.vchName); param.Add("@P_dtDOJ ", mce_Employee.dtDOJ); param.Add("@P_intJoinCategoryID", mce_Employee.intJoinCategoryID); param.Add("@P_intCourseID", mce_Employee.intCourseID); param.Add("@p_vchCourseName", mce_Employee.vchCourseName); param.Add("@P_intBranchID", mce_Employee.intBranchID); param.Add("@p_vchBranchName", mce_Employee.vchBranchName); param.Add("@P_intDesignationID", mce_Employee.intDesignationID); param.Add("@P_vchDesignation", mce_Employee.vchDesignation); param.Add("@P_intRoleID ", mce_Employee.intRoleID); param.Add("@P_intLevelID", mce_Employee.intLevelID); param.Add("@P_intRAID", mce_Employee.intRAID); param.Add("@P_intApprovalByID ", mce_Employee.intApprovalByID); param.Add("@P_vchGender", mce_Employee.vchGender); param.Add("@P_vchHighestQualification ", mce_Employee.vchHighestQualification); param.Add("@P_decExperienceAsJoiningDate ", mce_Employee.decExperienceAsJoiningDate); param.Add("@P_vchRemarks ", mce_Employee.vchRemarks); param.Add("@P_VCHMSGOUT", dbType: DbType.String, direction: ParameterDirection.Output, size: 5215585); return(DapperORM.ExecuteDML("SP_MCE_Employee_DML", param, "@P_VCHMSGOUT")); }
public ActionResult CreateEmployee(tbl_MCE_Employee mce_Employee) { mce_Employee.vchPassword = Util.GetHashByte("password"); _employee.AddEmployee(mce_Employee); ModelState.Clear(); var gender = new List <DDL_Data> { new DDL_Data() { vchText = "Male", vchValue = "Male" }, new DDL_Data() { vchText = "Female", vchValue = "Female" }, new DDL_Data() { vchText = "prefer not to say", vchValue = "prefer not to say" } }; ViewBag.gender = gender.ToList(); ViewBag.courseList = _course.CourseList1().ToList(); //ViewBag.branchList = _branches.BranchList().ToList(); ViewBag.designationList = _designation.DesignationList().ToList(); ViewBag.joinCategoryList = _joincategory.JoinCategoryList().ToList(); ViewBag.roleList = _role.RoleList().ToList(); ViewBag.levelList = _level.LevelList().ToList(); ViewBag.employeeList = _employee.EmployeeList1().ToList(); TempData["Success"] = "Data Created Successfully"; return(View()); }
public string Deleteemployee(tbl_MCE_Employee mce_Employee) { DynamicParameters param = new DynamicParameters(); param.Add("@P_CHRACTION", "EMPLOYEEDELETE"); param.Add("@P_intID", mce_Employee.intID); param.Add("@P_VCHMSGOUT", dbType: DbType.String, direction: ParameterDirection.Output, size: 5215585); return(DapperORM.ExecuteDML("SP_MCE_Employee_DML", param, "@P_VCHMSGOUT")); }
public ActionResult Edit(int?id) { if (id == null) { return(new HttpStatusCodeResult(HttpStatusCode.BadRequest)); } tbl_MCE_Employee employee = _employee.EmployeeDetails((int)id); var gender = new List <DDL_Data> { new DDL_Data() { vchText = "Male", vchValue = "Male" }, new DDL_Data() { vchText = "Female", vchValue = "Female" }, new DDL_Data() { vchText = "prefer not to say", vchValue = "prefer not to say" } }; ViewBag.gender = gender.ToList(); ViewBag.courseList = _course.CourseList1().ToList(); //ViewBag.branchList = _branches.BranchList().ToList(); ViewBag.designationList = _designation.DesignationList().ToList(); ViewBag.joinCategoryList = _joincategory.JoinCategoryList().ToList(); ViewBag.roleList = _role.RoleList().ToList(); ViewBag.levelList = _level.LevelList().ToList(); ViewBag.employeeList = _employee.EmployeeList1().ToList(); ViewBag.DefaultSubject = employee.intCourseID; ViewBag.DefaultBranch = employee.intBranchID; return(View(employee)); }
public ActionResult EditEmployee(tbl_MCE_Employee mce_Employee) { _employee.Editemployee(mce_Employee); TempData["Success"] = "Data Updated Successfully"; return(RedirectToAction("ViewEmployeeDataTable", "Employee")); }