Standardize toasts / validation - #625
Conversation
|
[diff-counting] Significant lines: 900. |
|
(I cherry-picked most commits from my original branch and added some extra changes in between, since some of that code got rid of desirable activity in the current iteration of Carriage, e.g. the instant notifications about time verification.) |
Add CULift requirements + lower arbitrary minimum ride length
|
|
||
| // Check weekends | ||
| if (start.day() === 0 || start.day() === 6 || end.day() === 0 || end.day() === 6) { | ||
| errors.push({ |
There was a problem hiding this comment.
This looks great!
I think CULift has different hours during breaks. I wonder if there is a way we can have admin change operating hours on their end and then we reflect it here? very small quality of life addition but it could be cool :)
There was a problem hiding this comment.
wait that's a great idea -- maybe i'll add that to jira as a future task? i feel like we should add a new view for that but push these changes since we want them fixed b4 january
Also add more descriptive error messages
Rides can't be scheduled with users whose end date has passed
Validate riders whose end date has passed
✅ Deploy Preview for carriage-web ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Summary
This pull request is the first step towards adding toast error/success messages consistently throughout Carriage.
Test Plan
Since most of this code is not breaking, I generally went through the codebase and general workflow of the app for each kind of user to test where toasts should show up.