lyra / plugin-magento

An open source plugin that links Magento based e-commerce websites to PayZen secure payment gateway developed by Lyra Network.
https://lyra.com/fr/guides/magento/
Open Software License 3.0
10 stars 12 forks source link

Error after update to 2.5.4 (systempay lyra) #20

Closed rsm1024 closed 3 years ago

rsm1024 commented 3 years ago

I can no longer access the backend unless I deactivate the module. in the log : main.ERROR: Type Error occurred when creating object: Lyranetwork\Systempay\Helper\Data

1 exception(s): Exception #0 (Magento\Framework\Exception\RuntimeException): Type Error occurred when creating object: Lyranetwork\Systempay\Helper\Data

rsm1024 commented 3 years ago

I succeeded by replacing the data.php file in \Helper with the old one from 2.5.0

data.zip

nabil509 commented 3 years ago

Hi,

The class Data/Helper.php dependencies are updated in this version. You should run Magento compilation command or delete the generated/code/Lyranetwork/ directory and clean Magento cache to fix error.

rsm1024 commented 3 years ago

Hi,

The class Data/Helper.php dependencies are updated in this version. You should run Magento compilation command or delete the generated/code/Lyranetwork/ directory and clean Magento cache to fix error.

Hi, I tried everything setup upgrade, compile, cache clean, flush.. The only solution I have found is to replace the file data.php with the old one and now i have no more errors.

check the difference between the 2 files "data.php"

i have magento 2.4.0

rsm1024 commented 3 years ago

I also have an error in the console

Uncaught TypeError: Cannot read property 'element' of undefined at Event._isCustomEvent.a (legacy-build.min.js:1)

Thank you for your help.

nabil509 commented 3 years ago

Hi,

We just tested on Magento 2.4.0. We have no problem neither on frontend nor on backend. We also compared the two files and the changes in the last version are wanted.

I think the two problems you face are related and you can solve them by deleting the generated/code/Lyranetwork/ directory and uploading the Magento static resources.

It seems your Magento references old file of our plugin for the first problem and did not deploy a find a JS file for the second one.

Let me know if this helps please.

rsm1024 commented 3 years ago

I found this code in data.php (version 2.5.0) which is not in the new version. `/**

the problem is that on my php.ini configuration, openssl was not activated. i activate openssl and now everything is working fine. even with version 2.5.5

thank you