From 8a5ed3f507d37c52e2a68a23ced6942cc752221d Mon Sep 17 00:00:00 2001 From: Alex Auvolat Date: Wed, 26 Feb 2020 22:49:27 +0100 Subject: Initial ability to configure accounts from web interface --- templates/config.html | 71 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 71 insertions(+) create mode 100644 templates/config.html (limited to 'templates/config.html') diff --git a/templates/config.html b/templates/config.html new file mode 100644 index 0000000..2d64444 --- /dev/null +++ b/templates/config.html @@ -0,0 +1,71 @@ +{{define "title"}}Account configuration |{{end}} + +{{define "body"}} +
+

Configure account

+ Go back +
+ +{{if .ErrorMessage}} +
An error occurred. +
{{ .ErrorMessage }}
+
+{{end}} + +
+
+ + + {{if .InvalidName}} +
Invalid name (must not be empty)
+ {{end}} +
+
+ + +
+ {{$config := .Config}} + {{$errors := .Errors}} + {{range $i, $schema := .Schema}} +
+ + {{if $schema.FixedValue}} + + {{else if $schema.IsBoolean}} + {{$value := index $config $schema.Name}} + + + {{else if $schema.IsPassword}} + + {{else}} + + {{end}} + {{$error := index $errors $schema.Name}} + {{if $error}} +
{{$error}}
+ {{end}} +
+ {{end}} + +
+ +{{end}} -- cgit v1.2.3