Skip to content

Conversation

@diego-ramos
Copy link
Contributor

This should be a temporary fix, as is a better solution to have some kind of enum with ids and descrption, but this will be a bigger change.

@jekkos
Copy link
Member

jekkos commented Apr 24, 2025

Hi problem with this fix is that existing data for payment types will need to be migrated to base64. So it's not backward compatible

@diego-ramos
Copy link
Contributor Author

Hi @jekkos, sorry for the late response, I just see your comment, but you are not right, if you check my code I'm not storing anything with base64, I'm just taking the stored "id" that is not a real id, is the string of the payment type ( in the language selected, that is what is causing the error ) and then I encoded on the frontend template to use it on the url to send the data without errors to the controller, then I decode the frontend data and continue from there, there is no need to migrate data.

@jekkos
Copy link
Member

jekkos commented May 21, 2025

You are right, this is only to store data in the session. Any reason you did not use url encoding?

@diego-ramos
Copy link
Contributor Author

You are right, this is only to store data in the session. Any reason you did not use url encoding?

Because encoding it throws same exception (the problem is when the url is decoded by codeigniter), I tried several options, and finally this one is the only one I found that works.

@jekkos jekkos merged commit 85120fa into opensourcepos:master May 22, 2025
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants