Zooflow: Improve Search Ribbon, Process Independent Search
This commit is contained in:
@@ -2,25 +2,25 @@
|
||||
Public Class SearchFilter
|
||||
|
||||
Public Shared Property DefaultFilters As New List(Of FilterTimeframe) From {
|
||||
New FilterTimeframe() With {.Name = "Kein", .DisableFilter = True, .[To] = Nothing},
|
||||
New FilterTimeframe() With {.Name = "Eigener", .CustomFilter = True, .[To] = Date.Now, .From = Date.Now},
|
||||
New FilterTimeframe() With {
|
||||
.Name = "letzte 7 Tage",
|
||||
.From = Date.Now.Subtract(TimeSpan.FromDays(7))
|
||||
},
|
||||
New FilterTimeframe() With {
|
||||
.Name = "letzte 14 Tage",
|
||||
.From = Date.Now.Subtract(TimeSpan.FromDays(14))
|
||||
},
|
||||
New FilterTimeframe() With {
|
||||
.Name = "letzte 30 Tage",
|
||||
.From = Date.Now.Subtract(TimeSpan.FromDays(30))
|
||||
},
|
||||
New FilterTimeframe() With {
|
||||
.Name = "aktueller Monat",
|
||||
.From = New Date(Now.Year, Now.Month, 1)
|
||||
New FilterTimeframe() With {.Name = "Kein", .DisableFilter = True, .[To] = Nothing},
|
||||
New FilterTimeframe() With {.Name = "Eigener", .CustomFilter = True, .[To] = Date.Now, .From = Date.Now},
|
||||
New FilterTimeframe() With {
|
||||
.Name = "letzte 7 Tage",
|
||||
.From = Date.Now.Subtract(TimeSpan.FromDays(7))
|
||||
},
|
||||
New FilterTimeframe() With {
|
||||
.Name = "letzte 14 Tage",
|
||||
.From = Date.Now.Subtract(TimeSpan.FromDays(14))
|
||||
},
|
||||
New FilterTimeframe() With {
|
||||
.Name = "letzte 30 Tage",
|
||||
.From = Date.Now.Subtract(TimeSpan.FromDays(30))
|
||||
},
|
||||
New FilterTimeframe() With {
|
||||
.Name = "aktueller Monat",
|
||||
.From = New Date(Now.Year, Now.Month, 1)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Public Class FilterTimeframe
|
||||
Public Property Name As String
|
||||
|
||||
@@ -1,25 +0,0 @@
|
||||
Namespace Search
|
||||
Public Class SearchToken
|
||||
|
||||
Public Class AttributeValueToken
|
||||
Public AttributeTitle As String
|
||||
Public AttributeId As Integer
|
||||
Public TermValue As String
|
||||
Public TermId As Integer
|
||||
|
||||
Public Overrides Function GetHashCode() As Integer
|
||||
Return (TermId.GetHashCode & AttributeId.GetHashCode).GetHashCode()
|
||||
End Function
|
||||
|
||||
Public Overrides Function Equals(obj As Object) As Boolean
|
||||
Return Me.GetHashCode() = DirectCast(obj, AttributeValueToken).GetHashCode()
|
||||
End Function
|
||||
|
||||
Public Overrides Function ToString() As String
|
||||
Return $"{TermValue} ({AttributeTitle})"
|
||||
End Function
|
||||
End Class
|
||||
|
||||
End Class
|
||||
|
||||
End Namespace
|
||||
Reference in New Issue
Block a user