Add the two flags to Hub. #607
This commit is contained in:
parent
b0b9867f81
commit
406568ab3d
1 changed files with 38 additions and 0 deletions
|
|
@ -80,6 +80,18 @@ class Hub
|
||||||
*/
|
*/
|
||||||
protected $payment_methods;
|
protected $payment_methods;
|
||||||
|
|
||||||
|
// flag if hub can be auto assigned
|
||||||
|
/**
|
||||||
|
* @ORM\Column(type="boolean")
|
||||||
|
*/
|
||||||
|
protected $flag_hub_auto_assign;
|
||||||
|
|
||||||
|
// flag if riders assigned to hub can be auto assigned
|
||||||
|
/**
|
||||||
|
* @ORM\Column(type="boolean")
|
||||||
|
*/
|
||||||
|
protected $flag_rider_auto_assign;
|
||||||
|
|
||||||
public function __construct()
|
public function __construct()
|
||||||
{
|
{
|
||||||
$this->time_open = new DateTime();
|
$this->time_open = new DateTime();
|
||||||
|
|
@ -90,6 +102,8 @@ class Hub
|
||||||
$this->flag_hub_view = false;
|
$this->flag_hub_view = false;
|
||||||
$this->notif_number = '';
|
$this->notif_number = '';
|
||||||
$this->payment_methods = new ArrayCollection();
|
$this->payment_methods = new ArrayCollection();
|
||||||
|
$this->flag_hub_auto_assign = false;
|
||||||
|
$this->flag_rider_auto_assign = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
public function getRiders()
|
public function getRiders()
|
||||||
|
|
@ -232,4 +246,28 @@ class Hub
|
||||||
$this->payment_methods = new ArrayCollection();
|
$this->payment_methods = new ArrayCollection();
|
||||||
return $this;
|
return $this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function setAutoAssignHubFlag($flag_hub_auto_assign = true)
|
||||||
|
{
|
||||||
|
$this->flag_hub_auto_assign = $flag_hub_auto_assign;
|
||||||
|
return $this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function isAutoAssignHub()
|
||||||
|
{
|
||||||
|
return $this->flag_hub_auto_assign;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function setAutoAssignRiderFlag($flag_rider_auto_assign = true)
|
||||||
|
{
|
||||||
|
$this->flag_rider_auto_assign = $flag_rider_auto_assign;
|
||||||
|
return $this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function isAutoAssignRider()
|
||||||
|
{
|
||||||
|
return $this->flag_rider_auto_assign;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue