OXID eShop CE
6.1.5
|
Public Member Functions | |
__construct () | |
validateBasketAmount ($dAmount) | |
checkLogin ($oUser, $sLogin, $aInvAddress) | |
checkEmail ($oUser, $sEmail) | |
checkPassword ($oUser, $sNewPass, $sConfPass, $blCheckLength=false) | |
getPasswordLength () | |
checkRequiredFields ($oUser, $aBillingAddress, $aDeliveryAddress) | |
checkCountries ($oUser, $aInvAddress, $aDelAddress) | |
checkVatId ($oUser, $aInvAddress) | |
getFieldValidationErrors () | |
getFirstValidationError () | |
validatePaymentInputData ($sPaymentId, & $aDynValue) | |
addValidationError ($sFieldName, $oErr) | |
setCompanyVatInValidator ($oCompanyVatInValidator) | |
getCompanyVatInValidator ($oCountry) | |
Public Attributes | |
const | INVALID_ACCOUNT_NUMBER = -5 |
const | INVALID_BANK_CODE = -4 |
Protected Member Functions | |
_getCountry ($sCountryId) | |
_addValidationError ($sFieldName, $oErr) | |
_validateDebitNote ($debitInformation) | |
_validateOldDebitInfo ($aDebitInfo) | |
_fixAccountNumber ($aDebitInfo) | |
_isAllBankInformationSet ($aRequiredFields, $aBankInformation) | |
_cleanDebitInformation ($aDebitInformation) | |
_hasRequiredParametersForVatInCheck ($aInvAddress) | |
Protected Attributes | |
$_aRequiredCCFields | |
$_aInputValidationErrors = [] | |
$_oCompanyVatInValidator = null | |
$_aPossibleCCType | |
$_aRequiredDCFields | |
Private Member Functions | |
_setFields ($oObject, $aFields) | |
Class for validating input
OxidEsales\EshopCommunity\Core\InputValidator::__construct | ( | ) |
Class constructor. The constructor is defined in order to be possible to call parent::__construct() in modules.
|
protected |
Used to collect user validation errors. This method is called from all of the input checking functionality to report found error.
string | $sFieldName | field name |
exception | $oErr | exception |
|
protected |
Clean up spaces.
array | $aDebitInformation | Debit information |
|
protected |
If account number is shorter than 10, add zeros in front of number.
array | $aDebitInfo | Debit info |
|
protected |
Load and return oxCountry
string | $sCountryId |
|
protected |
Check if all need parameters entered
array | $aInvAddress | Address |
|
protected |
Checks if all bank information is set.
array | $aRequiredFields | fields must be set. |
array | $aBankInformation | actual information. |
|
private |
Creates oxAddress object from given array.
\OxidEsales\Eshop\Application\Model\User | oxAddress | $oObject | |
array | $aFields |
|
protected |
Validates debit note.
array | $debitInformation |
|
protected |
Validates old debit info.
array | $aDebitInfo | Debit info |
OxidEsales\EshopCommunity\Core\InputValidator::addValidationError | ( | $sFieldName, | |
$oErr | |||
) |
Used to collect user validation errors. This method is called from all of the input checking functionality to report found error.
string | $sFieldName | field name |
exception | $oErr | exception |
OxidEsales\EshopCommunity\Core\InputValidator::checkCountries | ( | $oUser, | |
$aInvAddress, | |||
$aDelAddress | |||
) |
Checks if user defined countries (billing and delivery) are active
\OxidEsales\Eshop\Application\Model\User | $oUser | active user |
array | $aInvAddress | billing address info |
array | $aDelAddress | delivery address info |
OxidEsales\EshopCommunity\Core\InputValidator::checkEmail | ( | $oUser, | |
$sEmail | |||
) |
Checks if email (used as login) is not empty and is valid.
\OxidEsales\Eshop\Application\Model\User | $oUser | active user |
string | $sEmail | user email/login |
OxidEsales\EshopCommunity\Core\InputValidator::checkLogin | ( | $oUser, | |
$sLogin, | |||
$aInvAddress | |||
) |
Checks if user name does not break logic:
\OxidEsales\Eshop\Application\Model\User | $oUser | active user |
string | $sLogin | user preferred login name |
array | $aInvAddress | user information |
OxidEsales\EshopCommunity\Core\InputValidator::checkPassword | ( | $oUser, | |
$sNewPass, | |||
$sConfPass, | |||
$blCheckLength = false |
|||
) |
Checking if user password is fine. In case of error exception is thrown
\OxidEsales\Eshop\Application\Model\User | $oUser | active user |
string | $sNewPass | new user password |
string | $sConfPass | retyped user password |
bool | $blCheckLength | option to check password length |
OxidEsales\EshopCommunity\Core\InputValidator::checkRequiredFields | ( | $oUser, | |
$aBillingAddress, | |||
$aDeliveryAddress | |||
) |
Checking if all required fields were filled. In case of error exception is thrown
\OxidEsales\Eshop\Application\Model\User | $oUser | active user |
array | $aBillingAddress | billing address |
array | $aDeliveryAddress | delivery address |
OxidEsales\EshopCommunity\Core\InputValidator::checkVatId | ( | $oUser, | |
$aInvAddress | |||
) |
Checks if user passed VAT id is valid. Exception is thrown if id is not valid
\OxidEsales\Eshop\Application\Model\User | $oUser | active user |
array | $aInvAddress | user input array |
OxidEsales\EshopCommunity\Core\InputValidator::getCompanyVatInValidator | ( | $oCountry | ) |
Return VAT IN validator
\OxidEsales\Eshop\Application\Model\Country | $oCountry | country according which VAT id should be checked |
OxidEsales\EshopCommunity\Core\InputValidator::getFieldValidationErrors | ( | ) |
Returns error array if input validation for current field and rule reported an error
OxidEsales\EshopCommunity\Core\InputValidator::getFirstValidationError | ( | ) |
Returns first user input validation error
OxidEsales\EshopCommunity\Core\InputValidator::getPasswordLength | ( | ) |
min length of password
OxidEsales\EshopCommunity\Core\InputValidator::setCompanyVatInValidator | ( | $oCompanyVatInValidator | ) |
VAT IN validator setter
\OxidEsales\Eshop\Core\CompanyVatInValidator | $oCompanyVatInValidator | validator |
OxidEsales\EshopCommunity\Core\InputValidator::validateBasketAmount | ( | $dAmount | ) |
Validates basket amount
float | $dAmount | amount of article |
oxArticleInputException | if amount is not numeric or smaller 0 |
OxidEsales\EshopCommunity\Core\InputValidator::validatePaymentInputData | ( | $sPaymentId, | |
& | $aDynValue | ||
) |
Validates payment input data for credit card and debit note
string | $sPaymentId | the payment id of current payment |
array | $aDynValue | values of payment |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
const OxidEsales\EshopCommunity\Core\InputValidator::INVALID_ACCOUNT_NUMBER = -5 |
Invalid account number error code for template.
const OxidEsales\EshopCommunity\Core\InputValidator::INVALID_BANK_CODE = -4 |
Invalid bank number error code for template.