<div class="content-heading  justify-content-between">
  <div>曲目库管理</div>
  <div class="float-right">
    <div class="btn-group mb-1 mr-1" dropdown>
      <button class="btn dropdown-toggle btn-secondary btn-lg" type="button" dropdownToggle>曲目管理
        <span class="caret"></span>
      </button>
      <div *dropdownMenu class="dropdown-menu modal-lg" role="menu">
        <a class="dropdown-item" href="#" (click)="showModal({'arrayUrl':'conf/variety/all.htm'})">新增曲目</a>
        <div class="dropdown-divider"></div>
        <!-- <a class="dropdown-item" href="#" (click)="uploader.uploadFiles()">导入曲目</a>
        <div class="dropdown-divider"></div>
        <a class="dropdown-item" href="#" (click)="uploader.downloadTempalte()">下载模版</a>
        <div class="dropdown-divider"></div> -->
        <a class="dropdown-item" href="#" (click)="ModalService.showUploadWindow(bsService,'conf/tracks/upload.htm',
        {},{
          uploadTitle:'曲目上传',
          templateFile:'模版-曲目库导入.xls',
          uploadCallback:uploadCallback.bind(this),
          autoClose:true
        })">导入曲目</a>
        <div class="dropdown-divider"></div>
        <a class="dropdown-item" href="#" (click)="export()">导出曲目</a>
      </div>
    </div>
  </div>
</div>
<div class="table-responsive bg-white table-full">
  <table class="table table-striped table-hover table-bordered">
    <thead>
    <tr>
      <th><span class="table-sort" (click)="pager.sort('variety_name')">乐器名称</span></th>
      <th><span class="table-sort" (click)="pager.sort('tracks_group')">曲目分组</span></th>
      <th><span class="table-sort" (click)="pager.sort('tracks_code')">曲目代码</span></th>
      <th><span class="table-sort" (click)="pager.sort('tracks_name')">曲目名称</span></th>
      <th><span class="table-sort" (click)="pager.sort('tracks_type')">曲目类型</span></th>
      <th><span class="table-sort" (click)="pager.sort('tracks_author')">作者或出处</span></th>

      <th>填报说明</th>
      <th class="th-b-2"></th>
    </tr>
    </thead>
    <tbody>
    <tr *ngFor="let v of pager.getRecords(); let i = index">
      <td>{{v.variety_name}}</td>
      <td>{{v.tracks_group}}</td>
      <td>{{v.tracks_code}}</td>
      <td>{{v.tracks_name}}</td>
      <td>{{v.tracks_type}}</td>
      <td>{{v.tracks_author}}</td>
      <!--
      <td [innerHTML]="v.tracks_status | frameStatusCustom: ['允许填报','禁止填报']"></td>
      -->
      <td><span *ngIf="v.tracks_enrol_explain" class="text-success" [tooltip]="v.tracks_enrol_explain">有报考说明</span>

      <td><span class="table-button" (click)="showModal({ResponseEntity:v, 'arrayUrl':'conf/variety/all.htm'})"><em
        class="fa-lg fas fa-edit"></em></span>
        <span class="table-button ml-3 text-danger"
              (click)="pager.optrRecord('conf/tracks/delete.htm', v, {successMsg:'乐器/舞种已删除！', confirmMsg: '确定要删除该乐器/舞种吗？', successMsgType:'Swal'})"><em
          class="fa-lg fas fa-trash-alt "></em></span>
      </td>
    </tr>
    </tbody>
  </table>
  <frame-pager [url]="'./conf/tracks/page.htm'" #pager></frame-pager>
</div>


<!-- <frame-uploader [uploadUrl]="'conf/tracks/upload.htm'" [templateFile]="'模版-曲目库导入.xls'" [allowedFileType]="['xls']" [confirmMsg]="'上传文件会删除原有的曲目库信息,确定要继续吗'" #uploader></frame-uploader> -->
