<template><divclass="table-container-wapper tab-wapper"><divclass="header-container"><divclass="buttton-contain"><el-button:size="$formSize"icon="el-icon-circle-plus-outline"@click="handleAdd">增加指令</el-button></div></div><divclass="center-container"><el-tableref="table":data="tableData"header-row-class-name="iot-table-header"v-loading="isTableLoading"><templateslot="empty"><el-emptydescription="暂无数据"></el-empty></template><el-table-columnlabel="名称"prop="name"><templateslot-scope="scope"><spanv-if="scope.row.isEdit">{{scope.row.name}}</span><el-inputv-elsev-model="scope.row.name"size="small"label-width="80px"placeholder="请输入"maxlength="32"/></template></el-table-column><el-table-columnlabel="识别符"prop="code"><templateslot-scope="scope"><spanv-if="scope.row.isEdit">{{scope.row.code}}</span><el-inputv-elsev-model="scope.row.code"size="small"label-width="80px"placeholder="请输入"maxlength="32"/></template></el-table-column><el-table-columnlabel="是否隐藏"prop="isHead"><templateslot-scope="scope"><spanv-if="scope.row.isEdit">{{scope.row.isHead}}</span><el-selectv-elsev-model="scope.row.isHead"placeholder="全部"><el-optionv-for="item in isHeadList":key="item.id":label="item.label":value="item.value"></el-option></el-select></template></el-table-column><el-table-columnlabel="读写类型"prop="type"><templateslot-scope="scope"><spanv-if="scope.row.isEdit">{{scope.row.type}}</span><el-selectv-elsev-model="scope.row.type"placeholder="全部"><el-optionv-for="item in typeList":key="item.id":label="item.label":value="item.value"></el-option></el-select></template></el-table-column><el-table-columnlabel="关联物模型"prop="model"><templateslot-scope="scope"><spanv-if="scope.row.isEdit">{{scope.row.model}}</span><el-selectv-elsev-model="scope.row.model"multipleplaceholder="请选择"><el-optionv-for="item in modelList":key="item.id":label="item.label":value="item.value"></el-option></el-select></template></el-table-column><el-table-columnlabel="操作"min-width="120"><templateslot-scope="scope"><el-buttonv-if="scope.row.isEdit"type="text"@click="handleEdit(scope.row)"icon="el-icon-edit"></el-button><el-buttonv-if="!scope.row.isEdit"type="text"@click="handelConfirm(scope.row)"icon="el-icon-check"></el-button><el-buttontype="text"class="text-delbtn"@click="handleDelete(scope)"icon="el-icon-delete"></el-button></template></el-table-column></el-table></div></div></template>