예제 #1
0
        /// <summary>
        /// Delete current employee from employee dbcontext
        /// </summary>
        /// <returns></returns>
        public int DeleteEmployee(Employee employee)
        {
            int rowsAffected = -1;

            rowsAffected = _employeeRepository.Delete(employee);
            return rowsAffected;
        }
예제 #2
0
        /// <summary>
        /// For add new employee
        /// </summary>
        /// <param name="employee"></param>
        /// <returns></returns>
        public int AddEmployee(Employee employee)
        {
            int rowsAffected = -1;

            rowsAffected = _employeeRepository.Add(employee);
            return rowsAffected;
        }