implemented editGoalieLtLossesPrompt

This commit is contained in:
Jonathan Lamothe 2019-11-14 02:49:55 -05:00
parent ac3b8e9522
commit 3ba3875752
2 changed files with 11 additions and 1 deletions

View File

@ -32,6 +32,7 @@ module Mtlstats.Actions.EditGoalie
, editGoalieLtMins
, editGoalieLtGoals
, editGoalieLtWins
, editGoalieLtLosses
) where
import Control.Monad (void)
@ -137,6 +138,14 @@ editGoalieLtWins
-> ProgState
editGoalieLtWins wins = editGoalie (gLifetime.gsWins .~ wins) EGLifetime
-- | Edits a goalie's lifetime losses
editGoalieLtLosses
:: Int
-- ^ The number of losses
-> ProgState
-> ProgState
editGoalieLtLosses = undefined
editGoalie :: (Goalie -> Goalie) -> EditGoalieMode -> ProgState -> ProgState
editGoalie f mode s = fromMaybe s $ do
gid <- s^.progMode.editGoalieStateL.egsSelectedGoalie

View File

@ -110,4 +110,5 @@ editGoalieLtWinsPrompt = numPrompt "Lifetime wins: " $
-- | Prompt to edit a goalie's lifetime losses
editGoalieLtLossesPrompt :: Prompt
editGoalieLtLossesPrompt = undefined
editGoalieLtLossesPrompt = numPrompt "Lifetime losses: " $
modify . editGoalieLtLosses