Skip to content

Commit 56251db

Browse files
Add files via upload
1 parent fd9568b commit 56251db

File tree

2 files changed

+52
-0
lines changed

2 files changed

+52
-0
lines changed

confirm_delete_employee.html

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
<!DOCTYPE html>
2+
<html>
3+
<head>
4+
<title>Confirm Delete Employee</title>
5+
<!-- Use Bootstrap for styling -->
6+
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css">
7+
</head>
8+
<body>
9+
<!-- Create a banner -->
10+
<div class="jumbotron">
11+
<h1 class="display-4">Employee Management System</h1>
12+
<p class="lead">Confirm Delete Employee</p>
13+
</div>
14+
<!-- Use a container to center the form -->
15+
<div class="container">
16+
<p>Are you sure you want to delete this employee?</p>
17+
<p><strong>Name:</strong> {{ employee[1] }}</p>
18+
<p><strong>Email:</strong> {{ employee[2] }}</p>
19+
<p><strong>Department:</strong> {{ employee[3] }}</p>
20+
<form action="{{ url_for('delete_employee', id=employee[0]) }}" method="post">
21+
<div class="form-group">
22+
<button type="submit" class="btn btn-danger mr-2">Yes</button>
23+
<a href="{{ url_for('get_all') }}" class="btn btn-secondary">No</a>
24+
</div>
25+
</form>
26+
</div>
27+
</body>
28+
</html>

get_employees.html

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
<!-- Use Bootstrap for styling -->
2+
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css">
3+
4+
<!-- Create a table to display all employees -->
5+
<table class="table">
6+
<thead>
7+
<tr>
8+
<th scope="col">#</th>
9+
<th scope="col">Name</th>
10+
<th scope="col">Email</th>
11+
<th scope="col">Department</th>
12+
</tr>
13+
</thead>
14+
<tbody>
15+
{% for employee in employees %}
16+
<tr>
17+
<th scope="row">{{ employee.id }}</th>
18+
<td>{{ employee.name }}</td>
19+
<td>{{ employee.email }}</td>
20+
<td>{{ employee.department }}</td>
21+
</tr>
22+
{% endfor %}
23+
</tbody>
24+
</table>

0 commit comments

Comments
 (0)