mirror of
https://github.com/TheAnachronism/docspell.git
synced 2025-06-22 18:38:26 +00:00
Fix translation for direction
This commit is contained in:
@ -694,15 +694,15 @@ view2 texts attr settings model =
|
||||
(viewIntern2 texts settings True model)
|
||||
|
||||
|
||||
formHeading : String -> Model -> Html msg
|
||||
formHeading classes model =
|
||||
formHeading : Texts -> String -> Model -> Html msg
|
||||
formHeading texts classes model =
|
||||
let
|
||||
heading =
|
||||
fold (\_ -> "Add Tag")
|
||||
(\_ -> "Add Person")
|
||||
(\_ -> "Add Organization")
|
||||
(\_ -> "Add Equipment")
|
||||
(\_ -> "Add Custom Field")
|
||||
fold (\_ -> texts.addTagHeader)
|
||||
(\_ -> texts.addPersonHeader)
|
||||
(\_ -> texts.addOrgHeader)
|
||||
(\_ -> texts.addEquipmentHeader)
|
||||
(\_ -> texts.addCustomFieldHeader)
|
||||
|
||||
headIcon =
|
||||
fold (\_ -> Icons.tagIcon2 "mr-2")
|
||||
@ -724,11 +724,11 @@ viewModal2 texts settings mm =
|
||||
mm == Nothing
|
||||
|
||||
heading =
|
||||
fold (\_ -> "Add Tag")
|
||||
(\_ -> "Add Person")
|
||||
(\_ -> "Add Organization")
|
||||
(\_ -> "Add Equipment")
|
||||
(\_ -> "Add Custom Field")
|
||||
fold (\_ -> texts.addTagHeader)
|
||||
(\_ -> texts.addPersonHeader)
|
||||
(\_ -> texts.addOrgHeader)
|
||||
(\_ -> texts.addEquipmentHeader)
|
||||
(\_ -> texts.addCustomFieldHeader)
|
||||
|
||||
headIcon =
|
||||
fold (\_ -> Icons.tagIcon2 "mr-2")
|
||||
|
@ -117,7 +117,7 @@ formTabs texts flags settings model =
|
||||
directionCfg =
|
||||
{ makeOption =
|
||||
\entry ->
|
||||
{ text = Data.Direction.toString entry
|
||||
{ text = texts.direction entry
|
||||
, additional = ""
|
||||
}
|
||||
, placeholder = texts.chooseDirection
|
||||
|
@ -104,7 +104,7 @@ multiUpdate flags ids change receive =
|
||||
DirectionChange dir ->
|
||||
let
|
||||
data =
|
||||
ItemsAndDirection items (Data.Direction.toString dir)
|
||||
ItemsAndDirection items (Data.Direction.asString dir)
|
||||
in
|
||||
Api.setDirectionMultiple flags data receive
|
||||
|
||||
|
@ -688,7 +688,7 @@ renderEditForm2 texts flags cfg settings model =
|
||||
directionCfg =
|
||||
{ makeOption =
|
||||
\entry ->
|
||||
{ text = Data.Direction.toString entry
|
||||
{ text = texts.direction entry
|
||||
, additional = ""
|
||||
}
|
||||
, placeholder = texts.chooseDirection
|
||||
|
@ -1628,7 +1628,7 @@ setDirection flags model =
|
||||
in
|
||||
case dir of
|
||||
Just d ->
|
||||
Api.setDirection flags model.item.id (DirectionValue (Data.Direction.toString d)) SaveResp
|
||||
Api.setDirection flags model.item.id (DirectionValue (Data.Direction.asString d)) SaveResp
|
||||
|
||||
Nothing ->
|
||||
Cmd.none
|
||||
|
@ -314,7 +314,7 @@ addDetailForm texts settings model =
|
||||
[ class "flex flex-col px-2 py-2 mb-4"
|
||||
, class S.box
|
||||
]
|
||||
[ Comp.DetailEdit.formHeading S.header3 mm
|
||||
[ Comp.DetailEdit.formHeading texts.detailEdit S.header3 mm
|
||||
, Html.map ModalEditMsg (Comp.DetailEdit.view2 texts.detailEdit [] settings mm)
|
||||
]
|
||||
|
||||
|
@ -303,7 +303,7 @@ makeSettings model =
|
||||
, deleteMail = model.deleteMail
|
||||
, targetFolder = model.targetFolder
|
||||
, folders = folders
|
||||
, direction = Maybe.map Data.Direction.toString model.direction
|
||||
, direction = Maybe.map Data.Direction.asString model.direction
|
||||
, schedule = Data.CalEvent.makeEvent timer
|
||||
, itemFolder = model.itemFolderId
|
||||
, fileFilter = model.fileFilter
|
||||
|
@ -1120,7 +1120,7 @@ searchTabs texts ddd flags settings model =
|
||||
directionCfg =
|
||||
{ makeOption =
|
||||
\entry ->
|
||||
{ text = Data.Direction.toString entry
|
||||
{ text = texts.direction entry
|
||||
, additional = ""
|
||||
}
|
||||
, placeholder = texts.chooseDirection
|
||||
|
Reference in New Issue
Block a user