Plans page created, listing the plans from the database, new plan page created and saving to database
This commit is contained in:
1 parent
1d8ec431b2
commit
b944c37c02
5 files changed
+134
-9
No files matched your search
+17
-2
@@ -1,8 +1,23 @@
|
||||
<%- include("./partials/fileHeader") %>
|
||||
<%- include("./partials/header") %>
|
||||
|
||||
<main>
|
||||
The Plans Page
|
||||
<main class="container mx-auto p-4">
|
||||
<h2 class="text-xl text-white font-semibold mb-4">Welcome: <%= user.email %></h2>
|
||||
<div class="max-w-md mx-auto bg-white p-8 mb-10 rounded-lg shadow-md space-y-4">
|
||||
<h3 class="text-lg font-medium mb-6">My Retirement Plans</h3>
|
||||
<a href="/newPlan" class="block max-w-sm p-2"><div class="border-2 text-center border-gray-600 bg-blue-600 text-white py-1 w-full rounded-md hover:bg-transparent hover:text-indigo-700 font-semibold">New Plan</div></a>
|
||||
<hr class="mt-3">
|
||||
<% plans.forEach(plan => { %>
|
||||
<a href="<%= plan.link %>" class="block max-w-sm p-6 bg-white border border-gray-200 rounded-lg shadow-sm hover:bg-gray-100 dark:bg-gray-800 dark:border-gray-700 dark:hover:bg-gray-700">
|
||||
<h5 class="mb-2 text-2xl font-bold tracking-tight text-gray-900 dark:text-white"><%= plan.name %></h5>
|
||||
<div class="w-full bg-gray-200 rounded-full h-2.5 mb-4 dark:bg-gray-700">
|
||||
<div class="bg-green-600 h-2.5 rounded-full dark:bg-green-500" style="width: <%= plan.progress %> "></div>
|
||||
</div>
|
||||
<p class="font-normal text-gray-700 dark:text-gray-400"><%= plan.description %></p>
|
||||
</a>
|
||||
<% }) %>
|
||||
</div>
|
||||
|
||||
</main>
|
||||
|
||||
<%- include("./partials/navBar") %>
|
||||
|
||||
Reference in new issue
Block a user