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
Prevent bookings with same start / stop time #3304
Prevent bookings with same start / stop time #3304
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank @Wolfimschafspelz 👍
We need to add some missing translations, so they show up in Weblate for the translation to all other languages.
In validators.en.xlf
the key Duration cannot be zero.
with the same translations.
And your username suggests that you can add the German translations for the two new messages 😄 ?!?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey, after giving another thought, I'd like to see two more changes:
- replace "Length" with "Duration" in all places
- add a unit test for the validator
Edit: the last fixes were exactly what I had in mind, thank you 👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are some other issues in existing tests, due to the added configuration. I can solve them later on, if you don't find the solution.
tests/Validator/Constraints/TimesheetZeroDurationValidatorTest.php
Outdated
Show resolved
Hide resolved
tests/Validator/Constraints/TimesheetZeroDurationValidatorTest.php
Outdated
Show resolved
Hide resolved
tests/Validator/Constraints/TimesheetZeroDurationValidatorTest.php
Outdated
Show resolved
Hide resolved
Please run |
Codecov Report
@@ Coverage Diff @@
## master #3304 +/- ##
============================================
+ Coverage 91.96% 91.99% +0.03%
- Complexity 7723 7732 +9
============================================
Files 736 738 +2
Lines 23312 23338 +26
============================================
+ Hits 21438 21470 +32
+ Misses 1874 1868 -6
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me 👍
Thank you @Wolfimschafspelz for being patient 😄
Description
Types of changes
Checklist
composer code-check
)