VirtueMart
3.2.14.9808
|
Public Member Functions | |
__construct () | |
setId ($cid) | |
getCurrentUser () | |
getVendor ($vendorId=1, $return=TRUE) | |
getUser () | |
getContactDetails () | |
store (&$data) | |
saveUserData (&$data, $trigger=true) | |
storeVendorData ($data) | |
setFraudProtection () | |
storeAddress (&$data) | |
validateUserData (&$data, $type='BT', $showInfo=false) | |
_prepareUserFields (&$data, $type, $userinfo=0, $prefix= '') | |
getBTuserinfo_id ($id=0) | |
getUserInfoInUserFields ($layoutName, $type, $uid, $cart=true, $isVendor=false) | |
storeUserDataByFields ($data, $type, $toggles, $skips) | |
remove ($userIds) | |
removeAddress ($virtuemart_userinfo_id) | |
getUserList () | |
getSwitchUserList ($superVendor=null, $adminID=false) | |
_getFilter () | |
getUserAddressList ($_uid=0, $_type= 'ST', $_virtuemart_userinfo_id=-1) | |
getCustomerNumberById () | |
getSuperAdminCount () | |
getAclGroupIndentedTree () | |
Public Member Functions inherited from VmModel | |
__construct ($cidName='cid', $config=array()) | |
setDebugSql ($b) | |
getName () | |
setState ($property, $value=null) | |
getState ($property=null, $default=null) | |
getTable ($name= '', $prefix= 'Table', $options=array()) | |
setIdName ($idName) | |
getIdName () | |
getId () | |
setId ($id) | |
setMainTable ($maintablename, $maintable=0) | |
getDefaultOrdering () | |
addvalidOrderingFieldName ($add) | |
removevalidOrderingFieldName ($name) | |
setDefaultValidOrderingFields ($defaultTable=null) | |
_getOrdering ($preTable='') | |
checkFilterOrder ($toCheck, $view=0, $task= '') | |
checkValidOrderingFieldName ($toCheck) | |
checkFilterDir ($toCheck, $view=0, $task= '') | |
getPagination ($perRow=5) | |
setPaginationLimits () | |
getTotal () | |
setGetCount ($withCount) | |
exeSortSearchListQuery ($object, $select, $joinedTables, $whereString= '', $groupBy= '', $orderBy= '', $filter_order_Dir= '', $nbrReturnProducts=false) | |
emptyCache () | |
getData ($id=0) | |
store (&$data) | |
remove ($ids) | |
setToggleName ($togglesName) | |
toggle ($field, $val=NULL, $cidname=0, $tablename=0, $view=false) | |
move ($direction, $filter=null) | |
saveorder ($cid=array(), $order, $filter=null) | |
addImages ($obj, $limit=0) | |
resetErrors () | |
Public Member Functions inherited from vObject | |
__toString () | |
get ($prop, $def=null) | |
set ($prop, $value=null) | |
setProperties ($props) | |
Public Attributes | |
$searchTable = 'juser' | |
Public Attributes inherited from VmModel | |
$_id = 0 | |
$_data = null | |
$_query = null | |
$_total = null | |
$_pagination = 0 | |
$_limit = 0 | |
$_limitStart = 0 | |
$_maintable = '' | |
$_maintablename = '' | |
$_idName = '' | |
$_cidName = 'cid' | |
$_togglesName = null | |
$_selectedOrderingDir = 'DESC' | |
$_noLimit = false | |
$_tablePreFix = '' | |
$_validOrderingFieldName = array() | |
$_validFilterDir = array('ASC','DESC') | |
Private Member Functions | |
setUserId ($id) | |
sendRegistrationEmail ($user, $password, $doUserActivation) | |
Private Attributes | |
$_defaultShopperGroup = 0 | |
$customer_number = 0 | |
Additional Inherited Members | |
Static Public Member Functions inherited from VmModel | |
static | addTablePath ($path) |
static | addIncludePath ($path= '', $prefix= '') |
static | getInstance ($type, $prefix= '', $config=array()) |
static | getModel ($name=false) |
static | joinLangTables ($tablename, $prefix, $on, $method=0) |
static | joinLangSelectFields ($langFields, $as=true) |
static | joinLangLikeFields ($langFields, $keyword) |
static | joinLangLikeField ($searchField, $keyword) |
Protected Member Functions inherited from VmModel | |
populateState () | |
_createTable ($name, $prefix= 'Table', $config=array()) | |
_getList ($query, $limitstart=0, $limit=0) | |
_getListCount ($query) | |
Static Protected Member Functions inherited from VmModel | |
static | _createFileName ($type, $parts=array()) |
Protected Attributes inherited from VmModel | |
$__state_set = null | |
$name | |
$option = null | |
$state | |
$event_clean_cache = null | |
$_maxItems = 1000 | |
VirtueMartModelUser::__construct | ( | ) |
Constructor for the user model.
The user ID is read and determined if it is an array of ids or just one single id.
VirtueMartModelUser::_getFilter | ( | ) |
If a filter was set, get the SQL WHERE clase
VirtueMartModelUser::_prepareUserFields | ( | & | $data, |
$type, | |||
$userinfo = 0 , |
|||
$prefix = '' |
|||
) |
VirtueMartModelUser::getAclGroupIndentedTree | ( | ) |
Return a list of Joomla ACL groups.
The returned object list includes a group anme and a group name with spaces prepended to the name for displaying an indented tree.
VirtueMartModelUser::getBTuserinfo_id | ( | $id = 0 | ) |
VirtueMartModelUser::getContactDetails | ( | ) |
Retrieve contact info for a user if any
VirtueMartModelUser::getCurrentUser | ( | ) |
VirtueMartModelUser::getCustomerNumberById | ( | ) |
VirtueMartModelUser::getSuperAdminCount | ( | ) |
Get the number of active Super Admins
VirtueMartModelUser::getSwitchUserList | ( | $superVendor = null , |
|
$adminID = false |
|||
) |
VirtueMartModelUser::getUser | ( | ) |
Retrieve the detail record for the current $id if the data has not already been loaded.
VirtueMartModelUser::getUserAddressList | ( | $_uid = 0 , |
|
$_type = 'ST' , |
|||
$_virtuemart_userinfo_id = -1 |
|||
) |
Retrieve a single address for a user
$_uid | int User ID |
$_virtuemart_userinfo_id | string Optional User Info ID |
$_type | string, addess- type, ST (ShipTo, default) or BT (BillTo). Empty string to ignore |
VirtueMartModelUser::getUserInfoInUserFields | ( | $layoutName, | |
$type, | |||
$uid, | |||
$cart = true , |
|||
$isVendor = false |
|||
) |
VirtueMartModelUser::getUserList | ( | ) |
Retrieve a list of users from the database.
VirtueMartModelUser::getVendor | ( | $vendorId = 1 , |
|
$return = TRUE |
|||
) |
Sets the internal user id with given vendor Id
int | $vendorId |
VirtueMartModelUser::remove | ( | $userIds | ) |
Delete all record ids selected
VirtueMartModelUser::removeAddress | ( | $virtuemart_userinfo_id | ) |
VirtueMartModelUser::saveUserData | ( | & | $data, |
$trigger = true |
|||
) |
This function is NOT for anonymous. Anonymous just get the information directly sent by email. This function saves the vm Userdata for registered JUsers. TODO, setting of shoppergroup isnt done
TODO No reason not to use this function for new users, but it requires a Joomla <user> plugin that gets fired by the onAfterStoreUser. I'll built that (OvE)
Notice: As long we do not have the silent registration, an anonymous does not get registered. It is enough to send the virtuemart_order_id with the email. The order is saved with all information in an extra table, so there is no need for a silent registration. We may think about if we actually need/want the feature silent registration The information of anonymous is stored in the order table and has nothing todo with the usermodel!
|
private |
This uses the shopFunctionsF::renderAndSendVmMail function, which uses a controller and task to render the content and sents it then.
VirtueMartModelUser::setFraudProtection | ( | ) |
FraudProtection to comply to the French financial Law 2018
VirtueMartModelUser::setId | ( | $cid | ) |
public function Resets the user id and data
|
private |
Internal function
unknown_type | $id |
VirtueMartModelUser::store | ( | & | $data | ) |
Bind the post data to the JUser object and the VM tables, then saves it It is used to register new users This function can also change already registered users, this is important when a registered user changes his email within the checkout.
VirtueMartModelUser::storeAddress | ( | & | $data | ) |
Take a data array and save any address info found in the array.
array | $data | (Posted) user data |
sting | $_table | Table name to write to, null (default) not to write to the database |
boolean | $_cart | Attention, this was deleted, the address to cart is now done in the controller (True to write to the session (cart)) |
VirtueMartModelUser::storeUserDataByFields | ( | $data, | |
$type, | |||
$toggles, | |||
$skips | |||
) |
This stores the userdata given in userfields
VirtueMartModelUser::storeVendorData | ( | $data | ) |
VirtueMartModelUser::validateUserData | ( | & | $data, |
$type = 'BT' , |
|||
$showInfo = false |
|||
) |
Test userdata if valid
String | if BT or ST |
Object | If given, an object with data address data that must be formatted to an array |
|
private |
|
private |
VirtueMartModelUser::$searchTable = 'juser' |