Add connections dashboard

This commit is contained in:
世界
2024-10-06 21:41:07 +08:00
parent c223f50ffb
commit 9dadf5f648
17 changed files with 670 additions and 25 deletions
+3 -3
View File
@@ -1,9 +1,9 @@
import Foundation
public extension Profile {
var lastUpdatedString: String {
public extension Date {
var myFormat: String {
let dateFormatter = DateFormatter()
dateFormatter.dateFormat = "yyyy-MM-dd HH:mm:ss"
return dateFormatter.string(from: lastUpdated!)
return dateFormatter.string(from: self)
}
}
+5
View File
@@ -68,6 +68,11 @@ public enum SharedPreferences {
await excludeAPNsRoute.set(nil)
}
// Connections Filter
public static let connectionStateFilter = Preference<Int>("connection_state_filter", defaultValue: 0)
public static let connectionSort = Preference<Int>("connection_sort", defaultValue: 0)
// On Demand Rules
public static let alwaysOn = Preference<Bool>("always_on", defaultValue: false)