<ion-header>
  <ion-toolbar class="header-toolbar">
      <ion-buttons slot="start">
          <!-- <ion-back-button color="light" class="btnBack" defaultHref="/eit/homepage" ></ion-back-button> -->
          <nav-buttons backLink=""></nav-buttons>
        </ion-buttons>
    <ion-title color="light">{{headerTitle}}</ion-title>
  </ion-toolbar>
</ion-header>

<ion-content padding>

  <div *ngIf="eitAddedList && eitAddedList.length > 0 ">
    <ion-card *ngFor="let eitAddedObj of eitAddedList; let i=index ">

      <ion-card-header>

        <!-- <button *ngIf="getPassMnuEntryObj.UPDATE_BUTTON == 'Y' && eitAddedObj.statusID!=2" ion-button icon-only
              (click)="updateEITRrq(i)">
              <ion-icon name="create"></ion-icon>
            </button> -->
        <button ion-button icon-only (click)="removeAddedItem(i)">
          <ion-icon name="trash"></ion-icon>
        </button>

      </ion-card-header>
      <ion-card-content>
        
        <ion-grid>
          <div>
            <ion-row>
              <ion-col class="colBold">
                <label for="">{{"confirmAddEit.status" | translate}}</label>
              </ion-col>
              <ion-col>
                <label for="">{{eitAddedObj.status}}</label>
              </ion-col>
            </ion-row>
          </div>
          <div *ngFor="let item of eitAddedObj.Collection_Transaction">
            <ion-row *ngIf="item.DISPLAY_FLAG != 'N' ">
              <ion-col class="colBold">
                <label for="">{{item.SEGMENT_PROMPT}}</label>
              </ion-col>
              <ion-col class="colBold">
                <label for="">{{item.SEGMENT_VALUE_DSP}}</label>
              </ion-col>
            </ion-row>
          </div>

        </ion-grid>
      </ion-card-content>
    </ion-card>
  </div>
  <div class="no-dataDiv"
    *ngIf="!getResEITTransactionList || getResEITTransactionList[0]?.Collection_Transaction.length <= 0">
    <!-- <div class="no-dataDiv"> -->
    <ion-row>
      <img class="empty-data" src="../assets/imgs/noData.png" />
    </ion-row>
    <h4> {{'general, noData' | translate}}</h4>
  </div>
  <!-- <no-data *ngIf="!getResEITTransactionList || getResEITTransactionList[0]?.Collection_Transaction.length <= 0" txt="{{'general.noData' | translate}}"></no-data>  -->
  <div *ngIf="getResEITTransactionList && getResEITTransactionList[0]?.Collection_Transaction.length > 0 ">
  <!-- <div> -->
    <ion-card *ngFor="let EITTransactionList of getResEITTransactionList; let i=index ">

      <ion-card-header class="boxHdr">
        <div class="hrTitle">{{this.headerTitle}}</div>

        <button ion-button (click)="deleteEIT(i)"
          *ngIf="getPassMnuEntryObj.DELETE_BUTTON == 'Y' && EITTransactionList.statusID!=3">
          <img class="imgSize" src="../assets/imgs/delete.png"></button>
        <button ion-button *ngIf="getPassMnuEntryObj.UPDATE_BUTTON == 'Y' && EITTransactionList.statusID!=2"
          (click)="updateEITRrq(i)">
          <img class="imgSize" src="../assets/imgs/edit.png"></button>
      </ion-card-header>
      <ion-card-content>


        <ion-grid>
          <div>
            <ion-row>
              <ion-col class="colBold">
                <label for="">status</label>
              </ion-col>
              <ion-col>
                <label for="">{{EITTransactionList.status}}</label>
              </ion-col>
            </ion-row>
          </div>
          <div *ngFor="let item of EITTransactionList.Collection_Transaction">
            <ion-row *ngIf="item.DISPLAY_FLAG != 'N' ">
              <ion-col class="colBold">
                <label for="">{{item.SEGMENT_PROMPT}}</label>
              </ion-col>
              <ion-col>
                <label for="">{{item.SEGMENT_VALUE_DSP}}</label>
              </ion-col>
            </ion-row>
          </div>

        </ion-grid>
      </ion-card-content>
    </ion-card>

  </div>
  <ion-infinite-scroll (ionInfinite)="doInfinite($event)">
    <ion-infinite-scroll-content></ion-infinite-scroll-content>
  </ion-infinite-scroll>

</ion-content>

<ion-footer>
  <div class="centerDiv">
    <!-- <button *ngIf="getPassMnuEntryObj.ADD_BUTTON == 'Y'" ion-button (click)="addEITRrq()">{{'requestEit.add'
            | translate}} </button> -->
    <ion-button class="footer-button" color="customnavy" ion-button (click)="addEITRrq()">
      {{'general, add' | translate}}</ion-button>
  </div>
</ion-footer>