Blame view
src/components/widgets/list/PlainTable.vue
1.89 KB
93a68cfa1
|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 |
<template> <v-card> <v-toolbar card dense color="transparent"> <v-toolbar-title><h4>Project</h4></v-toolbar-title> <v-spacer></v-spacer> <v-btn icon> <v-icon>more_vert</v-icon> </v-btn> </v-toolbar> <v-divider></v-divider> <v-card-text class="pa-0"> <template> <v-data-table :headers="headers" :items="projects" hide-actions class="elevation-0" > <template slot="items" slot-scope="props"> <td> <v-avatar size="36px"> <img :src="props.item.avatar" :alt="props.item.username" /> </v-avatar> </td> <td>{{ props.item.name }}</td> <td class="text-xs-left">{{ props.item.deadline }}</td> <td class="text-xs-left"><v-progress-linear :value="props.item.progress" height="5" :color="props.item.color"></v-progress-linear> </td> <td class="text-xs-right"> <v-btn flat icon color="grey"> <v-icon>edit</v-icon> </v-btn> <v-btn flat icon color="grey"> <v-icon>delete</v-icon> </v-btn> </td> </template> </v-data-table> </template> <v-divider></v-divider> </v-card-text> </v-card> </template> <script> import { Projects } from '@/api/project'; export default { data () { return { headers: [ { text: '', align: 'center', sortable: false, value: 'avatar' }, { text: 'Name', align: 'left', value: 'name' }, { text: 'Deadline', value: 'deadline' }, { text: 'Progress', value: 'progress' }, { text: 'Action', value: 'action', align: 'right' }, ], }; }, computed: { projects () { return Projects; } } }; </script> |