price fix

This commit is contained in:
merdan 2022-02-06 20:54:10 +05:00
parent 02b7f4b11b
commit 9a7d91c9fc
2 changed files with 3 additions and 3 deletions

View File

@ -41,7 +41,7 @@ class Products extends ProductController
*/
public function get($id)
{
return ($product = $this->productRepository->findl($id))?
return ($product = $this->productRepository->find($id))?
new ProductResource($product) :
response()->json(['error' => 'not found'],404);
}

View File

@ -717,7 +717,7 @@ class Core
? $this->getAllCurrencies()->where('code', $currencyCode)->first()
: $this->getCurrentCurrency();
$formatter = new \NumberFormatter(app()->getLocale(), \NumberFormatter::CURRENCY);
$formatter = new \NumberFormatter('tr_TR', \NumberFormatter::CURRENCY);
if ($symbol = $currency->symbol) {
if ($this->currencySymbol($currency) == $symbol) {
@ -746,7 +746,7 @@ class Core
$price = 0;
}
$formater = new \NumberFormatter(app()->getLocale(), \NumberFormatter::CURRENCY);
$formater = new \NumberFormatter('tr_TR', \NumberFormatter::CURRENCY);
if ($symbol = $this->getBaseCurrency()->symbol) {
if ($this->currencySymbol($this->getBaseCurrencyCode()) == $symbol) {