Ejemplo n.º 1
0
        private DataEF.SkaterSeasonStat SetSkaterStats(DataEF.Season dbSeason, DataEF.Skater dbSkater, SthsData.SkaterSeasonStats skaterStats)
        {
            var dbSeasonStats = new DataEF.SkaterSeasonStat()
            {
                Season = dbSeason,
                Skater = dbSkater,
                Team   = DataDB,
            };

            PopulateSkaterStats(dbSeasonStats, skaterStats);
            Database.SkaterSeasonStats.Add(dbSeasonStats);
            return(dbSeasonStats);
        }
Ejemplo n.º 2
0
        private DataEF.SkaterSeasonStat SetSubtotalSkaterStats(DataEF.Season dbSeason, DataEF.Skater dbSkater, SthsData.SkaterSeasonStats skaterStats)
        {
            var dbSeasonSubtotalStats = new DataEF.SkaterSeasonStat()
            {
                Season     = dbSeason,
                Skater     = dbSkater,
                Team       = dbSeason.Teams.Where(a => a.Acronym == skaterStats.TeamAcronym).First(),
                IsSubtotal = true
            };

            PopulateSkaterStats(dbSeasonSubtotalStats, skaterStats);
            Database.SkaterSeasonStats.Add(dbSeasonSubtotalStats);
            return(dbSeasonSubtotalStats);
        }
Ejemplo n.º 3
0
 private static void PopulateSkaterStats(DataEF.SkaterSeasonStat dbSeasonStats, SthsData.SkaterSeasonStats skaterStats)
 {
     dbSeasonStats.GP   = skaterStats.GP;
     dbSeasonStats.G    = skaterStats.G;
     dbSeasonStats.A    = skaterStats.A;
     dbSeasonStats.P    = skaterStats.P;
     dbSeasonStats.PLMI = skaterStats.PLMI;
     dbSeasonStats.PIM  = skaterStats.PIM;
     dbSeasonStats.PM5  = skaterStats.PM5;
     dbSeasonStats.HIT  = skaterStats.HIT;
     dbSeasonStats.HTT  = skaterStats.HTT;
     dbSeasonStats.SHT  = skaterStats.SHT;
     dbSeasonStats.OSB  = skaterStats.OSB;
     dbSeasonStats.OSM  = skaterStats.OSM;
     dbSeasonStats.SB   = skaterStats.SB;
     dbSeasonStats.MP   = skaterStats.MP;
     dbSeasonStats.PPG  = skaterStats.PPG;
     dbSeasonStats.PPA  = skaterStats.PPA;
     dbSeasonStats.PPP  = skaterStats.PPP;
     dbSeasonStats.PPS  = skaterStats.PPS;
     dbSeasonStats.PPM  = skaterStats.PPM;
     dbSeasonStats.PKG  = skaterStats.PKG;
     dbSeasonStats.PKA  = skaterStats.PKA;
     dbSeasonStats.PKP  = skaterStats.PKP;
     dbSeasonStats.PKS  = skaterStats.PKS;
     dbSeasonStats.PKM  = skaterStats.PKM;
     dbSeasonStats.GW   = skaterStats.GW;
     dbSeasonStats.GT   = skaterStats.GT;
     dbSeasonStats.FOW  = skaterStats.FOW;
     dbSeasonStats.FOT  = skaterStats.FOT;
     dbSeasonStats.GA   = skaterStats.GA;
     dbSeasonStats.TA   = skaterStats.TA;
     dbSeasonStats.EG   = skaterStats.EG;
     dbSeasonStats.HT   = skaterStats.HT;
     dbSeasonStats.PSG  = skaterStats.PSG;
     dbSeasonStats.PSS  = skaterStats.PSS;
     dbSeasonStats.FW   = skaterStats.FW;
     dbSeasonStats.FL   = skaterStats.FL;
     dbSeasonStats.FT   = skaterStats.FT;
     dbSeasonStats.GS   = skaterStats.GS;
     dbSeasonStats.PS   = skaterStats.PS;
     dbSeasonStats.WG   = skaterStats.WG;
     dbSeasonStats.WP   = skaterStats.WP;
     dbSeasonStats.S1   = skaterStats.S1;
     dbSeasonStats.S2   = skaterStats.S2;
     dbSeasonStats.S3   = skaterStats.S3;
 }