之前有个需给table中的input框根据要求添加相应的样式,
并且不可以输入,只是一个提示的作用,因此想着这样设计不太理想,
干脆给单元格设置样式?
<div>
<el-button v-if="constract.list" @click="hanleCell">切换</el-button>
<el-form :model="constract" ref="constract">
<el-table
:data="constract.list"
border
style="width: 100%"
:cell-class-name="cellName"
>
<el-table-column prop="name" label="名称" width="200">
</el-table-column>
<el-table-column prop="typeOne" label="类型一" width="200">
<!--<el-form-item slot-scope="scope">
<el-input v-model="scope.row.typeOne"></el-input>
</el-form-item> -->
</el-table-column>
<el-table-column prop="typeTwo" label="类型二" width="200">
<!--<el-form-item slot-scope="scope">
<el-input v-model="scope.row.typeTwo "></el-input><