예제 #1
0
 protected function UpdateAddressLabels()
 {
     if ($this->blnEditMode) {
         $this->lblHeaderAddress->Text = $this->objAddress->ShortDescription;
     } else {
         $this->lblHeaderAddress->Text = 'New Address';
     }
     if ($this->objAddress->CompanyId) {
         $this->lblCompany->Text = $this->objAddress->Company->ShortDescription;
     }
     $this->lblShortDescription->Text = $this->objAddress->ShortDescription;
     $this->lblAddress1->Text = $this->objAddress->Address1;
     $this->lblAddress2->Text = $this->objAddress->Address2;
     $this->lblCity->Text = $this->objAddress->City;
     if ($this->objAddress->StateProvince) {
         $this->lblStateProvince->Text = $this->objAddress->StateProvince->__toString();
     }
     if ($this->objAddress->Country) {
         $this->lblCountry->Text = $this->objAddress->Country->__toString();
     }
     $this->lblPostalCode->Text = $this->objAddress->PostalCode;
     if ($this->objAddress->CreationDate) {
         $this->lblCreationDate->Text = $this->objAddress->CreationDate->PHPDate('Y-m-d H:i:s') . ' by ' . $this->objAddress->CreatedByObject->__toStringFullName();
     }
     if ($this->objAddress->ModifiedDate) {
         $this->lblModifiedDate->Text = $this->objAddress->ModifiedDate . ' by ' . $this->objAddress->ModifiedByObject->__toStringFullName();
     } else {
         $this->lblModifiedDate->Text = '';
     }
     // Update custom labels
     if ($this->arrCustomFields) {
         CustomField::UpdateLabels($this->arrCustomFields);
     }
 }
예제 #2
0
 protected function UpdateReceiptLabels()
 {
     $this->lblFromCompany->Text = $this->objReceipt->FromCompany->__toStringWithLink();
     $this->lblFromContact->Text = $this->objReceipt->FromContact->__toStringWithLink();
     $this->lblToContact->Text = $this->objReceipt->ToContact->__toStringWithLink();
     $this->lblToAddress->Text = $this->objReceipt->ToAddress->__toStringWithLink();
     if (QApplication::$TracmorSettings->CustomReceiptNumbers) {
         $this->lblReceiptNumber->Text = $this->objReceipt->ReceiptNumber;
     }
     $this->pnlNote->Text = nl2br($this->objReceipt->Transaction->Note);
     $this->lblDueDate->Text = $this->objReceipt->DueDate ? $this->objReceipt->DueDate->__toString() : '';
     $this->lblReceiptDate->Text = $this->objReceipt->ReceiptDate ? $this->objReceipt->ReceiptDate->__toString() : '';
     // Update custom labels
     if ($this->arrCustomFields) {
         CustomField::UpdateLabels($this->arrCustomFields);
     }
 }
예제 #3
0
 protected function UpdateCompanyLabels()
 {
     if ($this->blnEditMode) {
         $this->lblHeaderCompanyName->Text = $this->objCompany->__toString();
     } else {
         $this->lblHeaderCompanyName->Text = 'New Company';
     }
     $this->lblShortDescription->Text = $this->objCompany->ShortDescription;
     $this->lblWebsite->Text = $this->objCompany->Website;
     $this->lblEmail->Text = $this->objCompany->Email;
     $this->pnlLongDescription->Text = nl2br($this->objCompany->LongDescription);
     if ($this->objCompany->Address) {
         $this->lblAddress->Text = $this->objCompany->Address->__toString();
     } else {
         $this->lblAddress->Text = "";
     }
     $this->lblTelephone->Text = $this->objCompany->Telephone;
     $this->lblFax->Text = $this->objCompany->Fax;
     if ($this->objCompany->CreationDate) {
         $this->lblCreationDate->Text = $this->objCompany->CreationDate->PHPDate('Y-m-d H:i:s') . ' by ' . $this->objCompany->CreatedByObject->__toStringFullName();
     }
     if ($this->objCompany->ModifiedDate) {
         $this->lblModifiedDate->Text = $this->objCompany->ModifiedDate . ' by ' . $this->objCompany->ModifiedByObject->__toStringFullName();
     }
     // Update custom labels
     if ($this->arrCustomFields) {
         CustomField::UpdateLabels($this->arrCustomFields);
     }
 }
예제 #4
0
 public function UpdateAssetLabels()
 {
     if ($this->objAsset->AssetModelId) {
         $this->lblAssetModel->Text = $this->objAsset->AssetModel->__toStringWithLink();
         $this->lblAssetModelCode->Text = $this->objAsset->AssetModel->AssetModelCode;
         if ($this->objAsset->AssetModel->CategoryId) {
             $this->lblCategory->Text = $this->objAsset->AssetModel->Category->__toString();
         }
         if ($this->objAsset->AssetModel->ManufacturerId) {
             $this->lblManufacturer->Text = $this->objAsset->AssetModel->Manufacturer->__toString();
         }
     }
     if ($this->objAsset->LocationId) {
         $this->lblLocation->Text = $this->objAsset->Location->__toString();
     }
     $this->lblAssetCode->Text = $this->objAsset->AssetCode;
     $this->lblHeaderAssetCode->Text = $this->objAsset->AssetCode;
     if ($this->objAsset->ParentAssetId) {
         $this->lblParentAssetCode->Text = $this->objAsset->ParentAsset->__toStringWithLink("bluelink");
     } else {
         $this->lblParentAssetCode->Text = "";
     }
     if ($this->objAsset->ModifiedDate) {
         $this->lblModifiedDate->Text = $this->objAsset->ModifiedDate . ' by ' . $this->objAsset->ModifiedByObject->__toStringFullName();
     }
     // Update custom labels
     if ($this->arrCustomFields) {
         CustomField::UpdateLabels($this->arrCustomFields);
     }
 }
예제 #5
0
 protected function UpdateShipmentLabels()
 {
     $this->lblShipDate->Text = $this->objShipment->ShipDate->__toString();
     $this->lblFromCompany->Text = $this->objShipment->FromCompany->__toStringWithLink();
     $this->lblFromContact->Text = $this->objShipment->FromContact->__toStringWithLink();
     $this->lblFromAddress->Text = $this->objShipment->FromAddress->__toStringWithLink();
     $this->lblToCompany->Text = $this->objShipment->ToCompany->__toStringWithLink();
     $this->lblToContact->Text = $this->objShipment->ToContact->__toStringWithLink();
     $this->lblToAddress->Text = $this->objShipment->ToAddress->__toStringWithLink();
     if (QApplication::$TracmorSettings->CustomShipmentNumbers) {
         $this->lblShipmentNumber->Text = $this->objShipment->ShipmentNumber;
     }
     $this->lblCourier->Text = $this->objShipment->CourierId ? $this->objShipment->Courier->__toString() : "Other";
     $this->lblTrackingNumber->Text = $this->objShipment->__toStringTrackingNumber();
     $this->pnlNote->Text = nl2br($this->objShipment->Transaction->Note);
     if ($this->arrCustomFields) {
         CustomField::UpdateLabels($this->arrCustomFields);
     }
 }
예제 #6
0
 protected function UpdateLabels()
 {
     $this->lblShortDescription->Text = $this->txtShortDescription->Text;
     $this->lblAssetModelCode->Text = $this->txtAssetModelCode->Text;
     $this->lblCategory->Text = $this->lstCategory->SelectedName;
     $this->lblManufacturer->Text = $this->lstManufacturer->SelectedName;
     $this->pnlLongDescription->Text = nl2br($this->txtLongDescription->Text);
     $this->lblImage->Text = $this->ifcImage->GetDisplayHtml($this->objAssetModel->ImagePath);
     // Update custom labels
     if ($this->arrCustomFields) {
         CustomField::UpdateLabels($this->arrCustomFields);
     }
     // From AssetModelEditFormBase, this loads an Asset Model object or creates a new one
     $this->SetupAssetModel();
 }
예제 #7
0
 protected function UpdateContactLabels()
 {
     if ($this->blnEditMode) {
         $this->lblHeaderContact->Text = sprintf('%s %s', $this->objContact->FirstName, $this->objContact->LastName);
     } else {
         $this->lblHeaderContact->Text = 'New Contact';
     }
     if ($this->objContact->CompanyId) {
         $this->lblCompany->Text = $this->objContact->Company->__toStringWithLink();
     }
     $this->lblFirstName->Text = $this->objContact->FirstName;
     $this->lblLastName->Text = $this->objContact->LastName;
     $this->lblTitle->Text = $this->objContact->Title;
     $this->lblEmail->Text = $this->objContact->Email;
     if ($this->objContact->AddressId) {
         $this->lblAddress->Text = $this->objContact->Address->__toStringWithLink();
     }
     $this->pnlDescription->Text = nl2br($this->objContact->Description);
     $this->lblPhoneOffice->Text = $this->objContact->PhoneOffice;
     $this->lblPhoneMobile->Text = $this->objContact->PhoneMobile;
     $this->lblPhoneHome->Text = $this->objContact->PhoneHome;
     $this->lblFax->Text = $this->objContact->Fax;
     if ($this->objContact->CreationDate) {
         $this->lblCreationDate->Text = $this->objContact->CreationDate->PHPDate('Y-m-d H:i:s') . ' by ' . $this->objContact->CreatedByObject->__toStringFullName();
     }
     if ($this->objContact->ModifiedDate) {
         $this->lblModifiedDate->Text = $this->objContact->ModifiedDate . ' by ' . $this->objContact->ModifiedByObject->__toStringFullName();
     }
     // Update custom labels
     if ($this->arrCustomFields) {
         CustomField::UpdateLabels($this->arrCustomFields);
     }
 }
 public function UpdateInventoryLabels()
 {
     $this->lblHeaderInventoryModelCode->Text = $this->objInventoryModel->InventoryModelCode;
     $this->lblShortDescription->Text = $this->objInventoryModel->ShortDescription;
     if ($this->objInventoryModel->CategoryId) {
         $this->lblCategory->Text = $this->objInventoryModel->Category->__toString();
     }
     if ($this->objInventoryModel->ManufacturerId) {
         $this->lblManufacturer->Text = $this->objInventoryModel->Manufacturer->__toString();
     }
     $this->pnlLongDescription->Text = nl2br($this->objInventoryModel->LongDescription);
     $this->lblInventoryModelCode->Text = $this->objInventoryModel->InventoryModelCode;
     $this->lblTotalQuantity->Text = InventoryModel::GetTotalQuantityByInventoryModelId($this->objInventoryModel->InventoryModelId);
     if ($this->objInventoryModel->ModifiedDate) {
         $this->lblModifiedDate->Text = $this->objInventoryModel->ModifiedDate . ' by ' . $this->objInventoryModel->ModifiedByObject->__toStringFullName();
     }
     // Update custom labels
     if ($this->arrCustomFields) {
         CustomField::UpdateLabels($this->arrCustomFields);
     }
 }
 public function UpdateAssetLabels()
 {
     if ($this->objAsset->AssetModelId) {
         $this->lblAssetModel->Text = $this->objAsset->AssetModel->__toStringWithLink();
         $this->lblAssetModelCode->Text = $this->objAsset->AssetModel->AssetModelCode;
         if ($this->objAsset->AssetModel->CategoryId) {
             $this->lblCategory->Text = $this->objAsset->AssetModel->Category->__toString();
         }
         if ($this->objAsset->AssetModel->ManufacturerId) {
             $this->lblManufacturer->Text = $this->objAsset->AssetModel->Manufacturer->__toString();
         }
     }
     if ($this->objAsset->LocationId) {
         $this->lblLocation->Text = $this->objAsset->Location->__toString();
     }
     $this->lblAssetCode->Text = $this->objAsset->AssetCode;
     $this->lblHeaderAssetCode->Text = $this->objAsset->AssetCode;
     if ($this->objAsset->ParentAssetId) {
         $this->lblParentAssetCode->Text = $this->objAsset->ParentAsset->__toStringWithLink("bluelink");
     } else {
         $this->lblParentAssetCode->Text = "";
     }
     if ($this->objAsset->ModifiedDate) {
         $this->lblModifiedDate->Text = $this->objAsset->ModifiedDate . ' by ' . $this->objAsset->ModifiedByObject->__toStringFullName();
     }
     // Update custom labels
     if ($this->arrCustomFields) {
         CustomField::UpdateLabels($this->arrCustomFields);
     }
     if (QApplication::$TracmorSettings->DepreciationFlag == '1' && $this->chkAssetDepreciation instanceof QCheckBox) {
         $this->chkAssetDepreciation->Enabled = false;
         $this->hideAssetDepreciationFields();
         if ($this->objAsset->DepreciationFlag == 1) {
             $this->lblPurchaseCost->Text = money_format('%i', $this->objAsset->PurchaseCost);
             $this->lblPurchaseDate->Text = $this->objAsset->PurchaseDate->__toString();
             $this->lblPurchaseCost->Display = true;
             $this->lblPurchaseDate->Display = true;
             $this->lblBookValue->Display = true;
         }
     }
 }
예제 #10
0
 protected function UpdateShipmentLabels()
 {
     $this->lblShipDate->Text = $this->objShipment->ShipDate->__toString();
     $this->lblFromCompany->Text = $this->objShipment->FromCompany->__toStringWithLink();
     $this->lblFromContact->Text = $this->objShipment->FromContact->__toStringWithLink();
     $this->lblFromAddress->Text = $this->objShipment->FromAddress->__toStringWithLink();
     $this->lblToCompany->Text = $this->objShipment->ToCompany->__toStringWithLink();
     $this->lblToContact->Text = $this->objShipment->ToContact->__toStringWithLink();
     $this->lblToAddress->Text = $this->objShipment->ToAddress->__toStringWithLink();
     if (QApplication::$TracmorSettings->CustomShipmentNumbers) {
         $this->lblShipmentNumber->Text = $this->objShipment->ShipmentNumber;
     }
     $this->lblCourier->Text = $this->objShipment->CourierId ? $this->objShipment->Courier->__toString() : "Other";
     $this->lblTrackingNumber->Text = $this->objShipment->__toStringTrackingNumber();
     $this->pnlNote->Text = nl2br($this->objShipment->Transaction->Note);
     if ($this->objFedexShipment) {
         $this->lblToPhone->Text = $this->objFedexShipment->ToPhone;
         $this->lblBillTransportationTo->Text = $this->objFedexShipment->FedexServiceTypeId == 6 ? FedExDC::ground_pay_type($this->objFedexShipment->PayType) : FedExDC::express_pay_type($this->objFedexShipment->PayType);
         $this->lblPayerAccount->Text = $this->objFedexShipment->PayType === 1 ? $this->objFedexShipment->ShippingAccount->__toString() : $this->objFedexShipment->PayerAccountNumber;
         $this->lblReference->Text = $this->objFedexShipment->Reference;
         $this->lblFedexNotifySenderEmail->Text = $this->objFedexShipment->NotifySenderEmail;
         $this->lblFedexNotifyRecipientEmail->Text = $this->objFedexShipment->NotifyRecipientEmail;
         $this->lblFedexNotifyOtherEmail->Text = $this->objFedexShipment->NotifyOtherEmail;
         $this->lblFxServiceType->Text = $this->objFedexShipment->FedexServiceType ? $this->objFedexShipment->FedexServiceType->__toString() : '';
         $this->lblPackageType->Text = $this->objFedexShipment->PackageType ? $this->objFedexShipment->PackageType->__toString() : '';
         $this->lblPackageWeight->Text = $this->objFedexShipment->PackageWeight;
         $this->lblPackageLength->Text = $this->objFedexShipment->PackageLength;
         $this->lblPackageWidth->Text = $this->objFedexShipment->PackageWidth;
         $this->lblPackageHeight->Text = $this->objFedexShipment->PackageHeight;
         $this->lblValue->Text = $this->objFedexShipment->DeclaredValue;
         $this->lblWeightUnit->Text = $this->objFedexShipment->WeightUnit->__toString();
         $this->lblLengthUnit->Text = $this->objFedexShipment->LengthUnit->__toString();
         $this->lblCurrencyUnit->Text = $this->objFedexShipment->CurrencyUnit->__toString();
         $this->lblHoldAtLocationAddress->Text = $this->objFedexShipment->HoldAtLocationAddress;
         $this->lblHoldAtLocationCity->Text = $this->objFedexShipment->HoldAtLocationCity;
         $this->lblHoldAtLocationState->Text = $this->objFedexShipment->HoldAtLocationStateObject ? $this->objFedexShipment->HoldAtLocationStateObject->__toString() : '';
         $this->lblHoldAtLocationPostalCode->Text = $this->objFedexShipment->HoldAtLocationPostalCode;
         $this->lblFedexLabelPrinterType->Text = FedExDC::label_printer_type($this->objFedexShipment->LabelPrinterType);
         $this->lblFedexLabelFormatType->Text = FedExDC::label_format_type($this->objFedexShipment->LabelFormatType);
         $this->lblFedexThermalPrinterPort->Text = $this->objFedexShipment->ThermalPrinterPort;
     }
     // Update custom labels
     if ($this->arrCustomFields) {
         CustomField::UpdateLabels($this->arrCustomFields);
     }
 }
예제 #11
0
 protected function UpdateLabels()
 {
     $this->lblShortDescription->Text = $this->txtShortDescription->Text;
     $this->lblAssetModelCode->Text = $this->txtAssetModelCode->Text;
     $this->lblCategory->Text = $this->lstCategory->SelectedName;
     $this->lblManufacturer->Text = $this->lstManufacturer->SelectedName;
     $this->pnlLongDescription->Text = nl2br($this->txtLongDescription->Text);
     $this->lblImage->Text = $this->ifcImage->GetDisplayHtml($this->objAssetModel->ImagePath);
     // Update Depreciation label if enabled
     if (QApplication::$TracmorSettings->DepreciationFlag == '1') {
         $this->lblDepreciationClass->Text = $this->lstDepreciationClass->SelectedValue == null ? '' : $this->lstDepreciationClass->SelectedName;
     }
     // Update custom labels
     if ($this->arrCustomFields) {
         CustomField::UpdateLabels($this->arrCustomFields);
     }
     // From AssetModelEditFormBase, this loads an Asset Model object or creates a new one
     $this->SetupAssetModel();
 }