public __construct ( $id = null, $name = null, $type = null, $address = null, $email = null, $faxPhone = null, $primaryPhone = null, $externalId = null, $comment = null, $creditStatus = null, $settings = null, $appliedLabels = null, $primaryContactId = null, $appliedTeamIds = null, $thirdPartyCompanyId = null, $lastModifiedDateTime = null ) |
public function __construct($qid) { include '../helpers/db_new.inc.php'; $sql = 'SELECT fullname ,shortname ,englishname ,acronym ,exchid ,companyid ,privileged FROM quotes WHERE qid = :qid AND ActiveFlag = 1'; try { $stmt = $pdo->prepare($sql); $stmt->bindParam(':qid', $qid); $stmt->execute(); } catch (PDOException $e) { $error = $e->getMessage(); $redirect = '../error.html.php'; header("Location: {$redirect}"); exit; } $row = $stmt->fetch(); if ($row) { parent::__construct($row['companyid']); $this->_qid = $qid; $this->_quoteName = $row['fullname']; $this->_quoteShortName = $row['shortname']; $this->_englishName = $row['englishname']; $this->_acronym = $row['acronym']; $this->_exchid = $row['exchid']; $this->_privileged = $row['privileged']; } }
public function __construct() { parent::__construct(); $this->setupCustomFields('Accounts'); foreach ($this->field_defs as $field) { if (isset($field['name'])) { $this->field_name_map[$field['name']] = $field; } } //Email logic if (!empty($_REQUEST['parent_id']) && !empty($_REQUEST['parent_type']) && $_REQUEST['parent_type'] == 'Emails' && !empty($_REQUEST['return_module']) && $_REQUEST['return_module'] == 'Emails') { $_REQUEST['parent_name'] = ''; $_REQUEST['parent_id'] = ''; } }
/** * @brief Constructor * * @note It's allowed to create an object with the ID 0 (for the root element). * * @param Database &$database reference to the Database-object * @param User &$current_user reference to the current user which is logged in * @param Log &$log reference to the Log-object * @param integer $id ID of the manufacturer we want to get * * @throws Exception if there is no such manufacturer in the database * @throws Exception if there was an error */ public function __construct(&$database, &$current_user, &$log, $id) { parent::__construct($database, $current_user, $log, 'manufacturers', $id); }
function __construct() { parent::__construct(); $this->getField('accountnumber')->dropnotnull(); unset($this->_autohandlers['accountnumber']); }
function __construct() { parent::__construct(); }
public function __construct() { parent::__construct(); global $current_user; if (!empty($current_user)) { $this->team_id = $current_user->default_team; //default_team is a team id } else { $this->team_id = 1; // make the item globally accessible } //Email logic if (!empty($_REQUEST['parent_id']) && !empty($_REQUEST['parent_type']) && $_REQUEST['parent_type'] == 'Emails' && !empty($_REQUEST['return_module']) && $_REQUEST['return_module'] == 'Emails') { $_REQUEST['parent_name'] = ''; $_REQUEST['parent_id'] = ''; } }