|
|
|
@ -269,67 +269,7 @@ func Layout(view ViewContext, content templ.Component) templ.Component { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
} |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 27, "</li><li class=\"nav-item\">") |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
if currentPath == "/plugin/detection" { |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 28, "<a class=\"nav-link active\" href=\"/plugin/detection\"><i class=\"fas fa-search me-2\"></i>Job Detection</a>") |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
} else { |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 29, "<a class=\"nav-link\" href=\"/plugin/detection\"><i class=\"fas fa-search me-2\"></i>Job Detection</a>") |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
} |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 30, "</li><li class=\"nav-item\">") |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
if currentPath == "/plugin/queue" { |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 31, "<a class=\"nav-link active\" href=\"/plugin/queue\"><i class=\"fas fa-list me-2\"></i>Job Queue</a>") |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
} else { |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 32, "<a class=\"nav-link\" href=\"/plugin/queue\"><i class=\"fas fa-list me-2\"></i>Job Queue</a>") |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
} |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 33, "</li><li class=\"nav-item\">") |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
if currentPath == "/plugin/execution" { |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 34, "<a class=\"nav-link active\" href=\"/plugin/execution\"><i class=\"fas fa-tasks me-2\"></i>Job Execution</a>") |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
} else { |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 35, "<a class=\"nav-link\" href=\"/plugin/execution\"><i class=\"fas fa-tasks me-2\"></i>Job Execution</a>") |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
} |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 36, "</li><li class=\"nav-item\">") |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
if currentPath == "/plugin/configuration" { |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 37, "<a class=\"nav-link active\" href=\"/plugin/configuration\"><i class=\"fas fa-sliders-h me-2\"></i>Configuration</a>") |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
} else { |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 38, "<a class=\"nav-link\" href=\"/plugin/configuration\"><i class=\"fas fa-sliders-h me-2\"></i>Configuration</a>") |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
} |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 39, "</li></ul></div></div><!-- Sidebar backdrop for mobile --><div class=\"sidebar-backdrop\" id=\"sidebarBackdrop\"></div><!-- Main content --><main class=\"col-md-9 ms-sm-auto col-lg-10 px-3 px-md-4\"><div class=\"pt-3\">") |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 27, "</li></ul></div></div><!-- Sidebar backdrop for mobile --><div class=\"sidebar-backdrop\" id=\"sidebarBackdrop\"></div><!-- Main content --><main class=\"col-md-9 ms-sm-auto col-lg-10 px-3 px-md-4\"><div class=\"pt-3\">") |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
@ -337,43 +277,43 @@ func Layout(view ViewContext, content templ.Component) templ.Component { |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 40, "</div></main></div></div><!-- Footer --><footer class=\"footer mt-auto py-3 bg-light\"><div class=\"container-fluid text-center\"><small class=\"text-muted\">© ") |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 28, "</div></main></div></div><!-- Footer --><footer class=\"footer mt-auto py-3 bg-light\"><div class=\"container-fluid text-center\"><small class=\"text-muted\">© ") |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
var templ_7745c5c3_Var14 string |
|
|
|
templ_7745c5c3_Var14, templ_7745c5c3_Err = templ.JoinStringErrs(fmt.Sprintf("%d", time.Now().Year())) |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ.Error{Err: templ_7745c5c3_Err, FileName: `view/layout/layout.templ`, Line: 336, Col: 60} |
|
|
|
return templ.Error{Err: templ_7745c5c3_Err, FileName: `view/layout/layout.templ`, Line: 292, Col: 60} |
|
|
|
} |
|
|
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var14)) |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 41, " SeaweedFS Admin v") |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 29, " SeaweedFS Admin v") |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
var templ_7745c5c3_Var15 string |
|
|
|
templ_7745c5c3_Var15, templ_7745c5c3_Err = templ.JoinStringErrs(version.VERSION_NUMBER) |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ.Error{Err: templ_7745c5c3_Err, FileName: `view/layout/layout.templ`, Line: 336, Col: 102} |
|
|
|
return templ.Error{Err: templ_7745c5c3_Err, FileName: `view/layout/layout.templ`, Line: 292, Col: 102} |
|
|
|
} |
|
|
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var15)) |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 42, " ") |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 30, " ") |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
if !strings.Contains(version.VERSION, "enterprise") { |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 43, "<span class=\"mx-2\">•</span> <a href=\"https://seaweedfs.com\" target=\"_blank\" class=\"text-decoration-none\"><i class=\"fas fa-star me-1\"></i>Enterprise Version Available</a>") |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 31, "<span class=\"mx-2\">•</span> <a href=\"https://seaweedfs.com\" target=\"_blank\" class=\"text-decoration-none\"><i class=\"fas fa-star me-1\"></i>Enterprise Version Available</a>") |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
} |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 44, "</small></div></footer><!-- Bootstrap JS --><script src=\"/static/js/bootstrap.bundle.min.js\"></script><!-- Modal Alerts JS (replaces native alert/confirm) --><script src=\"/static/js/modal-alerts.js\"></script><!-- Custom JS --><script src=\"/static/js/admin.js\"></script><script src=\"/static/js/iam-utils.js\"></script><script src=\"/static/js/s3tables.js\"></script></body></html>") |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 32, "</small></div></footer><!-- Bootstrap JS --><script src=\"/static/js/bootstrap.bundle.min.js\"></script><!-- Modal Alerts JS (replaces native alert/confirm) --><script src=\"/static/js/modal-alerts.js\"></script><!-- Custom JS --><script src=\"/static/js/admin.js\"></script><script src=\"/static/js/iam-utils.js\"></script><script src=\"/static/js/s3tables.js\"></script></body></html>") |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
@ -402,69 +342,69 @@ func LoginForm(title string, errorMessage string, csrfToken string) templ.Compon |
|
|
|
templ_7745c5c3_Var16 = templ.NopComponent |
|
|
|
} |
|
|
|
ctx = templ.ClearChildren(ctx) |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 45, "<!doctype html><html lang=\"en\"><head><meta charset=\"UTF-8\"><title>") |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 33, "<!doctype html><html lang=\"en\"><head><meta charset=\"UTF-8\"><title>") |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
var templ_7745c5c3_Var17 string |
|
|
|
templ_7745c5c3_Var17, templ_7745c5c3_Err = templ.JoinStringErrs(title) |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ.Error{Err: templ_7745c5c3_Err, FileName: `view/layout/layout.templ`, Line: 364, Col: 17} |
|
|
|
return templ.Error{Err: templ_7745c5c3_Err, FileName: `view/layout/layout.templ`, Line: 320, Col: 17} |
|
|
|
} |
|
|
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var17)) |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 46, " - Login</title><link rel=\"icon\" href=\"/static/favicon.ico\" type=\"image/x-icon\"><meta name=\"viewport\" content=\"width=device-width, initial-scale=1\"><link href=\"/static/css/bootstrap.min.css\" rel=\"stylesheet\"><link href=\"/static/css/fontawesome.min.css\" rel=\"stylesheet\"></head><body class=\"bg-light\"><div class=\"container\"><div class=\"row justify-content-center min-vh-100 align-items-center\"><div class=\"col-md-6 col-lg-4\"><div class=\"card shadow\"><div class=\"card-body p-5\"><div class=\"text-center mb-4\"><i class=\"fas fa-server fa-3x text-primary mb-3\"></i><h4 class=\"card-title\">") |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 34, " - Login</title><link rel=\"icon\" href=\"/static/favicon.ico\" type=\"image/x-icon\"><meta name=\"viewport\" content=\"width=device-width, initial-scale=1\"><link href=\"/static/css/bootstrap.min.css\" rel=\"stylesheet\"><link href=\"/static/css/fontawesome.min.css\" rel=\"stylesheet\"></head><body class=\"bg-light\"><div class=\"container\"><div class=\"row justify-content-center min-vh-100 align-items-center\"><div class=\"col-md-6 col-lg-4\"><div class=\"card shadow\"><div class=\"card-body p-5\"><div class=\"text-center mb-4\"><i class=\"fas fa-server fa-3x text-primary mb-3\"></i><h4 class=\"card-title\">") |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
var templ_7745c5c3_Var18 string |
|
|
|
templ_7745c5c3_Var18, templ_7745c5c3_Err = templ.JoinStringErrs(title) |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ.Error{Err: templ_7745c5c3_Err, FileName: `view/layout/layout.templ`, Line: 378, Col: 57} |
|
|
|
return templ.Error{Err: templ_7745c5c3_Err, FileName: `view/layout/layout.templ`, Line: 334, Col: 57} |
|
|
|
} |
|
|
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var18)) |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 47, "</h4><p class=\"text-muted\">Please sign in to continue</p></div>") |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 35, "</h4><p class=\"text-muted\">Please sign in to continue</p></div>") |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
if errorMessage != "" { |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 48, "<div class=\"alert alert-danger\" role=\"alert\"><i class=\"fas fa-exclamation-triangle me-2\"></i> ") |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 36, "<div class=\"alert alert-danger\" role=\"alert\"><i class=\"fas fa-exclamation-triangle me-2\"></i> ") |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
var templ_7745c5c3_Var19 string |
|
|
|
templ_7745c5c3_Var19, templ_7745c5c3_Err = templ.JoinStringErrs(errorMessage) |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ.Error{Err: templ_7745c5c3_Err, FileName: `view/layout/layout.templ`, Line: 385, Col: 45} |
|
|
|
return templ.Error{Err: templ_7745c5c3_Err, FileName: `view/layout/layout.templ`, Line: 341, Col: 45} |
|
|
|
} |
|
|
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var19)) |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 49, "</div>") |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 37, "</div>") |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
} |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 50, "<form method=\"POST\" action=\"/login\"><input type=\"hidden\" name=\"csrf_token\" value=\"") |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 38, "<form method=\"POST\" action=\"/login\"><input type=\"hidden\" name=\"csrf_token\" value=\"") |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
var templ_7745c5c3_Var20 string |
|
|
|
templ_7745c5c3_Var20, templ_7745c5c3_Err = templ.JoinStringErrs(csrfToken) |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ.Error{Err: templ_7745c5c3_Err, FileName: `view/layout/layout.templ`, Line: 390, Col: 84} |
|
|
|
return templ.Error{Err: templ_7745c5c3_Err, FileName: `view/layout/layout.templ`, Line: 346, Col: 84} |
|
|
|
} |
|
|
|
_, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var20)) |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 51, "\"><div class=\"mb-3\"><label for=\"username\" class=\"form-label\">Username</label><div class=\"input-group\"><span class=\"input-group-text\"><i class=\"fas fa-user\"></i></span> <input type=\"text\" class=\"form-control\" id=\"username\" name=\"username\" required></div></div><div class=\"mb-4\"><label for=\"password\" class=\"form-label\">Password</label><div class=\"input-group\"><span class=\"input-group-text\"><i class=\"fas fa-lock\"></i></span> <input type=\"password\" class=\"form-control\" id=\"password\" name=\"password\" required></div></div><button type=\"submit\" class=\"btn btn-primary w-100\"><i class=\"fas fa-sign-in-alt me-2\"></i>Sign In</button></form></div></div></div></div></div><script src=\"/static/js/bootstrap.bundle.min.js\"></script></body></html>") |
|
|
|
templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 39, "\"><div class=\"mb-3\"><label for=\"username\" class=\"form-label\">Username</label><div class=\"input-group\"><span class=\"input-group-text\"><i class=\"fas fa-user\"></i></span> <input type=\"text\" class=\"form-control\" id=\"username\" name=\"username\" required></div></div><div class=\"mb-4\"><label for=\"password\" class=\"form-label\">Password</label><div class=\"input-group\"><span class=\"input-group-text\"><i class=\"fas fa-lock\"></i></span> <input type=\"password\" class=\"form-control\" id=\"password\" name=\"password\" required></div></div><button type=\"submit\" class=\"btn btn-primary w-100\"><i class=\"fas fa-sign-in-alt me-2\"></i>Sign In</button></form></div></div></div></div></div><script src=\"/static/js/bootstrap.bundle.min.js\"></script></body></html>") |
|
|
|
if templ_7745c5c3_Err != nil { |
|
|
|
return templ_7745c5c3_Err |
|
|
|
} |
|
|
|
|