added "Edit Standings" to edit menu

This commit is contained in:
Jonathan Lamothe 2020-01-15 00:13:50 -05:00
parent a909b9ba7a
commit 82603ba504
2 changed files with 7 additions and 0 deletions

View File

@ -36,6 +36,7 @@ module Mtlstats.Actions
, editSelectedPlayer , editSelectedPlayer
, editGoalie , editGoalie
, editSelectedGoalie , editSelectedGoalie
, editStandings
, addPlayer , addPlayer
, addGoalie , addGoalie
, resetCreatePlayerState , resetCreatePlayerState
@ -157,6 +158,10 @@ editSelectedGoalie f s = fromMaybe s $ do
goalies' = modifyNth n f goalies goalies' = modifyNth n f goalies
Just $ s & database.dbGoalies .~ goalies' Just $ s & database.dbGoalies .~ goalies'
-- | Enters edit standings mode
editStandings :: ProgState -> ProgState
editStandings = undefined
-- | Adds the entered player to the roster -- | Adds the entered player to the roster
addPlayer :: ProgState -> ProgState addPlayer :: ProgState -> ProgState
addPlayer s = fromMaybe s $ do addPlayer s = fromMaybe s $ do

View File

@ -180,6 +180,8 @@ editMenu = Menu "*** EDIT ***" ()
modify editPlayer modify editPlayer
, MenuItem '4' "Edit Goalie" $ , MenuItem '4' "Edit Goalie" $
modify editGoalie modify editGoalie
, MenuItem '5' "Edit Standings" $
modify editStandings
, MenuItem 'R' "Return to Main Menu" $ , MenuItem 'R' "Return to Main Menu" $
modify backHome modify backHome
] ]