Skip to content

Handle null values in dashboard #11529#11618

Merged
offtherailz merged 9 commits intogeosolutions-it:masterfrom
rowheat02:handleNullDashbaord
Oct 22, 2025
Merged

Handle null values in dashboard #11529#11618
offtherailz merged 9 commits intogeosolutions-it:masterfrom
rowheat02:handleNullDashbaord

Conversation

@rowheat02
Copy link
Copy Markdown
Contributor

@rowheat02 rowheat02 commented Oct 21, 2025

Description

Please check if the PR fulfills these requirements

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

  • Enhancement

fixes #11529

What is the current behavior?

#11529

  • Null values of Group by fields can not be filtered which is making the chart unreadable sometimes as it's value is being used to calculate the height of the chart

What is the new behavior?

  • The user can remove the null value of the group by field.
  • As Null values was not being rendered on chart by plotly so respective placeholder value for null on Group by field can be updated by the field type.
    • e.g: for string : "NULL" by default, user can also change it
    • for number placeholder value should be number
    • Similarly, for all data types, placeholder value is handled accordingly
    • image

Breaking change

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

  • Yes, and I documented them in migration notes
  • No

Other useful information

For test, types layer can be used from gs-stable for all type of data types.
image

@rowheat02 rowheat02 added this to the 2025.02.00 milestone Oct 21, 2025
@rowheat02 rowheat02 requested a review from offtherailz October 21, 2025 15:52
@rowheat02 rowheat02 marked this pull request as ready for review October 21, 2025 15:52
Copy link
Copy Markdown
Member

@offtherailz offtherailz left a comment

Choose a reason for hiding this comment

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

  • I see that the checkboxes in fact are mutually exclusive, so having checkbox can be redundant and misleading. I think it makes more sense to have a dedicated section at the bottom like this:
Null values handling

Group by attribute:   // or X 
| default      V | // dropdown
------------------
|- exclude       |
| - placeholder  |

If placeholder is selected, show the placeholder. If the scrolls hides for some reason, preserve some space, or make it simply disabled.

  • Instead of the variables excludeNullGroupByFieldValue, useNullPlaceholderForGroupByFieldValue etc... I'd use a more structured approach
"options": { 
    "nullHandling": {
          "groupByAttributes": {
              "strategy": "include"(default)|"exclude"|"placeholder", 
              "placeholder":  "NULL"
           }
       }
}

@rowheat02
Copy link
Copy Markdown
Contributor Author

image

As suggested, updated

  • UI
  • variable names
  • Help pop-up added
  • Tests updated and added

@rowheat02 rowheat02 requested a review from offtherailz October 22, 2025 14:34
@offtherailz offtherailz enabled auto-merge (squash) October 22, 2025 15:56
@offtherailz offtherailz merged commit 5a2d6f0 into geosolutions-it:master Oct 22, 2025
5 checks passed
rowheat02 added a commit to rowheat02/MapStore2 that referenced this pull request Oct 24, 2025
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.

Handle null values in dashboard

3 participants