Skip to content

Commit

Permalink
Merge pull request #865 from smart-village-solutions/feature/SVA-1059…
Browse files Browse the repository at this point in the history
…-show-alert-after-the-survey-is-answered

feat: show alert after the survey is answered
  • Loading branch information
ardasnturk authored Jul 12, 2023
2 parents 92d6da2 + 23c0005 commit 91938b1
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/config/texts.js
Original file line number Diff line number Diff line change
Expand Up @@ -933,6 +933,11 @@ export const texts = {
submitComment: {
de: 'Kommentar senden',
pl: 'Wyślij komentarz'
},
submitSuccess: {
entry:
'Mit Ihren Ideen und Rückmeldungen helfen Sie uns dabei, den Service der Gemeinde weiter zu verbessern.',
header: 'Vielen Dank für die Teilnahme an unserer Umfrage.'
}
},
tabBarLabel: {
Expand Down
2 changes: 2 additions & 0 deletions src/hooks/surveyHooks.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,8 @@ export const useAnswerSelection = (id?: string, refetch?: () => void) => {
variables: { decreaseId: previousSubmission, increaseId: selection }
});

Alert.alert(texts.survey.submitSuccess.header, texts.survey.submitSuccess.entry);

if (errors || data?.votesForSurvey?.statusCode !== 200) {
throw new Error();
}
Expand Down

0 comments on commit 91938b1

Please sign in to comment.