Bugfix
This commit is contained in:
parent
1563754c2a
commit
75913e8da4
|
@ -48,13 +48,12 @@ const User = {
|
||||||
)
|
)
|
||||||
return []
|
return []
|
||||||
|
|
||||||
return prisma.user
|
return prisma.wifiDevice.findMany({
|
||||||
.findUnique({
|
where: {
|
||||||
where: {
|
accessPointId: { not: null },
|
||||||
sAMAccountName: parent.sAMAccountName
|
user: { id: parent.id }
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
.wifiDevices()
|
|
||||||
},
|
},
|
||||||
|
|
||||||
campus: parent => {
|
campus: parent => {
|
||||||
|
|
|
@ -13,10 +13,10 @@
|
||||||
calculate-widths
|
calculate-widths
|
||||||
>
|
>
|
||||||
<template #[`item.status`]="{ item }">
|
<template #[`item.status`]="{ item }">
|
||||||
<v-chip v-if="item.status == 'ONLINE'" color="green" dark small>
|
<v-chip v-if="item.status == 'ONLINE'" color="green" dark x-small>
|
||||||
Online
|
Online
|
||||||
</v-chip>
|
</v-chip>
|
||||||
<v-chip v-else color="grey" small dark>Offline</v-chip>
|
<v-chip v-else color="grey" dark x-small>Offline</v-chip>
|
||||||
</template>
|
</template>
|
||||||
<template #[`item.ip`]="{ item }">
|
<template #[`item.ip`]="{ item }">
|
||||||
<code> {{ item.ip }}</code>
|
<code> {{ item.ip }}</code>
|
||||||
|
@ -40,6 +40,9 @@
|
||||||
>
|
>
|
||||||
{{ item.apName }}
|
{{ item.apName }}
|
||||||
</router-link>
|
</router-link>
|
||||||
|
<span v-if="item.accessPoint.local">
|
||||||
|
({{ item.accessPoint.local }})
|
||||||
|
</span>
|
||||||
</template>
|
</template>
|
||||||
<template #[`item.uptime`]="{ item }">
|
<template #[`item.uptime`]="{ item }">
|
||||||
<span v-if="item.uptime > 0">
|
<span v-if="item.uptime > 0">
|
||||||
|
@ -49,21 +52,12 @@
|
||||||
</span>
|
</span>
|
||||||
<span v-else><small> Off-line </small> </span>
|
<span v-else><small> Off-line </small> </span>
|
||||||
</template>
|
</template>
|
||||||
<template #[`item.controller`]="{ item }">
|
|
||||||
<ApIcon :controller="item.controller" />
|
|
||||||
</template>
|
|
||||||
<template #[`item.local`]="{ item }">
|
|
||||||
{{ item.accessPoint.local }}
|
|
||||||
</template>
|
|
||||||
</v-data-table>
|
</v-data-table>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import ApIcon from '@/components/ApIcon.vue'
|
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
components: { ApIcon },
|
|
||||||
props: {
|
props: {
|
||||||
wifiDevices: {
|
wifiDevices: {
|
||||||
type: Array,
|
type: Array,
|
||||||
|
@ -78,13 +72,11 @@ export default {
|
||||||
{ text: 'MAC', value: 'mac' },
|
{ text: 'MAC', value: 'mac' },
|
||||||
{ text: 'Status', value: 'status' },
|
{ text: 'Status', value: 'status' },
|
||||||
{ text: 'ESSID', value: 'essid' },
|
{ text: 'ESSID', value: 'essid' },
|
||||||
{ text: 'Controladora', value: 'controller' },
|
|
||||||
{ text: 'Uptime', value: 'uptime' },
|
{ text: 'Uptime', value: 'uptime' },
|
||||||
{ text: 'Marca', value: 'oui' },
|
{ text: 'Marca', value: 'oui' },
|
||||||
{ text: 'Primeira aparição', value: 'firstSeen' },
|
{ text: 'Primeira aparição', value: 'firstSeen' },
|
||||||
{ text: 'Última aparição', value: 'lastSeen' },
|
{ text: 'Última aparição', value: 'lastSeen' },
|
||||||
{ text: 'AccessPoint', value: 'apName' },
|
{ text: 'AccessPoint', value: 'apName' }
|
||||||
{ text: 'Local', value: 'local' }
|
|
||||||
]
|
]
|
||||||
}),
|
}),
|
||||||
computed: {
|
computed: {
|
||||||
|
|
|
@ -91,7 +91,6 @@
|
||||||
</v-expansion-panel-header>
|
</v-expansion-panel-header>
|
||||||
<v-expansion-panel-content>
|
<v-expansion-panel-content>
|
||||||
<v-expansion-panels accordion>
|
<v-expansion-panels accordion>
|
||||||
<v-divider />
|
|
||||||
<wifi-devices-table :wifi-devices="user.wifiDevices" />
|
<wifi-devices-table :wifi-devices="user.wifiDevices" />
|
||||||
</v-expansion-panels>
|
</v-expansion-panels>
|
||||||
</v-expansion-panel-content>
|
</v-expansion-panel-content>
|
||||||
|
|
Loading…
Reference in New Issue
Block a user