Skip to content

Commit

Permalink
Update last-log-items.component.html
Browse files Browse the repository at this point in the history
  • Loading branch information
polterguy committed Dec 18, 2023
1 parent a711242 commit cc8919d
Showing 1 changed file with 72 additions and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,43 +2,102 @@
<mat-card-content class="h-100">

<div class="d-flex justify-content-between align-items-center">

<p class="mb-0 mat-body-2 fw-bold">System logs</p>
<a mat-button color="primary" routerLink="/log" class="p-0">See all</a>

<a
mat-button
color="primary"
routerLink="/log">
See all
</a>

</div>

<div class="table-responsive w-100 log-table leave-as-normal">
<table mat-table [dataSource]="dataSource" class="w-100">

<table
mat-table
[dataSource]="dataSource"
class="w-100">

<!-- Created column -->
<ng-container matColumnDef="created">
<th mat-header-cell *matHeaderCellDef> Date/time </th>
<td mat-cell *matCellDef="let element" class="pr-3 text-nowrap"> {{element.created | since}} </td>

<th
mat-header-cell
*matHeaderCellDef>
Date/time
</th>

<td
mat-cell
*matCellDef="let element"
class="pr-3 text-nowrap">
{{element.created | since}}
</td>

</ng-container>

<!-- Type column -->
<ng-container matColumnDef="type">
<th mat-header-cell *matHeaderCellDef> Type </th>
<td mat-cell *matCellDef="let element" class="pr-3"
[class.error]="element.type === 'error' || element.type === 'fatal'"> {{element.type}} </td>

<th
mat-header-cell
*matHeaderCellDef>
Type
</th>

<td
mat-cell
*matCellDef="let element"
class="pr-3"
[class.error]="element.type === 'error' || element.type === 'fatal'">
{{element.type}}
</td>

</ng-container>

<!-- Content column -->
<ng-container matColumnDef="content">
<th mat-header-cell *matHeaderCellDef> Content </th>
<td mat-cell *matCellDef="let element" class="pr-3">
<p class="my-0 text-truncate mx-width-100">{{element.content}} </p>

<th
mat-header-cell
*matHeaderCellDef>
Content
</th>

<td
mat-cell
*matCellDef="let element"
class="pr-3">
<p class="my-0 text-truncate mx-width-100">{{element.content}}</p>
</td>

</ng-container>

<!-- More column, implying action buttons -->
<ng-container matColumnDef="more">
<th mat-header-cell *matHeaderCellDef>

<th
mat-header-cell
*matHeaderCellDef>
<span class="d-flex justify-content-end me-2">Details</span>
</th>
<td mat-cell *matCellDef="let element">
<button mat-button color="primary" (click)="viewLog(element)" class="d-block pe-2 ms-auto">

<td
mat-cell
*matCellDef="let element"
class="mx-0">

<button
mat-button
color="primary"
(click)="viewLog(element)"
class="d-block px-2 ms-auto">
Details
</button>

</td>
</ng-container>

Expand Down

0 comments on commit cc8919d

Please sign in to comment.