/** * Get the associated LeasingBookingLeads object * * @param PropelPDO $con Optional Connection object. * @param $doQuery Executes a query to get the object if required * @return LeasingBookingLeads The associated LeasingBookingLeads object. * @throws PropelException */ public function getLeasingBookingLeads(PropelPDO $con = null, $doQuery = true) { if ($this->aLeasingBookingLeads === null && $this->booking_leads_id !== null && $doQuery) { $this->aLeasingBookingLeads = LeasingBookingLeadsQuery::create()->findPk($this->booking_leads_id, $con); /* The following can be used additionally to guarantee the related object contains a reference to this object. This level of coupling may, however, be undesirable since it could result in an only partially populated collection in the referenced object. $this->aLeasingBookingLeads->addLeasingBookingss($this); */ } return $this->aLeasingBookingLeads; }
/** * If this collection has already been initialized with * an identical criteria, it returns the collection. * Otherwise if this LeasingNationality is new, it will return * an empty collection; or if this LeasingNationality has previously * been saved, it will retrieve related LeasingBookingLeadss from storage. * * This method is protected by default in order to keep the public * api reasonable. You can provide public methods for those you * actually need in LeasingNationality. * * @param Criteria $criteria optional Criteria object to narrow the query * @param PropelPDO $con optional connection object * @param string $join_behavior optional join type to use (defaults to Criteria::LEFT_JOIN) * @return PropelObjectCollection|LeasingBookingLeads[] List of LeasingBookingLeads objects */ public function getLeasingBookingLeadssJoinLeasingCountry($criteria = null, $con = null, $join_behavior = Criteria::LEFT_JOIN) { $query = LeasingBookingLeadsQuery::create(null, $criteria); $query->joinWith('LeasingCountry', $join_behavior); return $this->getLeasingBookingLeadss($query, $con); }
/** * Returns a new LeasingBookingLeadsQuery object. * * @param string $modelAlias The alias of a model in the query * @param LeasingBookingLeadsQuery|Criteria $criteria Optional Criteria to build the query from * * @return LeasingBookingLeadsQuery */ public static function create($modelAlias = null, $criteria = null) { if ($criteria instanceof LeasingBookingLeadsQuery) { return $criteria; } $query = new LeasingBookingLeadsQuery(null, null, $modelAlias); if ($criteria instanceof Criteria) { $query->mergeWith($criteria); } return $query; }