✨feature: Add page for signle site test list
This commit is contained in:
23
views/test-list.ejs
Normal file
23
views/test-list.ejs
Normal file
@@ -0,0 +1,23 @@
|
||||
<%
|
||||
// Helper function to format date
|
||||
function formatDate(dateString) {
|
||||
let date = new Date(dateString);
|
||||
return date.toLocaleString('en-CA', {
|
||||
year: 'numeric',
|
||||
month: 'long',
|
||||
day: 'numeric',
|
||||
hour: 'numeric',
|
||||
minute: '2-digit'
|
||||
});
|
||||
}
|
||||
%>
|
||||
|
||||
<ul class="list bg-base-100 rounded-box shadow-md mt-8">
|
||||
<% for (let i=0; i < sites.length; i++) { %>
|
||||
<li class="list-row list-none items-center gap-8">
|
||||
<h3 class="text-slate-300 m-0 p-0"><a href="/test/<%= i %>" class="text-slate-300 link">Test <%= i+1 %></a></h3>
|
||||
<span class="site-name list-col-grow text-18px"><%= sites[i].domain_name %> - <%= formatDate(sites[i].created_at) %></span>
|
||||
<span class="badge badge-info">In Progress</span>
|
||||
</li>
|
||||
<% } %>
|
||||
</ul>
|
||||
Reference in New Issue
Block a user