This repository has been archived on 2023-08-16. You can view files and clone it, but cannot push or open issues or pull requests.
Foodloop-Server/templates/admin/tokens/read.html.ep

35 lines
1.2 KiB
Text
Raw Normal View History

% layout 'admin';
% title 'Tokens';
2017-04-08 01:32:13 +00:00
% content_for javascript => begin
% end
% if ( my $error = flash 'error' ) {
<div class="alert alert-danger" role="alert">
<strong>Error!</strong> <%= $error %>
</div>
% } elsif ( my $success = flash 'success' ) {
<div class="alert alert-success" role="alert">
<strong>Success!</strong> <%= $success %>
</div>
% }
<form action="<%= url_for %>" method="post">
<div class="form-group">
<label for="token-name">Token Name</label>
<input id="token-name" type="text" class="form-control" placeholder="Token Text" name="token-name" value="<%= $token->accounttokenname %>">
</div>
<div class="form-group">
<label for="token-used">Token Used?</label>
<select id="token-used" class="form-control" name="token-used">
<option value="0"<%= $token->used == 0 ? ' selected' : '' %>>Available</option>
<option value="1"<%= $token->used == 1 ? ' selected' : '' %>>Used</option>
</select>
</div>
<div class="form-group">
<button class="btn btn-primary form-control" type="submit">Update</button>
</div>
</form>
<form action="<%= url_for . '/delete' %>" method="post">
<div class="form-group">
<button class="btn btn-danger form-control" type="submit">Delete</button>
</div>
</form>