Skip to content

Commit

Permalink
perf: 修改自定义操作列插槽语法
Browse files Browse the repository at this point in the history
  • Loading branch information
BoBoooooo committed Jan 24, 2021
1 parent 26e1168 commit 68204a6
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
"axios": "^0.19.2",
"core-js": "3.6.5",
"dayjs": "1.8.20",
"element-pro-crud": "^0.8.3-3",
"element-pro-crud": "^0.8.3-51",
"element-ui": "^2.13.2",
"inquirer": "^6.5.2",
"lodash": "^4.17.14",
Expand Down
8 changes: 3 additions & 5 deletions src/views/person/Person.vue
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,9 @@
tableTitle: true
}"
>
<template #column_jobno="{row}">
<el-tag>{{ row.jobno }}</el-tag>
</template>
<template #column_personname="{row}">
<span><i class="el-icon el-icon-user" style="color: red"></i>{{ row.personname }}</span>
<template #columnFormatter="{row,prop}">
<el-tag v-if="prop === 'jobno'">{{ row.jobno }}</el-tag>
<span v-if="prop === 'personname'"><i class="el-icon el-icon-user" style="color: red"></i>{{ row.personname }}</span>
</template>
</CrudTable>
</div>
Expand Down

0 comments on commit 68204a6

Please sign in to comment.