📜  获取商店的当前货币 - 任何代码示例

📅  最后修改于: 2022-03-11 15:00:43.834000             🧑  作者: Mango

代码示例1
$objectManager = \Magento\Framework\App\ObjectManager::getInstance(); // Instance of Object Manager
$priceHelper = $objectManager->create('Magento\Framework\Pricing\Helper\Data'); // Instance of Pricing Helper
$value =  1000; // or whatever value you have in your template
$formattedCurrencyValue = $priceHelper->currency($value, true, false);