Пример #1
0
 function __construct(Agent $model = null, Database $db = null)
 {
     parent::__construct();
     $this->agent = $model;
     $this->db = $db;
     if ($this->db == null) {
         $this->db = new Database();
     }
 }
Пример #2
0
 function __construct(Flight $flight = null, Database $db = null)
 {
     parent::__construct();
     $this->flight = $flight;
     if ($db == null) {
         $this->db = new Database();
     } else {
         $this->db = $db;
     }
 }
Пример #3
0
 public function __construct($flight_id = NULL, $ticket_cat = NULL, $ticket_type = NULL, $adult = 0, $child = 0, $price = 0.0)
 {
     parent::__construct();
     $this->flight_id = $flight_id;
     $this->children_no = $child;
     $this->adult_no = $adult;
     $this->ticket_cat = $ticket_cat;
     $this->ticket_type = $ticket_type;
     $this->ticket_adult_price = $price;
     $this->id = Validator::UniqueKey();
 }