added pointsAccounted field to GameState

This commit is contained in:
Jonathan Lamothe 2019-09-14 00:09:28 -04:00
parent 1a25c0dc92
commit 926a125692

View File

@ -55,6 +55,7 @@ module Mtlstats.Types (
awayScore,
overtimeFlag,
dataVerified,
pointsAccounted,
-- ** CreatePlayerState Lenses
cpsNumber,
cpsName,
@ -176,24 +177,25 @@ instance Show ProgMode where
-- | The game state
data GameState = GameState
{ _gameYear :: Maybe Int
{ _gameYear :: Maybe Int
-- ^ The year the game took place
, _gameMonth :: Maybe Int
, _gameMonth :: Maybe Int
-- ^ The month the game took place
, _gameDay :: Maybe Int
, _gameDay :: Maybe Int
-- ^ The day of the month the game took place
, _gameType :: Maybe GameType
, _gameType :: Maybe GameType
-- ^ The type of game (home/away)
, _otherTeam :: String
, _otherTeam :: String
-- ^ The name of the other team
, _homeScore :: Maybe Int
, _homeScore :: Maybe Int
-- ^ The home team's score
, _awayScore :: Maybe Int
, _awayScore :: Maybe Int
-- ^ The away team's score
, _overtimeFlag :: Maybe Bool
, _overtimeFlag :: Maybe Bool
-- ^ Indicates whether or not the game went into overtime
, _dataVerified :: Bool
, _dataVerified :: Bool
-- ^ Set to 'True' when the user confirms the entered data
, _pointsAccounted :: Int
} deriving (Eq, Show)
-- | The type of game
@ -470,15 +472,16 @@ newProgState = ProgState
-- | Constructor for a 'GameState'
newGameState :: GameState
newGameState = GameState
{ _gameYear = Nothing
, _gameMonth = Nothing
, _gameDay = Nothing
, _gameType = Nothing
, _otherTeam = ""
, _homeScore = Nothing
, _awayScore = Nothing
, _overtimeFlag = Nothing
, _dataVerified = False
{ _gameYear = Nothing
, _gameMonth = Nothing
, _gameDay = Nothing
, _gameType = Nothing
, _otherTeam = ""
, _homeScore = Nothing
, _awayScore = Nothing
, _overtimeFlag = Nothing
, _dataVerified = False
, _pointsAccounted = 0
}
-- | Constructor for a 'CreatePlayerState'