statping/html/tmpl/plugins.html

158 lines
7.3 KiB
HTML
Raw Normal View History

2018-06-10 01:31:13 +00:00
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<link rel="stylesheet" href="/css/bootstrap.min.css">
<link rel="stylesheet" href="/css/base.css">
2018-06-11 03:41:02 +00:00
<title>Statup | Plugins</title>
2018-06-10 01:31:13 +00:00
</head>
<body>
2018-06-22 04:02:57 +00:00
<div class="container col-md-7 col-sm-12 mt-2 bg-light">
2018-06-10 01:31:13 +00:00
2018-06-12 07:21:16 +00:00
2018-06-11 03:41:02 +00:00
{{template "nav"}}
2018-06-10 01:31:13 +00:00
<div class="row">
2018-06-22 06:56:44 +00:00
<div class="col-md-4 col-sm-12">
2018-06-10 01:31:13 +00:00
2018-06-11 03:41:02 +00:00
<div class="nav flex-column nav-pills" id="v-pills-tab" role="tablist" aria-orientation="vertical">
<a class="nav-link active" id="v-pills-home-tab" data-toggle="pill" href="#v-pills-home" role="tab" aria-controls="v-pills-home" aria-selected="true">Settings</a>
2018-06-23 04:17:57 +00:00
<a class="nav-link" id="v-pills-style-tab" data-toggle="pill" href="#v-pills-style" role="tab" aria-controls="v-pills-style" aria-selected="false">Styling</a>
{{ range .Communications }}
<a class="nav-link text-uppercase" id="v-pills-{{ .Method }}-tab" data-toggle="pill" href="#v-pills-{{ .Method }}" role="tab" aria-controls="v-pills-{{ .Method }}" aria-selected="false">{{ .Method }}</a>
{{ end }}
2018-06-19 04:48:25 +00:00
<a class="nav-link" id="v-pills-browse-tab" data-toggle="pill" href="#v-pills-browse" role="tab" aria-controls="v-pills-home" aria-selected="false">Browse Plugins</a>
2018-06-12 05:23:30 +00:00
{{ range .Plugins }}
2018-06-19 06:00:56 +00:00
<a class="nav-link text-capitalize" id="v-pills-{{underscore .Name}}-tab" data-toggle="pill" href="#v-pills-{{underscore .Name}}" role="tab" aria-controls="v-pills-profile" aria-selected="false">{{.Name}}</a>
2018-06-12 05:23:30 +00:00
{{end}}
2018-06-11 03:41:02 +00:00
</div>
</div>
2018-06-22 06:56:44 +00:00
<div class="col-md-8 col-sm-12">
2018-06-11 03:41:02 +00:00
<div class="tab-content" id="v-pills-tabContent">
2018-06-12 07:21:16 +00:00
<div class="tab-pane fade show active" id="v-pills-home" role="tabpanel" aria-labelledby="v-pills-home-tab">
<h3>Settings</h3>
2018-06-19 00:01:03 +00:00
<form method="POST" action="/settings">
<div class="form-group">
<label for="formGroupExampleInput">Project Name</label>
<input type="text" name="project" class="form-control" value="{{ .Name }}" id="formGroupExampleInput" placeholder="Great Uptime">
</div>
<div class="form-group">
<label for="formGroupExampleInput">Project Description</label>
<input type="text" name="description" class="form-control" value="{{ .Description }}" id="formGroupExampleInput" placeholder="Great Uptime">
</div>
2018-06-19 04:48:25 +00:00
<div class="form-group">
<label for="formGroupExampleInput">Custom Footer</label>
<textarea rows="4" name="footer" class="form-control" id="formGroupExampleInput">{{ .Footer }}</textarea>
</div>
2018-06-19 00:01:03 +00:00
<button type="submit" class="btn btn-primary btn-block">Save Settings</button>
</form>
2018-06-12 07:21:16 +00:00
</div>
2018-06-19 04:48:25 +00:00
<div class="tab-pane fade" id="v-pills-style" role="tabpanel" aria-labelledby="v-pills-style-tab">
<h3>Custom Style</h3>
<form method="POST" action="/settings">
<div class="form-group">
<textarea rows="15" name="style" class="form-control" id="formGroupExampleInput">{{ .Style }}</textarea>
</div>
<button type="submit" class="btn btn-primary btn-block">Save Settings</button>
</form>
</div>
2018-06-23 04:17:57 +00:00
{{ range .Communications }}
<div class="tab-pane fade" id="v-pills-{{ .Method }}" role="tabpanel" aria-labelledby="v-pills-{{ .Method }}-tab">
<form method="POST" action="/settings/{{ .Method }}">
<div class="form-group">
<label for="formGroupExampleInput">SMTP Host</label>
<input type="text" name="host" class="form-control" value="{{ .Host }}" id="formGroupExampleInput" placeholder="Great Uptime">
</div>
<div class="form-group">
<label for="formGroupExampleInput">SMTP Username</label>
<input type="text" name="username" class="form-control" value="{{ .Username }}" id="formGroupExampleInput" placeholder="Great Uptime">
</div>
<div class="form-group">
<label for="formGroupExampleInput">SMTP Password</label>
<input type="password" name="password" class="form-control" value="{{ .Password }}" id="formGroupExampleInput">
</div>
<div class="form-group">
<label for="formGroupExampleInput">SMTP Port</label>
<input type="number" name="port" class="form-control" value="{{ .Port }}" id="formGroupExampleInput" placeholder="587">
</div>
<div class="form-group">
<label for="formGroupExampleInput">Outgoing Email Address</label>
<input type="text" name="address" class="form-control" value="{{ .Var1 }}" id="formGroupExampleInput" placeholder="noreply@domain.com">
</div>
<div class="form-group">
<label for="formGroupExampleInput">Limit Emails per Hour</label>
<input type="number" name="limit" class="form-control" value="30" id="formGroupExampleInput" placeholder="noreply@domain.com">
</div>
<button type="submit" class="btn btn-primary btn-block">Save Email Settings</button>
</form>
</div>
{{ end }}
2018-06-12 07:21:16 +00:00
<div class="tab-pane fade" id="v-pills-browse" role="tabpanel" aria-labelledby="v-pills-browse-tab">
{{ range .Repos }}
<div class="card col-6" style="width: 18rem;">
<div class="card-body">
<h5 class="card-title">{{ .Name }}</h5>
<p class="card-text">{{ .Description }}</p>
<a href="/plugins/download/{{ .Name }}" class="card-link">Add</a>
</div>
</div>
{{ end }}
</div>
2018-06-11 09:58:41 +00:00
2018-06-12 05:23:30 +00:00
{{ range .Plugins }}
2018-06-14 06:38:15 +00:00
2018-06-19 06:00:56 +00:00
<div class="tab-pane fade" id="v-pills-{{underscore .Name}}" role="tabpanel" aria-labelledby="v-pills-{{underscore .Name}}-tab">
2018-06-14 01:19:00 +00:00
<h4 class="text-capitalize">{{ .Name }}</h4>
<span class="text-muted">{{ .Description }}</span>
2018-06-19 06:17:43 +00:00
<div class="mt-1">
2018-06-19 06:00:56 +00:00
{{ safe .Form }}
2018-06-19 06:17:43 +00:00
</div>
2018-06-19 06:00:56 +00:00
2018-06-12 05:23:30 +00:00
</div>
{{end}}
2018-06-11 09:58:41 +00:00
2018-06-11 03:41:02 +00:00
</div>
2018-06-10 01:31:13 +00:00
</div>
</div>
</div>
2018-06-22 04:02:57 +00:00
{{template "footer"}}
2018-06-10 01:31:13 +00:00
<script src="/js/jquery-3.3.1.slim.min.js"></script>
2018-06-11 03:41:02 +00:00
<script src="/js/bootstrap.min.js"></script>
2018-06-10 01:31:13 +00:00
2018-06-19 04:48:25 +00:00
2018-06-10 01:31:13 +00:00
</body>
</html>