This commit is contained in:
2025-03-11 19:07:16 -04:00
parent 84290f9c46
commit 74808f3fb2
8 changed files with 46 additions and 122 deletions

View File

@@ -7,7 +7,7 @@
<body>
<%- include('partials/nav') %>
<div class="content">
Change Password
<h1>Change Password</h1>
<form id="editor" method="POST" action="/changepassword">
Old Password:<input type="password" name="password0"><br>
New Password:<input type="password" name="password1"><br>

View File

@@ -1,9 +0,0 @@
<!DOCTYPE html>
<html>
<head>
<title>You don't have any tickets</title>
</head>
<body>
<h1>No tickets for you!!</h1>
</body>
</html>

View File

@@ -1,27 +0,0 @@
<!DOCTYPE html>
<html>
<head>
<title>Your Tickets</title>
</head>
<body>
<h1>Welcome, <%= username %>!</h1>
<table border="1">
<tr>
<th>Ticket</th>
<th>Owner</th>
<th>Offered To</th>
<th>QRCode</th>
</tr>
<% for (const t in tlist) { %>
<tr>
<td> <%= t %> </td>
<td> <%= tlist[t].owner %> </td>
<td> <%= tlist[t].offered %> </td>
<td> <%= QRCode.toDataURL("https://abc.com", function(err,url) { if (err) { console.error(err); return; } console.log(url); }); %> </td>
</tr>
<% } %>
<tr>
</tr>
</table>
</body>
</html>

View File

@@ -1,26 +1,28 @@
<!-- views/partials/nav.ejs -->
<div class="nav">
Falls on Fire<br>
<div class="nav-header">
Falls on Fire
</div>
<div class="nav-items">
<a href="/buy">Buy Tickets</a><br>
<%if (typeof username!='undefined' && username) {%>
<a href="/mytickets">View My Tickets</a><br>
<%}%>
<%if (typeof superuser!='undefined' && superuser) {%>
<a href="/camps">View Camps (Admin)</a><br>
<a href="/settings">Settings (Admin)</a><br>
<%}%>
<%if (typeof username!='undefined' && username) {%>
<a href="/changepassword">Change Password</a><br>
<a href="/logout">Log Out</a><br>
<%} else {%>
<a href="/create">Create Account</a><br>
<a href="/login">Log In</a><br>
<%}%>
<%if (typeof username!='undefined' && username) {%>
<a href="/mytickets">View My Tickets</a><br>
<%}%>
<%if (typeof superuser!='undefined' && superuser) {%>
<a href="/camps">View Camps (Admin)</a><br>
<a href="/settings">Settings (Admin)</a><br>
<%}%>
<%if (typeof username!='undefined' && username) {%>
<a href="/changepassword">Change Password</a><br>
<a href="/logout">Log Out</a><br>
<%} else {%>
<a href="/create">Create Account</a><br>
<a href="/login">Log In</a><br>
<%}%>
</div>
<div class="message" id="message">
<% if (typeof commonData.message !== 'undefined') { %>
<p><%= commonData.message %></p>
<% } %>
<% if (typeof commonData.message !== 'undefined') { %>
<p><%= commonData.message %></p>
<% } %>
</div>
<% if (commonData.error) { %>
<div id="errorModal">

View File

@@ -1,28 +0,0 @@
<!DOCTYPE html>
<html>
<head>
<title>Your Tickets</title>
</head>
<body>
<h1>Welcome, <%= username %>!</h1>
<table border="1">
<tr>
<th>Ticket</th>
<th>Owner</th>
<th>Offered To</th>
<th>QRCode</th>
</tr>
<% for (const t in tlist) { %>
<tr>
<td> <%= t %> </td>
<td> <%= tlist[t].owner %> </td>
<td> <%= tlist[t].offered %> </td>
<td> <%= simpledata %> </td>
<td> <%= QRCode.toDataURL("https://abc.com", function(err,url) { if (err) { console.error(err); return; } console.log(url); }); %> </td>
</tr>
<% } %>
<tr>
</tr>
</table>
</body>
</html>

View File

@@ -1,28 +0,0 @@
<!DOCTYPE html>
<html>
<head>
<title>Your Tickets</title>
</head>
<body>
<h1>Welcome, <%= username %>!</h1>
<table border="1">
<tr>
<th>Ticket</th>
<th>Owner</th>
<th>Offered To</th>
<th>QRCode</th>
</tr>
<% for (const t in tlist) { %>
<tr>
<td> <%= t %> </td>
<td> <%= tlist[t].owner %> </td>
<td> <%= tlist[t].offered %> </td>
<td> <%= simpledata %> </td>
<td> <%= QRCode.toDataURL("https://abc.com", function(err,url) { if (err) { console.error(err); return; } console.log(url); }); %> </td>
</tr>
<% } %>
<tr>
</tr>
</table>
</body>
</html>