private void UpdateCourse(SimpleEditableCourseStat source, CourseStat target) { target.CourseId = source.CourseId; target.TeeMarkerId = source.TeeMarkerId; target.Slope = source.Slope; target.Rating = source.Rating; target.Yardage = source.Yardage; }
internal void SetCourse(CourseStat courseStat) { _editingCourseStat = courseStat; if (CourseStat != null) { CourseStat.ErrorsChanged -= RaiseCanExecuteChanged; } CourseStat = new SimpleEditableCourseStat(); CopyCourseStat(courseStat, CourseStat); }
private void CopyCourseStat(CourseStat source, SimpleEditableCourseStat target) { target.CourseId = source.CourseId; if (EditMode) { target.Yardage = source.Yardage; target.TeeMarkerId = source.TeeMarkerId; target.Rating = source.Rating; target.Slope = source.Slope; } }
internal void InsertCourseStat(CourseStat courseStat) { using (_dbConnection = new SqlConnection(_connectionString)) { var parameters = new DynamicParameters(); parameters.Add("@COURSE_ID", courseStat.CourseId); parameters.Add("@TEE_MARKER_ID", courseStat.TeeMarkerId); parameters.Add("@SLOPE", courseStat.Slope); parameters.Add("@RATING", courseStat.Rating); parameters.Add("@YARDAGE", courseStat.Yardage); _dbConnection.Execute("dbo.USP_INS_COURSE_STAT", parameters, commandType: CommandType.StoredProcedure); } }
private void OnViewRounds(CourseStat courseStat) { ViewRoundsRequested(courseStat.CourseId); }
private void OnViewHoles(CourseStat courseStat) { ViewHolesRequested(courseStat.CourseId, courseStat.TeeMarkerId); }
internal void UpdateCourseStat(CourseStat _editingCourseStat) { throw new NotImplementedException(); }