summaryrefslogtreecommitdiff
path: root/views
diff options
context:
space:
mode:
Diffstat (limited to 'views')
-rw-r--r--views/admin.html61
-rw-r--r--views/footer.html10
-rw-r--r--views/header.html17
-rw-r--r--views/index.html83
-rw-r--r--views/login.html62
-rw-r--r--views/navbar.html14
-rw-r--r--views/register.html70
7 files changed, 317 insertions, 0 deletions
diff --git a/views/admin.html b/views/admin.html
new file mode 100644
index 0000000..2dc9b20
--- /dev/null
+++ b/views/admin.html
@@ -0,0 +1,61 @@
+{{template "header.html"}}
+{{template "navbar.html"}}
+{{template "jobs_modal.html"}}
+
+<div class="container">
+ <div class="row">
+ <div class="pull-left">
+ <button id="btn-reload" class="btn btn-primary btn-raised"><span class="glyphicon glyphicon-refresh"></span> Reload</button>
+ <button class="btn btn-primary btn-raised" data-toggle="modal" data-target="#jobs-modal"><span class="glyphicon glyphicon-plus-sign"></span> Add new host</button>
+ </div>
+ <div class="pull-right">
+ <form action="/logout" method="POST">
+ <button class="btn btn-danger btn-raised"><span class="glyphicon glyphicon-minus-sign"></span> Logout</button>
+ </form>
+ </div>
+ <table class="table table-striped table-hover table-responsive">
+ <thead>
+ <th>#</th>
+ <th>Host</th>
+ <th>Description</th>
+ <th>Status</th>
+ <th>Public</th>
+ <!--th>Status Code</th-->
+ <th>Last Update</th>
+ <th class="hide">Failure Reason</th>
+ <th>Delete</th>
+ </thead>
+ <tbody>
+{{range $index, $results := .Hosts}}
+ <tr class="{{.Class}}">
+ <td>{{add $index 1}}</td>
+ <td>{{.Host}} <a href="{{.Url}}" title="{{.Url}}" title="_blank"> <span class="fa fa-external-link-square"></span></a></td>
+ <td>{{.Description}}</td>
+ <td>{{.Status}}</td>
+ <td><span class="glyphicon glyphicon-{{if .Private}}remove{{else}}ok{{end}}"></span>
+ <!--td>{{.StatusCode}}</td-->
+ <td>{{.UpdatedAt}}</td>
+ <td class="hide">{{.Reason}}</td>
+ <!--td><span class="glyphicon glyphicon-pencil"></span></td-->
+ <td class="text-center"><a value="{{.Id}}" href="#" class="delete">&nbsp;<span class="fa fa-close"></span></a></td>
+ </tr>
+{{end}}
+ </tbody>
+ </table>
+ <p>Next run: <strong>{{.NextRun}}</strong></p>
+ <div class="spull-left">
+ <form action="/refresh" method="POST">
+ <button class="btn btn-primary btn-raised"><span class="glyphicon glyphicon-refresh"></span> Update all</button>
+ </form>
+ </div>
+ <hr>
+ <form class="form-horizontal" method="POST" action="/sticky/new">
+ <legend><h4>Information post</h4></legend>
+ <textarea class="form-control shadow-z-4" id="Sticky" name="Sticky" row="3" placeholder="Sticky post.">{{.Sticky}}</textarea>
+ <br>
+ <button class="btn btn-primary btn-raised" name="Action" value="add">Submit</button>
+ <button class="btn btn-danger btn-raised" name="Action" value="delete">Delete</button>
+ </form>
+ </div>
+</div>
+{{template "footer.html"}}
diff --git a/views/footer.html b/views/footer.html
new file mode 100644
index 0000000..0584450
--- /dev/null
+++ b/views/footer.html
@@ -0,0 +1,10 @@
+<footer class="footer shadow-y-2">
+ <div class="container">
+ <p class="pull-left sticky-footer"> Copyright 2015 | <a class='footer-a' href='//www.iamfabulous.de' title='Maximilian Möhring'>Maximilian M&ouml;hring <span class="fa fa-external-link"></span></a></p>
+ </div>
+</footer>
+
+<script src='//code.jquery.com/jquery-1.11.2.min.js'></script>
+<script src='//maxcdn.bootstrapcdn.com/bootstrap/3.3.2/js/bootstrap.min.js'></script>
+ </body>
+</html>
diff --git a/views/header.html b/views/header.html
new file mode 100644
index 0000000..a38c643
--- /dev/null
+++ b/views/header.html
@@ -0,0 +1,17 @@
+<!DOCTYPE html>
+
+<html>
+ <head>
+ <meta http-equiv='Content-Type' content='text/html; charset=utf-8'>
+ <meta http-equiv="X-UA-Compatible" content="IE=edge">
+ <meta name='viewport' content='width=device-width, initial-scale=1.0'>
+ <title>Freemail @ mail.iamfabulous.de</title>
+ <link rel='stylesheet' href='//maxcdn.bootstrapcdn.com/bootstrap/3.3.2/css/bootstrap.min.css'>
+ <link rel='stylesheet' type='text/css' href='/static/css/main.css'>
+ <link rel="stylesheet" href="//maxcdn.bootstrapcdn.com/font-awesome/4.3.0/css/font-awesome.min.css">
+ <link rel='shortcut icon' type='image/png' href='/static/img/favicon.ico'>
+ <noscript>
+ <style>.navbar{margin-bottom:0;}</style>
+ </noscript>
+ </head>
+ <body>
diff --git a/views/index.html b/views/index.html
index e69de29..71bb035 100644
--- a/views/index.html
+++ b/views/index.html
@@ -0,0 +1,83 @@
+{{template "header.html"}}
+{{template "navbar.html"}}
+
+{{if .Error}}
+<div class="container">
+ <div class="row">
+ {{range .Error}}
+ <p id="dd-alert-danger" class="col-md-4 col-md-offset-4 alert alert-danger alert-dismissible shadow-z-2" role="alert">
+ <button type="button" class="close" data-dismiss="alert" aria-label="close"><span aria-hidden="true">&times;</span></button>
+ {{.}}
+ </p>
+ {{end}}
+ </div>
+</div>
+{{end}}
+{{if .Success}}
+<div class="container">
+ <div class="row">
+ {{range .Success}}
+ <p id="dd-alert-success" class="col-md-4 col-md-offset-4 alert alert-success alert-dismissible shadow-z-2" role="alert"> <button type="button" class="close" data-dismiss="alert" aria-label="close"><span aria-hidden="true">&times;</span></button>
+ {{.}}
+ </p>
+ {{end}}
+ </div>
+</div>
+{{end}}
+
+<div class="container">
+ <div class="row">
+<form class="form-horizontal" method='post' action='/create'>
+ <fieldset>
+
+ <!-- Form Name -->
+ <div class="text-center">
+ <legend>Freemail @ mail.iamfabulous.de</legend>
+ </div>
+
+ <!-- Text input-->
+ <div class="form-group">
+ <label class="col-md-4 control-label" for="Email">Email:</label>
+ <div class="col-md-4">
+ <input id="Email" name="Email" placeholder="Your desired mail adress." class="form-control input-md" required="" type="text">
+ </div>
+ </div>
+
+ <!-- Text input-->
+ <div class="form-group">
+ <label class="col-md-4 control-label" for="ConfirmEmail">Confirm Email:</label>
+ <div class="col-md-4">
+ <input id="ConfirmEmail" name="ConfirmEmail" placeholder="Confirm your choice." class="form-control input-md" required="" type="text">
+ </div>
+ </div>
+
+ <!-- Text input-->
+ <div class="form-group">
+ <label class="col-md-4 control-label" for="Password">Password:</label>
+ <div class="col-md-4">
+ <input id="Password" name="Password" placeholder="Your password." class="form-control input-md" required="" type="password">
+ </div>
+ </div>
+
+ <!-- Text input-->
+ <div class="form-group">
+ <label class="col-md-4 control-label" for="ConfirmPassword">Confirm Password:</label>
+ <div class="col-md-4">
+ <input id="ConfirmPassword" name="ConfirmPassword" placeholder="Confirm your password." class="form-control input-md" required="" type="password">
+ </div>
+ </div>
+
+ <!-- Button -->
+ <div class="form-group">
+ <label class="col-md-4 control-label" for="submit"></label>
+ <div class="col-md-4">
+ <button class="btn btn-primary btn-raised">Submit</button>
+ </div>
+ </div>
+
+ </fieldset>
+</form>
+
+ </div>
+</div>
+{{template "footer.html"}}
diff --git a/views/login.html b/views/login.html
new file mode 100644
index 0000000..d7a3865
--- /dev/null
+++ b/views/login.html
@@ -0,0 +1,62 @@
+{{template "header.html"}}
+{{template "navbar.html"}}
+<div class="container">
+ <div class="row">
+{{range .Error}}
+<h4 class="col-md-4 col-md-offset-4 alert alert-danger alert-dismissible" role="alert">
+ <button type="button" class="close" data-dismiss="alert" aria-label="close"><span aria-hidden="true">&times;</span></button>
+ {{.}}
+</h4>
+{{end}}
+{{range .Success}}
+<h4 class="col-md-4 col-md-offset-4 alert alert-success alert-dismissible" role="alert">
+ <button type="button" class="close" data-dismiss="alert" aria-label="close"><span aria-hidden="true">&times;</span></button>
+ {{.}}
+</h4>
+{{end}}
+ </div>
+</div>
+<div class="container">
+ <div class="row">
+ </div>
+</div>
+<div class="container">
+ <div class="row">
+<form class="form-horizontal" method='post' action='/login'>
+ <fieldset>
+
+ <!-- Form Name -->
+ <div class="text-center">
+ <legend>Login!</legend>
+ </div>
+
+ <!-- Text input-->
+ <div class="form-group">
+ <label class="col-md-4 control-label" for="Name">Name:</label>
+ <div class="col-md-4">
+ <input id="Name" name="Name" placeholder="Your Name" class="form-control input-md" required="" type="text">
+ </div>
+ </div>
+
+ <!-- Text input-->
+ <div class="form-group">
+ <label class="col-md-4 control-label" for="Password">Password:</label>
+ <div class="col-md-4">
+ <input id="Password" name="Password" placeholder="Your Password" class="form-control input-md" required="" type="password">
+ </div>
+ </div>
+
+ <!-- Button -->
+ <div class="form-group">
+ <label class="col-md-4 control-label" for="submit"></label>
+ <div class="col-md-4">
+ <button class="btn btn-primary btn-raised">Submit</button>
+ </div>
+ </div>
+
+ </fieldset>
+</form>
+
+ </div>
+</div>
+{{template "footer.html"}}
diff --git a/views/navbar.html b/views/navbar.html
new file mode 100644
index 0000000..48e3877
--- /dev/null
+++ b/views/navbar.html
@@ -0,0 +1,14 @@
+<nav class='navbar navbar-default navbar-custom shadow-z-2' role='navigation'>
+ <div class='container'>
+ <div class='navbar-header'>
+ <a class='navbar-brand' href='/'><span class='glyphicon glyphicon-home'></span> Home</a>
+ </div>
+ <!--div class="collapse navbar-collapse" id="navbarCollapse">
+ <ul class="nav navbar-nav navbar-right">
+ <li>
+ <a class="" href="/admin" title="admin"><span class="glyphicon glyphicon-cog"></span> Admin</a>
+ </li>
+ </ul>
+ </div-->
+ </div>
+</nav>
diff --git a/views/register.html b/views/register.html
new file mode 100644
index 0000000..b1481fc
--- /dev/null
+++ b/views/register.html
@@ -0,0 +1,70 @@
+{{template "header.html"}}
+{{template "navbar.html"}}
+<div class="container">
+ <div class="row">
+{{range .Error}}
+<h4 class="col-md-4 col-md-offset-4 alert alert-danger alert-dismissible" role="alert">
+ <button type="button" class="close" data-dismiss="alert" aria-label="close"><span aria-hidden="true">&times;</span></button>
+ {{.}}
+</h4>
+{{end}}
+{{range .Success}}
+<h4 class="col-md-4 col-md-offset-4 alert alert-success alert-dismissible" role="alert">
+ <button type="button" class="close" data-dismiss="alert" aria-label="close"><span aria-hidden="true">&times;</span></button>
+ {{.}}
+</h4>
+{{end}}
+ </div>
+</div>
+<div class="container">
+ <div class="row">
+ </div>
+</div>
+<div class="container">
+ <div class="row">
+<form class="form-horizontal" method='post' action='/register'>
+ <fieldset>
+
+ <!-- Form Name -->
+ <div class="text-center">
+ <legend>Register!</legend>
+ </div>
+
+ <!-- Text input-->
+ <div class="form-group">
+ <label class="col-md-4 control-label" for="Name">Name:</label>
+ <div class="col-md-4">
+ <input id="Name" name="Name" placeholder="Your Name" class="form-control input-md" required="" type="text">
+ </div>
+ </div>
+
+ <!-- Text input-->
+ <div class="form-group">
+ <label class="col-md-4 control-label" for="Password">Password:</label>
+ <div class="col-md-4">
+ <input id="Password" name="Password" placeholder="Your Password" class="form-control input-md" required="" type="password">
+ </div>
+ </div>
+
+ <!-- Text input-->
+ <div class="form-group">
+ <label class="col-md-4 control-label" for="Email">Email:</label>
+ <div class="col-md-4">
+ <input id="Email" name="Email" placeholder="Your Email" class="form-control input-md" required="" type="email">
+ </div>
+ </div>
+
+ <!-- Button -->
+ <div class="form-group">
+ <label class="col-md-4 control-label" for="submit"></label>
+ <div class="col-md-4">
+ <button class="btn btn-primary">Submit</button>
+ </div>
+ </div>
+
+ </fieldset>
+</form>
+
+ </div>
+</div>
+{{template "footer.html"}}