Example #1
0
 /**
  * Обновляет инвайт
  *
  * @param ModuleUser_EntityInvite $oInvite    бъект инвайта
  *
  * @return bool
  */
 public function UpdateInvite(ModuleUser_EntityInvite $oInvite)
 {
     $sql = "UPDATE ?_invite\n\t\t\tSET\n\t\t\t\tuser_to_id = ? ,\n\t\t\t\tinvite_date_used = ? ,\n\t\t\t\tinvite_used =?\n\t\t\tWHERE invite_id = ?\n\t\t";
     $bResult = $this->oDb->query($sql, $oInvite->getUserToId(), $oInvite->getDateUsed(), $oInvite->getUsed(), $oInvite->getId());
     return $bResult !== false;
 }
Example #2
0
 /**
  * Обновляет инвайт
  *
  * @param ModuleUser_EntityInvite $oInvite
  * @return unknown
  */
 public function UpdateInvite(ModuleUser_EntityInvite $oInvite)
 {
     //чистим зависимые кеши
     $this->Cache_Clean(Zend_Cache::CLEANING_MODE_MATCHING_TAG, array("invate_new_to_{$oInvite->getUserToId()}", "invate_new_from_{$oInvite->getUserFromId()}"));
     return $this->oMapper->UpdateInvite($oInvite);
 }
 /**
  * Обновляет инвайт
  *
  * @param ModuleUser_EntityInvite $oInvite бъект инвайта
  * @return bool
  */
 public function UpdateInvite(ModuleUser_EntityInvite $oInvite)
 {
     $sql = "UPDATE " . Config::Get('db.table.invite') . "\n      SET\n        user_to_id = ? ,\n        invite_date_used = ? ,\n        invite_used =?\n      WHERE invite_id = ?\n    ";
     if ($this->oDb->query($sql, $oInvite->getUserToId(), $oInvite->getDateUsed(), $oInvite->getUsed(), $oInvite->getId())) {
         return true;
     }
     return false;
 }