unblockuser.component.html 2.94 KB
<div class="row" style="margin-right: auto;">
  <!-- main-heading -->
  <div class="col-sm-12 pageHeading" style="margin-left: 15px;">
    <h4>Unblock User</h4>
  </div>
  <!-- main-heading -->

  <ng-template #template>
    <div class="modal-header">
      <h4 class="modal-title pull-left">Confirmation</h4>
      <button type="button" class="close pull-right" aria-label="Close" (click)="modalRef.hide()">
        <span aria-hidden="true">&times;</span>
      </button>
    </div>
    <div class="modal-body">
      <p>Are you sure to unblock the selected user(s)?</p>
    </div>
    <div class="modal-footer">
      <button type="button" class="btn btn-primary btn-sm" (click)="UpdateUnBlockedUsers()">Yes</button>
      <button type="button" class="btn btn-primary btn-sm" (click)="modalRef.hide()">No</button>
    </div>
  </ng-template>

  <ng-template #templatesuccess>
    <div class="modal-header">
      <h4 class="modal-title pull-left">Confirmation</h4>
      <button type="button" class="close pull-right" aria-label="Close" (click)="modalRef.hide()">
        <span aria-hidden="true">&times;</span>
      </button>
    </div>
    <div class="modal-body" [innerHTML]="modalAlerts">
    </div>
    <div class="modal-footer">
    </div>
  </ng-template>

  <!-- container -->
  <div>
    <div class="container-fluid main-full">

      <div class="well">
        <table id="fixed_hdr2" class="table-hover  ui-widget-header sorttable">
          <thead>
            <tr>
              <th id="unknown">Select</th>
              <th id="FirstName">First Name</th>
              <th id="LastName">Last Name</th>
              <th id="LoginId">User ID</th>
              <th id="Password">Password</th>
              <th id="EmailId">Email ID</th>
              <th id="LoginTime">Blocked Date</th>
              <th id="AccountNumber">Account Number</th>
            </tr>
          </thead>
          <tbody>
            <tr *ngFor="let UserEntity of UserList;let i = index">
              <td>
                <input type="checkbox" (change)="onChange(i, UserEntity.Id, $event.target.checked)">
              </td>
              <td>{{UserEntity.FirstName}}</td>
              <td>{{UserEntity.LastName}}</td>
              <td>{{UserEntity.LoginId}}</td>
              <td>{{UserEntity.Password}}</td>
              <td>{{UserEntity.EmailId}}</td>
              <td>{{UserEntity.LoginTime| date: 'MM/dd/yyyy'}}</td>
              <td>{{UserEntity.AccountNumber}}</td>
            </tr>

          </tbody>
        </table>

        <div class="row">
          <div class="col-sm-12 marginTop20 text-center">
            <button class="btn btn-primary btn-sm" (click)="openModal(template)"
              [ngClass]="{disabled : !buttonStatus}"><i class="fa fa-times-circle"></i> Unblock</button>
            <button class="btn btn-primary btn-sm" (click)="redirect()"><i class="fa fa-close"></i> Cancel</button>
          </div>
        </div>
      </div>
    </div>
  </div>
  <!-- container -->
</div>