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

Organization search seems not recognizing special characters #3581

Open
jarias-lfx opened this issue Aug 24, 2022 · 12 comments
Open

Organization search seems not recognizing special characters #3581

jarias-lfx opened this issue Aug 24, 2022 · 12 comments
Assignees
Labels
bug Something isn't working CommunityReported

Comments

@jarias-lfx
Copy link

Ticket: SUPPORT-12023
Organization: AT&T Services, Inc.
Project: All

Bug Summary:
When contributor from AT&T Services are trying to sign the CCLA, they are unable to find the Organization using AT&T keyword:
image

Seems other searches using at least the "&" character is not working like 1&1 Telecommunication:
image

The Organization appears doing a manual alphabetical search order:
image

Doing the same search in other tools like Organization Dashboard, works without issues:
image

Checked Companies table DB and saw nothing out of the ordinary for AT&T.
image

@jarias-lfx jarias-lfx added the bug Something isn't working label Aug 24, 2022
@mlehotskylf
Copy link
Contributor

@nickmango @jarias-lfx is this still an issue?

@jarias-lfx
Copy link
Author

This is still an issue:
image

@nickmango
Copy link
Contributor

@mlehotskylf Verified and this is a bug on the backend.. The search API is not handling special characters.

@mlehotskylf
Copy link
Contributor

@nickmango is working on the fix.

@nickmango
Copy link
Contributor

@amolsontakke3576 noted the frontend is not encoding the query param for the company name. Can you edit this on your end ?

@amolsontakke3576
Copy link
Contributor

@nickmango I have encoded it. Lets take the example at&t and FE encoded it to at%26t, you need to decode it from the backend.
API :
https://api.easycla.lfx.linuxfoundation.org/v3/organization/search?companyName=at%26t&include-signing-entity-name=false

@nickmango
Copy link
Contributor

nickmango commented Jun 6, 2024

Hello @amolsontakke3576 which endpont are you using for the search in this flow ?
On the backend the API is able to decode the encoded value with the v4/company/lookup endpoint
curl --location 'http://localhost:8080/v4/company/lookup/?companyName=AT%26T' returns the expected response { "Employees": "100K+", "ID": "0012M00002hEN7AQAW", "Industry": "Diversified Telecommunication Services", "Link": "att.com", "Name": "AT&T", "Sector": "Telecommunication Services", "Source": "External Data Source", "signingEntityNames": null }

@amolsontakke3576
Copy link
Contributor

@nickmango It is V3 endpoint
v3/organization/search?companyName=at%26t&include-signing-entity-name=false

nickmango added a commit to nickmango/easycla that referenced this issue Jun 6, 2024
- Updated regex for companyName search parameter to resolve missing special characters

Signed-off-by: Harold Wanyama <[email protected]>
nickmango added a commit that referenced this issue Jun 6, 2024
@nickmango
Copy link
Contributor

Thanks @amolsontakke3576 . I have updated the API for this usecase

@thakurveerendras
Copy link
Contributor

Tested with AT&T org and found that it is working fine.

image

@thakurveerendras
Copy link
Contributor

Tested with some more organization that contains special character & found that it is working fine, So updating this ticket status
image
image
image

@thakurveerendras
Copy link
Contributor

Verified on prod, it is working fine. So closing this ticket

image

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

No branches or pull requests

5 participants