Beispiel #1
0
 /**
  * @param TodoWasMarkedAsExpired $event
  */
 protected function whenTodoWasMarkedAsExpired(TodoWasMarkedAsExpired $event)
 {
     $this->status = $event->newStatus();
 }
 /**
  * @param TodoWasMarkedAsExpired $event
  */
 public function onTodoWasMarkedAsExpired(TodoWasMarkedAsExpired $event)
 {
     $this->connection->update(Table::TODO, ['status' => $event->newStatus()->toString()], ['id' => $event->todoId()->toString()]);
 }