|
|
@ -21,13 +21,22 @@ |
|
|
|
<tbody class="table-body"> |
|
|
|
<tr class="table-body-tr" |
|
|
|
v-for="(value, index) in list" |
|
|
|
:key="index"> |
|
|
|
:key="index" |
|
|
|
@click="handleClickRow(index)"> |
|
|
|
<td class="td" |
|
|
|
v-for="(item, indexs) in value" |
|
|
|
:key="indexs"> |
|
|
|
<div v-if="typeof item === 'string' || typeof item === 'number'"> |
|
|
|
{{ item }} |
|
|
|
</div> |
|
|
|
|
|
|
|
<div v-if="typeof item === 'object'&& item.type === 'img'"> |
|
|
|
<!-- <span>{{ item.type+ item.src}}</span> --> |
|
|
|
<img style="width:18px;height:18px" |
|
|
|
:src="item.src" |
|
|
|
alt="" /> |
|
|
|
|
|
|
|
</div> |
|
|
|
<div v-if="typeof item === 'object' && item && item.type == 'index'"> |
|
|
|
<img v-if="highlightTop3 && index == 0" |
|
|
|
src="@/assets/img/shuju/top/1.png" |
|
|
@ -139,6 +148,10 @@ export default { |
|
|
|
created () { }, |
|
|
|
|
|
|
|
methods: { |
|
|
|
//点击某一行 |
|
|
|
handleClickRow (index) { |
|
|
|
this.$emit("handleClickRow", index); |
|
|
|
}, |
|
|
|
handleClickBtn (index, type) { |
|
|
|
this.$emit("operate", index, type); |
|
|
|
}, |
|
|
@ -191,7 +204,7 @@ export default { |
|
|
|
box-sizing: border-box; |
|
|
|
text-align: center; |
|
|
|
border: none; |
|
|
|
padding: 20px 5px; |
|
|
|
padding: 10px 5px; |
|
|
|
|
|
|
|
> div { |
|
|
|
overflow: hidden; |
|
|
|