|
|
|
@ -39,31 +39,26 @@ |
|
|
|
|
<el-table-column prop="name" label="实训名称" width="400"></el-table-column> |
|
|
|
|
<el-table-column prop="type" label="实训用途" width="160"> |
|
|
|
|
<template slot-scope="scope"> |
|
|
|
|
{{ scope.row.type === 1 ? '练习': '' }} |
|
|
|
|
{{ scope.row.type === 2 ? '考核': '' }} |
|
|
|
|
{{ scope.row.type === 1 ? '考核': '' }} |
|
|
|
|
{{ scope.row.type === 2 ? '练习': '' }} |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
|
<el-table-column prop="isAdmin" label="创建人" width="160"> |
|
|
|
|
<template slot-scope="scope"> |
|
|
|
|
{{ scope.row.isAdmin === 1 ? '管理员': '' }} |
|
|
|
|
{{ scope.row.isAdmin === 2 ? '教师': '' }} |
|
|
|
|
{{ scope.row.isAdmin === 0 ? '教师': '' }} |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
|
<el-table-column prop="updateTime" label="编辑时间" width="240"></el-table-column> |
|
|
|
|
<el-table-column label="操作"> |
|
|
|
|
<template slot-scope="scope"> |
|
|
|
|
<div v-if="showSearchDiv==1"> |
|
|
|
|
<el-button @click="toInputForm(scope.row,0)" type="text" size="small">查看</el-button> |
|
|
|
|
<el-button @click="toInputForm(scope.row,1)" type="text" size="small" |
|
|
|
|
v-if="isShowEditOrDelBtn(scope.row)">编辑 |
|
|
|
|
</el-button> |
|
|
|
|
<el-button @click="doSingleDel(scope.row)" type="text" size="small" v-if="isShowEditOrDelBtn(scope.row)"> |
|
|
|
|
删除 |
|
|
|
|
</el-button> |
|
|
|
|
</div> |
|
|
|
|
<!--<div v-else> |
|
|
|
|
<el-button @click="gotoDb(scope.row)" type="text" size="small">进入</el-button> |
|
|
|
|
</div>--> |
|
|
|
|
<el-button @click="toInputForm(scope.row,0)" type="text" size="small">查看</el-button> |
|
|
|
|
<el-button @click="toInputForm(scope.row,1)" type="text" size="small" |
|
|
|
|
v-if="isShowEditOrDelBtn(scope.row)">编辑 |
|
|
|
|
</el-button> |
|
|
|
|
<el-button @click="doSingleDel(scope.row)" type="text" size="small" v-if="isShowEditOrDelBtn(scope.row)"> |
|
|
|
|
删除 |
|
|
|
|
</el-button> |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
|
</el-table> |
|
|
|
@ -89,9 +84,7 @@ |
|
|
|
|
searchObj: { |
|
|
|
|
type: '', |
|
|
|
|
isAdmin: '', |
|
|
|
|
name: '', |
|
|
|
|
showSearchDiv: 1, |
|
|
|
|
selfIsAdmin:1 |
|
|
|
|
name: '' |
|
|
|
|
}, |
|
|
|
|
listData: [], |
|
|
|
|
delProjectItems: [], |
|
|
|
@ -108,7 +101,7 @@ |
|
|
|
|
initList(searchObj) { |
|
|
|
|
Train.getCaseList(searchObj).then(res => { |
|
|
|
|
if (res.code == 200) { |
|
|
|
|
this.listData = res.data; |
|
|
|
|
this.listData = res.data.rows; |
|
|
|
|
this.totalCount = res.totalCount; |
|
|
|
|
} |
|
|
|
|
}).catch(error => { |
|
|
|
|