[PR #265] [MERGED] PayflexCPV4 refactoring and fixes #278

Closed
opened 2026-03-03 15:44:17 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/mewebstudio/pos/pull/265
Author: @nuryagdym
Created: 2/18/2025
Status: Merged
Merged: 2/18/2025
Merged by: @nuryagdym

Base: masterHead: payflexcpv4-refactoring


📝 Commits (6)

  • f439d6f PayFlexCPV4Pos - fix response decode exception
  • 02a250f PayFlexCPV4Pos - remove unsupported transactions
  • 0c4ae6f PayFlexCPV4Pos - fix 3d payment status request
  • ff3e9fe PayFlexCPV4Pos - change gateway endpoints config
  • d275b15 PayFlexCPV4Pos - use http_build_query instead of form_params
  • 9bbc5df PayFlexCPV4Pos - coverage tests

📊 Changes

16 files changed (+422 additions, -559 deletions)

View changed files

📝 README.md (+1 -1)
📝 config/pos_production.php (+2 -3)
📝 config/pos_test.php (+2 -3)
examples/payflex-cp-v4/regular/cancel.php (+0 -3)
examples/payflex-cp-v4/regular/form.php (+0 -3)
examples/payflex-cp-v4/regular/post-auth.php (+0 -3)
examples/payflex-cp-v4/regular/refund.php (+0 -3)
📝 phpstan-baseline.neon (+12 -6)
📝 src/DataMapper/RequestDataMapper/PayFlexCPV4PosRequestDataMapper.php (+11 -106)
📝 src/DataMapper/ResponseDataMapper/PayFlexCPV4PosResponseDataMapper.php (+10 -68)
📝 src/Gateways/PayFlexCPV4Pos.php (+128 -61)
📝 src/Serializer/PayFlexCPV4PosSerializer.php (+3 -28)
📝 tests/Unit/DataMapper/RequestDataMapper/PayFlexCPV4PosRequestDataMapperTest.php (+86 -11)
📝 tests/Unit/DataMapper/ResponseDataMapper/PayFlexCPV4PosResponseDataMapperTest.php (+63 -0)
📝 tests/Unit/Gateways/PayFlexCPV4PosTest.php (+101 -199)
📝 tests/Unit/Serializer/PayFlexCPV4PosSerializerTest.php (+3 -61)

📄 Description

  • bug fix: Banka API'i Accept header'i gondermeyice JSON response donmeye baslamis, bu da decode ederken exection'a sebep oluyordu. (issue #264)
  • bug fix: isteklerde MerchantId yerine HostMerchantId gonderilecek sekilde guncellendi. (issue #264)
  • breaking change: configdeki gateway_endpoints URL'ler tekrardan duzenlendi. Bu gateway henuz 100% calismadigindan bu breaking change sorun cikarmamasi lazim.
  • clean up: PayFlexV4'den kopyalarken bazi PayflexCPV4 tarafindan deskteklenmeyen islemler vardi. Bu eski kodlar kaldirildi.
  • refactoring: istek gonderirken form_params kullanmak yerine serializerda http_build_query kullanilacak sekilde degistirildi.
  • tests: test eksigi olan yerlere yeni testler eklendi

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/mewebstudio/pos/pull/265 **Author:** [@nuryagdym](https://github.com/nuryagdym) **Created:** 2/18/2025 **Status:** ✅ Merged **Merged:** 2/18/2025 **Merged by:** [@nuryagdym](https://github.com/nuryagdym) **Base:** `master` ← **Head:** `payflexcpv4-refactoring` --- ### 📝 Commits (6) - [`f439d6f`](https://github.com/mewebstudio/pos/commit/f439d6f78a4d94b23cd81dbabac9ec6ac1db8c92) PayFlexCPV4Pos - fix response decode exception - [`02a250f`](https://github.com/mewebstudio/pos/commit/02a250f4ccea36b1cba2f95fe74a93e8bf897a52) PayFlexCPV4Pos - remove unsupported transactions - [`0c4ae6f`](https://github.com/mewebstudio/pos/commit/0c4ae6f0fbbcb36d403cbde9be1f38d6dbab9a14) PayFlexCPV4Pos - fix 3d payment status request - [`ff3e9fe`](https://github.com/mewebstudio/pos/commit/ff3e9fec045adfc967f6b2284872be406abab176) PayFlexCPV4Pos - change gateway endpoints config - [`d275b15`](https://github.com/mewebstudio/pos/commit/d275b15b6b211244545e2f72d5a6a53f9f54daac) PayFlexCPV4Pos - use http_build_query instead of form_params - [`9bbc5df`](https://github.com/mewebstudio/pos/commit/9bbc5df81fedff36f1910eb89a0ef85c2b1ba194) PayFlexCPV4Pos - coverage tests ### 📊 Changes **16 files changed** (+422 additions, -559 deletions) <details> <summary>View changed files</summary> 📝 `README.md` (+1 -1) 📝 `config/pos_production.php` (+2 -3) 📝 `config/pos_test.php` (+2 -3) ➖ `examples/payflex-cp-v4/regular/cancel.php` (+0 -3) ➖ `examples/payflex-cp-v4/regular/form.php` (+0 -3) ➖ `examples/payflex-cp-v4/regular/post-auth.php` (+0 -3) ➖ `examples/payflex-cp-v4/regular/refund.php` (+0 -3) 📝 `phpstan-baseline.neon` (+12 -6) 📝 `src/DataMapper/RequestDataMapper/PayFlexCPV4PosRequestDataMapper.php` (+11 -106) 📝 `src/DataMapper/ResponseDataMapper/PayFlexCPV4PosResponseDataMapper.php` (+10 -68) 📝 `src/Gateways/PayFlexCPV4Pos.php` (+128 -61) 📝 `src/Serializer/PayFlexCPV4PosSerializer.php` (+3 -28) 📝 `tests/Unit/DataMapper/RequestDataMapper/PayFlexCPV4PosRequestDataMapperTest.php` (+86 -11) 📝 `tests/Unit/DataMapper/ResponseDataMapper/PayFlexCPV4PosResponseDataMapperTest.php` (+63 -0) 📝 `tests/Unit/Gateways/PayFlexCPV4PosTest.php` (+101 -199) 📝 `tests/Unit/Serializer/PayFlexCPV4PosSerializerTest.php` (+3 -61) </details> ### 📄 Description - **bug fix**: Banka API'i `Accept` header'i gondermeyice JSON response donmeye baslamis, bu da decode ederken exection'a sebep oluyordu. (issue #264) - **bug fix**: isteklerde `MerchantId` yerine `HostMerchantId` gonderilecek sekilde guncellendi. (issue #264) - **breaking change**: configdeki `gateway_endpoints` URL'ler tekrardan duzenlendi. Bu gateway henuz 100% calismadigindan bu breaking change sorun cikarmamasi lazim. - **clean up:** PayFlexV4'den kopyalarken bazi PayflexCPV4 tarafindan deskteklenmeyen islemler vardi. Bu eski kodlar kaldirildi. - **refactoring:** istek gonderirken `form_params` kullanmak yerine serializerda `http_build_query` kullanilacak sekilde degistirildi. - **tests:** test eksigi olan yerlere yeni testler eklendi --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-03-03 15:44:17 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/pos#278
No description provided.