OXID eShop CE  4.9.7
 All Classes Files Functions Variables Pages
oxuseraddresslist.php
Go to the documentation of this file.
1 <?php
2 
6 class oxUserAddressList extends oxList
7 {
8 
12  public function __construct()
13  {
14  parent::__construct('oxaddress');
15  }
16 
22  public function load($sUserId)
23  {
24  $sViewName = getViewName('oxcountry');
25  $oBaseObject = $this->getBaseObject();
26  $sSelectFields = $oBaseObject->getSelectFields();
27 
28  $sSelect = "
29  SELECT {$sSelectFields}, `oxcountry`.`oxtitle` AS oxcountry
30  FROM oxaddress
31  LEFT JOIN {$sViewName} AS oxcountry ON oxaddress.oxcountryid = oxcountry.oxid
32  WHERE oxaddress.oxuserid = " . oxDb::getDb()->quote($sUserId);
33  $this->selectString($sSelect);
34  }
35 }