浏览代码

HUE-9485 [frontend] Add a click event on the HueTable row

Johan Ahlen 5 年之前
父节点
当前提交
eaff00fd42
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      desktop/core/src/desktop/js/components/HueTable.vue

+ 1 - 1
desktop/core/src/desktop/js/components/HueTable.vue

@@ -29,7 +29,7 @@
       </tr>
     </thead>
     <tbody>
-      <tr v-for="(row, rowIndex) in rows" :key="rowIndex">
+      <tr v-for="(row, rowIndex) in rows" :key="rowIndex" @click="$emit('row-clicked', row)">
         <td v-for="(column, colIndex) in columns" :key="colIndex">
           <component
             :is="column.cellComponent"