zgo/src/app/listorders/listorders.component.html

41 lines
1.4 KiB
HTML
Raw Normal View History

<app-header></app-header>
<div align="center">
<h1 class="text">{{(ownerUpdate | async)!.name}}</h1>
<button class="text" mat-raised-button [routerLink]="['/shop']" color="primary">
Back to Shop
</button>
</div>
<mat-divider></mat-divider>
<div align="center">
<table class="text" width="75%">
<tr>
<td width="50%" align="center">
<h3>Today's Total:</h3>
<p class="total"><img src="/assets/zec-roboto.png" height="14px" />{{todayTotal}}</p>
</td>
<td width="50%" align="center">
<h3>Overall Total:</h3>
<p class="total"><img src="/assets/zec-roboto.png" height="14px" />{{total}}</p>
</td>
</tr>
</table>
</div>
<mat-divider></mat-divider>
<mat-accordion *ngIf = "orders.length > 0">
<mat-expansion-panel class="text" *ngFor = "let order of orders">
<mat-expansion-panel-header class="text" >
<mat-panel-title>
<span class="price"><img src="/assets/zec-roboto.png" height="50%" />{{order.totalZec}}</span> <span class="mini"> (@{{order.price | currency: 'USD'}})</span>
</mat-panel-title>
<mat-panel-description>
{{order.timestamp | date: 'medium'}}
</mat-panel-description>
</mat-expansion-panel-header>
<p class="text">Order: {{order._id}}</p>
<mat-list>
<mat-list-item class="text small" *ngFor="let item of order.lines">{{item.qty}} x {{item.name}}</mat-list-item>
</mat-list>
</mat-expansion-panel>
</mat-accordion>
<p class="text" *ngIf = "orders.length <= 0">No orders</p>