mirror of
https://github.com/meshtastic/Meshtastic-Apple.git
synced 2026-04-20 22:13:56 +00:00
Add role to node details
This commit is contained in:
parent
179dec259b
commit
efa32c1acc
1 changed files with 13 additions and 0 deletions
|
|
@ -110,6 +110,19 @@ struct NodeDetail: View {
|
|||
}
|
||||
}
|
||||
|
||||
if let role = node.user?.role, let deviceRole = DeviceRoles(rawValue: Int(role)) {
|
||||
HStack {
|
||||
Label {
|
||||
Text("Role")
|
||||
} icon: {
|
||||
Image(systemName: deviceRole.systemName)
|
||||
.symbolRenderingMode(.multicolor)
|
||||
}
|
||||
Spacer()
|
||||
Text(deviceRole.name)
|
||||
}
|
||||
}
|
||||
|
||||
if let dm = node.telemetries?.filtered(using: NSPredicate(format: "metricsType == 0")).lastObject as? TelemetryEntity, dm.uptimeSeconds > 0 {
|
||||
HStack {
|
||||
Label {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue