Git Product home page Git Product logo

custom-currency's People

Contributors

ecommpro avatar edgargomez avatar johnorourke avatar manelio avatar noeli-eshopguru avatar noeli-getjohn avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

custom-currency's Issues

No region found within the locale 'de' - exception due to empty locale with Zend_Locale_Format

The Zend class throws an exception if the locale is empty or not 5 characters long.

We are relying on CurrencyInterface->getLocale() to find the currency locale but it looks like this can be empty, or taken from the user's Accept-Language header. If the Accept-Language header contains only 'de' (not 'de_DE'), then the exception is thrown.

We should use the Magento locale resolver instead as it will always return a valid locale.

Cannot deploy module on Magento Cloud

When deploying in the Cloud (have tried through composer and copying directly into app/code), the process fails with:

[2022-***2-***4 ***5:***:40] ERROR: [***] The command "php ./bin/magento module:enable --all --ansi --no-interaction" failed. There are no commands defined in the "module" namespace.

Exception: Invalid template file

Magento version: 2.3.1
Plugin version: 1.0.0

I have the following error when I try to reach the front office:

1 exception(s):
Exception #0 (Magento\Framework\Exception\ValidatorException): Invalid template file: '/app/vendor/composer/../ecommpro/module-custom-currency/view/frontend/templates/bootstrap.phtml' in module: '' block's name: 'custom-currency-bootstrap'

It looks like it comes from https://github.com/ecommpro/custom-currency/blob/master/registration.php#L5 as if I replace:

\Magento\Framework\Component\ComponentRegistrar::register(
    \Magento\Framework\Component\ComponentRegistrar::MODULE,
    'EcommPro_CustomCurrency',
    isset($file) ? dirname($file) : __DIR__
);

with:

\Magento\Framework\Component\ComponentRegistrar::register(
    \Magento\Framework\Component\ComponentRegistrar::MODULE,
    'EcommPro_CustomCurrency',
    __DIR__
);

(from 4de1a3e), the error is gone.

We're sorry, an error has occurred while generating this content - E_NOTICE in core triggered by EnsureTabExistsPlugin

Hi,

Commit 5176526 added a plugin to \Magento\Config\Model\Config\Structure\Data, which adds to the config array regardless of context. I have another module (BSSCommerce Customer Approval) which sends email out from a frontend controller, in a backend context (to notify the admin). Somehow that results in use of \Magento\Email\Model\BackendTemplate being used which triggers this plugin but with an empty config array. Our plugin adds the 'tabs' entry which then triggers an undefined variable on line 235 of \Magento\Config\Model\Config\Structure because the 'sections' entry isn't there.

That undefined variable notice gets turned into an exception by Magento's error handler, which in the case of an email template will turn the template output into "We're sorry, an error has occurred while generating this content".

We should either move this plugin into etc/adminhtml/di.xml or add an extra check so it only adds the tab if the 'tabs' entry is present already. Do you have a preference?

Is it also possible this isn't needed? I guess it was a workaround for some issue!

Currency Codes

I noticed an issue with another modules which looks at the Currency field code for the chosen Currency.

This seems to mae an exception when you have a Custom Currency with a code with more than 3 characters...

I don't know if you can take that into account or list it as an known issue or something.

Unable to inject custom currency at install time.

Magento Version: 2.3.5
Plugin Version: 1.1.3

Good afternoon,

I have spent a good amount of time trying to get a custom currency to run at install time following the instructions in the README. I edit the di.xml file to include:

<type name="EcommPro\CustomCurrency\Model\Config"><arguments><argument name="currencies" xsi:type="array"><item name=“EXAMPLE” xsi:type="array"><item name="code" xsi:type="string">EXAMPLE</item><item name="singular" xsi:type="string">Example</item><item name="plural" xsi:type="string">Examples</item></item></argument></arguments></type>

After that, I have tried all of the following, but none of them cause the currency to show in the currency config screen or the ecom custom currency screen.

  • bin/magento cache:clean
  • bin/magento cache:flush
  • bin/magento setup:upgrade
  • bin/magento setup:di:compile
  • deleting the changed generated files in the /generated folder

I am able to run bin/magento dev:di:info "EcommPro\CustomCurrency\Model\Config" and see the example json as the value of currences, but nothing is changing in the UI.

I'm not a php expert, but I saw that this commit removed reference the currencies variable, maybe that is the issue? Any help to get this working is appreciated. Thanks!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.