mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-09-22 00:20:47 +02:00
🐛 Improve date filter
This commit is contained in:
parent
2f01f3224d
commit
bb989bcb35
1 changed files with 2 additions and 2 deletions
|
@ -632,13 +632,13 @@ func filterRelativeTime(valueMills int64, valueIsNotEmpty bool, operator FilterO
|
||||||
case FilterOperatorIsNotEqual:
|
case FilterOperatorIsNotEqual:
|
||||||
return valueTime.Before(otherValueStart) || valueTime.After(otherValueEnd)
|
return valueTime.Before(otherValueStart) || valueTime.After(otherValueEnd)
|
||||||
case FilterOperatorIsGreater:
|
case FilterOperatorIsGreater:
|
||||||
return valueTime.After(otherValueEnd) || valueTime.Equal(otherValueEnd)
|
return valueTime.After(otherValueStart)
|
||||||
case FilterOperatorIsGreaterOrEqual:
|
case FilterOperatorIsGreaterOrEqual:
|
||||||
return valueTime.After(otherValueStart) || valueTime.Equal(otherValueStart)
|
return valueTime.After(otherValueStart) || valueTime.Equal(otherValueStart)
|
||||||
case FilterOperatorIsLess:
|
case FilterOperatorIsLess:
|
||||||
return valueTime.Before(otherValueStart)
|
return valueTime.Before(otherValueStart)
|
||||||
case FilterOperatorIsLessOrEqual:
|
case FilterOperatorIsLessOrEqual:
|
||||||
return valueTime.Before(otherValueEnd) || valueTime.Equal(otherValueEnd)
|
return valueTime.Before(otherValueStart) || valueTime.Equal(otherValueStart)
|
||||||
case FilterOperatorIsBetween:
|
case FilterOperatorIsBetween:
|
||||||
if RelativeDateDirectionBefore == direction {
|
if RelativeDateDirectionBefore == direction {
|
||||||
if RelativeDateDirectionBefore == direction2 {
|
if RelativeDateDirectionBefore == direction2 {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue