You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently, validateAuditPeriod throws an error if request does not contain year and half values. The reason why those unnecessaries is needed is querying AuditPeriod is based on given year and half.
According to requirement, however, it is enough to figure out the latest AuditPeriod to validate whether the request is overdue or not.
// validateAuditPeriod
1. filter audit period if its `start` date is lower than timestamp
2. filter audit period if its `end` date is bigger than timestamp
3. return true if audit period exists, else throw an ValidationError
The text was updated successfully, but these errors were encountered:
Currently,
validateAuditPeriod
throws an error ifrequest
does not containyear
andhalf
values. The reason why those unnecessaries is needed is queryingAuditPeriod
is based on given year and half.According to requirement, however, it is enough to figure out the latest
AuditPeriod
to validate whether the request is overdue or not.The text was updated successfully, but these errors were encountered: