element-ui table-自定义表格某列的表头样式或者功能

  • 自带表格
  • 自定义表格某列的表头样式或者功能
js 复制代码
 <el-table>
 	<el-table-column :prop="date">
 		//自定义表身每行数据
 		<template slot-scope="scope">
        	{{scope.row[scope.column.label] === '-' ? '-' : scope.row[scope.column.label]}}
        </template>
        
        //自定义表头
        <template slot='header'  slot-scope="scope">
			<el-button type="primary" @click="filterTest(scope.column)">筛选</el-button>
        </template>
     </el-table-column>
</el-table>
相关推荐
涛涛ing38 分钟前
OpenAI Astra 泄露:零样本生成 3D 网页,前端开发者慌了吗?
前端
ssshooter1 小时前
现在网页都能提供 MCP 了?!
前端·人工智能·程序员
杉氧1 小时前
状态管理变迁史:为什么我们放弃了 Redux 选择 Zustand?
android·前端·react native
cidy_981 小时前
OpenCode 手动配置火山方舟 Agent Plan 教程
前端
鹏多多1 小时前
PC 网站接入微信登录,这 10 个坑我替你踩完了!
前端·javascript·vue.js
律宏阔2 小时前
微信小程序使用 Orval + OpenAPI 自动生成接口:Axios 兼容踩坑记录
前端·微信小程序
律宏阔2 小时前
微信小程序集成 TDesign 完整记录:解决 NPM packages not found
前端·微信小程序
律宏阔2 小时前
微信小程序 ECharts 瘦身实战:分包异步化 + componentPlaceholder 避开主包 2MB 限制
前端·微信小程序
夏天要喝冰可乐2 小时前
从 Idea 到开源插件:我用 Vibe Coding 做了「文章摆渡」
前端·ai编程·vibecoding
小小小小宇2 小时前
pi agent
前端