aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoris2016-06-03 20:34:30 +0200
committerJoris2016-06-03 20:34:30 +0200
commit6ebd46c4913695210bd46179817bcc166a225ed8 (patch)
tree8e53d43d8805a29e9cd58ce0397a29c0ba376b0c
parent8e3a7bf1cb83bbb6e3dcd54308eefa52a29cd679 (diff)
Add creation and amount translations
-rw-r--r--src/client/elm/LoggedIn/Income/View.elm4
-rw-r--r--src/server/Model/Message/Key.hs2
-rw-r--r--src/server/Model/Message/Translations.hs10
3 files changed, 14 insertions, 2 deletions
diff --git a/src/client/elm/LoggedIn/Income/View.elm b/src/client/elm/LoggedIn/Income/View.elm
index 39f16f4..036cd80 100644
--- a/src/client/elm/LoggedIn/Income/View.elm
+++ b/src/client/elm/LoggedIn/Income/View.elm
@@ -84,11 +84,11 @@ addIncomeView loggedData addIncome =
in
Html.form
[ onSubmitPrevDefault Msg.NoOp ]
- [ label [] [ text "Creation" ]
+ [ label [] [ text (getMessage "Creation" loggedData.translations) ]
, htmlMap <| Input.textInput creation []
, errorFor "DateValidationError" creation
- , label [] [ text "amount" ]
+ , label [] [ text (getMessage "Amount" loggedData.translations) ]
, htmlMap <| Input.textInput amount []
, errorFor "IncomeValidationError" amount
diff --git a/src/server/Model/Message/Key.hs b/src/server/Model/Message/Key.hs
index 32c7856..dea1a03 100644
--- a/src/server/Model/Message/Key.hs
+++ b/src/server/Model/Message/Key.hs
@@ -79,6 +79,8 @@ data Key =
| Income
| MonthlyNetIncomes
| IncomeNotDeleted
+ | Creation
+ | Amount
-- Http error
diff --git a/src/server/Model/Message/Translations.hs b/src/server/Model/Message/Translations.hs
index 973b756..7bde74f 100644
--- a/src/server/Model/Message/Translations.hs
+++ b/src/server/Model/Message/Translations.hs
@@ -299,6 +299,16 @@ m l IncomeNotDeleted =
English -> "The income could not have been deleted."
French -> "Le revenu n'a pas pu être supprimé."
+m l Creation =
+ case l of
+ English -> "Creation"
+ French -> "Création"
+
+m l Amount =
+ case l of
+ English -> "Amount"
+ French -> "Montant"
+
-- Http error
m l Timeout =