Show price without tax to prepare tax per customer country.
This commit is contained in:
parent
c1157679e8
commit
fca404e8d5
@ -44,7 +44,6 @@ class Dolistore
|
|||||||
// setups
|
// setups
|
||||||
public $url; // the url of this page
|
public $url; // the url of this page
|
||||||
public $shop_url; // the url of the shop
|
public $shop_url; // the url of the shop
|
||||||
public $vat_rate; // the vat rate used in the shop (prices are provided without vat)
|
|
||||||
public $lang; // the integer representing the lang in the store
|
public $lang; // the integer representing the lang in the store
|
||||||
public $debug_api; // usefull if no dialog
|
public $debug_api; // usefull if no dialog
|
||||||
|
|
||||||
@ -60,7 +59,6 @@ class Dolistore
|
|||||||
|
|
||||||
$this->url = DOL_URL_ROOT.'/admin/modules.php?mode=marketplace';
|
$this->url = DOL_URL_ROOT.'/admin/modules.php?mode=marketplace';
|
||||||
$this->shop_url = 'https://www.dolistore.com/index.php?controller=product&id_product=';
|
$this->shop_url = 'https://www.dolistore.com/index.php?controller=product&id_product=';
|
||||||
$this->vat_rate = 1.2; // 20% de TVA
|
|
||||||
$this->debug_api = $debug;
|
$this->debug_api = $debug;
|
||||||
|
|
||||||
$langtmp = explode('_', $langs->defaultlang);
|
$langtmp = explode('_', $langs->defaultlang);
|
||||||
@ -250,7 +248,7 @@ class Dolistore
|
|||||||
|
|
||||||
// free or pay ?
|
// free or pay ?
|
||||||
if ($product->price > 0) {
|
if ($product->price > 0) {
|
||||||
$price = '<h3>'.price(round((float) $product->price * $this->vat_rate, 2)).' €</h3>';
|
$price = '<h3>'.price(price2num($product->price, 'MT'), 0, $langs, 1, -1, -1, 'EUR').' '.$langs->trans("HT").'</h3>';
|
||||||
$download_link = '<a target="_blank" href="'.$this->shop_url.$product->id.'"><img width="32" src="'.DOL_URL_ROOT.'/admin/dolistore/img/follow.png" /></a>';
|
$download_link = '<a target="_blank" href="'.$this->shop_url.$product->id.'"><img width="32" src="'.DOL_URL_ROOT.'/admin/dolistore/img/follow.png" /></a>';
|
||||||
} else {
|
} else {
|
||||||
$price = '<h3>'.$langs->trans('Free').'</h3>';
|
$price = '<h3>'.$langs->trans('Free').'</h3>';
|
||||||
|
|||||||
@ -3675,7 +3675,7 @@ function img_searchclear($titlealt = 'default', $other = '')
|
|||||||
* @param string $text Text info
|
* @param string $text Text info
|
||||||
* @param integer $infoonimgalt Info is shown only on alt of star picto, otherwise it is show on output after the star picto
|
* @param integer $infoonimgalt Info is shown only on alt of star picto, otherwise it is show on output after the star picto
|
||||||
* @param int $nodiv No div
|
* @param int $nodiv No div
|
||||||
* @param string $admin '1'=Info for admin users. '0'=Info for standard users (change only the look), 'xxx'=Other
|
* @param string $admin '1'=Info for admin users. '0'=Info for standard users (change only the look), 'error','xxx'=Other
|
||||||
* @param string $morecss More CSS
|
* @param string $morecss More CSS
|
||||||
* @return string String with info text
|
* @return string String with info text
|
||||||
*/
|
*/
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user