Skip to content

DAPP-2000: Change Support Page API#2001

Merged
rohitmalhotra1420 merged 2 commits intomainfrom
DAPP-2000-change-support-page-api
Jan 22, 2025
Merged

DAPP-2000: Change Support Page API#2001
rohitmalhotra1420 merged 2 commits intomainfrom
DAPP-2000-change-support-page-api

Conversation

@meKushdeepSingh
Copy link
Contributor

Updated the Support Page to use the new API endpoint.

@meKushdeepSingh meKushdeepSingh self-assigned this Jan 17, 2025
@meKushdeepSingh meKushdeepSingh linked an issue Jan 17, 2025 that may be closed by this pull request
@github-actions
Copy link

  1. It seems that the import statement for 'queries/baseURL' is incorrect because it should be './queries/baseURL' assuming it's a relative path.
  2. The import statement for 'queries/models' is correct assuming it's valid and the file exists.
  3. The definition of the sendSupportMessageType type looks correct.
  4. In the sendSupportMessage function, there is a reference to sendSupportMessageModelCreator function which is not defined in the provided code. Make sure it's imported from the correct location.
  5. The way the axios POST request is structured seems correct.
  6. The url for the axios request is constructed using the analyticsBaseURL from the 'baseURL' module.
  7. The headers object in the axios request is correctly set to specify the 'Content-Type' as 'application/json'.
  8. The response from the axios call is then used to call sendSupportMessageModelCreator function with response.data. Make sure this function exists and is correctly handling the data.

Overall, the code looks good assuming that the missing function sendSupportMessageModelCreator is correctly imported from the right location and defined.

@github-actions
Copy link

github-actions bot commented Jan 17, 2025

PR Preview Action v1.4.7
Preview removed because the pull request was closed.
2025-01-22 07:39 UTC

@github-actions
Copy link

In the Support component:

  1. It looks like the useSendSupportMessage hook is being used without being imported.
  2. In the handleContactFormSubmit function, the const { name, email, topic, subject, message } = supportFormik.values; should use const { name, email, topic, subject, message } = supportFormik.values; instead to destructure the values.
  3. In the Select component, the onSelect prop should be changed to onChange for consistency with other form fields.

In the file where the useSendSupportMessage hook is used:

  1. The import of pushsupportBaseURL is duplicated and inconsistent with the definition in the same file.
  2. The import of pushsupportBaseURL should be removed as it is not being used.

Overall, the code logic seems correct, but there are some minor issues and inconsistencies that need addressing.

Please make the necessary corrections and improvements.

@corlard3y corlard3y linked an issue Jan 20, 2025 that may be closed by this pull request
@rohitmalhotra1420 rohitmalhotra1420 merged commit 6941c8f into main Jan 22, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Change Support Page API 🐛 [BUG] - <Support section is not working on Website>

3 participants