diff options
author | Joris | 2016-08-21 14:30:40 +0200 |
---|---|---|
committer | Joris | 2016-08-21 14:30:40 +0200 |
commit | 75804df1cb231033f94183e41cdf79d36d8f6710 (patch) | |
tree | 48b7932285091fdbdaba6d77586859c1e1750ce0 /src/client/elm/View.elm | |
parent | 3889d21ab58fbbc0134854b95013196a82e8d510 (diff) |
Show a message if there is an error during a server request
Diffstat (limited to 'src/client/elm/View.elm')
-rw-r--r-- | src/client/elm/View.elm | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/src/client/elm/View.elm b/src/client/elm/View.elm index 00833cb..4a0822f 100644 --- a/src/client/elm/View.elm +++ b/src/client/elm/View.elm @@ -14,6 +14,7 @@ import Dialog import Tooltip import View.Header as Header +import View.Errors as Errors import SignIn.View as SignInView import LoggedIn.View as LoggedInView @@ -25,15 +26,12 @@ view model = div [] [ Header.view model - , mainView model + , case model.view of + SignInView signIn -> + SignInView.view model signIn + LoggedInView loggedIn -> + LoggedInView.view model loggedIn + , Errors.view model.translations model.errors , Dialog.view model.dialog , Html.map Msg.Tooltip <| Tooltip.view model.tooltip ] - -mainView : Model -> Html Msg -mainView model = - case model.view of - SignInView signIn -> - SignInView.view model signIn - LoggedInView loggedIn -> - LoggedInView.view model loggedIn |