当前位置: 首页>>代码示例>>PHP>>正文


PHP Company::Load方法代码示例

本文整理汇总了PHP中Company::Load方法的典型用法代码示例。如果您正苦于以下问题:PHP Company::Load方法的具体用法?PHP Company::Load怎么用?PHP Company::Load使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Company的用法示例。


在下文中一共展示了Company::Load方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: __toStringFullAddressWithWebsite

 public function __toStringFullAddressWithWebsite($cssClass = null)
 {
     $objCompany = Company::Load($this->CompanyId);
     $strWebsite = $objCompany->Website;
     $strToReturn = sprintf('%s<br>%s', $this->__toStringFullAddress(), $strWebsite);
     return $strToReturn;
 }
开发者ID:brustj,项目名称:tracmor,代码行数:7,代码来源:Address.class.php

示例2: SetupCompany

 protected function SetupCompany()
 {
     // Lookup Object PK information from Query String (if applicable)
     // Set mode to Edit or New depending on what's found
     $intCompanyId = QApplication::QueryString('intCompanyId');
     if ($intCompanyId) {
         $this->objCompany = Company::Load($intCompanyId);
         if (!$this->objCompany) {
             throw new Exception('Could not find a Company object with PK arguments: ' . $intCompanyId);
         }
         $this->strTitleVerb = QApplication::Translate('Edit');
         $this->blnEditMode = true;
     } else {
         $this->objCompany = new Company();
         $this->strTitleVerb = QApplication::Translate('Create');
         $this->blnEditMode = false;
     }
 }
开发者ID:brustj,项目名称:tracmor,代码行数:18,代码来源:CompanyEditFormBase.class.php

示例3: lstCompany_Select

 public function lstCompany_Select()
 {
     // Clear out the items from lstAddress
     $this->lstAddress->RemoveAllItems();
     if ($this->lstCompany->SelectedValue) {
         // Load the selected company
         $objCompany = Company::Load($this->lstCompany->SelectedValue);
         // Get all available addresses for that company
         if ($objCompany) {
             $objAddressArray = $objCompany->GetAddressArray();
             $this->lstAddress->Enabled = true;
         } else {
             $objAddressArray = null;
             $this->lstAddress->Enabled = false;
         }
     } else {
         // Or load all addresses for all companies
         //$objAddressArray = Address::LoadAll(QQ::Clause(QQ::OrderBy(QQN::Address()->ShortDescription)));
         //$this->lstAddress->Enabled = true;
         $objAddressArray = null;
     }
     $this->lstAddress->AddItem('- Select One -', null);
     if ($objAddressArray) {
         foreach ($objAddressArray as $objAddress) {
             $objListItem = new QListItem($objAddress->__toString(), $objAddress->AddressId);
             // Select the proper AddressID if editing an existing contact
             if ($this->blnEditMode && $this->objContact->Address && $this->objContact->AddressId == $objAddress->AddressId) {
                 $objListItem->Selected = true;
             }
             $this->lstAddress->AddItem($objListItem);
         }
     }
     /*			if ($this->lstCompany->SelectedValue && $this->lstCompany->SelectedValue == -1) {
     		 $this->pnlNewCompany->Visible = true;
     			}
     			else {
     			$this->pnlNewCompany->Visible = false;
     			}*/
 }
开发者ID:heshuai64,项目名称:einv2,代码行数:39,代码来源:contact_edit.php

示例4: Reload

 /**
  * Reload this Company from the database.
  * @return void
  */
 public function Reload()
 {
     // Make sure we are actually Restored from the database
     if (!$this->__blnRestored) {
         throw new QCallerException('Cannot call Reload() on a new, unsaved Company object.');
     }
     // Reload the Object
     $objReloaded = Company::Load($this->intCompanyId);
     // Update $this's local variables to match
     $this->AddressId = $objReloaded->AddressId;
     $this->strShortDescription = $objReloaded->strShortDescription;
     $this->strWebsite = $objReloaded->strWebsite;
     $this->strTelephone = $objReloaded->strTelephone;
     $this->strFax = $objReloaded->strFax;
     $this->strEmail = $objReloaded->strEmail;
     $this->strLongDescription = $objReloaded->strLongDescription;
     $this->CreatedBy = $objReloaded->CreatedBy;
     $this->dttCreationDate = $objReloaded->dttCreationDate;
     $this->ModifiedBy = $objReloaded->ModifiedBy;
     $this->strModifiedDate = $objReloaded->strModifiedDate;
 }
开发者ID:proxymoron,项目名称:tracmor,代码行数:25,代码来源:CompanyGen.class.php

示例5: __get

 /**
  * Override method to perform a property "Get"
  * This will get the value of $strName
  *
  * @param string $strName Name of the property to get
  * @return mixed
  */
 public function __get($strName)
 {
     switch ($strName) {
         ///////////////////
         // Member Variables
         ///////////////////
         case 'ShipmentId':
             // Gets the value for intShipmentId (Read-Only PK)
             // @return integer
             return $this->intShipmentId;
         case 'ShipmentNumber':
             // Gets the value for strShipmentNumber (Unique)
             // @return string
             return $this->strShipmentNumber;
         case 'TransactionId':
             // Gets the value for intTransactionId (Unique)
             // @return integer
             return $this->intTransactionId;
         case 'FromCompanyId':
             // Gets the value for intFromCompanyId (Not Null)
             // @return integer
             return $this->intFromCompanyId;
         case 'FromContactId':
             // Gets the value for intFromContactId (Not Null)
             // @return integer
             return $this->intFromContactId;
         case 'FromAddressId':
             // Gets the value for intFromAddressId (Not Null)
             // @return integer
             return $this->intFromAddressId;
         case 'ToCompanyId':
             // Gets the value for intToCompanyId (Not Null)
             // @return integer
             return $this->intToCompanyId;
         case 'ToContactId':
             // Gets the value for intToContactId (Not Null)
             // @return integer
             return $this->intToContactId;
         case 'ToAddressId':
             // Gets the value for intToAddressId (Not Null)
             // @return integer
             return $this->intToAddressId;
         case 'CourierId':
             // Gets the value for intCourierId
             // @return integer
             return $this->intCourierId;
         case 'TrackingNumber':
             // Gets the value for strTrackingNumber
             // @return string
             return $this->strTrackingNumber;
         case 'ShipDate':
             // Gets the value for dttShipDate (Not Null)
             // @return QDateTime
             return $this->dttShipDate;
         case 'ShippedFlag':
             // Gets the value for blnShippedFlag
             // @return boolean
             return $this->blnShippedFlag;
         case 'CreatedBy':
             // Gets the value for intCreatedBy
             // @return integer
             return $this->intCreatedBy;
         case 'CreationDate':
             // Gets the value for dttCreationDate
             // @return QDateTime
             return $this->dttCreationDate;
         case 'ModifiedBy':
             // Gets the value for intModifiedBy
             // @return integer
             return $this->intModifiedBy;
         case 'ModifiedDate':
             // Gets the value for strModifiedDate (Read-Only Timestamp)
             // @return string
             return $this->strModifiedDate;
             ///////////////////
             // Member Objects
             ///////////////////
         ///////////////////
         // Member Objects
         ///////////////////
         case 'Transaction':
             // Gets the value for the Transaction object referenced by intTransactionId (Unique)
             // @return Transaction
             try {
                 if (!$this->objTransaction && !is_null($this->intTransactionId)) {
                     $this->objTransaction = Transaction::Load($this->intTransactionId);
                 }
                 return $this->objTransaction;
             } catch (QCallerException $objExc) {
                 $objExc->IncrementOffset();
                 throw $objExc;
             }
         case 'FromCompany':
//.........这里部分代码省略.........
开发者ID:proxymoron,项目名称:tracmor,代码行数:101,代码来源:ShipmentGen.class.php

示例6: btnSave_Click

 protected function btnSave_Click()
 {
     $intCompanyId = $this->lstCompany->SelectedValue;
     $objCompany = Company::Load($intCompanyId);
     // Altered $TracmorSettings __set() method so that just setting a value will save it in the database.
     QApplication::$TracmorSettings->CompanyId = $intCompanyId;
     QApplication::$TracmorSettings->PackingListTerms = $this->txtPackingListTerms->Text;
     QApplication::$TracmorSettings->AutodetectTrackingNumbers = $this->chkAutoDetectTrackingNumbers->Checked;
     QApplication::$TracmorSettings->ReceiveToLastLocation = $this->chkReceiveToLastLocation->Checked;
     QApplication::$TracmorSettings->CustomShipmentNumbers = (string) $this->chkCustomShipmentNumbers->Checked;
     QApplication::$TracmorSettings->CustomReceiptNumbers = (string) $this->chkCustomReceiptNumbers->Checked;
     // Show saved notification
     $this->pnlSaveNotification->Display = true;
 }
开发者ID:proxymoron,项目名称:tracmor,代码行数:14,代码来源:shipping_account_list.php

示例7: btnMassDelete_Click

 protected function btnMassDelete_Click($strFormId, $strControlId, $strParameter)
 {
     $items = $this->dtgCompany->getSelected('CompanyId');
     // Show confirm "Are you sure you want to {delete/edit} these objects?"
     if (count($items) > 0) {
         $this->lblMassActionError->Text = "";
         if (!$this->dlgMassDelete->Display) {
             $arrToBeSkipped = array();
             foreach ($items as $item) {
                 // Check if any Shipments or Receipts include selected contact
                 if (Shipment::hasCompany($item)) {
                     // append $item to  be skipped
                     $arrToBeSkipped[] = $item;
                 } else {
                     $this->arrToDelete[] = $item;
                 }
             }
             if (count($arrToBeSkipped) > 0) {
                 if (count($arrToBeSkipped) == 1) {
                     $toBe = 'is';
                     $ending1 = 'y';
                     $ending2 = '';
                 } else {
                     $toBe = 'are';
                     $ending1 = 'ies';
                     $ending2 = 's';
                 }
                 // Show dialog box "There are {number} {entity_type}s that are not able to be deleted. Would you like to continue the deletion process, skipping these items?"
                 $this->dlgMassDelete->Text = sprintf("There %s %s compan%s that %s not able to be deleted.\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t Would you like to continue the deletion process,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t skipping these item%s?<br />", $toBe, count($arrToBeSkipped), $ending1, $toBe, $ending2);
                 $this->dlgMassDelete->ShowDialogBox();
             } else {
                 if (count($this->arrToDelete) > 0) {
                     try {
                         // Get an instance of the database
                         $objDatabase = QApplication::$Database[1];
                         // Begin a MySQL Transaction to be either committed or rolled back
                         $objDatabase->TransactionBegin();
                         foreach ($this->arrToDelete as $intCompanyId) {
                             Company::Load($intCompanyId)->Delete();
                         }
                         $objDatabase->TransactionCommit();
                         $this->arrToDelete = array();
                         QApplication::Redirect('');
                     } catch (QMySqliDatabaseException $objExc) {
                         $objDatabase->TransactionRollback();
                         throw new QDatabaseException();
                     }
                 }
             }
             //	print_r(get_class_methods(get_class($this->dlgDelete)));exit;//$this->dlgDelete->ShowDialogBox() ;
         }
     } else {
         $this->lblMassActionError->Text = "You haven't chosen any Company to Delete";
     }
 }
开发者ID:proxymoron,项目名称:tracmor,代码行数:55,代码来源:company_list.php

示例8: __get


//.........这里部分代码省略.........
              */
             return $this->intCreatedBy;
         case 'CreationDate':
             /**
              * Gets the value for dttCreationDate 
              * @return QDateTime
              */
             return $this->dttCreationDate;
         case 'ModifiedBy':
             /**
              * Gets the value for intModifiedBy 
              * @return integer
              */
             return $this->intModifiedBy;
         case 'ModifiedDate':
             /**
              * Gets the value for strModifiedDate (Read-Only Timestamp)
              * @return string
              */
             return $this->strModifiedDate;
             ///////////////////
             // Member Objects
             ///////////////////
         ///////////////////
         // Member Objects
         ///////////////////
         case 'Company':
             /**
              * Gets the value for the Company object referenced by intCompanyId (Not Null)
              * @return Company
              */
             try {
                 if (!$this->objCompany && !is_null($this->intCompanyId)) {
                     $this->objCompany = Company::Load($this->intCompanyId);
                 }
                 return $this->objCompany;
             } catch (QCallerException $objExc) {
                 $objExc->IncrementOffset();
                 throw $objExc;
             }
         case 'Address':
             /**
              * Gets the value for the Address object referenced by intAddressId 
              * @return Address
              */
             try {
                 if (!$this->objAddress && !is_null($this->intAddressId)) {
                     $this->objAddress = Address::Load($this->intAddressId);
                 }
                 return $this->objAddress;
             } catch (QCallerException $objExc) {
                 $objExc->IncrementOffset();
                 throw $objExc;
             }
         case 'CreatedByObject':
             /**
              * Gets the value for the UserAccount object referenced by intCreatedBy 
              * @return UserAccount
              */
             try {
                 if (!$this->objCreatedByObject && !is_null($this->intCreatedBy)) {
                     $this->objCreatedByObject = UserAccount::Load($this->intCreatedBy);
                 }
                 return $this->objCreatedByObject;
             } catch (QCallerException $objExc) {
                 $objExc->IncrementOffset();
开发者ID:heshuai64,项目名称:einv2,代码行数:67,代码来源:ContactGen.class.php

示例9: lstCompany_Change

 public function lstCompany_Change()
 {
     // Clear out the items from lstAddress
     $this->lstAddress->RemoveAllItems();
     if ($this->lstCompany->SelectedValue) {
         // Load the selected company
         $objCompany = Company::Load($this->lstCompany->SelectedValue);
         // Get all available addresses for that company
         if ($objCompany) {
             $objAddressArray = $objCompany->GetAddressArray();
             $this->lstAddress->Enabled = true;
         } else {
             $objAddressArray = null;
             $this->lstAddress->Enabled = false;
         }
     } else {
         // Or load all addresses for all companies
         $objAddressArray = Address::LoadAll(QQ::Clause(QQ::OrderBy(QQN::Address()->ShortDescription)));
         $this->lstAddress->Enabled = true;
     }
     $this->lstAddress->AddItem('- Select One -', null);
     if ($objAddressArray) {
         foreach ($objAddressArray as $objAddress) {
             $objListItem = new QListItem($objAddress->__toString(), $objAddress->AddressId);
             $this->lstAddress->AddItem($objListItem);
         }
     }
 }
开发者ID:heshuai64,项目名称:einv2,代码行数:28,代码来源:ContactEditPanel.class.php

示例10: btnEdit_Click

 public function btnEdit_Click($strFormId, $strControlId, $strParameter)
 {
     $strParameterArray = explode(',', $strParameter);
     $objCompany = Company::Load($strParameterArray[0]);
     $objEditPanel = new CompanyEditPanel($this, $this->strCloseEditPanelMethod, $objCompany);
     $strMethodName = $this->strSetEditPanelMethod;
     $this->objForm->{$strMethodName}($objEditPanel);
 }
开发者ID:heshuai64,项目名称:einv2,代码行数:8,代码来源:CompanyListPanelBase.class.php

示例11: btnSave_Click

 protected function btnSave_Click($strFormId, $strControlId, $strParameter)
 {
     $blnError = false;
     if ($this->objAssetTransactionArray && $this->objInventoryTransactionArray) {
         $intEntityQtypeId = EntityQtype::AssetInventory;
     } elseif ($this->objAssetTransactionArray) {
         $intEntityQtypeId = EntityQtype::Asset;
     } elseif ($this->objInventoryTransactionArray) {
         $intEntityQtypeId = EntityQtype::Inventory;
     } else {
         $blnError = true;
         $this->btnCancel->Warning = 'There are no assets or inventory in this shipment.';
     }
     if (QApplication::$TracmorSettings->CustomShipmentNumbers) {
         if ($objShipment = Shipment::LoadByShipmentNumber($this->txtShipmentNumber->Text)) {
             if ($objShipment->ShipmentId != $this->objShipment->ShipmentId) {
                 $blnError = true;
                 $this->txtShipmentNumber->Warning = 'That is a duplicate shipment number.';
             }
         }
     }
     if ($this->lstFxServiceType->SelectedValue) {
         $objtoFxAddress = Address::Load($this->lstToAddress->SelectedValue);
         if (!$objtoFxAddress || !$objtoFxAddress->PostalCode || !$objtoFxAddress->CountryId || !$objtoFxAddress->Address1) {
             $blnError = true;
             $this->lstFxServiceType->Warning = "Not a valid To Address.";
         }
         $objfromFxAddress = Address::Load($this->lstFromAddress->SelectedValue);
         if (!$objfromFxAddress || !$objfromFxAddress->PostalCode || !$objfromFxAddress->Address1 || !$objfromFxAddress->CountryId) {
             $blnError = true;
             $this->lstFxServiceType->Warning = "Not a valid From Address.";
         }
         $objfromFxContact = Contact::Load($this->lstFromContact->SelectedValue);
         if (!$objfromFxContact) {
             $blnError = true;
             $this->lstFxServiceType->Warning = "Not a valid From Contact.";
         }
         $objfromFxCompany = Company::Load($this->lstFromCompany->SelectedValue);
         if (!$objfromFxCompany) {
             $blnError = true;
             $this->lstFxServiceType->Warning = "Not a valid From Company.";
         } elseif (!$objfromFxCompany->Telephone) {
             $blnError = true;
             $this->lstFxServiceType->Warning = "The Shipping Company must have a telephone number.";
         }
         $objShippingAccount = ShippingAccount::Load($this->lstShippingAccount->SelectedValue);
         if (!$objShippingAccount) {
             $blnError = true;
             $this->lstFxServiceType->Warning = "Not a valid Shipping Account.";
         }
         /*				$fed = new FedExDC($objShippingAccount->Value);
         
         				$aRet = $fed->subscribe(
         					array(
         						1 => $this->lblShipmentNumber->Text, // Don't really need this but can be used for ref
         						4003 => $objfromFxContact->__toString(),
         						4008 => $objfromFxAddress->Address1,
         						4009 => $objfromFxAddress->Address2,
         						4011 => $objfromFxAddress->City,
         						4012 => $objfromFxAddress->__toStringStateProvinceAbbreviation(),
         						4013 => $objfromFxAddress->PostalCode,
         						4014 => $objfromFxAddress->__toStringCountryAbbreviation(),
         						4015 => $this->FxStrip($objfromFxCompany->Telephone),
         					)
         				);
         
         				if ($error = $fed->getError()) {
         					$blnError = true;
         					$this->lstFxServiceType->Warning = $error;
         				}
         				elseif (!$aRet[498]) {
         					$blnError = true;
         					$this->lstFxServiceType->Warning = "Fedex response is improperly formed.";
         				}
         				else {
         					$this->objShipment->FedexMeterNumber = $aRet[498];
         				}*/
     }
     if (!$blnError) {
         if (!$this->blnEditMode) {
             try {
                 // Get an instance of the database
                 $objDatabase = QApplication::$Database[1];
                 // Begin a MySQL Transaction to be either committed or rolled back
                 $objDatabase->TransactionBegin();
                 // Create the new transaction object and save it
                 $this->objTransaction = new Transaction();
                 $this->objTransaction->EntityQtypeId = $intEntityQtypeId;
                 $this->objTransaction->TransactionTypeId = 6;
                 $this->objTransaction->Note = $this->txtNote->Text;
                 $this->objTransaction->Save();
                 if ($intEntityQtypeId == EntityQtype::AssetInventory || $intEntityQtypeId == EntityQtype::Asset) {
                     // Assign different source and destinations depending on transaction type
                     foreach ($this->objAssetTransactionArray as $objAssetTransaction) {
                         if ($objAssetTransaction->Asset instanceof Asset) {
                             // Save the asset just to update the modified_date field so it can trigger an Optimistic Locking Exception when appropriate
                             $objAssetTransaction->Asset->Save();
                             // Assign the TransactionId
                             $objAssetTransaction->TransactionId = $this->objTransaction->TransactionId;
                             // Create the new asset if it was scheduled for receipt
//.........这里部分代码省略.........
开发者ID:brustj,项目名称:tracmor,代码行数:101,代码来源:shipment_edit.php

示例12: __get

 /**
  * Override method to perform a property "Get"
  * This will get the value of $strName
  *
  * @param string $strName Name of the property to get
  * @return mixed
  */
 public function __get($strName)
 {
     switch ($strName) {
         ///////////////////
         // Member Variables
         ///////////////////
         case 'ContactId':
             // Gets the value for intContactId (Read-Only PK)
             // @return integer
             return $this->intContactId;
         case 'CompanyId':
             // Gets the value for intCompanyId (Not Null)
             // @return integer
             return $this->intCompanyId;
         case 'AddressId':
             // Gets the value for intAddressId
             // @return integer
             return $this->intAddressId;
         case 'FirstName':
             // Gets the value for strFirstName
             // @return string
             return $this->strFirstName;
         case 'LastName':
             // Gets the value for strLastName (Not Null)
             // @return string
             return $this->strLastName;
         case 'Title':
             // Gets the value for strTitle
             // @return string
             return $this->strTitle;
         case 'Email':
             // Gets the value for strEmail
             // @return string
             return $this->strEmail;
         case 'PhoneOffice':
             // Gets the value for strPhoneOffice
             // @return string
             return $this->strPhoneOffice;
         case 'PhoneHome':
             // Gets the value for strPhoneHome
             // @return string
             return $this->strPhoneHome;
         case 'PhoneMobile':
             // Gets the value for strPhoneMobile
             // @return string
             return $this->strPhoneMobile;
         case 'Fax':
             // Gets the value for strFax
             // @return string
             return $this->strFax;
         case 'Description':
             // Gets the value for strDescription
             // @return string
             return $this->strDescription;
         case 'CreatedBy':
             // Gets the value for intCreatedBy
             // @return integer
             return $this->intCreatedBy;
         case 'CreationDate':
             // Gets the value for dttCreationDate
             // @return QDateTime
             return $this->dttCreationDate;
         case 'ModifiedBy':
             // Gets the value for intModifiedBy
             // @return integer
             return $this->intModifiedBy;
         case 'ModifiedDate':
             // Gets the value for strModifiedDate (Read-Only Timestamp)
             // @return string
             return $this->strModifiedDate;
             ///////////////////
             // Member Objects
             ///////////////////
         ///////////////////
         // Member Objects
         ///////////////////
         case 'Company':
             // Gets the value for the Company object referenced by intCompanyId (Not Null)
             // @return Company
             try {
                 if (!$this->objCompany && !is_null($this->intCompanyId)) {
                     $this->objCompany = Company::Load($this->intCompanyId);
                 }
                 return $this->objCompany;
             } catch (QCallerException $objExc) {
                 $objExc->IncrementOffset();
                 throw $objExc;
             }
         case 'Address':
             // Gets the value for the Address object referenced by intAddressId
             // @return Address
             try {
                 if (!$this->objAddress && !is_null($this->intAddressId)) {
//.........这里部分代码省略.........
开发者ID:proxymoron,项目名称:tracmor,代码行数:101,代码来源:ContactGen.class.php

示例13: __get

 /**
  * Override method to perform a property "Get"
  * This will get the value of $strName
  *
  * @param string $strName Name of the property to get
  * @return mixed
  */
 public function __get($strName)
 {
     switch ($strName) {
         ///////////////////
         // Member Variables
         ///////////////////
         case 'AddressId':
             // Gets the value for intAddressId (Read-Only PK)
             // @return integer
             return $this->intAddressId;
         case 'CompanyId':
             // Gets the value for intCompanyId (Not Null)
             // @return integer
             return $this->intCompanyId;
         case 'ShortDescription':
             // Gets the value for strShortDescription (Not Null)
             // @return string
             return $this->strShortDescription;
         case 'CountryId':
             // Gets the value for intCountryId (Not Null)
             // @return integer
             return $this->intCountryId;
         case 'Address1':
             // Gets the value for strAddress1 (Not Null)
             // @return string
             return $this->strAddress1;
         case 'Address2':
             // Gets the value for strAddress2
             // @return string
             return $this->strAddress2;
         case 'City':
             // Gets the value for strCity (Not Null)
             // @return string
             return $this->strCity;
         case 'StateProvinceId':
             // Gets the value for intStateProvinceId
             // @return integer
             return $this->intStateProvinceId;
         case 'PostalCode':
             // Gets the value for strPostalCode (Not Null)
             // @return string
             return $this->strPostalCode;
         case 'CreatedBy':
             // Gets the value for intCreatedBy
             // @return integer
             return $this->intCreatedBy;
         case 'CreationDate':
             // Gets the value for dttCreationDate
             // @return QDateTime
             return $this->dttCreationDate;
         case 'ModifiedBy':
             // Gets the value for intModifiedBy
             // @return integer
             return $this->intModifiedBy;
         case 'ModifiedDate':
             // Gets the value for strModifiedDate (Read-Only Timestamp)
             // @return string
             return $this->strModifiedDate;
             ///////////////////
             // Member Objects
             ///////////////////
         ///////////////////
         // Member Objects
         ///////////////////
         case 'Company':
             // Gets the value for the Company object referenced by intCompanyId (Not Null)
             // @return Company
             try {
                 if (!$this->objCompany && !is_null($this->intCompanyId)) {
                     $this->objCompany = Company::Load($this->intCompanyId);
                 }
                 return $this->objCompany;
             } catch (QCallerException $objExc) {
                 $objExc->IncrementOffset();
                 throw $objExc;
             }
         case 'Country':
             // Gets the value for the Country object referenced by intCountryId (Not Null)
             // @return Country
             try {
                 if (!$this->objCountry && !is_null($this->intCountryId)) {
                     $this->objCountry = Country::Load($this->intCountryId);
                 }
                 return $this->objCountry;
             } catch (QCallerException $objExc) {
                 $objExc->IncrementOffset();
                 throw $objExc;
             }
         case 'StateProvince':
             // Gets the value for the StateProvince object referenced by intStateProvinceId
             // @return StateProvince
             try {
                 if (!$this->objStateProvince && !is_null($this->intStateProvinceId)) {
//.........这里部分代码省略.........
开发者ID:proxymoron,项目名称:tracmor,代码行数:101,代码来源:AddressGen.class.php

示例14: btnSave_Click

 protected function btnSave_Click()
 {
     $intCompanyId = $this->lstCompany->SelectedValue;
     $objCompany = Company::Load($intCompanyId);
     $intAccountId = $this->lstFedexAccount->SelectedValue;
     $objAccount = ShippingAccount::Load($intAccountId);
     if ($objCompany && !$objCompany->Telephone) {
         $this->lstCompany->Warning = "The Shipping/Receiving company must have a valid telephone number.";
     } elseif ($objAccount && (!$objAccount->AccessId || !$objAccount->AccessCode)) {
         $this->lstFedexAccount->Warning = "The FedEx Account must have a valid account number and meter number.";
     } else {
         // Altered $TracmorSettings __set() method so that just setting a value will save it in the database.
         QApplication::$TracmorSettings->CompanyId = $intCompanyId;
         QApplication::$TracmorSettings->FedexAccountId = $intAccountId;
         QApplication::$TracmorSettings->FedexGatewayUri = $this->txtFedexGatewayUri->Text;
         QApplication::$TracmorSettings->PackingListTerms = $this->fckPackingListTerms->Text;
         QApplication::$TracmorSettings->AutodetectTrackingNumbers = $this->chkAutoDetectTrackingNumbers->Checked;
         QApplication::$TracmorSettings->ReceiveToLastLocation = $this->chkReceiveToLastLocation->Checked;
         // Show saved notification
         $this->pnlSaveNotification->Display = true;
     }
 }
开发者ID:heshuai64,项目名称:einv2,代码行数:22,代码来源:shipping_account_list.php

示例15: __get

 /**
  * Override method to perform a property "Get"
  * This will get the value of $strName
  *
  * @param string $strName Name of the property to get
  * @return mixed
  */
 public function __get($strName)
 {
     switch ($strName) {
         ///////////////////
         // Member Variables
         ///////////////////
         case 'CompanyId':
             // Gets the value for intCompanyId (PK)
             // @return integer
             return $this->intCompanyId;
             ///////////////////
             // Member Objects
             ///////////////////
         ///////////////////
         // Member Objects
         ///////////////////
         case 'Company':
             // Gets the value for the Company object referenced by intCompanyId (PK)
             // @return Company
             try {
                 if (!$this->objCompany && !is_null($this->intCompanyId)) {
                     $this->objCompany = Company::Load($this->intCompanyId);
                 }
                 return $this->objCompany;
             } catch (QCallerException $objExc) {
                 $objExc->IncrementOffset();
                 throw $objExc;
             }
             ////////////////////////////
             // Virtual Object References (Many to Many and Reverse References)
             // (If restored via a "Many-to" expansion)
             ////////////////////////////
         ////////////////////////////
         // Virtual Object References (Many to Many and Reverse References)
         // (If restored via a "Many-to" expansion)
         ////////////////////////////
         case '__Restored':
             return $this->__blnRestored;
         default:
             try {
                 return parent::__get($strName);
             } catch (QCallerException $objExc) {
                 $objExc->IncrementOffset();
                 throw $objExc;
             }
     }
 }
开发者ID:proxymoron,项目名称:tracmor,代码行数:54,代码来源:CompanyCustomFieldHelperGen.class.php


注:本文中的Company::Load方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。