Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

#9325 enhancement: support for 'isNull' logical operator on date field in layer filter #9423

Merged
merged 4 commits into from
Sep 12, 2023

Conversation

mahmoudadel54
Copy link
Contributor

Description

It is an enhancement feature added to filter layer from attribute table. Add 'isNull' operator to date field to filter attribute table based on it.

Please check if the PR fulfills these requirements

What kind of change does this PR introduce? (check one with "x", remove the others)

  • [s] Feature

Issue

#9325
What is the current behavior?
There was no operator for 'isNull' for date field
#9325

What is the new behavior?
'isNull' operator is added to the filter layer for date field.

Breaking change

Does this PR introduce a breaking change? (check one with "x", remove the other)

  • No

Other useful information

@mahmoudadel54 mahmoudadel54 added this to the 2023.02.01 milestone Sep 11, 2023
@mahmoudadel54 mahmoudadel54 self-assigned this Sep 11, 2023
@tdipisa tdipisa added the BackportNeeded Commits provided for an issue need to be backported to the milestone's stable branch label Sep 11, 2023
@mahmoudadel54 mahmoudadel54 linked an issue Sep 11, 2023 that may be closed by this pull request
6 tasks
Copy link
Contributor

@allyoucanmap allyoucanmap left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The implementation is good, just few changes to apply:

  • use disabled prop instead of this.props.operator === "isNull" ? '' : to keep it consistent with string field
  • fix failing test

About the disabled prop,
current implementation:
image

expected:
2023-09-12 09_54_38-Window

Note: both UTCDateTimePicker and NumberPicker support disabled prop that could be applied as follow disabled={this.props.operator === "isNull"}

Copy link
Contributor

@allyoucanmap allyoucanmap left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@allyoucanmap allyoucanmap merged commit e79919e into geosolutions-it:master Sep 12, 2023
6 checks passed
@allyoucanmap
Copy link
Contributor

@ElenaGallo please test this in dev and let us know if we can backport on 2023.02.xx, thanks.
Note: this also introduces isNull operator for numbers, dates, date-time and time

@ElenaGallo
Copy link
Contributor

Test passed, @mahmoudadel54 please backport this to 2023.02.xx.Thanks

mahmoudadel54 added a commit to mahmoudadel54/MapStore2 that referenced this pull request Oct 9, 2023
@tdipisa tdipisa removed the BackportNeeded Commits provided for an issue need to be backported to the milestone's stable branch label Oct 9, 2023
tdipisa pushed a commit that referenced this pull request Oct 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support for isNull logical operator on date field in layer filter
4 participants