diff options
Diffstat (limited to 'src/client/elm/Model')
-rw-r--r-- | src/client/elm/Model/Action.elm | 5 | ||||
-rw-r--r-- | src/client/elm/Model/Action/SignInAction.elm | 9 | ||||
-rw-r--r-- | src/client/elm/Model/View.elm | 5 | ||||
-rw-r--r-- | src/client/elm/Model/View/SignInView.elm | 17 |
4 files changed, 6 insertions, 30 deletions
diff --git a/src/client/elm/Model/Action.elm b/src/client/elm/Model/Action.elm index 60c1aca..3d06521 100644 --- a/src/client/elm/Model/Action.elm +++ b/src/client/elm/Model/Action.elm @@ -5,16 +5,17 @@ module Model.Action import Time exposing (Time) import Signal exposing (Address) -import Model.Action.SignInAction exposing (SignInAction) import Model.Action.LoggedInAction exposing (LoggedInAction) import Model.Init exposing (Init) +import SignIn.Action as SignInAction + type Action = NoOp | SignIn String | UpdateTime Time | GoLoggedInView Init - | UpdateSignIn SignInAction + | UpdateSignIn SignInAction.Action | UpdateLoggedIn LoggedInAction | GoSignInView | SignOut diff --git a/src/client/elm/Model/Action/SignInAction.elm b/src/client/elm/Model/Action/SignInAction.elm deleted file mode 100644 index bead018..0000000 --- a/src/client/elm/Model/Action/SignInAction.elm +++ /dev/null @@ -1,9 +0,0 @@ -module Model.Action.SignInAction - ( SignInAction(..) - ) where - -type SignInAction = - UpdateLogin String - | WaitingServer - | ValidLogin - | ErrorLogin String diff --git a/src/client/elm/Model/View.elm b/src/client/elm/Model/View.elm index 90c0e53..7fc42af 100644 --- a/src/client/elm/Model/View.elm +++ b/src/client/elm/Model/View.elm @@ -3,10 +3,11 @@ module Model.View ) where import Model.Payment exposing (Payments) -import Model.View.SignInView exposing (..) import Model.View.LoggedInView exposing (..) +import SignIn.Model as SignInModel + type View = LoadingView - | SignInView SignInView + | SignInView SignInModel.Model | LoggedInView LoggedInView diff --git a/src/client/elm/Model/View/SignInView.elm b/src/client/elm/Model/View/SignInView.elm deleted file mode 100644 index f72d05a..0000000 --- a/src/client/elm/Model/View/SignInView.elm +++ /dev/null @@ -1,17 +0,0 @@ -module Model.View.SignInView - ( SignInView - , initSignInView - ) where - -type alias SignInView = - { login : String - , waitingServer : Bool - , result : Maybe (Result String String) - } - -initSignInView : Maybe String -> SignInView -initSignInView mbSignInError = - { login = "" - , waitingServer = False - , result = Maybe.map Err mbSignInError - } |