Skip to content

Commit 9688bbe

Browse files
authored
Merge pull request #306 from ioet/297-add-extra-features-to-projects-table
fix: #297 removing pagination from table
2 parents ee22b85 + 27bc5a0 commit 9688bbe

File tree

2 files changed

+26
-36
lines changed

2 files changed

+26
-36
lines changed
Lines changed: 22 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -1,37 +1,23 @@
1-
<table class="table table-sm table-bordered table-striped">
2-
<thead class="thead-orange">
3-
<tr class="d-flex">
4-
<th class="col-9">Project</th>
5-
<th class="col-3 text-center"></th>
6-
</tr>
7-
</thead>
8-
<tbody>
9-
<tr
10-
class="d-flex"
11-
*ngFor="
12-
let project of projects
13-
| filterProject: filterProjects
14-
| paginate: { itemsPerPage: itemsPerPage, currentPage: initPage3, id: 'third' }
15-
"
16-
>
17-
<td class="col-sm-9">{{ project.name }}</td>
18-
<td class="col-sm-3 text-center">
19-
<button type="button" class="btn btn-sm btn-primary" (click)="updateProject(project)">
20-
<i class="fa fa-pencil fa-xs"></i>
21-
</button>
22-
<button type="button" class="btn btn-sm btn-danger ml-2" (click)="deleteProject(project.id)">
23-
<i class="fa fa-trash-alt fa-xs"></i>
24-
</button>
25-
</td>
26-
</tr>
27-
</tbody>
28-
</table>
29-
<div class="d-flex align-items-end flex-column">
30-
<pagination-controls
31-
class="mt-auto p-2 custom-pagination"
32-
(pageChange)="initPage3 = $event"
33-
id="third"
34-
previousLabel=""
35-
nextLabel=""
36-
></pagination-controls>
1+
<div class="project-list">
2+
<table class="table table-sm table-bordered table-striped">
3+
<thead class="thead-orange">
4+
<tr class="d-flex">
5+
<th class="col-9">Project</th>
6+
<th class="col-3 text-center"></th>
7+
</tr>
8+
</thead>
9+
<tbody>
10+
<tr class="d-flex" *ngFor="let project of projects">
11+
<td class="col-sm-9">{{ project.name }}</td>
12+
<td class="col-sm-3 text-center">
13+
<button type="button" class="btn btn-sm btn-primary" (click)="updateProject(project)">
14+
<i class="fa fa-pencil fa-xs"></i>
15+
</button>
16+
<button type="button" class="btn btn-sm btn-danger ml-2" (click)="deleteProject(project.id)">
17+
<i class="fa fa-trash-alt fa-xs"></i>
18+
</button>
19+
</td>
20+
</tr>
21+
</tbody>
22+
</table>
3723
</div>
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,5 @@
11
@import '../../../../../../../styles/colors.scss';
2+
3+
.project-list {
4+
max-height: 300px; overflow: auto; display:inline-block; width: 100%;
5+
}

0 commit comments

Comments
 (0)