This commit is contained in:
2023-12-14 11:15:56 +01:00
parent 55f5869385
commit f6f9819058
21 changed files with 3516 additions and 0 deletions

0
views/categories.pug Normal file
View File

19
views/index.pug Normal file
View File

@@ -0,0 +1,19 @@
doctype html
html
head
title= title
body
h1 Welcome to our Web App!
p This is a simple example using Express and Pug.
a(href='/users') View Users
div
div
p Transactions
p=transactionCount
div
p Categorys
p=categoryCount
div
p Users
p=userCount

13
views/layout/base.pug Normal file
View File

@@ -0,0 +1,13 @@
doctype html
html
head
title= title
link(href="/assets/css/app.css",rel="stylesheet")
block additionalAssets
body
div.container
block headline
block content

View File

@@ -0,0 +1,24 @@
extends ../layout/base.pug
block headline
h1 Transactions
block content
form(action="/tansactions",method="POST")
table
thead
th ID
th Date
th Description
th Account
th Amount
tbody
each transaction in transactions
tr
td=transaction.TransactionID
td=transaction.Date
td=transaction.Description
td=transaction.Account.Name
td(class=`${transaction.Type} amount` )=transaction.Amount

9
views/users.pug Normal file
View File

@@ -0,0 +1,9 @@
doctype html
html
head
title= title
body
h1 Users
ul
each user in users
li= user.Name