Skip to content
This repository has been archived by the owner on Jan 9, 2023. It is now read-only.

feat: added successful alert when adding new appointments #1897

Merged

Conversation

sotous
Copy link
Contributor

@sotous sotous commented Mar 12, 2020

Added successful alert when adding new appointments. Replicated successful alert from new patients process and added the successful property on the translation file.

Fixes #1894

Changes proposed in this pull request:

  • Added a property to the index.ts which belongs to enUs translations for scheduling, in order to display correctly the successful message.
  • Modified NewAppointment.tsx file. The function onNewAppointmentSaveSuccess, was modified by adding a toast to it after the history.push process ends successfully.

**There were not new dependencies added.

Added successful alert when adding new appointments. Replicated successful alert from new patients
process and added the successful property on the translation file

re HospitalRun#1894
@jsf-clabot
Copy link

jsf-clabot commented Mar 12, 2020

CLA assistant check
All committers have signed the CLA.

@vercel
Copy link

vercel bot commented Mar 12, 2020

This pull request is being automatically deployed with ZEIT Now (learn more).
To see the status of your deployment, click below or on the icon next to each commit.

🔍 Inspect: https://zeit.co/hospitalrun/hospitalrun-frontend/3n3bkozto
✅ Preview: https://hospitalrun-fr-git-fork-sotous-feature-success-message-n-425c1f.hospitalrun.now.sh

Comment on lines +45 to +49
Toast(
'success',
t('Success!'),
`${t('scheduling.appointment.successfullyCreated')} ${newAppointment.id}`,
)
Copy link
Member

Choose a reason for hiding this comment

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

Could we add a test to make sure that the toast is getting called and has the proper message?

@matteovivona matteovivona added the in progress indicates that issue/pull request is currently being worked on label Mar 14, 2020
@matteovivona matteovivona added this to In progress in Version 2.0 via automation Mar 14, 2020
@matteovivona matteovivona added this to the v2.0 milestone Mar 14, 2020
@vercel vercel bot temporarily deployed to Preview March 14, 2020 10:38 Inactive
…into feature/success-message-new-appointment
Added test for toast when a new appointment is created successfully

re HospitalRun#1894
…sotous/hospitalrun-frontend into feature/success-message-new-appointment
@jackcmeyer jackcmeyer merged commit 9e51fdf into HospitalRun:master Mar 18, 2020
Version 2.0 automation moved this from In progress to Done Mar 18, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
in progress indicates that issue/pull request is currently being worked on
Projects
Version 2.0
  
Done
Development

Successfully merging this pull request may close these issues.

Success alert when new appointment is created
4 participants