fix: offer the questionnaire after every placement, the bus part to escorts
This commit is contained in:
1 parent
9fedc5b5d3
commit
2f4f9800dd
30 files changed
+311
-77
No files matched your search
@@ -118,8 +118,10 @@ class DispositionVoter extends Voter
|
||||
|
||||
/**
|
||||
* Whether the teamer may fill in, and later read, the questionnaire after this placement
|
||||
* (config/questionnaires/teamer_escort.yaml). Only the teamer themself: the office reads the
|
||||
* submitted responses through ROLE_ADMINISTRATIVE, not through this attribute.
|
||||
* (config/questionnaires/teamer_assignment.yaml). Every placement gets it; one with a bus
|
||||
* escort gets the bus sections as well, which is the form's business, not this voter's. Only
|
||||
* the teamer themself: the office reads the submitted responses through ROLE_ADMINISTRATIVE,
|
||||
* not through this attribute.
|
||||
*
|
||||
* "Over" is the destination's end date, not Disposition::STATUS_ENDED: the cron sets that a
|
||||
* run late, and it moves on to checking_invoice and completed while the date stays true. An
|
||||
@@ -137,12 +139,11 @@ class DispositionVoter extends Voter
|
||||
}
|
||||
|
||||
if (true === $disposition->isSkipFormalities()
|
||||
|| Disposition::STATUS_CALLED_OFF === $disposition->getStatus()
|
||||
|| true !== $disposition->getAssignment()?->hasBusEscort()) {
|
||||
|| Disposition::STATUS_CALLED_OFF === $disposition->getStatus()) {
|
||||
return false;
|
||||
}
|
||||
|
||||
$dateTo = $disposition->getAssignment()->getDestination()?->getDateTo();
|
||||
$dateTo = $disposition->getAssignment()?->getDestination()?->getDateTo();
|
||||
|
||||
return null !== $dateTo
|
||||
&& $dateTo >= $this->questionnaireGoLive
|
||||
|
||||
Reference in new issue
Block a user