public function __construct($clientID, $signatory, $partnerID) { if ((int) $clientID > 0) { $this->_clientID = $clientID; } else { throw new \Exception('Client Class: Client ID is 0'); } $this->_signatory = $signatory; $this->_partnerID = $partnerID; if ($this->_signatory == 1) { $this->_DB = ClientModel::forge($clientID); } else { if ($this->_signatory == 2) { $this->_DB = PartnerModel::forge($partnerID); } else { if ($this->_signatory == 3) { $this->_DB = ClientModel::forge($clientID); $this->_DB2 = PartnerModel::forge($partnerID); $this->_partner = new static($clientID, 2, $partnerID); } } } // -- Load the Client up // --------------------- $this->load(); }