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

PIMS-1871: Fuzzy search is returning properties already in other projects #2590

Merged
merged 9 commits into from
Aug 2, 2024

Conversation

LawrenceLau2020
Copy link
Collaborator

🎯 Summary

PIMS-1871:

Changes

  • Added a subquery to the fuzzy search to exclude properties that are already in projects.

🔰 Checklist

  • I have read and agree with the following checklist and am following the guidelines in our Code of Conduct document.
  • I have performed a self-review of my code.
  • I have commented my code, particularly in hard-to-understand areas.
  • I have made corresponding changes to the documentation where required.
  • I have tested my changes to the best of my ability.
  • My changes generate no new warnings.

Copy link

🚀 Deployment Information

The Express API Image has been built with the tag: 2590. Please make sure to utilize this specific tag when promoting these changes to the TEST and PROD environments during the API deployment. For more updates please monitor Image Tags Page on Wiki.

Copy link

codeclimate bot commented Jul 30, 2024

Code Climate has analyzed commit f2c5b0a and detected 0 issues on this pull request.

The test coverage on the diff in this pull request is 90.9% (50% is the threshold).

This pull request will bring the total coverage in the repository to 93.9%.

View more on Code Climate.

Copy link
Collaborator

@dbarkowsky dbarkowsky left a comment

Choose a reason for hiding this comment

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

The subquery is checking for cases where the property belongs to any project, but are users allowed to add properties to projects if they were previously part of a cancelled project? Would be nice if there was a way to do that.

@LawrenceLau2020
Copy link
Collaborator Author

LawrenceLau2020 commented Aug 1, 2024

I've added a couple sub queries for both the parcelsQuery and the buildingsQuery to try to include properties that don't belong to any projects as well as belonging to "Cancelled" projects. Could use a second pair of eyes right now, try searching for a building that doesn't belong to any project, I think the query includes the building, but it isn't showing up because the query might not be ordering the results correctly.

The parcel query needs testing as well and possible refactoring, as I was just trying to get the buildingsQuery to work properly first.

@LawrenceLau2020 LawrenceLau2020 merged commit f37b7a9 into main Aug 2, 2024
9 checks passed
@LawrenceLau2020 LawrenceLau2020 deleted the PIMS-1871 branch August 2, 2024 18:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants