本文整理汇总了PHP中Company::LoadAll方法的典型用法代码示例。如果您正苦于以下问题:PHP Company::LoadAll方法的具体用法?PHP Company::LoadAll怎么用?PHP Company::LoadAll使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Company
的用法示例。
在下文中一共展示了Company::LoadAll方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: __construct
public function __construct($objParentObject, $strClosePanelMethod, $arrayShipmentId)
{
try {
parent::__construct($objParentObject);
} catch (QCallerException $objExc) {
$objExc->IncrementOffset();
throw $objExc;
}
$this->objCompanyArray = Company::LoadAll(QQ::Clause(QQ::OrderBy(QQN::Company()->ShortDescription)));
$this->arrShipmentToEdit = $arrayShipmentId;
$this->chkShipDate_Create();
$this->chkCourier_Create();
$this->chkToCompany_Create();
$this->chkFromCompany_Create();
$this->chkNote_Create();
$this->calShipDate_Create();
$this->lstCourier_Create();
$this->lstToCompany_Create();
$this->lstToContact_Create();
$this->lstToAddress_Create();
$this->lstFromCompany_Create();
$this->lstFromContact_Create();
$this->lstFromAddress_Create();
$this->txtNote_Create();
$this->lblWarning_Create();
$this->btnApply_Create();
$this->btnCancel_Create();
// Disable inputs
$this->calShipDate->Enabled = false;
$this->lstToCompany->Enabled = false;
$this->lstToContact->Enabled = false;
$this->lstToAddress->Enabled = false;
$this->lstFromCompany->Enabled = false;
$this->lstFromAddress->Enabled = false;
$this->lstFromContact->Enabled = false;
$this->lstCourier->Enabled = false;
$this->txtNote->Enabled = false;
// Load Custom Fields
$this->objCustomFieldArray = CustomField::LoadObjCustomFieldArray(EntityQtype::Shipment, false);
if ($this->objCustomFieldArray) {
$this->arrCustomFields = CustomField::CustomFieldControlsCreate($this->objCustomFieldArray, false, $this, true, true, false);
foreach ($this->arrCustomFields as $field) {
$field['input']->Enabled = false;
$this->arrCheckboxes[$field['input']->strControlId] = new QCheckBox($this, 'chk' . $field['input']->strControlId);
$this->arrCheckboxes[$field['input']->strControlId]->Checked = false;
$this->arrCheckboxes[$field['input']->strControlId]->AddAction(new QClickEvent(), new QJavaScriptAction("enableInput(this)"));
}
}
}
示例2: lstCompany_Create
protected function lstCompany_Create()
{
$this->lstCompany = new QListBox($this);
$this->lstCompany->Name = QApplication::Translate('Company');
$this->lstCompany->Required = true;
if (!$this->blnEditMode) {
$this->lstCompany->AddItem(QApplication::Translate('- Select One -'), null);
}
$objCompanyArray = Company::LoadAll(QQ::Clause(QQ::OrderBy(QQN::Company()->ShortDescription)));
if ($objCompanyArray) {
foreach ($objCompanyArray as $objCompany) {
$objListItem = new QListItem($objCompany->__toString(), $objCompany->CompanyId);
if ($objCompany->CompanyId == $this->intCompanyId) {
$objListItem->Selected = true;
}
$this->lstCompany->AddItem($objListItem);
}
}
}
示例3: lstFromCompany_Create
protected function lstFromCompany_Create()
{
$this->lstFromCompany = new QListBox($this);
$this->lstFromCompany->Name = QApplication::Translate('From Company');
$this->lstFromCompany->Required = true;
if (!$this->blnEditMode) {
$this->lstFromCompany->AddItem('- Select One -', null);
}
$objFromCompanyArray = Company::LoadAll(QQ::Clause(QQ::OrderBy(QQN::Company()->ShortDescription)));
if ($objFromCompanyArray) {
foreach ($objFromCompanyArray as $objFromCompany) {
$objListItem = new QListItem($objFromCompany->__toString(), $objFromCompany->CompanyId);
if ($this->objReceipt->FromCompany && $this->objReceipt->FromCompany->CompanyId == $objFromCompany->CompanyId) {
$objListItem->Selected = true;
}
$this->lstFromCompany->AddItem($objListItem);
}
}
$this->lstFromCompany->AddAction(new QChangeEvent(), new QAjaxAction('lstFromCompany_Select'));
$this->lstFromCompany->TabIndex = 1;
$this->intNextTabIndex++;
$this->lstFromCompany->Focus();
}
示例4: dtgCompany_Bind
protected function dtgCompany_Bind()
{
// Because we want to enable pagination AND sorting, we need to setup the $objClauses array to send to LoadAll()
// Remember! We need to first set the TotalItemCount, which will affect the calcuation of LimitClause below
$this->dtgCompany->TotalItemCount = Company::CountAll();
// Setup the $objClauses Array
$objClauses = array();
// If a column is selected to be sorted, and if that column has a OrderByClause set on it, then let's add
// the OrderByClause to the $objClauses array
if ($objClause = $this->dtgCompany->OrderByClause) {
array_push($objClauses, $objClause);
}
// Add the LimitClause information, as well
if ($objClause = $this->dtgCompany->LimitClause) {
array_push($objClauses, $objClause);
}
// Set the DataSource to be the array of all Company objects, given the clauses above
$this->dtgCompany->DataSource = Company::LoadAll($objClauses);
}
示例5: lstToCompany_Create
protected function lstToCompany_Create()
{
$this->lstToCompany = new QListBox($this);
$this->lstToCompany->Name = QApplication::Translate('To Company');
$this->lstToCompany->Required = true;
if (!$this->blnEditMode) {
$this->lstToCompany->AddItem(QApplication::Translate('- Select One -'), null);
}
$objToCompanyArray = Company::LoadAll();
if ($objToCompanyArray) {
foreach ($objToCompanyArray as $objToCompany) {
$objListItem = new QListItem($objToCompany->__toString(), $objToCompany->CompanyId);
if ($this->objShipment->ToCompany && $this->objShipment->ToCompany->CompanyId == $objToCompany->CompanyId) {
$objListItem->Selected = true;
}
$this->lstToCompany->AddItem($objListItem);
}
}
}
示例6: btnNext_Click
//.........这里部分代码省略.........
$lstDefaultValue->Width = 200;
$lstDefaultValue->Display = false;
$this->lstMapDefaultValueArray[] = $lstDefaultValue;
$dtpDate = new QDateTimePicker($this);
$dtpDate->DateTimePickerType = QDateTimePickerType::Date;
$dtpDate->DateTimePickerFormat = QDateTimePickerFormat::MonthDayYear;
$dtpDate->Display = false;
$this->dtpDateArray[] = $dtpDate;
if (array_key_exists($i, $this->lstMapHeaderArray)) {
$this->lstTramorField_Change(null, $this->lstMapHeaderArray[$i]->ControlId, null);
}
}
$this->arrMapFields[$i]['row1'] = $strFirstRowArray[$i];
}
$this->btnNext->Text = "Import Now";
fclose($file_skipped);
// Create Add Field button
$btnAddField = new QButton($this);
$btnAddField->Text = "Add Field";
$btnAddField->AddAction(new QClickEvent(), new QServerAction('btnAddField_Click'));
$btnAddField->AddAction(new QEnterKeyEvent(), new QServerAction('btnAddField_Click'));
$btnAddField->AddAction(new QEnterKeyEvent(), new QTerminateAction());
$this->lstMapHeaderArray[] = $btnAddField;
}
}
}
} elseif ($this->intStep == 2) {
// Step 2 complete
$blnError = false;
$blnCompany = false;
$blnLastName = false;
$blnContactId = false;
$this->intCompanyArray = array();
foreach (Company::LoadAll() as $objCompany) {
$this->intCompanyArray[strtolower($objCompany->ShortDescription)] = $objCompany->CompanyId;
}
for ($i = 0; $i < count($this->lstMapHeaderArray) - 1; $i++) {
$lstMapHeader = $this->lstMapHeaderArray[$i];
$strSelectedValue = strtolower($lstMapHeader->SelectedValue);
if ($strSelectedValue == "company") {
$blnCompany = true;
}
if ($strSelectedValue == "last name") {
$blnLastName = true;
} elseif ($strSelectedValue == "id") {
$blnContactId = true;
}
}
if ($this->lstMapDefaultValueArray) {
// Checking errors for required Default Value text fields
foreach ($this->lstMapDefaultValueArray as $lstDefault) {
if ($lstDefault->Display && $lstDefault->Required && !$lstDefault->SelectedValue) {
$lstDefault->Warning = "You must select one default value.";
$blnError = true;
break;
} else {
$blnError = false;
$lstDefault->Warning = "";
}
}
}
if ($this->txtMapDefaultValueArray) {
// Checking errors for required Default Value lst fields
foreach ($this->txtMapDefaultValueArray as $txtDefault) {
if ($txtDefault->Display && $txtDefault->Required && !$txtDefault->Text) {
$txtDefault->Warning = "You must enter default value.";
示例7: Refresh
/**
* Refresh this MetaControl with Data from the local Shipment object.
* @param boolean $blnReload reload Shipment from the database
* @return void
*/
public function Refresh($blnReload = false)
{
if ($blnReload) {
$this->objShipment->Reload();
}
if ($this->lblShipmentId) {
if ($this->blnEditMode) {
$this->lblShipmentId->Text = $this->objShipment->ShipmentId;
}
}
if ($this->txtShipmentNumber) {
$this->txtShipmentNumber->Text = $this->objShipment->ShipmentNumber;
}
if ($this->lblShipmentNumber) {
$this->lblShipmentNumber->Text = $this->objShipment->ShipmentNumber;
}
if ($this->lstTransaction) {
$this->lstTransaction->RemoveAllItems();
if (!$this->blnEditMode) {
$this->lstTransaction->AddItem(QApplication::Translate('- Select One -'), null);
}
$objTransactionArray = Transaction::LoadAll();
if ($objTransactionArray) {
foreach ($objTransactionArray as $objTransaction) {
$objListItem = new QListItem($objTransaction->__toString(), $objTransaction->TransactionId);
if ($this->objShipment->Transaction && $this->objShipment->Transaction->TransactionId == $objTransaction->TransactionId) {
$objListItem->Selected = true;
}
$this->lstTransaction->AddItem($objListItem);
}
}
}
if ($this->lblTransactionId) {
$this->lblTransactionId->Text = $this->objShipment->Transaction ? $this->objShipment->Transaction->__toString() : null;
}
if ($this->lstFromCompany) {
$this->lstFromCompany->RemoveAllItems();
if (!$this->blnEditMode) {
$this->lstFromCompany->AddItem(QApplication::Translate('- Select One -'), null);
}
$objFromCompanyArray = Company::LoadAll();
if ($objFromCompanyArray) {
foreach ($objFromCompanyArray as $objFromCompany) {
$objListItem = new QListItem($objFromCompany->__toString(), $objFromCompany->CompanyId);
if ($this->objShipment->FromCompany && $this->objShipment->FromCompany->CompanyId == $objFromCompany->CompanyId) {
$objListItem->Selected = true;
}
$this->lstFromCompany->AddItem($objListItem);
}
}
}
if ($this->lblFromCompanyId) {
$this->lblFromCompanyId->Text = $this->objShipment->FromCompany ? $this->objShipment->FromCompany->__toString() : null;
}
if ($this->lstFromContact) {
$this->lstFromContact->RemoveAllItems();
if (!$this->blnEditMode) {
$this->lstFromContact->AddItem(QApplication::Translate('- Select One -'), null);
}
$objFromContactArray = Contact::LoadAll();
if ($objFromContactArray) {
foreach ($objFromContactArray as $objFromContact) {
$objListItem = new QListItem($objFromContact->__toString(), $objFromContact->ContactId);
if ($this->objShipment->FromContact && $this->objShipment->FromContact->ContactId == $objFromContact->ContactId) {
$objListItem->Selected = true;
}
$this->lstFromContact->AddItem($objListItem);
}
}
}
if ($this->lblFromContactId) {
$this->lblFromContactId->Text = $this->objShipment->FromContact ? $this->objShipment->FromContact->__toString() : null;
}
if ($this->lstFromAddress) {
$this->lstFromAddress->RemoveAllItems();
if (!$this->blnEditMode) {
$this->lstFromAddress->AddItem(QApplication::Translate('- Select One -'), null);
}
$objFromAddressArray = Address::LoadAll();
if ($objFromAddressArray) {
foreach ($objFromAddressArray as $objFromAddress) {
$objListItem = new QListItem($objFromAddress->__toString(), $objFromAddress->AddressId);
if ($this->objShipment->FromAddress && $this->objShipment->FromAddress->AddressId == $objFromAddress->AddressId) {
$objListItem->Selected = true;
}
$this->lstFromAddress->AddItem($objListItem);
}
}
}
if ($this->lblFromAddressId) {
$this->lblFromAddressId->Text = $this->objShipment->FromAddress ? $this->objShipment->FromAddress->__toString() : null;
}
if ($this->lstToCompany) {
$this->lstToCompany->RemoveAllItems();
if (!$this->blnEditMode) {
//.........这里部分代码省略.........
示例8: Form_Create
protected function Form_Create()
{
// check rigths for the Inventory to Ship
$this->blnShowInventory = true;
$objRoleModule = RoleModule::LoadByRoleIdModuleId(QApplication::$objUserAccount->RoleId, 3);
if ($objRoleModule->AccessFlag) {
$objRoleModuleAuthorization = RoleModuleAuthorization::LoadByRoleModuleIdAuthorizationId($objRoleModule->RoleModuleId, 2);
if ($objRoleModuleAuthorization->AuthorizationLevelId == 3) {
$this->blnShowInventory = false;
}
} else {
$this->blnShowInventory = false;
}
// Call SetupShipment to either Load/Edit Existing or Create New
$this->SetupShipment();
$this->objCompanyArray = Company::LoadAll(QQ::Clause(QQ::OrderBy(QQN::Company()->ShortDescription)));
// Create the Header Menu
$this->ctlHeaderMenu_Create();
// Create the Shortcut Menu
$this->ctlShortcutMenu_Create();
// Packing List Link
$this->lblPackingListLink_Create();
// Shipping Labels
$this->lblShipmentNumber_Create();
$this->lblHeaderShipment_Create();
$this->lblShipDate_Create();
$this->lblFromCompany_Create();
$this->lblFromContact_Create();
$this->lblFromAddress_Create();
$this->lstToCompany_Create();
$this->lblNewToCompany_Create();
$this->lstToContact_Create();
$this->lblNewToContact_Create();
$this->lstToAddress_Create();
$this->lblNewToAddress_Create();
$this->lblFromAddressFull_Create();
$this->lblToCompany_Create();
$this->lblToContact_Create();
$this->lblToAddress_Create();
$this->lblToAddressFull_Create();
$this->lblCourier_Create();
$this->pnlNote_Create();
$this->lblTrackingNumber_Create();
// Shipping Inputs
$this->dlgExchange_Create();
$this->dlgDueDate_Create();
$this->calShipDate_Create();
$this->lstFromCompany_Create();
$this->lblNewFromCompany_Create();
$this->lstFromContact_Create();
$this->lblNewFromContact_Create();
$this->lstFromAddress_Create();
$this->lblNewFromAddress_Create();
if (QApplication::$TracmorSettings->CustomShipmentNumbers) {
$this->txtShipmentNumber_Create();
}
$this->lstCourier_Create();
$this->txtNote_Create();
$this->txtNewAssetCode_Create();
if ($this->blnShowInventory) {
$this->txtNewInventoryModelCode_Create();
$this->btnLookup_Create();
$this->ctlInventorySearchTool_Create();
$this->lstSourceLocation_Create();
$this->txtQuantity_Create();
$this->btnAddInventory_Create();
}
$this->txtTrackingNumber_Create();
//$this->lblAdvanced_Create();
$this->txtReceiptAssetCode_Create();
$this->chkAutoGenerateAssetCode_Create();
$this->dtpScheduleReceiptDueDate_Create();
$this->rblAssetType_Create();
$this->chkScheduleReceipt_Create();
$this->btnAddAsset_Create();
$this->ctlAssetSearchTool_Create();
$this->btnSaveExchange_Create();
$this->btnCancelExchange_Create();
$this->btnSaveDueDate_Create();
$this->btnCancelDueDate_Create();
$this->pnlAttachments_Create();
// Create all custom asset fields
$this->customFields_Create();
//Set display logic of Built-In Fields
$this->UpdateBuiltInFields();
$this->UpdateAddressAccess();
$this->UpdateCompanyAccess();
$this->UpdateContactAccess();
// New entities Dialog
$this->dlgNew_Create();
if (!$this->objShipment->ShippedFlag) {
// Shipping Buttons
$this->btnDelete_Create();
}
$this->btnSave_Create();
$this->btnCancel_Create();
$this->btnEdit_Create();
$this->atcAttach_Create();
// Complete Shipment Buttons
$this->btnCompleteShipment_Create();
//.........这里部分代码省略.........
示例9: lstCompany_Create
protected function lstCompany_Create()
{
$this->lstCompany = new QListBox($this);
$this->lstCompany->Name = QApplication::Translate('Company');
$this->lstCompany->Required = true;
if (!$this->blnEditMode) {
$this->lstCompany->AddItem('- Select One -', null);
//$this->lstCompany->AddItem('New Company', -1, false);
}
$objCompanyArray = Company::LoadAll(QQ::Clause(QQ::OrderBy(QQN::Company()->ShortDescription)));
if ($objCompanyArray) {
foreach ($objCompanyArray as $objCompany) {
$objListItem = new QListItem($objCompany->__toString(), $objCompany->CompanyId);
if ($this->objContact->Company && $this->objContact->Company->CompanyId == $objCompany->CompanyId) {
$objListItem->Selected = true;
}
$this->lstCompany->AddItem($objListItem);
}
}
$this->lstCompany->AddAction(new QChangeEvent(), new QAjaxAction('lstCompany_Select'));
QApplication::ExecuteJavaScript(sprintf("document.getElementById('%s').focus()", $this->lstCompany->ControlId));
$this->lstCompany->TabIndex = $this->intTabIndex++;
}
示例10: lstCompany_Create
protected function lstCompany_Create()
{
$this->lstCompany = new QListBox($this);
$this->lstCompany->Name = QApplication::Translate('Default Shipping & Receiving Company:');
$this->lstCompany->Required = false;
$this->lstCompany->AddItem('- Select One -', null);
$objCompanyArray = Company::LoadAll(QQ::Clause(QQ::OrderBy(QQN::Company()->ShortDescription)));
if ($objCompanyArray) {
foreach ($objCompanyArray as $objCompany) {
$objListItem = new QListItem($objCompany->__toString(), $objCompany->CompanyId);
if (QApplication::$TracmorSettings->CompanyId && QApplication::$TracmorSettings->CompanyId == $objCompany->CompanyId) {
$objListItem->Selected = true;
}
$this->lstCompany->AddItem($objListItem);
}
}
$this->lstCompany->AddAction(new QChangeEvent(), new QAjaxAction('lstCompany_Change'));
$this->lstCompany->AddAction(new QEnterKeyEvent(), new QAjaxAction('btnSave_Click'));
$this->lstCompany->AddAction(new QEnterKeyEvent(), new QTerminateAction());
}
示例11: Refresh
/**
* Refresh this MetaControl with Data from the local Contact object.
* @param boolean $blnReload reload Contact from the database
* @return void
*/
public function Refresh($blnReload = false)
{
if ($blnReload) {
$this->objContact->Reload();
}
if ($this->lblContactId) {
if ($this->blnEditMode) {
$this->lblContactId->Text = $this->objContact->ContactId;
}
}
if ($this->lstCompany) {
$this->lstCompany->RemoveAllItems();
if (!$this->blnEditMode) {
$this->lstCompany->AddItem(QApplication::Translate('- Select One -'), null);
}
$objCompanyArray = Company::LoadAll();
if ($objCompanyArray) {
foreach ($objCompanyArray as $objCompany) {
$objListItem = new QListItem($objCompany->__toString(), $objCompany->CompanyId);
if ($this->objContact->Company && $this->objContact->Company->CompanyId == $objCompany->CompanyId) {
$objListItem->Selected = true;
}
$this->lstCompany->AddItem($objListItem);
}
}
}
if ($this->lblCompanyId) {
$this->lblCompanyId->Text = $this->objContact->Company ? $this->objContact->Company->__toString() : null;
}
if ($this->lstAddress) {
$this->lstAddress->RemoveAllItems();
$this->lstAddress->AddItem(QApplication::Translate('- Select One -'), null);
$objAddressArray = Address::LoadAll();
if ($objAddressArray) {
foreach ($objAddressArray as $objAddress) {
$objListItem = new QListItem($objAddress->__toString(), $objAddress->AddressId);
if ($this->objContact->Address && $this->objContact->Address->AddressId == $objAddress->AddressId) {
$objListItem->Selected = true;
}
$this->lstAddress->AddItem($objListItem);
}
}
}
if ($this->lblAddressId) {
$this->lblAddressId->Text = $this->objContact->Address ? $this->objContact->Address->__toString() : null;
}
if ($this->txtFirstName) {
$this->txtFirstName->Text = $this->objContact->FirstName;
}
if ($this->lblFirstName) {
$this->lblFirstName->Text = $this->objContact->FirstName;
}
if ($this->txtLastName) {
$this->txtLastName->Text = $this->objContact->LastName;
}
if ($this->lblLastName) {
$this->lblLastName->Text = $this->objContact->LastName;
}
if ($this->txtTitle) {
$this->txtTitle->Text = $this->objContact->Title;
}
if ($this->lblTitle) {
$this->lblTitle->Text = $this->objContact->Title;
}
if ($this->txtEmail) {
$this->txtEmail->Text = $this->objContact->Email;
}
if ($this->lblEmail) {
$this->lblEmail->Text = $this->objContact->Email;
}
if ($this->txtPhoneOffice) {
$this->txtPhoneOffice->Text = $this->objContact->PhoneOffice;
}
if ($this->lblPhoneOffice) {
$this->lblPhoneOffice->Text = $this->objContact->PhoneOffice;
}
if ($this->txtPhoneHome) {
$this->txtPhoneHome->Text = $this->objContact->PhoneHome;
}
if ($this->lblPhoneHome) {
$this->lblPhoneHome->Text = $this->objContact->PhoneHome;
}
if ($this->txtPhoneMobile) {
$this->txtPhoneMobile->Text = $this->objContact->PhoneMobile;
}
if ($this->lblPhoneMobile) {
$this->lblPhoneMobile->Text = $this->objContact->PhoneMobile;
}
if ($this->txtFax) {
$this->txtFax->Text = $this->objContact->Fax;
}
if ($this->lblFax) {
$this->lblFax->Text = $this->objContact->Fax;
}
if ($this->txtDescription) {
//.........这里部分代码省略.........
示例12: Refresh
/**
* Refresh this MetaControl with Data from the local Address object.
* @param boolean $blnReload reload Address from the database
* @return void
*/
public function Refresh($blnReload = false)
{
if ($blnReload) {
$this->objAddress->Reload();
}
if ($this->lblAddressId) {
if ($this->blnEditMode) {
$this->lblAddressId->Text = $this->objAddress->AddressId;
}
}
if ($this->lstCompany) {
$this->lstCompany->RemoveAllItems();
if (!$this->blnEditMode) {
$this->lstCompany->AddItem(QApplication::Translate('- Select One -'), null);
}
$objCompanyArray = Company::LoadAll();
if ($objCompanyArray) {
foreach ($objCompanyArray as $objCompany) {
$objListItem = new QListItem($objCompany->__toString(), $objCompany->CompanyId);
if ($this->objAddress->Company && $this->objAddress->Company->CompanyId == $objCompany->CompanyId) {
$objListItem->Selected = true;
}
$this->lstCompany->AddItem($objListItem);
}
}
}
if ($this->lblCompanyId) {
$this->lblCompanyId->Text = $this->objAddress->Company ? $this->objAddress->Company->__toString() : null;
}
if ($this->txtShortDescription) {
$this->txtShortDescription->Text = $this->objAddress->ShortDescription;
}
if ($this->lblShortDescription) {
$this->lblShortDescription->Text = $this->objAddress->ShortDescription;
}
if ($this->lstCountry) {
$this->lstCountry->RemoveAllItems();
if (!$this->blnEditMode) {
$this->lstCountry->AddItem(QApplication::Translate('- Select One -'), null);
}
$objCountryArray = Country::LoadAll();
if ($objCountryArray) {
foreach ($objCountryArray as $objCountry) {
$objListItem = new QListItem($objCountry->__toString(), $objCountry->CountryId);
if ($this->objAddress->Country && $this->objAddress->Country->CountryId == $objCountry->CountryId) {
$objListItem->Selected = true;
}
$this->lstCountry->AddItem($objListItem);
}
}
}
if ($this->lblCountryId) {
$this->lblCountryId->Text = $this->objAddress->Country ? $this->objAddress->Country->__toString() : null;
}
if ($this->txtAddress1) {
$this->txtAddress1->Text = $this->objAddress->Address1;
}
if ($this->lblAddress1) {
$this->lblAddress1->Text = $this->objAddress->Address1;
}
if ($this->txtAddress2) {
$this->txtAddress2->Text = $this->objAddress->Address2;
}
if ($this->lblAddress2) {
$this->lblAddress2->Text = $this->objAddress->Address2;
}
if ($this->txtCity) {
$this->txtCity->Text = $this->objAddress->City;
}
if ($this->lblCity) {
$this->lblCity->Text = $this->objAddress->City;
}
if ($this->lstStateProvince) {
$this->lstStateProvince->RemoveAllItems();
$this->lstStateProvince->AddItem(QApplication::Translate('- Select One -'), null);
$objStateProvinceArray = StateProvince::LoadAll();
if ($objStateProvinceArray) {
foreach ($objStateProvinceArray as $objStateProvince) {
$objListItem = new QListItem($objStateProvince->__toString(), $objStateProvince->StateProvinceId);
if ($this->objAddress->StateProvince && $this->objAddress->StateProvince->StateProvinceId == $objStateProvince->StateProvinceId) {
$objListItem->Selected = true;
}
$this->lstStateProvince->AddItem($objListItem);
}
}
}
if ($this->lblStateProvinceId) {
$this->lblStateProvinceId->Text = $this->objAddress->StateProvince ? $this->objAddress->StateProvince->__toString() : null;
}
if ($this->txtPostalCode) {
$this->txtPostalCode->Text = $this->objAddress->PostalCode;
}
if ($this->lblPostalCode) {
$this->lblPostalCode->Text = $this->objAddress->PostalCode;
}
//.........这里部分代码省略.........
示例13: Refresh
/**
* Refresh this MetaControl with Data from the local CompanyCustomFieldHelper object.
* @param boolean $blnReload reload CompanyCustomFieldHelper from the database
* @return void
*/
public function Refresh($blnReload = false)
{
if ($blnReload) {
$this->objCompanyCustomFieldHelper->Reload();
}
if ($this->lstCompany) {
$this->lstCompany->RemoveAllItems();
if (!$this->blnEditMode) {
$this->lstCompany->AddItem(QApplication::Translate('- Select One -'), null);
}
$objCompanyArray = Company::LoadAll();
if ($objCompanyArray) {
foreach ($objCompanyArray as $objCompany) {
$objListItem = new QListItem($objCompany->__toString(), $objCompany->CompanyId);
if ($this->objCompanyCustomFieldHelper->Company && $this->objCompanyCustomFieldHelper->Company->CompanyId == $objCompany->CompanyId) {
$objListItem->Selected = true;
}
$this->lstCompany->AddItem($objListItem);
}
}
}
if ($this->lblCompanyId) {
$this->lblCompanyId->Text = $this->objCompanyCustomFieldHelper->Company ? $this->objCompanyCustomFieldHelper->Company->__toString() : null;
}
}
示例14: dtgCompany_Bind
public function dtgCompany_Bind()
{
// Get Total Count b/c of Pagination
$this->dtgCompany->TotalItemCount = Company::CountAll();
$objClauses = array();
if ($objClause = $this->dtgCompany->OrderByClause) {
array_push($objClauses, $objClause);
}
if ($objClause = $this->dtgCompany->LimitClause) {
array_push($objClauses, $objClause);
}
$this->dtgCompany->DataSource = Company::LoadAll($objClauses);
}
示例15: Form_Create
protected function Form_Create()
{
// Call SetupShipment to either Load/Edit Existing or Create New
$this->SetupShipment();
// If the courier is FedEx, load the FedexShipment object
if ($this->blnEditMode) {
if ($this->objShipment->CourierId === 1) {
$this->objFedexShipment = FedexShipment::LoadByShipmentId($this->objShipment->ShipmentId);
}
}
$this->objCompanyArray = Company::LoadAll(QQ::Clause(QQ::OrderBy(QQN::Company()->ShortDescription)));
// Create the Header Menu
$this->ctlHeaderMenu_Create();
// Create the Shortcut Menu
$this->ctlShortcutMenu_Create();
// FedEx Shipment Panel
$this->pnlFedExShipment_Create();
// Packing List Link
$this->lblPackingListLink_Create();
$this->lblFedexShippingLabelLink_Create();
// Shipping Labels
$this->lblShipmentNumber_Create();
$this->lblHeaderShipment_Create();
// $this->lblHeaderCompleteShipment_Create();
$this->lblShipDate_Create();
$this->lblFromCompany_Create();
$this->lblFromContact_Create();
$this->lblFromAddress_Create();
$this->lblFromAddressFull_Create();
$this->lblToCompany_Create();
$this->lblToContact_Create();
$this->lblToAddress_Create();
$this->lblToAddressFull_Create();
$this->lblCourier_Create();
$this->lblToPhone_Create();
$this->lblBillTransportationTo_Create();
$this->lblReference_Create();
$this->lblFedexNotifySenderEmail_Create();
$this->lblFedexNotifyRecipientEmail_Create();
$this->lblFedexNotifyOtherEmail_Create();
$this->lblHoldAtLocationAddress_Create();
$this->lblHoldAtLocationCity_Create();
$this->lblHoldAtLocationState_Create();
$this->lblHoldAtLocationPostalCode_Create();
$this->pnlNote_Create();
$this->lblTrackingNumber_Create();
$this->lblSenderLabel_Create();
$this->lblPayerAccount_Create();
$this->lblFxServiceType_Create();
$this->lblPackageType_Create();
$this->lblPackageWeight_Create();
$this->lblPackageLength_Create();
$this->lblPackageWidth_Create();
$this->lblPackageHeight_Create();
$this->lblValue_Create();
$this->lblWeightUnit_Create();
$this->lblLengthUnit_Create();
$this->lblCurrencyUnit_Create();
// Shipping Inputs
$this->dlgExchange_Create();
$this->dlgDueDate_Create();
$this->calShipDate_Create();
$this->lstFromCompany_Create();
$this->lblNewFromCompany_Create();
$this->lstFromContact_Create();
$this->lblNewFromContact_Create();
$this->lstFromAddress_Create();
$this->lblNewFromAddress_Create();
$this->lstToCompany_Create();
$this->lblNewToCompany_Create();
$this->lstToContact_Create();
$this->lblNewToContact_Create();
$this->txtToPhone_Create();
$this->lstBillTransportationTo_Create();
$this->lstShippingAccount_Create();
$this->txtReference_Create();
$this->txtFedexNotifySenderEmail_Create();
$this->txtFedexNotifyRecipientEmail_Create();
$this->txtFedexNotifyOtherEmail_Create();
$this->chkFedexNotifySenderShipFlag_Create();
$this->chkFedexNotifySenderExceptionFlag_Create();
$this->chkFedexNotifySenderDeliveryFlag_Create();
$this->chkFedexNotifyRecipientShipFlag_Create();
$this->chkFedexNotifyRecipientExceptionFlag_Create();
$this->chkFedexNotifyRecipientDeliveryFlag_Create();
$this->chkFedexNotifyOtherShipFlag_Create();
$this->chkFedexNotifyOtherExceptionFlag_Create();
$this->chkFedexNotifyOtherDeliveryFlag_Create();
$this->lstFxServiceType_Create();
$this->txtRecipientThirdPartyAccount_Create();
$this->lstPackageType_Create();
$this->txtPackageWeight_Create();
$this->lstWeightUnit_Create();
$this->txtPackageLength_Create();
$this->txtPackageWidth_Create();
$this->txtPackageHeight_Create();
$this->lstLengthUnit_Create();
$this->txtValue_Create();
$this->lstCurrencyUnit_Create();
$this->chkSaturdayDeliveryFlag_Create();
//.........这里部分代码省略.........