<ecm-header #header [isFixedHeader]=true> </ecm-header>
<ecm-breadcrumbs [pageName]="'USERORDER'"></ecm-breadcrumbs>

<div class="row orderDisplay">
	<span class="orders">Orders ( {{(ordersItems | async)?.length}} )</span>
	<div *ngFor="let order of ordersList" >
	<md-card class="dispaly">
	<div class="row headContents">
		<div class="small-6 medium-2 large-2 columns">
<!-- 			<span class="orderDate">Order Date</span> <span class="date">{{order?.orderDate}}</span> -->
			 <span class="orderDate">Order Date</span> <span class="date">{{ toDate(order?.orderDate) |date : dispDateFormat}}</span>
		</div>
		<div class="small-6 medium-3 large-3 columns">
			<span class="orderID">Order ID</span> <span class="id">{{order?.orderNo}}</span>
		</div>
		<div class="small-6 medium-3 large-3 columns" style="text-align: center;">
			<span class="orderTotal">Order Total</span> <span class="total">Rs {{order?.amount}}</span>
		</div>
		<div class="small-6 medium-4 large-4 columns invoiceDetail">
			<span class="orderInvoice" (click)="invoiceDetail()">Invoice</span> 
			<span class="orderDetail" (click)="orderDetail()">Order Details</span>
		</div>
	</div>
	<div *ngFor="let orderDets of order.ecmOrderDets" class="row orderList">
	     <ecm-card  [orderDetails]="orderDets"></ecm-card>
	     <div class="small-12 medium-4 large-4 columns reviewScreen">
<!-- 			<user-review [itemCode]="orderDets.itemCode"></user-review> -->
				<user-review [itemCode]="orderDets.itemCode" ></user-review>
		</div>
	</div>
</md-card>
</div>
</div>