diff options
author | Lars Wirzenius <lars.wirzenius@codethink.co.uk> | 2014-10-11 20:28:38 +0300 |
---|---|---|
committer | Richard Maw <richard.maw@codethink.co.uk> | 2014-10-13 11:58:46 +0100 |
commit | 4186aeb988e2c60ab8733c904d5e28ea1e36f43c (patch) | |
tree | f5017fa874b72f5de1570f82dfe04d05626ae8be | |
parent | 44a2dca52d232428b5a52e2c73fcad1adfee7a8f (diff) | |
download | lorry-controller-4186aeb988e2c60ab8733c904d5e28ea1e36f43c.tar.gz |
Remove buttons from static status page
-rw-r--r-- | templates/status.tpl | 48 |
1 files changed, 29 insertions, 19 deletions
diff --git a/templates/status.tpl b/templates/status.tpl index 9201f04..2665861 100644 --- a/templates/status.tpl +++ b/templates/status.tpl @@ -11,28 +11,38 @@ <h1>Status of Lorry Controller</h1> -% if running_queue: -<form method="POST" action="/1.0/stop-queue"> - <p>New jobs are allowed. - <input type="submit" name="submit" value="Don't allow new jobs" /> - <input type="hidden" name="redirect" value="/1.0/status-html" /> - </p> -</form> +% if links: +% if running_queue: + <form method="POST" action="/1.0/stop-queue"> + <p>New jobs are allowed. + <input type="submit" name="submit" value="Don't allow new jobs" /> + <input type="hidden" name="redirect" value="/1.0/status-html" /> + </p> + </form> +% else: + <form method="POST" action="/1.0/start-queue"> + <p>New jobs are NOT allowed. + <input type="submit" name="submit" value="Allow new jobs" /> + <input type="hidden" name="redirect" value="/1.0/status-html" /> + </p> + </form> +% end % else: -<form method="POST" action="/1.0/start-queue"> - <p>New jobs are NOT allowed. - <input type="submit" name="submit" value="Allow new jobs" /> - <input type="hidden" name="redirect" value="/1.0/status-html" /> - </p> -</form> +% if running_queue: + <p>New jobs are allowed.</p> +% else: + <p>New jobs are NOT allowed.</p> +% end % end -<form method="POST" action="/1.0/read-configuration"> - <p> - <input type="submit" name="submit" value="Re-read configuration" /> - <input type="hidden" name="redirect" value="/1.0/status-html" /> - </p> -</form> +% if links: + <form method="POST" action="/1.0/read-configuration"> + <p> + <input type="submit" name="submit" value="Re-read configuration" /> + <input type="hidden" name="redirect" value="/1.0/status-html" /> + </p> + </form> +% end <p>Maximum number of jobs: {{max_jobs}}.</p> |