diff --git a/src/Entity/RiderSession.php b/src/Entity/RiderSession.php new file mode 100644 index 00000000..6d9fbf91 --- /dev/null +++ b/src/Entity/RiderSession.php @@ -0,0 +1,109 @@ +id = $this->generateKeyID(); + $this->rider = null; + $this->is_active = false; + } + + public function generateKeyID() + { + // use uniqid for now, since primary key dupes will trigger exceptions + return uniqid(); + } + + public function getID() + { + return $this->id; + } + + public function setDevicePushID($id) + { + $this->device_push_id = $id; + return $this; + } + + public function getDevicePushID() + { + return $this->device_push_id; + } + + public function setRider(Rider $rider = null) + { + $this->rider = $rider; + return $this; + } + + public function getRider() + { + return $this->rider; + } + + public function setPhoneNumber($num) + { + $this->phone_number = $num; + return $this; + } + + public function getPhoneNumber() + { + return $this->phone_number; + } + + public function setActive($flag = true) + { + $this->is_active = $flag; + return $this; + } + + public function isActive() + { + return $this->is_active; + } +}