|
OXID eShop CE
4.9.7
|
Inheritance diagram for oxUser:
Collaboration diagram for oxUser:Public Member Functions | |
| __construct () | |
| setMallUsersStatus ($blOn=false) | |
| __get ($sParamName) | |
| getNewsSubscription () | |
| getUserCountry ($sCountryId=null, $iLang=null) | |
| getUserCountryId ($sCountry=null) | |
| getUserGroups ($sOXID=null) | |
| getUserAddresses ($sUserId=null) | |
| setSelectedAddressId ($sAddressId) | |
| getSelectedAddressId () | |
| getSelectedAddress ($sWishId=false) | |
| getUserPayments ($sOXID=null) | |
| save () | |
| allowDerivedUpdate () | |
| inGroup ($sGroupID) | |
| delete ($sOXID=null) | |
| load ($oxID) | |
| exists ($sOXID=null) | |
| getOrders ($iLimit=false, $iPage=0) | |
| getOrderCount () | |
| getNoticeListArtCnt () | |
| getWishListArtCnt () | |
| getEncodedDeliveryAddress () | |
| getActiveCountry () | |
| createUser () | |
| addToGroup ($sGroupID) | |
| removeFromGroup ($sGroupID=null) | |
| onOrderExecute ($oBasket, $iSuccess) | |
| getBasket ($sName) | |
| convertBirthday ($aData) | |
| getBoni () | |
| checkValues ($sLogin, $sPassword, $sPassword2, $aInvAddress, $aDelAddress) | |
| setNewsSubscription ($blSubscribe, $blSendOptIn, $blForceCheckOptIn=false) | |
| changeUserData ($sUser, $sPassword, $sPassword2, $aInvAddress, $aDelAddress) | |
| login ($sUser, $sPassword, $blCookie=false) | |
| logout () | |
| loadAdminUser () | |
| loadActiveUser ($blForceAdmin=false) | |
| checkIfEmailExists ($sEmail) | |
| getUserRecommLists ($sOXID=null) | |
| getRecommListsCount ($sOx=null) | |
| loadUserByUpdateId ($sUid) | |
| setUpdateKey ($blReset=false) | |
| getUpdateLinkTerm () | |
| isExpiredUpdateId ($sKey) | |
| getUpdateId () | |
| encodePassword ($sPassword, $sSalt) | |
| prepareSalt ($sSalt) | |
| decodeSalt ($sSaltHex) | |
| setPassword ($sPassword=null) | |
| isSamePassword ($sNewPass) | |
| isLoadedFromCookie () | |
| getPasswordHash () | |
| getReviewUserHash ($sUserId) | |
| getReviewUserId ($sReviewUserHash) | |
| getState () | |
| getStateId () | |
| getStateTitle ($sId=null) | |
| isTermsAccepted () | |
| acceptTerms () | |
| setCreditPointsForRegistrant ($sUserId, $sRecEmail) | |
| setCreditPointsForInviter () | |
| updateFbId () | |
| updateInvitationStatistics ($aRecEmail) | |
| getIdByUserName ($sUserName) | |
| hasAccount () | |
| isPriceViewModeNetto () | |
Public Member Functions inherited from oxBase | |
| getUseSkipSaveFields () | |
| setUseSkipSaveFields ($blUseSkipSaveFields) | |
| __set ($sName, $sValue) | |
| __isset ($mVar) | |
| __clone () | |
| oxClone ($oObject) | |
| getUpdateSeo () | |
| setUpdateSeo ($blUpdateSeo) | |
| init ($sTableName=null, $blForceAllFields=false) | |
| assign ($dbRecord) | |
| getClassName () | |
| getCoreTableName () | |
| getId () | |
| setId ($sOXID=null) | |
| setShopId ($iShopId) | |
| getShopId () | |
| getViewName ($blForceCoreTableUsage=null) | |
| modifyCacheKey ($sCacheKey, $blOverride=false) | |
| disableLazyLoading () | |
| isDerived () | |
| setIsDerived ($blVal) | |
| isMultilang () | |
| isLoaded () | |
| buildSelectString ($aWhere=null) | |
| assignRecord ($sSelect) | |
| getFieldData ($sFieldName) | |
| getSelectFields ($blForceCoreTableUsage=null) | |
| allowDerivedDelete () | |
| getSqlActiveSnippet ($blForceCoreTable=null) | |
| beforeUpdate ($sOXID=null) | |
| onChange ($iAction=null, $sOXID=null) | |
| setInList () | |
| isOx () | |
| isReadOnly () | |
| setReadOnly ($blReadOnly) | |
| getFieldNames () | |
| addFieldName ($sName) | |
| getLanguage () | |
Public Member Functions inherited from oxSuperCfg | |
| __call ($sMethod, $aArgs) | |
| getConfig () | |
| setConfig ($oConfig) | |
| getSession () | |
| setSession ($oSession) | |
| getUser () | |
| setUser ($oUser) | |
| isAdmin () | |
| setAdminMode ($blAdmin) | |
Protected Member Functions | |
| _getStateObject () | |
| _getWishListId () | |
| _getMergedAddressFields () | |
| _assignAddress ($aDelAddress) | |
| _getLoginQueryHashedWithMD5 ($sUser, $sPassword, $sShopID, $blAdmin) | |
| _getLoginQuery ($sUser, $sPassword, $sShopID, $blAdmin) | |
| _getShopSelect ($myConfig, $sShopID, $blAdmin) | |
| _getFacebookUserId () | |
| _getCookieUserId () | |
| _ldapLogin ($sUser, $sPassword, $sShopID, $sShopSelect) | |
| _getUserRights () | |
| _insert () | |
| _update () | |
| _setAutoGroups ($sCountryId) | |
| _dbLogin ($sUser, $sPassword, $sShopID) | |
| _isDemoShop () | |
| _getDemoShopLoginQuery ($sUser, $sPassword) | |
Protected Member Functions inherited from oxBase | |
| _setUpdateSeoOnFieldChange ($sField) | |
| _removeElement2ShopRelations ($sOxId) | |
| _isInList () | |
| _getObjectViewName ($sTable, $sShopID=null) | |
| _getTableFields ($sTable, $blReturnSimple=false) | |
| _getAllFields ($blReturnSimple=false) | |
| _initDataStructure ($blForceFullStructure=false) | |
| _getNonCachedFieldNames ($blForceFullStructure=false) | |
| _getFieldStatus ($sFieldName) | |
| _addField ($sName, $iStatus, $sType=null, $sLength=null) | |
| _getFieldLongName ($sFieldName) | |
| _setFieldData ($sFieldName, $sValue, $iDataType=oxField::T_TEXT) | |
| _canFieldBeNull ($sFieldName) | |
| _getFieldDefaultValue ($sFieldName) | |
| _getUpdateFieldValue ($sFieldName, $oField) | |
| _getUpdateFields ($blUseSkipSaveFields=true) | |
| _isDisabledFieldCache () | |
| _addSkippedSaveFieldsForMapping () | |
| _disableLazyLoadingForCaching () | |
Protected Attributes | |
| $_blDisableShopCheck = true | |
| $_oNewsSubscription = null | |
| $_sClassName = 'oxuser' | |
| $_aBaskets = array() | |
| $_oGroups | |
| $_aAddresses = array() | |
| $_oPayments | |
| $_oRecommList | |
| $_blMallUsers = false | |
| $_iCntNoticeListArticles = null | |
| $_iCntWishListArticles = null | |
| $_iCntRecommLists = null | |
| $_sUpdateKey = null | |
| $_blLoadedFromCookie = null | |
| $_sSelAddressId = null | |
| $_oSelAddress = null | |
| $_sWishId = null | |
| $_oUserCountryTitle = null | |
| $_oStateObject = null | |
Protected Attributes inherited from oxBase | |
| $_sOXID = null | |
| $_iShopId = null | |
| $_blIsSimplyClonable = true | |
| $_sClassName = 'oxbase' | |
| $_sCoreTable = null | |
| $_sViewTable = null | |
| $_aFieldNames = array('oxid' => 0) | |
| $_sCacheKey = null | |
| $_blUseLazyLoading = false | |
| $_aSkipSaveFields = array('oxtimestamp') | |
| $_blUseSkipSaveFields = true | |
| $_sExistKey = 'oxid' | |
| $_blIsDerived = null | |
| $_blIsSeoObject = false | |
| $_blUpdateSeo = true | |
| $_blReadOnly = false | |
| $_blIsInList = false | |
| $_isLoaded = false | |
| $_aInnerLazyCache = null | |
| $_blEmployMultilanguage = false | |
Static Protected Attributes | |
| static | $_aUserCookie = array() |
Static Protected Attributes inherited from oxBase | |
| static | $_blDisableFieldCaching = array() |
Static Protected Attributes inherited from oxSuperCfg | |
| static | $_oConfig = null |
| static | $_oSession = null |
| static | $_oRights = null |
| static | $_oActUser = null |
| static | $_blIsAdmin = null |
User manager. Performs user managing function, as assigning to groups, updating information, deletion and other.
Definition at line 9 of file oxuser.php.
| oxUser::__construct | ( | ) |
Class constructor, initiates parent constructor (parent::oxBase()).
Reimplemented from oxBase.
Definition at line 169 of file oxuser.php.
| oxUser::__get | ( | $sParamName | ) |
Getter for special not frequently used fields
| string | $sParamName | name of parameter to get value |
Reimplemented from oxBase.
Definition at line 194 of file oxuser.php.
|
protected |
creates new address entry or updates existing
| array | $aDelAddress | address data array |
Definition at line 1186 of file oxuser.php.
|
protected |
Initiates user login against data in DB.
| object |
Definition at line 2249 of file oxuser.php.
|
protected |
Checks if user is connected via cookies and if so, returns user id.
Definition at line 1481 of file oxuser.php.
|
protected |
Return sql to get id of mall admin in demo shop
| object::$oEx |
Definition at line 2303 of file oxuser.php.
|
protected |
Checks if user is connected via Facebook connect and if so, returns user id.
Definition at line 1459 of file oxuser.php.
|
protected |
Builds and returns user login query
| string | $sUser | login name |
| string | $sPassword | login password |
| string | $sShopID | shopid |
| bool | $blAdmin | admin/non admin mode |
| object |
Definition at line 1258 of file oxuser.php.
|
protected |
Builds and returns user login query.
MD5 encoding is used in legacy eShop versions. We still allow to perform the login for users registered in the previous eshop versions.
| string | $sUser | login name |
| string | $sPassword | login password |
| string | $sShopID | shopid |
| bool | $blAdmin | admin/non admin mode |
Definition at line 1225 of file oxuser.php.
|
protected |
|
protected |
Returns shopselect part of login query sql
| object | $myConfig | shop config |
| string | $sShopID | shopid |
| bool | $blAdmin | admin/non admin mode |
Definition at line 1290 of file oxuser.php.
|
protected |
|
protected |
Returns user rights index. Index cannot be higher than current session user rights index.
Definition at line 1584 of file oxuser.php.
|
protected |
|
protected |
Inserts user object data to DB. Returns true on success.
Reimplemented from oxBase.
Definition at line 1629 of file oxuser.php.
|
protected |
|
protected |
|
protected |
Automatically assigns user to specific groups according to users country information
| string | $sCountryId | users country id |
Definition at line 1784 of file oxuser.php.
|
protected |
Updates changed user object data to DB. Returns true on success.
Reimplemented from oxBase.
Definition at line 1647 of file oxuser.php.
| oxUser::acceptTerms | ( | ) |
Writes terms acceptance info to db
Definition at line 2101 of file oxuser.php.
| oxUser::addToGroup | ( | $sGroupID | ) |
Adds user to the group
| string | $sGroupID | group id |
Definition at line 849 of file oxuser.php.
| oxUser::allowDerivedUpdate | ( | ) |
Overrides parent isDerived check and returns true
Reimplemented from oxBase.
Definition at line 528 of file oxuser.php.
| oxUser::changeUserData | ( | $sUser, | |
| $sPassword, | |||
| $sPassword2, | |||
| $aInvAddress, | |||
| $aDelAddress | |||
| ) |
When changing/updating user information in frontend this method validates user input. If data is fine - automatically assigns this values. Additionally calls methods (oxuser::_setAutoGroups, oxuser::setNewsSubscription) to perform automatic groups assignment and returns newsletter subscription status. If some action fails - exception is thrown.
| string | $sUser | user login name |
| string | $sPassword | user password |
| string | $sPassword2 | user confirmation password |
| array | $aInvAddress | user billing address |
| array | $aDelAddress | delivery address |
| oxUserException,oxInputException,oxConnectionException |
Definition at line 1133 of file oxuser.php.
| oxUser::checkIfEmailExists | ( | $sEmail | ) |
Checks for already used email
| string | $sEmail | user email/login |
Definition at line 1676 of file oxuser.php.
| oxUser::checkValues | ( | $sLogin, | |
| $sPassword, | |||
| $sPassword2, | |||
| $aInvAddress, | |||
| $aDelAddress | |||
| ) |
Performs bunch of checks if user profile data is correct; on any error exception is thrown
| string | $sLogin | user login name |
| string | $sPassword | user password |
| string | $sPassword2 | user password to compare |
| array | $aInvAddress | array of user profile data |
| array | $aDelAddress | array of user profile data |
| oxUserException,oxInputException |
Definition at line 1036 of file oxuser.php.
| oxUser::convertBirthday | ( | $aData | ) |
User birthday converter. Usually this data comes in array form, so before writing into DB it must be converted into string
| array | $aData | dirthday data |
Definition at line 958 of file oxuser.php.
| oxUser::createUser | ( | ) |
Inserts new or updates existing user
| oxUserException | exception |
Definition at line 799 of file oxuser.php.
| oxUser::decodeSalt | ( | $sSaltHex | ) |
Returns plains password salt representation
| string | $sSaltHex | heximal representation of password salt value |
Definition at line 1947 of file oxuser.php.
| oxUser::delete | ( | $sOXID = null | ) |
Removes user data stored in some DB tables (such as oxuserpayments, oxaddress oxobject2group, oxremark, etc). Return true on success.
| string | $sOXID | object ID (default null) |
Reimplemented from oxBase.
Definition at line 558 of file oxuser.php.
| oxUser::encodePassword | ( | $sPassword, | |
| $sSalt | |||
| ) |
Encodes and returns given password
| string | $sPassword | password to encode |
| string | $sSalt | any unique string value |
Definition at line 1909 of file oxuser.php.
| oxUser::exists | ( | $sOXID = null | ) |
Checks if user exists in database.
| string | $sOXID | object ID (default null) |
Reimplemented from oxBase.
Definition at line 633 of file oxuser.php.
| oxUser::getActiveCountry | ( | ) |
Returns user country ID, but If delivery address is given - returns delivery country.
Definition at line 772 of file oxuser.php.
| oxUser::getBasket | ( | $sName | ) |
Returns notice, wishlist or saved basket object
| string | $sName | name/type of basket |
Definition at line 929 of file oxuser.php.
| oxUser::getBoni | ( | ) |
Return standart credit rating, can be set in config option iCreditRating;
Definition at line 1011 of file oxuser.php.
| oxUser::getEncodedDeliveryAddress | ( | ) |
| oxUser::getIdByUserName | ( | $sUserName | ) |
retruns user id by user name
| string | $sUserName | user name |
Definition at line 2208 of file oxuser.php.
| oxUser::getNewsSubscription | ( | ) |
Returns user newsletter subscription controller object
Definition at line 233 of file oxuser.php.
| oxUser::getNoticeListArtCnt | ( | ) |
| oxUser::getOrderCount | ( | ) |
| oxUser::getOrders | ( | $iLimit = false, |
|
$iPage = 0 |
|||
| ) |
Returns object with ordering information (order articles list).
| int | $iLimit | how many entries to load |
| int | $iPage | which page to start |
Definition at line 676 of file oxuser.php.
| oxUser::getPasswordHash | ( | ) |
Returns password hash. In case password in db is plain or decodable password is processed and hash returned
Definition at line 2004 of file oxuser.php.
| oxUser::getRecommListsCount | ( | $sOx = null | ) |
Returns recommlist count
| string | $sOx | object ID (default is null) |
Definition at line 1761 of file oxuser.php.
| oxUser::getReviewUserHash | ( | $sUserId | ) |
Generates user password and username hash for review
| string | $sUserId | userid |
Definition at line 2021 of file oxuser.php.
| oxUser::getReviewUserId | ( | $sReviewUserHash | ) |
Gets from review user hash user id
| string | $sReviewUserHash | review user hash |
Definition at line 2036 of file oxuser.php.
| oxUser::getSelectedAddress | ( | $sWishId = false | ) |
Sets in the array oxuser::_aAddresses selected address. Returns user selected Address id.
| bool | $sWishId | wishlist user id |
Definition at line 413 of file oxuser.php.
| oxUser::getSelectedAddressId | ( | ) |
Returns user chosen address id ("oxaddressid" or "deladrid")
Definition at line 371 of file oxuser.php.
| oxUser::getState | ( | ) |
Return user state id
Definition at line 2051 of file oxuser.php.
| oxUser::getStateId | ( | ) |
| oxUser::getStateTitle | ( | $sId = null | ) |
Get state title by id
| string | $sId | state ID |
Definition at line 2073 of file oxuser.php.
| oxUser::getUpdateId | ( | ) |
| oxUser::getUpdateLinkTerm | ( | ) |
Return password update link validity term (seconds). Default 3600 * 6
Definition at line 1866 of file oxuser.php.
| oxUser::getUserAddresses | ( | $sUserId = null | ) |
Returns user defined Address list object
| string | $sUserId | object ID (default is null) |
Definition at line 334 of file oxuser.php.
| oxUser::getUserCountry | ( | $sCountryId = null, |
|
$iLang = null |
|||
| ) |
Returns user country (object) according to passed parameters or they are taken from user object ( oxid, country id) and session (language)
| string | $sCountryId | country id (optional) |
| int | $iLang | active language (optional) |
Definition at line 266 of file oxuser.php.
| oxUser::getUserCountryId | ( | $sCountry = null | ) |
Returns user countryid according to passed name
| string | $sCountry | country |
Definition at line 291 of file oxuser.php.
| oxUser::getUserGroups | ( | $sOXID = null | ) |
Returns assigned user groups list object
| string | $sOXID | object ID (default is null) |
Definition at line 307 of file oxuser.php.
| oxUser::getUserPayments | ( | $sOXID = null | ) |
Returns user payment history list object
| string | $sOXID | object ID (default is null) |
Definition at line 459 of file oxuser.php.
| oxUser::getUserRecommLists | ( | $sOXID = null | ) |
Returns user recommendation list object
| string | $sOXID | object ID (default is null) |
Definition at line 1729 of file oxuser.php.
| oxUser::getWishListArtCnt | ( | ) |
| oxUser::hasAccount | ( | ) |
returns true if user registered and have account
Definition at line 2224 of file oxuser.php.
| oxUser::inGroup | ( | $sGroupID | ) |
Checks if this object is in group, returns true on success.
| string | $sGroupID | user group ID |
Definition at line 540 of file oxuser.php.
| oxUser::isExpiredUpdateId | ( | $sKey | ) |
Checks if password update key is not expired yet
| string | $sKey | key |
Definition at line 1878 of file oxuser.php.
| oxUser::isLoadedFromCookie | ( | ) |
| oxUser::isPriceViewModeNetto | ( | ) |
Return user price view mode, true - if netto mode
Definition at line 2235 of file oxuser.php.
| oxUser::isSamePassword | ( | $sNewPass | ) |
Checks if user entered password is the same as old
| string | $sNewPass | new password |
Definition at line 1981 of file oxuser.php.
| oxUser::isTermsAccepted | ( | ) |
Checks if user accepted latest shopping terms and conditions version
Definition at line 2089 of file oxuser.php.
| oxUser::load | ( | $oxID | ) |
Loads object (user) details from DB. Returns true on success.
| string | $oxID | User ID |
Reimplemented from oxBase.
Definition at line 608 of file oxuser.php.
| oxUser::loadActiveUser | ( | $blForceAdmin = false | ) |
Loads active user object. If user is not available - returns false.
| bool | $blForceAdmin | (default false) |
Definition at line 1406 of file oxuser.php.
| oxUser::loadAdminUser | ( | ) |
Loads active admin user object (if possible). If user is not available - returns false.
Definition at line 1393 of file oxuser.php.
| oxUser::loadUserByUpdateId | ( | $sUid | ) |
Tries to load user object by passed update id. Update id is generated when user forgot passwords and wants to update it
| string | $sUid | update id |
Definition at line 1832 of file oxuser.php.
| oxUser::login | ( | $sUser, | |
| $sPassword, | |||
$blCookie = false |
|||
| ) |
Performs user login by username and password. Fetches user data from DB. Registers in session. Returns true on success, FALSE otherwise.
| object | |
| oxCookieException | |
| oxUserException |
Definition at line 1315 of file oxuser.php.
| oxUser::logout | ( | ) |
Logs out session user. Returns true on success
Definition at line 1369 of file oxuser.php.
| oxUser::onOrderExecute | ( | $oBasket, | |
| $iSuccess | |||
| ) |
Called after saving an order.
| object | $oBasket | Shopping basket object |
| int | $iSuccess | order success status |
Definition at line 895 of file oxuser.php.
| oxUser::prepareSalt | ( | $sSalt | ) |
Returns safe salt value (heximal representation)
| string | $sSalt | any unique string value |
Definition at line 1928 of file oxuser.php.
| oxUser::removeFromGroup | ( | $sGroupID = null | ) |
Removes user from passed user group.
| string | $sGroupID | group id |
Definition at line 874 of file oxuser.php.
| oxUser::save | ( | ) |
Saves (updates) user object data information in DB. Return true on success.
Reimplemented from oxBase.
Definition at line 482 of file oxuser.php.
| oxUser::setCreditPointsForInviter | ( | ) |
| oxUser::setCreditPointsForRegistrant | ( | $sUserId, | |
| $sRecEmail | |||
| ) |
Assigns registration points for invited user and its inviter (calls oxUser::setInvitationCreditPoints())
| string | $sUserId | inviter user id |
| string | $sRecEmail | recipient (registrant) email |
Definition at line 2120 of file oxuser.php.
| oxUser::setMallUsersStatus | ( | $blOn = false | ) |
Sets mall user status
| bool | $blOn | mall users is on or off |
Definition at line 182 of file oxuser.php.
| oxUser::setNewsSubscription | ( | $blSubscribe, | |
| $blSendOptIn, | |||
$blForceCheckOptIn = false |
|||
| ) |
Sets newsletter subscription status to user
| bool | $blSubscribe | subscribes/unsubscribes user from newsletter |
| bool | $blSendOptIn | if to send confirmation email |
| bool | $blForceCheckOptIn | forces to check subscription even when it is set to 1 |
Definition at line 1075 of file oxuser.php.
| oxUser::setPassword | ( | $sPassword = null | ) |
Sets new password for user ( save is not called)
| string | $sPassword | password |
Definition at line 1957 of file oxuser.php.
| oxUser::setSelectedAddressId | ( | $sAddressId | ) |
Selected user address setter
| string | $sAddressId | selected address id |
Definition at line 361 of file oxuser.php.
| oxUser::setUpdateKey | ( | $blReset = false | ) |
Generates or resets and saves users update key
| bool | $blReset | marker to reset update info |
Definition at line 1846 of file oxuser.php.
| oxUser::updateFbId | ( | ) |
| oxUser::updateInvitationStatistics | ( | $aRecEmail | ) |
Updating invitations statistics
| array | $aRecEmail | array of recipients emails |
Definition at line 2185 of file oxuser.php.
|
protected |
Definition at line 52 of file oxuser.php.
|
protected |
Definition at line 38 of file oxuser.php.
|
staticprotected |
Definition at line 80 of file oxuser.php.
|
protected |
Definition at line 17 of file oxuser.php.
|
protected |
Definition at line 115 of file oxuser.php.
|
protected |
Definition at line 73 of file oxuser.php.
|
protected |
Definition at line 87 of file oxuser.php.
|
protected |
Definition at line 101 of file oxuser.php.
|
protected |
Definition at line 94 of file oxuser.php.
|
protected |
Definition at line 45 of file oxuser.php.
|
protected |
Definition at line 24 of file oxuser.php.
|
protected |
Definition at line 59 of file oxuser.php.
|
protected |
Definition at line 66 of file oxuser.php.
|
protected |
Definition at line 129 of file oxuser.php.
|
protected |
Definition at line 148 of file oxuser.php.
|
protected |
Definition at line 143 of file oxuser.php.
|
protected |
Definition at line 31 of file oxuser.php.
|
protected |
Definition at line 122 of file oxuser.php.
|
protected |
Definition at line 108 of file oxuser.php.
|
protected |
Definition at line 136 of file oxuser.php.