Add SmartTable Vue component.
This commit is contained in:
@ -6,9 +6,12 @@ import { store } from './store';
|
||||
import router from './router';
|
||||
import { FontAwesomeIcon } from '@fortawesome/vue-fontawesome';
|
||||
|
||||
import SmartTable from 'vuejs-smart-table';
|
||||
|
||||
import './registerServiceWorker';
|
||||
|
||||
Vue.component('fa-icon', FontAwesomeIcon);
|
||||
Vue.use(SmartTable);
|
||||
|
||||
new Vue({
|
||||
router,
|
||||
|
8
web/src/types/vuejs-smart-table.d.ts
vendored
Normal file
8
web/src/types/vuejs-smart-table.d.ts
vendored
Normal file
@ -0,0 +1,8 @@
|
||||
declare module 'vuejs-smart-table' {
|
||||
var VTable: any;
|
||||
var VTh: any;
|
||||
var VTr: any;
|
||||
var SmartPagination: any;
|
||||
var defaultExport: any;
|
||||
export default defaultExport;
|
||||
}
|
@ -10,6 +10,20 @@
|
||||
</fieldset>
|
||||
<section class=api-tokens>
|
||||
<h2>API Tokens</h2>
|
||||
<v-table :data=apiTokens>
|
||||
<thead slot=head>
|
||||
<v-th sortKey="name">Name</v-th>
|
||||
<v-th sortKey="created">Created</v-th>
|
||||
<v-th sortKey="expires">Expires</v-th>
|
||||
</thead>
|
||||
<tbody slot=body slot-scope="{displayData}">
|
||||
<tr v-for="token in displayData" :key="token.id">
|
||||
<td>{{token.name}}</td>
|
||||
<td>{{token.created}}</td>
|
||||
<td>{{token.expires}}</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</v-table>
|
||||
</section>
|
||||
<section class=device-data>
|
||||
<h2>Data on this Device</h2>
|
||||
|
Reference in New Issue
Block a user