<!DOCTYPE html>
<div class="usercorrection">
    <ks-title title="试题纠错" :underline="false" />
    <el-tabs v-model="activeName" @tab-click="handleClick">
        <el-tab-pane label="所有记录" name="first">
            <div class="usercorrection-list">
                <div class="usercorrection-item" v-for="(item,i) in allList" :key="i">
                    <div class="usercorrection-item__index">{{i+1}}、</div>
                    <div class="usercorrection-item__content">
                        <div class="usercorrection-item__contentitem">
                            <span style="margin-right: 60px;">错误类型：&nbsp;{{item.errortype_name}}</span>
                            <span>纠错时间：&nbsp;{{item.adddate}}</span>
                        </div>
                        <div class="usercorrection-item__contentitem">
                            <span>题目内容：</span>
                            <div v-html="item.tk_content" style="float: left"></div>
                        </div>
                        <div class="usercorrection-item__contentitem">
                            <span>错误内容：</span>
                            <div class="usercorrection-item__contenttext">{{item.correction_content}}</div>
                        </div>
                    </div>
                    <div class="usercorrection-item__methods" :style="{color: item.status_name == '已纠正' ? '#2BC152' : '#606367'}">{{item.status_name}}</div>
                </div>
                <el-pagination style="text-align: center;margin-top: 20px;" :current-page="currentPage" @current-change="getUserTkCorrectionAllList" background layout="prev, pager, next" :total="allPageCount" v-if="allPageCount>0">
                </el-pagination>
                <ks-empty msg="您还没有纠错记录" v-else />
            </div>
        </el-tab-pane>
        <el-tab-pane label="已纠正" name="second">
            <div class="usercorrection-list">
                <div class="usercorrection-item" v-for="(item,i) in trueList" :key="i">
                    <div class="usercorrection-item__index">{{i+1}}、</div>
                    <div class="usercorrection-item__content">
                        <div class="usercorrection-item__contentitem">
                            <span style="margin-right: 60px;">错误类型：&nbsp;{{item.errortype_name}}</span>
                            <span>纠错时间：&nbsp;{{item.adddate}}</span>
                        </div>
                        <div class="usercorrection-item__contentitem">
                            <span>题目内容：</span>
                            <div style="float: left" v-html="item.tk_content"></div>
                        </div>
                        <div class="usercorrection-item__contentitem">
                            <span>错误内容：</span>
                            <div class="usercorrection-item__contenttext">{{item.correction_content}}</div>
                        </div>
                    </div>
                    <div class="usercorrection-item__methods" :style="{color: item.status_name == '已纠正' ? '#2BC152' : '#606367'}">{{item.status_name}}</div>
                </div>
                <el-pagination style="text-align: center;margin-top: 20px;" :current-page="currentPage" @current-change="getUserTkCorrectionTrueList" background layout="prev, pager, next" :total="truePageCount" v-if="truePageCount>0">
                </el-pagination>
                <ks-empty msg="该分类没有纠错记录" v-else />
            </div>
        </el-tab-pane>
        <el-tab-pane label="未纠正" name="third">
            <div class="usercorrection-list">
                <div class="usercorrection-item" v-for="(item,i) in falseList" :key="i">
                    <div class="usercorrection-item__index">{{i+1}}、</div>
                    <div class="usercorrection-item__content">
                        <div class="usercorrection-item__contentitem">
                            <span style="margin-right: 60px;">错误类型：&nbsp;{{item.errortype_name}}</span>
                            <span>纠错时间：&nbsp;{{item.adddate}}</span>
                        </div>
                        <div class="usercorrection-item__contentitem">
                            <span>题目内容：</span>
                            <div style="float: left" v-html="item.tk_content"></div>
                        </div>
                        <div class="usercorrection-item__contentitem">
                            <span>错误内容：</span>
                            <div class="usercorrection-item__contenttext">{{item.correction_content}}</div>
                        </div>
                    </div>
                    <div class="usercorrection-item__methods" :style="{color: item.status_name == '已纠正' ? '#2BC152' : '#606367'}">{{item.status_name}}</div>
                </div>
                <el-pagination style="text-align: center;margin-top: 20px;" :current-page="currentPage" @current-change="getUserTkCorrectionFalseList" background layout="prev, pager, next" :total="falsePageCount" v-if="falsePageCount>0">
                </el-pagination>
                <ks-empty msg="该分类没有纠错记录" v-else />
            </div>
        </el-tab-pane>
    </el-tabs>
</div>