element table表格表头显示斜杠/斜线

<el-table
   :data="form.tableData"
   ref="table"
   tooltip-effect="dark"
   border
   height="100%"
   @selection-change='selectRow'>
   <el-table-column
      label="项目"
      align="right">
      <el-table-column
         prop="name"
         label="数量">
         <el-table-column
            width="150"
            prop="month"
            label="月份">
            <template slot-scope="scope">
                <el-form-item :prop="'tableData.' + scope.$index + '.taskCode'">
                   <el-input 
                      v-model="scope.row.new_exceptQuota" 
                      :disabled="requestStatus == 'detail'" 
                      clearable>
                   </el-input>
                </el-form-item>
             </template>
         </el-table-column>
      </el-table-column>
   </el-table-column>
   <el-table-column
      label="右侧大标题"
      align="center"
      :key="item">
      <el-table-column
         label="第二行第一列"
         align="center">
         <template slot-scope="scope">
            <el-form-item  :prop="'tableData.' + scope.$index + '.taskCode'">
               <el-input 
                    v-model="scope.row.new_exceptQuota" 
                    :disabled="requestStatus == 'detail'" 
                    clearable>
               </el-input>
             </el-form-item>
         </template>
      </el-table-column>


      //多个<el-table-column></el-table-column>


   </el-table-column>
</el-table>

样式部分:

/deep/ .el-table th{
	overflow: initial;
}
/deep/ .el-table thead tr:first-of-type th:first-of-type,
/deep/ .el-table thead tr:nth-of-type(2) th:first-of-type{
	border-bottom: none;
}
/deep/ .el-table thead tr:first-of-type th:first-of-type .cell{
	text-align: right;
}
/deep/ .el-table thead tr:nth-of-type(2) th:first-of-type .cell{
	padding-left: 0;
}
/deep/ .el-table thead tr:last-of-type th:first-of-type .cell{
	text-align: left;
}
/deep/ .el-table thead tr:first-of-type th:first-of-type:before,
/deep/ .el-table thead tr:last-of-type th:first-of-type:before{
	content: '';
	position: absolute;
	width: 1px;
	background-color: #666;
	display: block;
}
/deep/ .el-table thead tr:first-of-type th:first-of-type:before {
	height: 198px; //根据情况调整
	top: 0; 
	left: 39px;  //根据情况调整
	transform: rotate(-34deg);  //根据情况调整
	transform-origin: top;
	z-index: 2;
}
/deep/ .el-table thead tr:last-of-type th:first-of-type:before {
	height: 183px;  //根据情况调整
	bottom: 0;
	right: 0;  //根据情况调整
	transform: rotate(-54deg);  //根据情况调整
	transform-origin: bottom;
}

完成效果:

评论 8
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值