blob: 4e673faf8fd482b8935bf4b8cc9f63124fdc9211 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
module LoggedIn.Income.Update
( update
) where
import Effects exposing (Effects)
import Form exposing (Form)
import LoggedData exposing (LoggedData)
import LoggedIn.Income.Model as IncomeModel
import LoggedIn.Income.Action as IncomeAction
update : LoggedData -> IncomeAction.Action -> IncomeModel.Model -> (IncomeModel.Model, Effects IncomeAction.Action)
update loggedData action model =
case action of
IncomeAction.NoOp ->
( model
, Effects.none
)
IncomeAction.AddIncomeAction formAction ->
( { model | addIncome = Form.update formAction model.addIncome }
, Effects.none
)
|