【发布时间】:2020-10-14 00:43:47
【问题描述】:
我正在使用 vuetify 数据表
<v-data-table
:headers="fields"
:items="items"
:search="search"
:mobile-breakpoint="NaN"
fixed-header
:loading="isBusy"
>
<template v-slot:item="{item,headers}">
<tr>
<td
v-for="(header, index) in headers"
:key="index"
>{{ header.formatFn(item[header.value]) }}</td>
</tr>
</template>
<template v-slot:item.userid="{ item }">Abc{{item}}</template>
<v-alert
slot="no-results"
:value="true"
color="error"
icon="warning"
>Your search for "{{ search }}" found no results.</v-alert>
<template slot="no-data">No Data Exists!</template>
</v-data-table>
以下插槽 template v-slot:item.userid="{ item }">Abc{{item}}</template> 因任何我无法弄清楚的原因而无法工作
我的字段数组有一个字段“用户 ID”。
【问题讨论】:
-
请显示数据语法。
标签: vue.js vuetify.js