fix:web:edit form: fix broken "File format help" link (fix #2103)

Now not broken, https rather than http, and pointing to the "Data
formats" section, which has links to each of the file formats
(in case editing a non-journal file).
This commit is contained in:
Simon Michael 2023-10-21 03:33:01 +01:00
parent 3a717d1625
commit 9b8044f737
2 changed files with 6 additions and 3 deletions

View File

@ -12,6 +12,7 @@ module Hledger.Web.Settings where
import Data.Default (def)
import Data.Maybe (fromMaybe)
import Data.Text (Text)
import qualified Data.Text as T
import Data.Yaml
import Language.Haskell.TH.Syntax (Q, Exp)
import Text.Hamlet
@ -19,6 +20,8 @@ import Text.Shakespeare.Text (st)
import Yesod.Default.Config
import Yesod.Default.Util
import Hledger.Cli.Version (packagemajorversion)
development :: Bool
development =
#if DEVELOPMENT
@ -31,10 +34,10 @@ production :: Bool
production = not development
hledgerorgurl :: Text
hledgerorgurl = "http://hledger.org"
hledgerorgurl = "https://hledger.org"
manualurl :: Text
manualurl = hledgerorgurl <> "hledger.html"
manualurl = hledgerorgurl <> "/" <> T.pack packagemajorversion <> "/hledger.html"
-- | The default IP address to listen on. May be overridden with --host.
defhost :: String

View File

@ -11,7 +11,7 @@
<tr>
<td style="border:0">
<span.help>
^{helplink "file-format" "File format help"}
^{helplink "data-formats" "File format help"}
<td .text-right style="border:0">
<a.btn.btn-default href="@{ManageR}">Go back
<input.btn.btn-default type=submit value="Save">