I've created a minimal working patch for now, which adds a Mode setting to the Square settings form.
I think this could be improved by either having a single set of credentials and using Mode to determine which endpoint to use, or having two sets of credentials, one each for Sandbox & Production. For the first option however, the logic for creating a Square Payment Gateway would then have to be updated as well. OTOH for the second option, we'll have to work on whether all fields should be optional/required, and we would also need to work out how to auth with the different endpoints (probably have a separate button for each mode).
I am not sure which one is right for now, since I've just started using Square and I only needed to test the Sandbox locally for now and the patch I made just worked. Happy to look a bit more into it once I have more time and if other people have any feedback.
yusufhm β created an issue.
I've given up on making the changes here - I'm quite pressed for time on this project I'm working on, and the fixes required for this module to work are way more involved than I initially thought. Might revisit this in the future if/once I get some more time on my hands.
yusufhm β created an issue.
Merged & tagged
Hi @kopeboy, I've updated the project page as requested.
yusufhm β made their first commit to this issueβs fork.
yusufhm β made their first commit to this issueβs fork.
I have updated the PHP requirement to also allow ^8.0.
yusufhm β made their first commit to this issueβs fork.