
思路解析:
點擊修改,將單元格內改變成輸入框格式,點擊保存去調取接口
<!-- 表格主體 -->
<template slot-scope="scope">
<span v-if="scope.row.isSet">
<el-input
size="large"
placeholder="請輸入內容"
v-model="scope.row[temTableData.keyList[index]]"
@input="inputChange($event)"
>
</el-input>
</span>
<span v-else>{{ scope.row[temTableData.keyList[index]] }}</span>
</template>
inputChange(e) { //解決空字符串時 input 不可以輸入字段
this.$forceUpdate();
},
