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

[fix]:standard texts query #2753

Merged
merged 3 commits into from
Nov 13, 2023
Merged

[fix]:standard texts query #2753

merged 3 commits into from
Nov 13, 2023

Conversation

vdegraaf
Copy link
Contributor

Ticket: none

Fixes:

  • order of standard texts on incidentDetail and categoryDetail
  • return null when standard texts are undefined

Copy link
Contributor

@OscarBakker OscarBakker left a comment

Choose a reason for hiding this comment

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

just some small changes and you're good to go

@@ -47,6 +37,18 @@ const DefaultTextsContainer = ({
[status]
)

if (!defaultTexts) return null
Copy link
Contributor

Choose a reason for hiding this comment

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

why the second check on defaultTexts? 40 should be enough

@@ -40,7 +40,7 @@ export const StandardTextsField = ({ name, onChange }: Props) => {

useEffect(() => {
get(
`${configuration.STANDARD_TEXTS_ENDPOINT}?ordering=statusmessagecategory__position&category_id=10&category_id=${params.categoryId}`
`${configuration.STANDARD_TEXTS_ENDPOINT}?ordering=statusmessagecategory__position&category_id=${params.categoryId}`
Copy link
Contributor

Choose a reason for hiding this comment

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

😶‍🌫️

@vdegraaf vdegraaf merged commit a3568a1 into main Nov 13, 2023
7 checks passed
@vdegraaf vdegraaf deleted the fix/standard-texts-query branch November 13, 2023 13:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants