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

Parameter-Select autocomplete doesn't find correct value; expected value is substring of autofill-results #163

Closed
jsuesse opened this issue Jul 11, 2022 · 2 comments
Labels
bug Something isn't working

Comments

@jsuesse
Copy link
Contributor

jsuesse commented Jul 11, 2022

Setup

  • NeoDash version: 2.1.2
  • Neo4j Database version: 4.4.8 (Community.

Somewhat related issues:

#50 was fixed by allowing manual editing of property-name
This could be solved by allowing manual entering of property-value

Steps to reproduce

  • use a parameter-select card
  • set label and property
  • Want to select a string e.g. zoo
  • a node with exact match where node.property="zoo" exists!

Expected behavior

results show exact match first, it can be selected.

Actual behavior

  • results that contain that substring, but come before it in the alphabet are shown first.
  • zoo can't be selected
    results:
alabama_zoo
best_zoo
example_zoo
fantastic_zoo
great_zoo

See image: Blue-Boxes are the same string
image

It seems that the results are determined by checking if string contains substring, then sorting these results.
Instead, exact matches should appear first in list.

Workaround

Use Free-Text-Select. Selection of any value is possible there.

Thanks for considering. Have a great day!

@jsuesse jsuesse added the bug Something isn't working label Jul 11, 2022
@jsuesse
Copy link
Contributor Author

jsuesse commented Jul 13, 2022

Propose fix:

In /src/card/settings/custom/CardSettingsContentPropertySelect.tsx insert ORDER BY size(value) ASC into line 95 and line 98.

example for line 95:
change from

const newQuery = "MATCH (n:`" + entityType + "`) \nWHERE toLower(toString(n.`" + propertyType + "`)) CONTAINS toLower($input) \nRETURN DISTINCT n.`" + propertyType + "` as value LIMIT 5";

to

const newQuery = "MATCH (n:`" + entityType + "`) \nWHERE toLower(toString(n.`" + propertyType + "`)) CONTAINS toLower($input) \nRETURN DISTINCT n.`" + propertyType + "` as value ORDER BY size(value) ASC LIMIT 5";

Might create a proper PR when I find time.

jsuesse added a commit to jsuesse/neodash that referenced this issue Jul 29, 2022
nielsdejong added a commit that referenced this issue Aug 3, 2022
* sort parameter-select results by size ASC

Related to #163

* Make change more explicit by adding "ASC"

* Casting values to string so that we can always sort by size

Co-authored-by: Niels de Jong <[email protected]>
nielsdejong added a commit that referenced this issue Aug 4, 2022
* Added documentation portal in new and improved ASCIIdoc format (#156)

* Created new documentation structure

* Renamed navigation adoc fiel

* Restructuring of documentation

* Updated page structure

* Added README for documentation directory, code to run docs locally

* Restructring and cleaning up docs

* Updated links and images in documentation portal

* Renamed quickstart

* Renamed quickstart in docs folder

* Add bg color (#158)

* Add bg color

* Added some minor robustness to report background color, updated docs

Co-authored-by: Vitor Horta <[email protected]>
Co-authored-by: Niels de Jong <[email protected]>

* Temporarily disabled flaky Cypress test (#161)

* Added handling of share URL without password + better date handling for line charts  (#162)

* Added handling of special case where no password is provided in the share URL

* Improved handling of date/datetime types for line charts

* Feature/resize more visible (#170)

* Stability fixes for 2.0.11

* Added prototype SSO implementation

* Changed dockerfile usage from ENV to ARG (#93)

* Stability fixes for 2.0.11 (#76)

Fix for rendering dictionaries in tables/single value charts.
Added resize handler for fullscreen map views.
Added missing auto-run config to pie charts.
Fixed broken value scale parameter for bar charts.

* Changed dockerfile usage from ENV to ARG

Also using CMD as opposed to ENTRYPOINT

* Updated supporting docker scripts

* Renamed docker run scripts, deleted docker-build.bash

* Changed dockerfile usage from ENV to ARG

Also using CMD as opposed to ENTRYPOINT

* Updated supporting docker scripts

* Renamed docker run scripts, deleted docker-build.bash

* Updated README to match new Docker image setup

Co-authored-by: Niels de Jong <[email protected]>
Co-authored-by: Tobias <[email protected]>

* Added color selector component. Clean up/refactoring of file names

* Tweaking of color picker for advanced settings, added framework for rule-based styling of reports

* Clean up, refactoring of project structure

* Added version number to Dockerfile

* Moved version number in docker file to before RUN command

* Added some more comments to the docker scripts

* Restructured scripts and docker file locations, added conf.d

* Added conf.d directory

* Updated version number and Dockerfile references

* updated path to conf.d

* Updated version number in dockerfile

* First version of rule-based styling is completed

* Fixed handling of nginx configuration file (#98)

* Remedied errors in handling of nginx configs

* Adjusted copy of default.conf

Co-authored-by: Tobias Krøgholt <[email protected]>

* Update Dockerfile

* Update Dockerfile

* Improved handling of null values in tables

* Added support for custom style rules to relevant report types

* Removed standalone password from default configuration

* Fixed default styling for config.json

* Updated release notes, readme and docker push script for 2.0.12

* Updated description of component hierarchy

* Set dockerfile to pull from master by default

* Changed docker startup script to contain a message for the user

* Updated dockerfile startup message

* Fixed startup message in Dockerfile

* Corrected null check for table rendering

* Better null handling for rule based evaluation in tables

* Cleanup of code documentation

* Updated documentation

* Clean up of comments

* Work in progress on drag-and-drop dashboards/pages

* Styling fixes for resizable layout

* Styling for drag-and-drop pages/reports. Bumped version to 2.1

* Fixed icon for card settings

* WIP on the drag-and-drop dashboard header

* WIP on drag-and-drop page reordering

* Added support for loading dashboards from a relative URL in standalone mode

* Hotfix for broken demo dashboard

* Refactoring dashboard header code

* Controlled drag-and-drop state for dashboards

* Drag-and-drop layout for pages with dynamic add-card placement

* Tweaking style for the new resizable reports

* Bump to 2.0.15. Added option to replace dashboard parameters in Markdown and iFrame strings

* added html to image to lib

* Tweaking the resizeable report/page view

* W.I.P. on downloading reports/dashboard as image

* Style tweaks

* Added button to download entire dashboard as an image

* Updated release notes for 2.0.15

* Dockerfile - Configuration through env variables at runtime (#125)

* Configuration throug env variables

- Env variables can now be used to define the contents of config.json (when the container starts)
- Added tips for setting up single sign on

* Cleanup of Dockerfile and README

* Removed temporary files

* Bumped version number

Co-authored-by: Håkan Löfqvist <[email protected]>

* Updated release notes

* Updated README on Docker deployments

* Add bar chart report ; add catch for when a dashboard is cached

* Finish rebasing from 2.0.15

* Added pie chart report and generalized report testing

* Added auto-position of add card button

* Added dashboard upgrading from 2.0 --> 2.1

* Clean up. Added help modal for reports

* Added Hierarchical Charts (#124)

* Added extra option (standalone dashboard by URL to build config

* WIP on dockerfile

* Reverted back to old Docker config

* Fixed import for react-color-picker, clean up Dockerfile

* Updated material-ui-color-picker dependency

* Report updates base on global params

Disable refresh when a global parameter is changed that is not used in the report

* Update CardView.tsx

Removing extra logs

* Hierarchical  Charts

Hierarchical  Charts Added
Pie Chart Options added
Pie Chart Percentage Default true

* Added extra option (standalone dashboard by URL to build config

* WIP on dockerfile

* Reverted back to old Docker config

* Fixed import for react-color-picker, clean up Dockerfile

* Updated material-ui-color-picker dependency

* Update CardView.tsx

Removing extra logs

* Hierarchical  Charts

Hierarchical  Charts Added
Pie Chart Options added
Pie Chart Percentage Default true

* Added extra option (standalone dashboard by URL to build config

* Merge

* Reverted back to old Docker config

* Merge

* Updated material-ui-color-picker dependency

* Added missing line in Dockerfile

* Icon + quick fix

Fixes base on comments

* Added comments to describe functionality

* Fixed comments on PR review for hierarchy reports

* Updated Dockerfile and package.json

* Removed console.log

Co-authored-by: Niels de Jong <[email protected]>

* Fixed button style of reset for hierarchy reports

* Removed legacy docker scripts

* Removed temporary logging

* Removed editable button for non-editable cards

* Clean up of card settings

* Fixed bug where code-editor will duplicate text

* Added auto upgrade of cached dashboard version

* added new query + 3 new testcases

* added a few more tests and also some code to make testing easier

* Fixed bug where the code editor didn't update internal state after pasting

* Update README.md

* Update README.md

* Update README.md

* Finalized cypress tests

* testing GH actions

* testing GH actions

* Removed CD experiment

* Fixed upload S3 script - revert

* Added CD config

* Fixed case-sensentive import error

* Docs and Small Fixes

Docs on hierarchical reports.
Fix on restart button
Fix on lodash names

* Fixed description text for hierarhical charts examples

* added small change to run test in the background

* added githhub action for cypress

* syntax changes

* small modification 2.0

* wait-on mod

* renamed the deploy to develop and  created a master with docker

* small master docker test on dev

* docker-ready

* syntax fix

* deleted develop for test purpose

* syntax fix

* syntax fix final

* added dependency between different jobs

* Fixed typos in in-app docs

* removed 2 files + test to publish npm

* mod

* made changes

* added npm install

* modified stuff

* take 345

* take 346

* take 347

* take 348

* take 349

* take 350

* take 351

* take 351

* added develop-deployment.yml and new stuff(still master pulls develop) + removed publish-package-npm.bash

* Tweaked workaround for paste+replace bug in codemirror

* Fixed bug where iFrame URL does not get replaced by parameters if it's the only text in the page. Fixed bug where minimizing card settings results in a glitched page layout

* Changed the 'save as image' library

* Added google site tracker

* Code cleanup, added comments

* Downgraded mui data grid

* Downgrade mui datagrid

* Removed video generation from .cypress.json, fixed workflows, reverted index.html

* Updated workflows

* Fix bug where neodash will ask you to clear a dashboard when none exists

* Fixed bug where editing the vertical alignment of a single value caused the number to clip

* Added placeholder for docs

* Updated cypress test to work better on GitHub test VM's. Added placeholder for new adocs

* Added warning handler for Cypress

* Removed it.only from Cypress IT

* Fixed cypress test to reflect new cached dashboard changes

* Updated GitHub workflows, added small wait after entering URL to allow for Redux cache sync

* Added publish to npm step. Removed debug settings.

* Fixed error in workflow definition

* Added changelog, release-notes, final fixes to CI/CD pipeline, style fix for parameter selectors

* Fixed release notes

* Final tweaks to workflows & changelog

* Updated cypress stress test to wait for loading the stress dashboards

* Fixed flaky test in Cypress stress test

* Feature/rebase 2.1 master (#139)

* 2.1 Release (#131)

## NeoDash 2.1
The 2.1 release is a major update to the NeoDash application.

Main updates:
- Added new drag-and-drop dashboard layout - reports can be **moved** and **resized** freely within the dashboard.
- Updated dashboard file format for new layout (2.0 dashboards are automatically migrated).
- Pages can now be reordered by dragging and dropping. 
- Added three new hierarchical report types:
  - Treemaps
  - Sunburst Charts
  - Circle Packing Charts
- Styling/usability improvements for pie charts.
- Improved image download (screenshot functionality) for all report types.
- Parameter select reports now resize the selector to fit the available space.

Other changes:
- Added continuous integration and deployment workflows.
- Created a new [User Guide](https://github.com/nielsdejong/neodash/wiki/User-Guide) with documentation on all report customizations is available.
- Added a new [Developer Guide](https://github.com/nielsdejong/neodash/wiki/Developer-Guide) with info on installing, building and extending the application.

* Bumped version new to fix npm signature

* Fixed npm publish command in workflow

* Reverse Pull-Request to sync develop with master (#141)

* 2.1 Release (#131)

## NeoDash 2.1
The 2.1 release is a major update to the NeoDash application.

Main updates:
- Added new drag-and-drop dashboard layout - reports can be **moved** and **resized** freely within the dashboard.
- Updated dashboard file format for new layout (2.0 dashboards are automatically migrated).
- Pages can now be reordered by dragging and dropping. 
- Added three new hierarchical report types:
  - Treemaps
  - Sunburst Charts
  - Circle Packing Charts
- Styling/usability improvements for pie charts.
- Improved image download (screenshot functionality) for all report types.
- Parameter select reports now resize the selector to fit the available space.

Other changes:
- Added continuous integration and deployment workflows.
- Created a new [User Guide](https://github.com/nielsdejong/neodash/wiki/User-Guide) with documentation on all report customizations is available.
- Added a new [Developer Guide](https://github.com/nielsdejong/neodash/wiki/Developer-Guide) with info on installing, building and extending the application.

* 2.1.1 - npm signature hotfix (#140)

Hotfix for npm signature signing

* Added different npm registry syntax

* Fixed Docker version number in deploy scripts

* Reverse PR (#143)

* 2.1.1 - npm signature hotfix (#140)

Hotfix for npm signature signing

* Added different npm registry syntax

* Added step in workflow for injecting the deployment HTML file into the npm published package (#147)

* Added GitHub issue templates (#145)

* Added issue templates

* Fixed issue template directory

* Converted Wiki Docs to ASCII-doc, updating README (#146)

* Converting docs to adoc

* Renamed adoc files

* Updated README. Updated Home page of the adocs to match labs standard

* Added tags

* Added screenshot

* Fixed adoc spacing

* Fixed styling on adoc files

* Final adjustments to ASCIIdoc migration of the Wiki

* Feature/add clone button to report (#150)

* added a skeleton for the clone button feature
* removed a comment
* removed stuff and also added a new icon
* Minor performance improvements on report cloning

Co-authored-by: aleksandarneo4j <[email protected]>
Co-authored-by: Bennu <[email protected]>
Co-authored-by: Niels de Jong <[email protected]>

* Fix on Hierarchical Charts (#151)

* Renamed some variables
* Renamed helper function

Co-authored-by: Niels de Jong <[email protected]>

* Several bug fixes for 2.1.2 (#148)

* Made resize button more visible. Added docker environment variables for standaloneUsername and standalonePassword. Fixed width of card title headers for standalone mode. Fixed rendering issue for nullable columns in tables

* Removed deprecated string parameters

* Changed grid compaction type from horizontal to vertical

* Bumped version number. Changed all GitHub references to new organization

* Updated release notes

* Re-enabled all IT tests

* fixed the reszie issue + returned card to how it was before my chnages

* Deleted old docs

* removed old stuff not needed

* Minor fixes based on PR review

Co-authored-by: Niels de Jong <[email protected]>
Co-authored-by: Tkrogholt <[email protected]>
Co-authored-by: Tobias <[email protected]>
Co-authored-by: Håkan Löfqvist <[email protected]>
Co-authored-by: Marius Conjeaud <[email protected]>
Co-authored-by: BennuFire <[email protected]>
Co-authored-by: aleksandarneo4j <[email protected]>
Co-authored-by: MariusC <[email protected]>

* Extend map chart functionality (#171)

* Initial try to integrate heatmap leaflet

* Add heatmap as a layer setting to the map chart

* Allow user to pick intensity property

* Add cluster markers to map

* Update map docs

* Added exclusion criteria for source-map-loader to avoid errors

* Removed testing files, added minor changes to docs, config and map chart

* Updated docs with new default value for heatmap markers

Co-authored-by: Marius Conjeaud <[email protected]>
Co-authored-by: Niels de Jong <[email protected]>

* Update pages.adoc (#180)

Decapitalize link location.

* Update faq.adoc (#179)

* Update faq.adoc

Decapitalize link location.

* Update faq.adoc

Co-authored-by: Niels de Jong <[email protected]>

* Update quickstart.adoc (#178)

Decapitalize link location.

* Update standalone-mode.adoc (#177)

Decapitalize link locations.

* Update index.adoc (#176)

Decapitalize link locations.

* Update configuration.adoc (#175)

Decapitalize link location.

* node property parameter-select: order results by size ASC (#173)

* sort parameter-select results by size ASC

Related to #163

* Make change more explicit by adding "ASC"

* Casting values to string so that we can always sort by size

Co-authored-by: Niels de Jong <[email protected]>

* Fix docs links, added release notes (#182)

* Bumping version

* Updated references to new documentation portal

* Fixed some more broken links. Added 2.1.3 release notes

* Small fixes to release notes

* Feature/choro (#174)

* Choropleth First Draft

* Debounce param selection

* Debounce param selection

* Debounce param selection
Choro Impl
Choro Docs

* Extra Params logic Refined
FIxes based on Review

* Feature from url

* Colors
Fix on boolean settings

* Good bye ma lover

* HotFix Selector

* Fixing some parameter names, styling

Co-authored-by: Niels de Jong <[email protected]>

Co-authored-by: Vitor Horta <[email protected]>
Co-authored-by: Vitor Horta <[email protected]>
Co-authored-by: Aleksandar <[email protected]>
Co-authored-by: Tkrogholt <[email protected]>
Co-authored-by: Tobias <[email protected]>
Co-authored-by: Håkan Löfqvist <[email protected]>
Co-authored-by: Marius Conjeaud <[email protected]>
Co-authored-by: BennuFire <[email protected]>
Co-authored-by: aleksandarneo4j <[email protected]>
Co-authored-by: MariusC <[email protected]>
Co-authored-by: SMFulton3-Neo4j <[email protected]>
Co-authored-by: Jonathan <[email protected]>
@BennuFire
Copy link
Collaborator

Closing due to merge on Aug 4.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants