mirror of
https://github.com/TheAnachronism/docspell.git
synced 2025-07-04 16:48:26 +00:00
Externalize error messages
This commit is contained in:
@ -1,5 +1,6 @@
|
||||
module Page.Queue.Data exposing
|
||||
( Model
|
||||
( FormState(..)
|
||||
, Model
|
||||
, Msg(..)
|
||||
, QueueView(..)
|
||||
, emptyModel
|
||||
@ -20,7 +21,7 @@ import Util.Maybe
|
||||
|
||||
type alias Model =
|
||||
{ state : JobQueueState
|
||||
, error : String
|
||||
, formState : FormState
|
||||
, pollingInterval : Float
|
||||
, init : Bool
|
||||
, stopRefresh : Bool
|
||||
@ -32,6 +33,11 @@ type alias Model =
|
||||
}
|
||||
|
||||
|
||||
type FormState
|
||||
= InitialForm
|
||||
| HttpError Http.Error
|
||||
|
||||
|
||||
type QueueView
|
||||
= CurrentJobs
|
||||
| QueueAll
|
||||
@ -44,7 +50,7 @@ type QueueView
|
||||
emptyModel : Model
|
||||
emptyModel =
|
||||
{ state = Api.Model.JobQueueState.empty
|
||||
, error = ""
|
||||
, formState = InitialForm
|
||||
, pollingInterval = 1200
|
||||
, init = False
|
||||
, stopRefresh = False
|
||||
|
Reference in New Issue
Block a user