Esempio n. 1
0
 /**
  * Handle all necessary operations when a user is updated
  *
  * @see DB_DataObject::update()
  */
 function update($dataObject = false)
 {
     if (isset($this->username)) {
         $this->username = strtolower($this->username);
     }
     return parent::update($dataObject);
 }
Esempio n. 2
0
 /**
  * Automatically refreshes HTML cache in addition to normal
  * update() call.
  *
  * @see DB_DataObject::update()
  * @param object $dataObject
  * @return boolean
  * @access public
  */
 function update($dataObject = false)
 {
     $this->_rebuildCache();
     return parent::update($dataObject);
 }
Esempio n. 3
0
 function update()
 {
     return parent::update();
 }
 function update($dataObject = false)
 {
     //        $this->setEcpmEnabled();
     if ($this->priority == self::PRIORITY_ECPM || $this->ecpm_enabled) {
         $this->ecpm = $this->calculateEcpm();
     }
     if (isset($this->campaignid)) {
         // Set the correct campaign status, loading the old data
         $this->recalculateStatus(OA_Dal::staticGetDO('campaigns', $this->campaignid));
     }
     return parent::update($dataObject);
 }
Esempio n. 5
0
 /**
  * Handle all necessary operations when a trafficker is updated
  *
  * @see DB_DataObject::update()
  */
 function update($dataObject = false)
 {
     // Store data to create a user
     if (!empty($this->username) && !empty($this->password)) {
         $aUser = array('contact_name' => $this->contact, 'email_address' => $this->email, 'username' => $this->username, 'password' => $this->password, 'default_account_id' => $this->account_id);
     }
     $ret = parent::update($dataObject);
     if (!$ret) {
         return $ret;
     }
     // Create user if needed
     if (!empty($aUser)) {
         $this->createUser($aUser);
     }
     $this->updateAccountName($this->name);
     return $ret;
 }