aboutsummaryrefslogtreecommitdiff
path: root/internal/ui/form/integration.go
diff options
context:
space:
mode:
authorGravatar Frédéric Guillot <f@miniflux.net> 2023-08-13 12:48:29 -0700
committerGravatar Frédéric Guillot <f@miniflux.net> 2023-08-13 13:32:05 -0700
commit28df0b119e8d3562ca00c6066911aa8538378175 (patch)
tree32e944c42fa3caba1cc3e4e3ffe4c948f2360eeb /internal/ui/form/integration.go
parent13d9d86acd988da5929da829ccd251916a9517b7 (diff)
downloadv2-28df0b119e8d3562ca00c6066911aa8538378175.tar.gz
v2-28df0b119e8d3562ca00c6066911aa8538378175.tar.zst
v2-28df0b119e8d3562ca00c6066911aa8538378175.zip
Add Shiori integration
Diffstat (limited to 'internal/ui/form/integration.go')
-rw-r--r--internal/ui/form/integration.go12
1 files changed, 12 insertions, 0 deletions
diff --git a/internal/ui/form/integration.go b/internal/ui/form/integration.go
index 9e60d6fd..5a332f28 100644
--- a/internal/ui/form/integration.go
+++ b/internal/ui/form/integration.go
@@ -62,6 +62,10 @@ type IntegrationForm struct {
AppriseEnabled bool
AppriseURL string
AppriseServicesURL string
+ ShioriEnabled bool
+ ShioriURL string
+ ShioriUsername string
+ ShioriPassword string
}
// Merge copy form values to the model.
@@ -115,6 +119,10 @@ func (i IntegrationForm) Merge(integration *model.Integration) {
integration.AppriseEnabled = i.AppriseEnabled
integration.AppriseServicesURL = i.AppriseServicesURL
integration.AppriseURL = i.AppriseURL
+ integration.ShioriEnabled = i.ShioriEnabled
+ integration.ShioriURL = i.ShioriURL
+ integration.ShioriUsername = i.ShioriUsername
+ integration.ShioriPassword = i.ShioriPassword
}
// NewIntegrationForm returns a new IntegrationForm.
@@ -171,5 +179,9 @@ func NewIntegrationForm(r *http.Request) *IntegrationForm {
AppriseEnabled: r.FormValue("apprise_enabled") == "1",
AppriseURL: r.FormValue("apprise_url"),
AppriseServicesURL: r.FormValue("apprise_services_url"),
+ ShioriEnabled: r.FormValue("shiori_enabled") == "1",
+ ShioriURL: r.FormValue("shiori_url"),
+ ShioriUsername: r.FormValue("shiori_username"),
+ ShioriPassword: r.FormValue("shiori_password"),
}
}