2016-10-08 3 views
0

anchor 태그를 비활성화하기 위해 2 ngClass 각도를 사용하고 있습니다. Google 크롬에서는 작동하지만 IE 11에서는 작동하지 않습니다. 비슷한 문제가 있습니까?Angular 2 ng-class가 IE 11에서 작동하지 않습니다.

<div id ="fileList" class="panel-body collapse in"> 
      <div class="table-responsive"> 
        <table id="uploadInvoice" class="table table-bordered table-condensed"> 
        <thead class ="thead"> 
        <tr> 
         <th class="gridHeader sortable order1" style="display:none;">File ID</th> 
         <th class="gridHeader sortable">File Name</th> 
         <th class="gridHeader sortable">Upload Status</th> 
         <th class="gridHeader sortable">Uploaded Date</th> 
         <th class="gridHeader sortable">Updated Date</th> 
         <th class="gridHeader sortable">Uploaded BY</th> 
        </tr> 
        </thead> 
        <tbody> 
        <tr *ngFor="let file of fileList"> 
         <td style="display:none;">{{file.id}}</td> 
         <td><a href="#fileList" data-toggle="collapse" [ngClass]="{'disabled':file.fileStatus == 'VALIDATING'}" 
         (click) ="getValidationSummary(file.id,file.fileName)">{{file.fileName}}</a></td> 
         <td>{{file.fileStatus}}</td> 
         <td>{{file.createdDate}}</td> 
         <td>{{file.modifiedDate}}</td> 
         <td>{{file.createdBy}}</td>          
        </tr> 
        </tbody> 
       </table> 

       </div> 
      </div> 
     </div> 
+0

나는 비슷한 상황에 처했다. 이 문제를 해결 한 행운이 있었습니까? – atsituab

+0

이 문제를 해결하는 방법에는 두 가지가 있습니다. uisng * NgIf를 사용하거나 [disabled] – Developer

답변

1

ngClass 대신 * ngIf를 사용하여 해결했습니다.

<div id="fileList" class="panel-body collapse in"> 
          <div class="table-responsive"> 
           <table id="uploadInvoice" 
            class="table table-bordered table-condensed"> 
            <thead class="thead"> 
             <tr> 
              <th class="gridHeader sortable order1" style="display: none;">File 
               ID</th> 
              <th class="gridHeader sortable">File Name</th> 
              <th class="gridHeader sortable">Upload Status</th> 
              <th class="gridHeader sortable">Uploaded Date</th> 
              <th class="gridHeader sortable">Updated Date</th> 
              <th class="gridHeader sortable">Uploaded BY</th> 
              <th class="gridHeader sortable ">Comments</th> 
             </tr> 
            </thead> 
            <tbody> 
             <tr *ngFor="let file of fileList"> 
              <td style="display: none;">{{file.id}}</td> 
              <td 
               *ngIf="(file.fileStatus != 'PROCESSED' && file.fileStatus != 'ERRORED')">{{file.fileName}}</td> 
              <td 
               *ngIf="(file.fileStatus == 'PROCESSED' || file.fileStatus == 'ERRORED' )"><a 
               href="#fileList" data-toggle="collapse" 
               (click)="getValidationSummary(file.id,file.fileName)">{{file.fileName}}</a></td> 
              <td>{{file.fileStatus}}</td> 
              <td>{{file.createdDate}}</td> 
              <td>{{file.modifiedDate}}</td> 
              <td>{{file.createdBy}}</td> 
              <td><span class="wrappingData">{{ file.comments }}</span></td> 
             </tr> 
            </tbody> 
           </table> 

          </div> 
         </div> 
관련 문제