work on panel, ability to upgrade users

This commit is contained in:
lingdocs 2022-03-16 14:56:53 +04:00
parent 7b6b8156ca
commit e0e18610fa
2 changed files with 7 additions and 1 deletions

View File

@ -3,7 +3,6 @@ import {
deleteLingdocsUser,
getLingdocsUser,
updateLingdocsUser,
deleteCouchDbAuthUser,
} from "../lib/couch-db";
import {
getHash,

View File

@ -75,6 +75,13 @@
</div>
<% } else if (users[i].upgradeToStudentRequest === "waiting"){ %>
Upgrade Denied
<% } else if (users[i].level === "basic") { %>
<div><%= users[i].level %></div>
<div>
<form action="/admin/upgradeToStudent/<%= users[i].userId %>/grant" method="POST">
<button class="btn btn-sm btn-success mx-2" type="submit"><i class="fas fa-thumbs-up mr-2"></i> Upgrade </button>
</form>
</div>
<% } else { %>
<%= users[i].level %>
<% } %>