/** * Sets contents of passed object to values from current object. * * If desired, this method can also make copies of all associated (fkey referrers) * objects. * * @param object $copyObj An object of Cliente (or compatible) type. * @param boolean $deepCopy Whether to also copy all rows that refer (by fkey) to the current row. * @param boolean $makeNew Whether to reset autoincrement PKs and make the object new. * @throws PropelException */ public function copyInto($copyObj, $deepCopy = false, $makeNew = true) { $copyObj->setApellido($this->getApellido()); $copyObj->setNombre($this->getNombre()); $copyObj->setTelefono($this->getTelefono()); $copyObj->setDireccion($this->getDireccion()); $copyObj->setIdProv($this->getIdProv()); $copyObj->setIdCiudad($this->getIdCiudad()); $copyObj->setEmail($this->getEmail()); $copyObj->setUser($this->getUser()); $copyObj->setPass($this->getPass()); if ($deepCopy && !$this->startCopy) { // important: temporarily setNew(false) because this affects the behavior of // the getter/setter methods for fkey referrer objects. $copyObj->setNew(false); // store object hash to prevent cycle $this->startCopy = true; foreach ($this->getVentas() as $relObj) { if ($relObj !== $this) { // ensure that we don't try to copy a reference to ourselves $copyObj->addVenta($relObj->copy($deepCopy)); } } //unflag object copy $this->startCopy = false; } // if ($deepCopy) if ($makeNew) { $copyObj->setNew(true); $copyObj->setIdClie(NULL); // this is a auto-increment column, so set to default value } }
/** * Sets contents of passed object to values from current object. * * If desired, this method can also make copies of all associated (fkey referrers) * objects. * * @param object $copyObj An object of sfGuardUser (or compatible) type. * @param boolean $deepCopy Whether to also copy all rows that refer (by fkey) to the current row. * @throws PropelException */ public function copyInto($copyObj, $deepCopy = false) { $copyObj->setUsername($this->username); $copyObj->setAlgorithm($this->algorithm); $copyObj->setSalt($this->salt); $copyObj->setPassword($this->password); $copyObj->setCreatedAt($this->created_at); $copyObj->setLastLogin($this->last_login); $copyObj->setIsActive($this->is_active); $copyObj->setIsSuperAdmin($this->is_super_admin); if ($deepCopy) { // important: temporarily setNew(false) because this affects the behavior of // the getter/setter methods for fkey referrer objects. $copyObj->setNew(false); foreach ($this->getNotaPedidosRelatedByAdministraId() as $relObj) { if ($relObj !== $this) { // ensure that we don't try to copy a reference to ourselves $copyObj->addNotaPedidoRelatedByAdministraId($relObj->copy($deepCopy)); } } foreach ($this->getNotaPedidosRelatedBySolicitaId() as $relObj) { if ($relObj !== $this) { // ensure that we don't try to copy a reference to ourselves $copyObj->addNotaPedidoRelatedBySolicitaId($relObj->copy($deepCopy)); } } foreach ($this->getNotaPedidosRelatedByControlaId() as $relObj) { if ($relObj !== $this) { // ensure that we don't try to copy a reference to ourselves $copyObj->addNotaPedidoRelatedByControlaId($relObj->copy($deepCopy)); } } foreach ($this->getNotaPedidosRelatedByAutorizaId() as $relObj) { if ($relObj !== $this) { // ensure that we don't try to copy a reference to ourselves $copyObj->addNotaPedidoRelatedByAutorizaId($relObj->copy($deepCopy)); } } foreach ($this->getNotaPedidoEstados() as $relObj) { if ($relObj !== $this) { // ensure that we don't try to copy a reference to ourselves $copyObj->addNotaPedidoEstado($relObj->copy($deepCopy)); } } foreach ($this->getEventos() as $relObj) { if ($relObj !== $this) { // ensure that we don't try to copy a reference to ourselves $copyObj->addEvento($relObj->copy($deepCopy)); } } foreach ($this->getCompraEstados() as $relObj) { if ($relObj !== $this) { // ensure that we don't try to copy a reference to ourselves $copyObj->addCompraEstado($relObj->copy($deepCopy)); } } foreach ($this->getVentas() as $relObj) { if ($relObj !== $this) { // ensure that we don't try to copy a reference to ourselves $copyObj->addVenta($relObj->copy($deepCopy)); } } foreach ($this->getVentaEstados() as $relObj) { if ($relObj !== $this) { // ensure that we don't try to copy a reference to ourselves $copyObj->addVentaEstado($relObj->copy($deepCopy)); } } foreach ($this->getsfGuardUserPermissions() as $relObj) { if ($relObj !== $this) { // ensure that we don't try to copy a reference to ourselves $copyObj->addsfGuardUserPermission($relObj->copy($deepCopy)); } } foreach ($this->getsfGuardUserGroups() as $relObj) { if ($relObj !== $this) { // ensure that we don't try to copy a reference to ourselves $copyObj->addsfGuardUserGroup($relObj->copy($deepCopy)); } } foreach ($this->getsfGuardRememberKeys() as $relObj) { if ($relObj !== $this) { // ensure that we don't try to copy a reference to ourselves $copyObj->addsfGuardRememberKey($relObj->copy($deepCopy)); } } foreach ($this->getRecepcionPedidosRelatedByRecibeId() as $relObj) { if ($relObj !== $this) { // ensure that we don't try to copy a reference to ourselves $copyObj->addRecepcionPedidoRelatedByRecibeId($relObj->copy($deepCopy)); } } foreach ($this->getRecepcionPedidosRelatedByControlaId() as $relObj) { if ($relObj !== $this) { // ensure that we don't try to copy a reference to ourselves $copyObj->addRecepcionPedidoRelatedByControlaId($relObj->copy($deepCopy)); } } foreach ($this->getRecepcionPedidosRelatedByAdministraId() as $relObj) { if ($relObj !== $this) { // ensure that we don't try to copy a reference to ourselves $copyObj->addRecepcionPedidoRelatedByAdministraId($relObj->copy($deepCopy)); } } foreach ($this->getUserProfiles() as $relObj) { if ($relObj !== $this) { // ensure that we don't try to copy a reference to ourselves $copyObj->addUserProfile($relObj->copy($deepCopy)); } } } // if ($deepCopy) $copyObj->setNew(true); $copyObj->setId(NULL); // this is a auto-increment column, so set to default value }
/** * Sets contents of passed object to values from current object. * * If desired, this method can also make copies of all associated (fkey referrers) * objects. * * @param object $copyObj An object of Paciente (or compatible) type. * @param boolean $deepCopy Whether to also copy all rows that refer (by fkey) to the current row. * @param boolean $makeNew Whether to reset autoincrement PKs and make the object new. * @throws PropelException */ public function copyInto($copyObj, $deepCopy = false, $makeNew = true) { $copyObj->setPacienteNombre($this->getPacienteNombre()); $copyObj->setPacienteAp($this->getPacienteAp()); $copyObj->setPacienteAm($this->getPacienteAm()); $copyObj->setPacienteCalle($this->getPacienteCalle()); $copyObj->setPacienteNoexterior($this->getPacienteNoexterior()); $copyObj->setPacienteNointerior($this->getPacienteNointerior()); $copyObj->setPacienteColonia($this->getPacienteColonia()); $copyObj->setPacienteCodigopostal($this->getPacienteCodigopostal()); $copyObj->setPacienteCiudad($this->getPacienteCiudad()); $copyObj->setPacienteEstado($this->getPacienteEstado()); $copyObj->setPacientePais($this->getPacientePais()); $copyObj->setPacienteTelefono($this->getPacienteTelefono()); $copyObj->setPacienteTelefonocelular($this->getPacienteTelefonocelular()); $copyObj->setPacienteFechanacimiento($this->getPacienteFechanacimiento()); $copyObj->setPacienteSexo($this->getPacienteSexo()); $copyObj->setPacienteEstadocivil($this->getPacienteEstadocivil()); $copyObj->setPacienteOcupacion($this->getPacienteOcupacion()); $copyObj->setPacienteConyuge($this->getPacienteConyuge()); $copyObj->setPacientePadre($this->getPacientePadre()); $copyObj->setPacienteMadre($this->getPacienteMadre()); $copyObj->setPacienteResponsable($this->getPacienteResponsable()); $copyObj->setPacienteTelefonoresponsable($this->getPacienteTelefonoresponsable()); if ($deepCopy && !$this->startCopy) { // important: temporarily setNew(false) because this affects the behavior of // the getter/setter methods for fkey referrer objects. $copyObj->setNew(false); // store object hash to prevent cycle $this->startCopy = true; foreach ($this->getAdmisions() as $relObj) { if ($relObj !== $this) { // ensure that we don't try to copy a reference to ourselves $copyObj->addAdmision($relObj->copy($deepCopy)); } } foreach ($this->getCitas() as $relObj) { if ($relObj !== $this) { // ensure that we don't try to copy a reference to ourselves $copyObj->addCita($relObj->copy($deepCopy)); } } foreach ($this->getConsultas() as $relObj) { if ($relObj !== $this) { // ensure that we don't try to copy a reference to ourselves $copyObj->addConsulta($relObj->copy($deepCopy)); } } foreach ($this->getPacientefacturacions() as $relObj) { if ($relObj !== $this) { // ensure that we don't try to copy a reference to ourselves $copyObj->addPacientefacturacion($relObj->copy($deepCopy)); } } foreach ($this->getVentas() as $relObj) { if ($relObj !== $this) { // ensure that we don't try to copy a reference to ourselves $copyObj->addVenta($relObj->copy($deepCopy)); } } //unflag object copy $this->startCopy = false; } // if ($deepCopy) if ($makeNew) { $copyObj->setNew(true); $copyObj->setIdpaciente(NULL); // this is a auto-increment column, so set to default value } }
/** * Sets contents of passed object to values from current object. * * If desired, this method can also make copies of all associated (fkey referrers) * objects. * * @param object $copyObj An object of Producto (or compatible) type. * @param boolean $deepCopy Whether to also copy all rows that refer (by fkey) to the current row. * @param boolean $makeNew Whether to reset autoincrement PKs and make the object new. * @throws PropelException */ public function copyInto($copyObj, $deepCopy = false, $makeNew = true) { $copyObj->setTitulo($this->getTitulo()); $copyObj->setIdartista($this->getIdartista()); $copyObj->setIdgenero($this->getIdgenero()); $copyObj->setAnio($this->getAnio()); $copyObj->setCantidadventas($this->getCantidadventas()); $copyObj->setStock($this->getStock()); $copyObj->setPrecio($this->getPrecio()); if ($deepCopy && !$this->startCopy) { // important: temporarily setNew(false) because this affects the behavior of // the getter/setter methods for fkey referrer objects. $copyObj->setNew(false); // store object hash to prevent cycle $this->startCopy = true; foreach ($this->getVentas() as $relObj) { if ($relObj !== $this) { // ensure that we don't try to copy a reference to ourselves $copyObj->addVenta($relObj->copy($deepCopy)); } } //unflag object copy $this->startCopy = false; } // if ($deepCopy) if ($makeNew) { $copyObj->setNew(true); $copyObj->setIdproducto(NULL); // this is a auto-increment column, so set to default value } }