Last active
August 29, 2015 14:13
-
-
Save radek-baczynski/af6378edbe1d52ef2199 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| namespace: | |
| UseCase: | |
| NoShowMarker: | |
| data class: NoShowMarkerData { | |
| Visit $visit; | |
| construct(Visit); | |
| } | |
| data validator class: NoShowMarkerValidator { | |
| isValid(NoShowMarkerData); | |
| } | |
| use case class: NoShowMarker { | |
| execute(NoShowMarkerData $data) | |
| this->validator->isValid($data); | |
| logika: | |
| begin | |
| // business logic, all is done! Model consistency | |
| new NoShow | |
| change VisitPatient... | |
| $response = new Response(Visit, VisitNoShow, VisitPatient); | |
| event->dispatch('onNoShowMarker', new NoShowMarkerEvent($response)) | |
| commit(); | |
| event->dispatch('postNoShowMarker', new NoShowMarkerEvent($response)) | |
| return response; | |
| response class: NoShowMarkerResponse { | |
| // all propels | |
| Visit $visit; | |
| VisitNoShow $noShow; | |
| Patient $patient; | |
| } | |
| } | |
| NoShowRemover: | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment