[*] BO #PSFV-94 : Added AdminImportController
git-svn-id: http://dev.prestashop.com/svn/v1/branches/1.5.x@9974 b9a71923-0436-4b27-9f14-aed3839534dd
This commit is contained in:
+1
-1
@@ -333,7 +333,7 @@ class AddressCore extends ObjectModel
|
||||
$address = new Address((int)$id_address);
|
||||
|
||||
if (!Validate::isLoadedObject($address))
|
||||
throw new Exception('Invalid address');
|
||||
throw new PrestashopException('Invalid address');
|
||||
}
|
||||
|
||||
return $address;
|
||||
|
||||
@@ -86,7 +86,6 @@ class HelperFormCore extends Helper
|
||||
'title' => $this->title,
|
||||
'firstCall' => $this->first_call,
|
||||
'current' => $this->currentIndex,
|
||||
'title' => $this->title,
|
||||
'token' => $this->token,
|
||||
'table' => $this->table,
|
||||
'languages' => $this->languages,
|
||||
|
||||
@@ -259,6 +259,28 @@ class ShopCore extends ObjectModel
|
||||
return $shop;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return Address the current shop address
|
||||
*/
|
||||
public function getAddress()
|
||||
{
|
||||
if (!isset($this->address))
|
||||
{
|
||||
$address = new Address();
|
||||
$address->company = Configuration::get('PS_SHOP_NAME');
|
||||
$address->id_country = Configuration::get('PS_SHOP_COUNTRY_ID');
|
||||
$address->id_state = Configuration::get('PS_SHOP_STATE_ID');
|
||||
$address->address1 = Configuration::get('PS_SHOP_ADDR1');
|
||||
$address->address2 = Configuration::get('PS_SHOP_ADDR2');
|
||||
$address->postcode = Configuration::get('PS_SHOP_CODE');
|
||||
$address->city = Configuration::get('PS_SHOP_CITY');
|
||||
|
||||
$this->address = $address;
|
||||
}
|
||||
|
||||
return $this->address;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get shop theme name
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user