Status window refactor.

master
Manager Bot 3 years ago
parent 0f296e5e26
commit 0a5efaeefc
  1. 23
      Web/templates/admin/blogs.html.ep
  2. 29
      Web/templates/admin/domains.html.ep
  3. 23
      Web/templates/admin/index.html.ep
  4. 23
      Web/templates/admin/people.html.ep
  5. 29
      Web/templates/admin/servers.html.ep
  6. 23
      Web/templates/admin/settings.html.ep
  7. 36
      Web/templates/auth/forgot.html.ep
  8. 41
      Web/templates/auth/login.html.ep
  9. 70
      Web/templates/auth/register.html.ep
  10. 49
      Web/templates/auth/reset.html.ep
  11. 17
      Web/templates/blog/create.html.ep
  12. 17
      Web/templates/blog/settings.html.ep
  13. 23
      Web/templates/dashboard/blog.html.ep
  14. 23
      Web/templates/dashboard/blog_builds.html.ep
  15. 24
      Web/templates/dashboard/blog_config.html.ep
  16. 24
      Web/templates/dashboard/blog_history.html.ep
  17. 29
      Web/templates/dashboard/blog_media.html.ep
  18. 2
      Web/templates/dashboard/blog_page.html.ep
  19. 2
      Web/templates/dashboard/blog_page_edit.html.ep
  20. 23
      Web/templates/dashboard/blog_pages.html.ep
  21. 2
      Web/templates/dashboard/blog_post.html.ep
  22. 2
      Web/templates/dashboard/blog_post_alter.html.ep
  23. 2
      Web/templates/dashboard/blog_post_edit.html.ep
  24. 23
      Web/templates/dashboard/blog_posts.html.ep
  25. 24
      Web/templates/dashboard/blog_settings.html.ep
  26. 62
      Web/templates/user_settings/change_password.html.ep
  27. 57
      Web/templates/user_settings/profile.html.ep

