Esempio n. 1
0
 /**
  * @param ChildDelivery $delivery The ChildDelivery object to add.
  */
 protected function doAddDelivery(ChildDelivery $delivery)
 {
     $this->collDeliveries[] = $delivery;
     $delivery->setDeliveryType($this);
 }
Esempio n. 2
0
 /**
  * Clears the current object, sets all attributes to their default values and removes
  * outgoing references as well as back-references (from other objects to this one. Results probably in a database
  * change of those foreign objects when you call `save` there).
  */
 public function clear()
 {
     if (null !== $this->aDelivery) {
         $this->aDelivery->removeDeliveryPeriodic($this);
     }
     if (null !== $this->aPeriodicPlan) {
         $this->aPeriodicPlan->removeDeliveryPeriodic($this);
     }
     $this->delivery_periodic_id = null;
     $this->delivery_id = null;
     $this->delivery_periodic_plan_id = null;
     $this->created_at = null;
     $this->updated_at = null;
     $this->sortable_rank = null;
     $this->alreadyInSave = false;
     $this->clearAllReferences();
     $this->resetModified();
     $this->setNew(true);
     $this->setDeleted(false);
 }
Esempio n. 3
0
 /**
  * Filter the query by a related \App\Propel\Delivery object
  *
  * @param \App\Propel\Delivery|ObjectCollection $delivery the related object to use as filter
  * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
  *
  * @return ChildDeliveryTypeQuery The current query, for fluid interface
  */
 public function filterByDelivery($delivery, $comparison = null)
 {
     if ($delivery instanceof \App\Propel\Delivery) {
         return $this->addUsingAlias(DeliveryTypeTableMap::COL_DELIVERY_TYPE_ID, $delivery->getDeliveryTypeId(), $comparison);
     } elseif ($delivery instanceof ObjectCollection) {
         return $this->useDeliveryQuery()->filterByPrimaryKeys($delivery->getPrimaryKeys())->endUse();
     } else {
         throw new PropelException('filterByDelivery() only accepts arguments of type \\App\\Propel\\Delivery or Collection');
     }
 }
Esempio n. 4
0
 /**
  * Filter the query by a related \App\Propel\Delivery object
  *
  * @param \App\Propel\Delivery|ObjectCollection $delivery The related object(s) to use as filter
  * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL
  *
  * @throws \Propel\Runtime\Exception\PropelException
  *
  * @return ChildOrderQuery The current query, for fluid interface
  */
 public function filterByDelivery($delivery, $comparison = null)
 {
     if ($delivery instanceof \App\Propel\Delivery) {
         return $this->addUsingAlias(OrderTableMap::COL_DELIVERY_ID, $delivery->getDeliveryId(), $comparison);
     } elseif ($delivery instanceof ObjectCollection) {
         if (null === $comparison) {
             $comparison = Criteria::IN;
         }
         return $this->addUsingAlias(OrderTableMap::COL_DELIVERY_ID, $delivery->toKeyValue('PrimaryKey', 'DeliveryId'), $comparison);
     } else {
         throw new PropelException('filterByDelivery() only accepts arguments of type \\App\\Propel\\Delivery or Collection');
     }
 }
Esempio n. 5
0
 /**
  * Exclude object from result
  *
  * @param   ChildDelivery $delivery Object to remove from the list of results
  *
  * @return $this|ChildDeliveryQuery The current query, for fluid interface
  */
 public function prune($delivery = null)
 {
     if ($delivery) {
         $this->addUsingAlias(DeliveryTableMap::COL_DELIVERY_ID, $delivery->getDeliveryId(), Criteria::NOT_EQUAL);
     }
     return $this;
 }
Esempio n. 6
0
 /**
  * Clears the current object, sets all attributes to their default values and removes
  * outgoing references as well as back-references (from other objects to this one. Results probably in a database
  * change of those foreign objects when you call `save` there).
  */
 public function clear()
 {
     if (null !== $this->aUser) {
         $this->aUser->removeOrder($this);
     }
     if (null !== $this->aDelivery) {
         $this->aDelivery->removeOrder($this);
     }
     $this->order_id = null;
     $this->user_id = null;
     $this->delivery_id = null;
     $this->order_comment = null;
     $this->created_at = null;
     $this->updated_at = null;
     $this->alreadyInSave = false;
     $this->clearAllReferences();
     $this->resetModified();
     $this->setNew(true);
     $this->setDeleted(false);
 }