<div class="content-heading  justify-content-between">
    <div>考生评分材料</div>
    <div class="float-right">
        <div class="row">
            <div class="wd-xl wd-sm">
                <ngx-select [items]="schoolArray" [(ngModel)]="query.school_id" (ngModelChange)="changeSchool()" placeholder="学校"
                    [autoClearSearch]="true" optionValueField="school_id" optionTextField="school_name">
                </ngx-select>
            </div>
            <div class="wd-xl wd-sm">
                <ngx-select [items]="batchArr" [(ngModel)]="query.batch_id" (ngModelChange)="requestData()" placeholder="批次"
                    [autoClearSearch]="true" optionValueField="batch_id" optionTextField="batch_name">
                </ngx-select>
            </div>            
            <div class="btn-group ml-3 mr-3" dropdown>
                <button class="btn dropdown-toggle btn-secondary" type="button" dropdownToggle>数据处理
                    <span class="caret"></span>
                </button>
                <div *dropdownMenu class="dropdown-menu modal-lg" role="menu">
                    <a class="dropdown-item" href="#" (click)="uploaVideoMertail()">导入视频材料</a>
                    <div class="dropdown-divider"></div>
                    <a class="dropdown-item" href="#" (click)="uploaPicoMertail()">导入图片材料</a>
                    <div class="dropdown-divider"></div>
                    <a class="dropdown-item" href="#" (click)="deleteMaterail()">删除材料</a>
                </div>
            </div>
        </div>
    </div>
</div>

<div class="table-responsive bg-white">
    <table class="table table-striped table-hover table-bordered">
        <thead>
            <tr>
                <th>学校代码</th>
                <th>学校名称</th>
                <th>批次代码</th>
                <th>批次名称</th>
                <th>科目代码</th>
                <th>科目名称</th>
                <th>评分日期</th>
                <th>姓名</th>
                <th>身份证</th>
                <th>考生评分序号</th>
                <th>考题内容</th>
                <th>图片考题路径</th>
                <th>文本内容</th>
                <th>图片作品材料</th>
                <th>视频作品材料</th>
            </tr>
        </thead>
        <tbody>
            <tr *ngFor="let v of pager.getRecords(); let i = index">
                <td>{{v.school_code}}</td>
                <td>{{v.school_name}}</td>
                <td>{{v.batch_code}}</td>
                <td>{{v.batch_name}}</td>
                <td>{{v.subject_code}}</td>
                <td>{{v.subject_name}}</td>
                <td>{{v.ly_exam_date}}</td>
                <td>{{v.std_name}}</td>
                <td>{{v.cert_id}}</td>
                <td>{{v.real_exam_echo}}</td>
                <td>{{v.topic_content}}</td>
                <td>{{v.topic_url}}</td>
                <td>{{v.material_text}}</td>
                <td>
                    <span (click)="showMaterials(v, 'pic');" class="text-muted table-button">{{v.pic_count}}</span>
                </td>
                <td>
                    <span (click)="showMaterials(v, 'video');" class="text-muted table-button">{{v.video_count}}</span>
                </td>                
            </tr>
        </tbody>
    </table>
    <frame-pager [url]="'./ex/material/page.htm'" [pagerParams]="{school_id: query.school_id, batch_id: query.batch_id}" #pager></frame-pager>
</div>