Ejemplo n.º 1
0
        public int SaveNewYear(string name, DateTime Date, int Year, int ownerID)
        {
            DataRepository dataRepository = new DataRepository();
            Year yr = new Year();
            yr.Name = name;
            yr.Year1 = Year;
            yr.Date = Date;
            yr.OwnerID = ownerID;

            int YID = dataRepository.Add(yr);
            return YID;
        }
Ejemplo n.º 2
0
 public int SaveNewTournCourse(string name, int YID, int ST)
 {
     DataRepository dataRepository = new DataRepository();
     Course course = new Course();
     course.CourseName = name;
     course.Stableford_Total = ST;
     course.YID = YID;
     int CID = dataRepository.Add(course);
     return CID;
 }
Ejemplo n.º 3
0
        public void SaveNewHole(int CID, int YID, int holenum, int par, int pin, int LD, int SIndx)
        {
            DataRepository dataRepository = new DataRepository();
            Hole h = new Hole();
            h.CourseID = CID;
            h.YearID = YID;
            h.HoleNum = holenum;
            h.Par = par;
            h.N_pin = pin;
            h.L_drive = LD;
            h.SI = SIndx;

            dataRepository.Add(h);
        }
Ejemplo n.º 4
0
 public int SaveNewTourn(string name, DateTime date, int yr)
 {
     DataRepository dataRepository = new DataRepository();
     CourseUA course = new CourseUA();
     course.CourseName = name;
     course.Stableford_Total = 5;
     int CID = dataRepository.Add(course);
     return CID;
 }
Ejemplo n.º 5
0
 public int SaveNewCourse(string name, int stable)
 {
     DataRepository dataRepository = new DataRepository();
     CourseUA course = new CourseUA();
     course.CourseName = name;
     course.Stableford_Total = stable;
     int CID = dataRepository.Add(course);
     return CID;
 }