@ -2,28 +2,7 @@
%= include 'admin/_nav', page => 'blogs' %= include 'admin/_nav', page => 'blogs'
% if ( my $confirmation = flash 'confirmation' ) { %= include '_base/status_window';
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%== $confirmation %>
</div>
% }
% if ( $c->stash->{success} ) {
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%= $c->stash->{success_message} %>
</div>
% }
% if ( $c->stash->{errors} ) {
<div style="margin-top: 2em" class="alert alert-danger" role="alert">
There were errors with your request that could not be resolved:
<ul>
% for my $error ( @{$c->stash->{errors}} ) {
<li><%= $error %></li>
% }
</ul>
</div>
% }
% if ( $blogs ) { % if ( $blogs ) {
<table style="border: 1px solid #ccc" class="table"> <table style="border: 1px solid #ccc" class="table">

@ -2,34 +2,7 @@
%= include 'admin/_nav', page => 'domains' %= include 'admin/_nav', page => 'domains'
% if ( my $confirmation = flash 'confirmation' ) { %= include '_base/status_window';
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%== $confirmation %>
</div>
% }
% if ( my $confirmation = flash 'error_message' ) {
<div style="margin-top: 2em" class="alert alert-danger" role="alert">
<%== $confirmation %>
</div>
% }
% if ( $c->stash->{success} ) {
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%= $c->stash->{success_message} %>
</div>
% }
% if ( $c->stash->{errors} ) {
<div style="margin-top: 2em" class="alert alert-danger" role="alert">
There were errors with your request that could not be resolved:
<ul>
% for my $error ( @{$c->stash->{errors}} ) {
<li><%= $error %></li>
% }
</ul>
</div>
% }
<form class="row mt-3 gy-2 gx-3 align-items-center" method="POST" enctype="multipart/form-data" action="<%= $c->url_for( 'do_admin_domain' ) %>"> <form class="row mt-3 gy-2 gx-3 align-items-center" method="POST" enctype="multipart/form-data" action="<%= $c->url_for( 'do_admin_domain' ) %>">
<div class="col-auto"> <div class="col-auto">

@ -2,26 +2,5 @@
%= include 'admin/_nav', page => 'info' %= include 'admin/_nav', page => 'info'
% if ( my $confirmation = flash 'confirmation' ) { %= include '_base/status_window';
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%== $confirmation %>
</div>
% }
% if ( $c->stash->{success} ) {
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%= $c->stash->{success_message} %>
</div>
% }
% if ( $c->stash->{errors} ) {
<div style="margin-top: 2em" class="alert alert-danger" role="alert">
There were errors with your request that could not be resolved:
<ul>
% for my $error ( @{$c->stash->{errors}} ) {
<li><%= $error %></li>
% }
</ul>
</div>
% }

@ -2,28 +2,7 @@
%= include 'admin/_nav', page => 'people' %= include 'admin/_nav', page => 'people'
% if ( my $confirmation = flash 'confirmation' ) { %= include '_base/status_window';
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%== $confirmation %>
</div>
% }
% if ( $c->stash->{success} ) {
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%= $c->stash->{success_message} %>
</div>
% }
% if ( $c->stash->{errors} ) {
<div style="margin-top: 2em" class="alert alert-danger" role="alert">
There were errors with your request that could not be resolved:
<ul>
% for my $error ( @{$c->stash->{errors}} ) {
<li><%= $error %></li>
% }
</ul>
</div>
% }
% if ( $people ) { % if ( $people ) {
<table style="border: 1px solid #ccc" class="table"> <table style="border: 1px solid #ccc" class="table">

@ -2,34 +2,7 @@
%= include 'admin/_nav', page => 'servers' %= include 'admin/_nav', page => 'servers'
% if ( my $confirmation = flash 'confirmation' ) { %= include '_base/status_window';
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%== $confirmation %>
</div>
% }
% if ( my $confirmation = flash 'error_message' ) {
<div style="margin-top: 2em" class="alert alert-danger" role="alert">
<%== $confirmation %>
</div>
% }
% if ( $c->stash->{success} ) {
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%= $c->stash->{success_message} %>
</div>
% }
% if ( $c->stash->{errors} ) {
<div style="margin-top: 2em" class="alert alert-danger" role="alert">
There were errors with your request that could not be resolved:
<ul>
% for my $error ( @{$c->stash->{errors}} ) {
<li><%= $error %></li>
% }
</ul>
</div>
% }
<form class="row mt-3 gy-2 gx-3 align-items-center" method="POST" enctype="multipart/form-data" action="<%= $c->url_for( 'do_admin_server' ) %>"> <form class="row mt-3 gy-2 gx-3 align-items-center" method="POST" enctype="multipart/form-data" action="<%= $c->url_for( 'do_admin_server' ) %>">
<div class="col-auto"> <div class="col-auto">

@ -2,26 +2,5 @@
%= include 'admin/_nav', page => 'settings' %= include 'admin/_nav', page => 'settings'
% if ( my $confirmation = flash 'confirmation' ) { %= include '_base/status_window';
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%== $confirmation %>
</div>
% }
% if ( $c->stash->{success} ) {
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%= $c->stash->{success_message} %>
</div>
% }
% if ( $c->stash->{errors} ) {
<div style="margin-top: 2em" class="alert alert-danger" role="alert">
There were errors with your request that could not be resolved:
<ul>
% for my $error ( @{$c->stash->{errors}} ) {
<li><%= $error %></li>
% }
</ul>
</div>
% }

@ -1,35 +1,19 @@
% layout 'standard', title => 'Forgot Password', sb_active => 'forgot'; % layout 'standard', title => 'Forgot Password', sb_active => 'forgot';
<h2 class="mt-5 display-6 mb-4">Reset Password</h2> <h2 class="mt-5 display-6 mb-4">Reset Password</h2>
<p>If you have forgotten the password for your account, please enter the email address below and you will get a link to reset your password.</p> <p>If you have forgotten the password for your account, please enter the email address below and you will get a link to reset your password.</p>
% if ( $c->stash->{success} ) { %= include '_base/status_window';
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%= $c->stash->{success_message} %>
</div>
% }
% if ( $c->stash->{errors} ) {
<div style="margin-top: 2em" class="alert alert-danger" role="alert">
There were errors with your request that could not be resolved:
<ul>
% for my $error ( @{$c->stash->{errors}} ) {
<li><%= $error %></li>
% }
</ul>
</div>
% }
<form autocomplete="off" style="margin-top: 1.5em" method="POST" action="<%= $c->url_for( 'do_forgot' ) %>"> <form autocomplete="off" style="margin-top: 1.5em" method="POST" action="<%= $c->url_for( 'do_forgot' ) %>">
<%= include '_base/form/input', type => 'email', name => 'email', <%= include '_base/form/input', type => 'email', name => 'email',
title => 'Email Address', title => 'Email Address',
help => '', help => '',
value => $c->stash->{form_email} value => $c->stash->{form_email}
%> %>
<button type="submit" class="btn btn-primary float-end">Reset Password</button> <button type="submit" class="btn btn-primary float-end">Reset Password</button>
</form> </form>

@ -2,31 +2,22 @@
<h2 class="mt-5 display-6 mb-4">Login</h2> <h2 class="mt-5 display-6 mb-4">Login</h2>
% if ( $c->stash->{errors} ) { %= include '_base/status_window';
<div style="margin-top: 2em" class="alert alert-danger" role="alert">
There were errors with your request that could not be resolved:
<ul>
% for my $error ( @{$c->stash->{errors}} ) {
<li><%= $error %></li>
% }
</ul>
</div>
% }
<form autocomplete="off" style="margin-top: 1.5em" method="POST" action="<%= $c->url_for( 'do_login' ) %>"> <form autocomplete="off" style="margin-top: 1.5em" method="POST" action="<%= $c->url_for( 'do_login' ) %>">
<%= include '_base/form/input', type => 'email', name => 'email', <%= include '_base/form/input', type => 'email', name => 'email',
title => 'Email Address', title => 'Email Address',
help => '', help => '',
value => $c->stash->{form_email} value => $c->stash->{form_email}
%> %>
<%= include '_base/form/input', type => 'password', name => 'password', <%= include '_base/form/input', type => 'password', name => 'password',
title => 'Password', title => 'Password',
help => '', help => '',
value => $c->stash->{form_password} value => $c->stash->{form_password}
%> %>
<button type="submit" class="btn btn-primary float-end">Login</button> <button type="submit" class="btn btn-primary float-end">Login</button>
</form> </form>

@ -1,45 +1,35 @@
% layout 'standard', title => 'Register', sb_active => 'register'; % layout 'standard', title => 'Register', sb_active => 'register';
<h2 class="mt-5 display-6 mb-4">Create an account</h2> <h2 class="mt-5 display-6 mb-4">Create an account</h2>
% if ( $c->stash->{errors} ) { %= include '_base/status_window';
<div style="margin-top: 2em" class="alert alert-danger" role="alert">
There were errors with your request that could not be resolved: <form autocomplete="off" style="margin-top: 1.5em" method="POST" action="<%= $c->url_for( 'do_register' ) %>">
<ul>
% for my $error ( @{$c->stash->{errors}} ) { <%= include '_base/form/input', type => 'text', name => 'name',
<li><%= $error %></li> title => 'Your name',
% } help => '',
</ul> value => $c->stash->{form_name}
</div> %>
% }
<%= include '_base/form/input', type => 'email', name => 'email',
<form autocomplete="off" style="margin-top: 1.5em" method="POST" action="<%= $c->url_for( 'do_register' ) %>"> title => 'Email Address',
help => '',
<%= include '_base/form/input', type => 'text', name => 'name', value => $c->stash->{form_email}
title => 'Your name', %>
help => '',
value => $c->stash->{form_name} <%= include '_base/form/input', type => 'password', name => 'password',
%> title => 'Password',
help => '',
<%= include '_base/form/input', type => 'email', name => 'email', value => $c->stash->{form_password}
title => 'Email Address', %>
help => '',
value => $c->stash->{form_email} <%= include '_base/form/input', type => 'password', name => 'password_confirm',
%> title => 'Confirm Password',
help => '',
<%= include '_base/form/input', type => 'password', name => 'password', value => $c->stash->{form_password_confirm}
title => 'Password', %>
help => '',
value => $c->stash->{form_password} <button type="submit" class="btn btn-primary float-end">Create Account</button>
%> </form>
<%= include '_base/form/input', type => 'password', name => 'password_confirm',
title => 'Confirm Password',
help => '',
value => $c->stash->{form_password_confirm}
%>
<button type="submit" class="btn btn-primary float-end">Create Account</button>
</form>

@ -2,37 +2,22 @@
<h2 class="mt-5 display-6 mb-4">Reset Password</h2> <h2 class="mt-5 display-6 mb-4">Reset Password</h2>
% if ( $c->stash->{success} ) { %= include '_base/status_window';
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%= $c->stash->{success_message} %>
</div>
% }
% if ( $c->stash->{errors} ) { <form autocomplete="off" style="margin-top: 1.5em" method="POST" action="<%= $c->url_for() %>">
<div style="margin-top: 2em" class="alert alert-danger" role="alert">
There were errors with your request that could not be resolved: <%= include '_base/form/input', type => 'password', name => 'password',
<ul> title => 'Enter your new password',
% for my $error ( @{$c->stash->{errors}} ) { help => '',
<li><%= $error %></li> value => $c->stash->{form_password}
% } %>
</ul>
</div> <%= include '_base/form/input', type => 'password', name => 'password_confirm',
% } title => 'Confirm your new password',
help => '',
value => $c->stash->{form_password_confirm}
%>
<form autocomplete="off" style="margin-top: 1.5em" method="POST" action="<%= $c->url_for() %>"> <button type="submit" class="btn btn-primary float-end">Reset Password</button>
</form>
<%= include '_base/form/input', type => 'password', name => 'password',
title => 'Enter your new password',
help => '',
value => $c->stash->{form_password}
%>
<%= include '_base/form/input', type => 'password', name => 'password_confirm',
title => 'Confirm your new password',
help => '',
value => $c->stash->{form_password_confirm}
%>
<button type="submit" class="btn btn-primary float-end">Reset Password</button>
</form>

@ -19,22 +19,7 @@
<p>If you have your own domain, you can also use that. Be sure to set your DNS records to match *.<%= $c->config->{customer_domain} %>.<p> <p>If you have your own domain, you can also use that. Be sure to set your DNS records to match *.<%= $c->config->{customer_domain} %>.<p>
% if ( $c->stash->{success} ) { %= include '_base/status_window';
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%= $c->stash->{success_message} %>
</div>
% }
% if ( $c->stash->{errors} ) {
<div style="margin-top: 2em" class="alert alert-danger" role="alert">
There were errors with your request that could not be resolved:
<ul>
% for my $error ( @{$c->stash->{errors}} ) {
<li><%= $error %></li>
% }
</ul>
</div>
% }
<form style="margin-top: 1.5em" method="POST" action="<%= $c->url_for( 'do_blog_create' ) %>"> <form style="margin-top: 1.5em" method="POST" action="<%= $c->url_for( 'do_blog_create' ) %>">
<div class="row"> <div class="row">

@ -17,22 +17,7 @@
<p>Let's name and describe this!</p> <p>Let's name and describe this!</p>
% if ( $c->stash->{success} ) { %= include '_base/status_window';
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%= $c->stash->{success_message} %>
</div>
% }
% if ( $c->stash->{errors} ) {
<div style="margin-top: 2em" class="alert alert-danger" role="alert">
There were errors with your request that could not be resolved:
<ul>
% for my $error ( @{$c->stash->{errors}} ) {
<li><%= $error %></li>
% }
</ul>
</div>
% }
<form style="margin-top: 1.5em" method="POST" action="<%= $c->url_for( 'do_blog_settings' ) %>"> <form style="margin-top: 1.5em" method="POST" action="<%= $c->url_for( 'do_blog_settings' ) %>">
<div class="mt-3 mb-3"> <div class="mt-3 mb-3">

@ -2,28 +2,7 @@
%= include 'dashboard/_blog_nav', page => 'info' %= include 'dashboard/_blog_nav', page => 'info'
% if ( my $confirmation = flash 'confirmation' ) { %= include '_base/status_window';
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%== $confirmation %>
</div>
% }
% if ( $c->stash->{success} ) {
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%= $c->stash->{success_message} %>
</div>
% }
% if ( $c->stash->{errors} ) {
<div style="margin-top: 2em" class="alert alert-danger" role="alert">
There were errors with your request that could not be resolved:
<ul>
% for my $error ( @{$c->stash->{errors}} ) {
<li><%= $error %></li>
% }
</ul>
</div>
% }
<div class="row mt-3 mx-2 gx-2 gy-2"> <div class="row mt-3 mx-2 gx-2 gy-2">
<div class="col"> <div class="col">

@ -6,28 +6,7 @@
%= include 'dashboard/_blog_nav', page => 'builds' %= include 'dashboard/_blog_nav', page => 'builds'
% if ( my $confirmation = flash 'confirmation' ) { %= include '_base/status_window';
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%== $confirmation %>
</div>
% }
% if ( $c->stash->{success} ) {
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%= $c->stash->{success_message} %>
</div>
% }
% if ( $c->stash->{errors} ) {
<div style="margin-top: 2em" class="alert alert-danger" role="alert">
There were errors with your request that could not be resolved:
<ul>
% for my $error ( @{$c->stash->{errors}} ) {
<li><%= $error %></li>
% }
</ul>
</div>
% }
%# Job Rejection Panel %# Job Rejection Panel
% if ( $c->param('reject_job') ) { % if ( $c->param('reject_job') ) {

@ -2,29 +2,7 @@
%= include 'dashboard/_blog_nav', page => 'settings' %= include 'dashboard/_blog_nav', page => 'settings'
% if ( my $confirmation = flash 'confirmation' ) { %= include '_base/status_window';
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%== $confirmation %>
</div>
% }
% if ( $c->stash->{success} ) {
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%= $c->stash->{success_message} %>
</div>
% }
% if ( $c->stash->{errors} ) {
<div style="margin-top: 2em" class="alert alert-danger" role="alert">
There were errors with your request that could not be resolved:
<ul>
% for my $error ( @{$c->stash->{errors}} ) {
<li><%= $error %></li>
% }
</ul>
</div>
% }
<form method="POST" action="<%= $c->url_for( 'do_dashboard_blog_config' ) %>"> <form method="POST" action="<%= $c->url_for( 'do_dashboard_blog_config' ) %>">
<div class="mt-3 mb-3"> <div class="mt-3 mb-3">

@ -2,29 +2,7 @@
%= include 'dashboard/_blog_nav', page => 'history' %= include 'dashboard/_blog_nav', page => 'history'
% if ( my $confirmation = flash 'confirmation' ) { %= include '_base/status_window';
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%== $confirmation %>
</div>
% }
% if ( $c->stash->{success} ) {
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%= $c->stash->{success_message} %>
</div>
% }
% if ( $c->stash->{errors} ) {
<div style="margin-top: 2em" class="alert alert-danger" role="alert">
There were errors with your request that could not be resolved:
<ul>
% for my $error ( @{$c->stash->{errors}} ) {
<li><%= $error %></li>
% }
</ul>
</div>
% }
% if ( $history ) { % if ( $history ) {
<table style="border: 1px solid #ccc" class="table mt-5"> <table style="border: 1px solid #ccc" class="table mt-5">

@ -2,34 +2,7 @@
%= include 'dashboard/_blog_nav', page => 'media' %= include 'dashboard/_blog_nav', page => 'media'
% if ( my $confirmation = flash 'confirmation' ) { %= include '_base/status_window';
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%== $confirmation %>
</div>
% }
% if ( my $error_message = flash 'error_message' ) {
<div style="margin-top: 2em" class="alert alert-danger" role="alert">
<%== $error_message %>
</div>
% }
% if ( $c->stash->{success} ) {
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%= $c->stash->{success_message} %>
</div>
% }
% if ( $c->stash->{errors} ) {
<div style="margin-top: 2em" class="alert alert-danger" role="alert">
There were errors with your request that could not be resolved:
<ul>
% for my $error ( @{$c->stash->{errors}} ) {
<li><%= $error %></li>
% }
</ul>
</div>
% }
<form class="row mt-3 gy-2 gx-3 align-items-center" method="POST" enctype="multipart/form-data" action="<%= $c->url_for( 'do_dashboard_blog_media' ) %>"> <form class="row mt-3 gy-2 gx-3 align-items-center" method="POST" enctype="multipart/form-data" action="<%= $c->url_for( 'do_dashboard_blog_media' ) %>">
<div class="col-auto"> <div class="col-auto">

@ -2,6 +2,8 @@
%= include 'dashboard/_blog_nav', page => 'page-create' %= include 'dashboard/_blog_nav', page => 'page-create'
%= include '_base/status_window';
<p class="mt-3 fs-4" >Create a new page!</p> <p class="mt-3 fs-4" >Create a new page!</p>
<form method="POST" action="<%= $c->url_for( 'do_dashboard_blog_page' ) %>"> <form method="POST" action="<%= $c->url_for( 'do_dashboard_blog_page' ) %>">

@ -2,6 +2,8 @@
%= include 'dashboard/_blog_nav', page => 'page-edit' %= include 'dashboard/_blog_nav', page => 'page-edit'
%= include '_base/status_window';
<p class="mt-3 fs-4" >Editing <span class="fw-bolder"><%= $blog_page->rel_path %></span></p> <p class="mt-3 fs-4" >Editing <span class="fw-bolder"><%= $blog_page->rel_path %></span></p>
<form method="POST" action="<%= $c->url_for( 'do_dashboard_blog_page_edit' ) %>"> <form method="POST" action="<%= $c->url_for( 'do_dashboard_blog_page_edit' ) %>">

@ -2,28 +2,7 @@
%= include 'dashboard/_blog_nav', page => 'pages' %= include 'dashboard/_blog_nav', page => 'pages'
% if ( my $confirmation = flash 'confirmation' ) { %= include '_base/status_window';
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%== $confirmation %>
</div>
% }
% if ( $c->stash->{success} ) {
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%= $c->stash->{success_message} %>
</div>
% }
% if ( $c->stash->{errors} ) {
<div style="margin-top: 2em" class="alert alert-danger" role="alert">
There were errors with your request that could not be resolved:
<ul>
% for my $error ( @{$c->stash->{errors}} ) {
<li><%= $error %></li>
% }
</ul>
</div>
% }
<div class="mt-3 mb-3 row"> <div class="mt-3 mb-3 row">
<div class="col"> <div class="col">

@ -2,6 +2,8 @@
%= include 'dashboard/_blog_nav', page => 'create' %= include 'dashboard/_blog_nav', page => 'create'
%= include '_base/status_window';
<form method="POST" action="<%= $c->url_for( 'do_dashboard_blog_post' ) %>"> <form method="POST" action="<%= $c->url_for( 'do_dashboard_blog_post' ) %>">
<div class="mt-3 mb-3"> <div class="mt-3 mb-3">
<label for="postTitle" class="col-sm-2 col-form-label">Title</label> <label for="postTitle" class="col-sm-2 col-form-label">Title</label>

@ -2,6 +2,8 @@
%= include 'dashboard/_blog_nav', page => 'edit' %= include 'dashboard/_blog_nav', page => 'edit'
%= include '_base/status_window';
<p class="mt-3 fs-4" >Editing <span class="fw-bolder"><%= $post->headers->{title} %></span></p> <p class="mt-3 fs-4" >Editing <span class="fw-bolder"><%= $post->headers->{title} %></span></p>
<form method="POST" action="<%= $c->url_for( 'do_dashboard_blog_post_alter' ) %>"> <form method="POST" action="<%= $c->url_for( 'do_dashboard_blog_post_alter' ) %>">

@ -2,6 +2,8 @@
%= include 'dashboard/_blog_nav', page => 'edit' %= include 'dashboard/_blog_nav', page => 'edit'
%= include '_base/status_window';
<form method="POST" action="<%= $c->url_for( 'do_dashboard_blog_post_edit' ) %>"> <form method="POST" action="<%= $c->url_for( 'do_dashboard_blog_post_edit' ) %>">
<input type="hidden" name="mdfile" value="<%= $post->filename %>"> <input type="hidden" name="mdfile" value="<%= $post->filename %>">

@ -2,28 +2,7 @@
%= include 'dashboard/_blog_nav', page => 'posts' %= include 'dashboard/_blog_nav', page => 'posts'
% if ( my $confirmation = flash 'confirmation' ) { %= include '_base/status_window';
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%== $confirmation %>
</div>
% }
% if ( $c->stash->{success} ) {
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%= $c->stash->{success_message} %>
</div>
% }
% if ( $c->stash->{errors} ) {
<div style="margin-top: 2em" class="alert alert-danger" role="alert">
There were errors with your request that could not be resolved:
<ul>
% for my $error ( @{$c->stash->{errors}} ) {
<li><%= $error %></li>
% }
</ul>
</div>
% }
<div class="row mt-3 mb-3"> <div class="row mt-3 mb-3">
<div class="col"> <div class="col">

@ -2,29 +2,7 @@
%= include 'dashboard/_blog_nav', page => 'settings' %= include 'dashboard/_blog_nav', page => 'settings'
% if ( my $confirmation = flash 'confirmation' ) { %= include '_base/status_window';
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%== $confirmation %>
</div>
% }
% if ( $c->stash->{success} ) {
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%= $c->stash->{success_message} %>
</div>
% }
% if ( $c->stash->{errors} ) {
<div style="margin-top: 2em" class="alert alert-danger" role="alert">
There were errors with your request that could not be resolved:
<ul>
% for my $error ( @{$c->stash->{errors}} ) {
<li><%= $error %></li>
% }
</ul>
</div>
% }
<form method="POST" action="<%= $c->url_for( 'do_dashboard_blog_settings' ) %>"> <form method="POST" action="<%= $c->url_for( 'do_dashboard_blog_settings' ) %>">
<div class="mt-3 mb-3"> <div class="mt-3 mb-3">

@ -2,44 +2,28 @@
<h2 class="mt-5 display-6 mb-4">Change your password</h2> <h2 class="mt-5 display-6 mb-4">Change your password</h2>
% if ( $c->stash->{success} ) { %= include '_base/status_window';
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%= $c->stash->{success_message} %>
</div>
% }
% if ( $c->stash->{errors} ) { <form style="margin-top: 1.5em" method="POST" action="<%= $c->url_for( 'do_change_password' ) %>">
<div style="margin-top: 2em" class="alert alert-danger" role="alert">
There were errors with your request that could not be resolved: <%= include '_base/form/input', type => 'password', name => 'password',
<ul> title => 'Your current password',
% for my $error ( @{$c->stash->{errors}} ) { help => '',
<li><%= $error %></li> value => $c->stash->{form_password}
% } %>
</ul>
</div> <%= include '_base/form/input', type => 'password', name => 'new_password',
% } title => 'Your new password',
help => '',
value => $c->stash->{form_new_password}
%>
<%= include '_base/form/input', type => 'password', name => 'password_confirm',
title => 'Confirm your new password',
help => '',
value => $c->stash->{form_password_confirm}
%>
<button type="submit" class="btn btn-primary float-end">Change Password</button>
<form style="margin-top: 1.5em" method="POST" action="<%= $c->url_for( 'do_change_password' ) %>"> </form>
<%= include '_base/form/input', type => 'password', name => 'password',
title => 'Your current password',
help => '',
value => $c->stash->{form_password}
%>
<%= include '_base/form/input', type => 'password', name => 'new_password',
title => 'Your new password',
help => '',
value => $c->stash->{form_new_password}
%>
<%= include '_base/form/input', type => 'password', name => 'password_confirm',
title => 'Confirm your new password',
help => '',
value => $c->stash->{form_password_confirm}
%>
<button type="submit" class="btn btn-primary float-end">Change Password</button>
</form>

@ -2,42 +2,27 @@
<h2 class="mt-5 display-6 mb-4">Change your name or email</h2> <h2 class="mt-5 display-6 mb-4">Change your name or email</h2>
% if ( $c->stash->{success} ) { %= include '_base/status_window';
<div style="margin-top: 2em" class="alert alert-success" role="alert">
<%= $c->stash->{success_message} %>
</div>
% }
% if ( $c->stash->{errors} ) { <form style="margin-top: 1.5em" method="POST" action="<%= $c->url_for( 'do_profile' ) %>">
<div style="margin-top: 2em" class="alert alert-danger" role="alert">
There were errors with your request that could not be resolved:
<ul>
% for my $error ( @{$c->stash->{errors}} ) {
<li><%= $error %></li>
% }
</ul>
</div>
% }
<form style="margin-top: 1.5em" method="POST" action="<%= $c->url_for( 'do_profile' ) %>"> <%= include '_base/form/input', type => 'text', name => 'name',
title => 'Your name',
help => '',
value => $c->stash->{form_name},
%>
<%= include '_base/form/input', type => 'text', name => 'name', <%= include '_base/form/input', type => 'email', name => 'email',
title => 'Your name', title => 'Email Address',
help => '', help => '',
value => $c->stash->{form_name}, value => $c->stash->{form_email},
%> %>
<%= include '_base/form/input', type => 'email', name => 'email', <%= include '_base/form/input', type => 'password', name => 'password',
title => 'Email Address', title => 'Your password (required for these changes)',
help => '', help => '',
value => $c->stash->{form_email}, value => $c->stash->{form_password}
%> %>
<%= include '_base/form/input', type => 'password', name => 'password', <button type="submit" class="btn btn-primary float-end">Update Profile</button>
title => 'Your password (required for these changes)', </form>
help => '',
value => $c->stash->{form_password}
%>
<button type="submit" class="btn btn-primary float-end">Update Profile</button>
</form>

Loading…
Cancel
Save