]> gitweb.erp-flowers.ru Git - erp24_rep/yii-erp24/.git/commit
fix(ERP-252): extract fillDeliveryAddressFallback method, eliminate duplication
authorAleksey Filippov <Aleksey.Filippov@erp-flowers.ru>
Mon, 2 Mar 2026 20:45:48 +0000 (23:45 +0300)
committerAleksey Filippov <Aleksey.Filippov@erp-flowers.ru>
Mon, 2 Mar 2026 20:45:48 +0000 (23:45 +0300)
commit129c6b052c91c1408de327152aa41ca644a8c2e9
tree2344017520000e4005b936850010d72a8a2f6df7
parente83a19085aef6a593100966a4d25fff75b02f975
fix(ERP-252): extract fillDeliveryAddressFallback method, eliminate duplication

- New method fillDeliveryAddressFallback() handles 3 raw_data formats:
  1) string (FlowWow text) → parseAddressFromDeliveryText()
  2) array with address (YM API JSON) → extract structured fields
  3) null/missing → defaults "Уточняется"
- Replaced 3 inline fallback blocks with single method call
- Fixed surprise-delivery parsing ("Отправим смс получателю...")
- 20 unit tests, 115 assertions — all passing

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
erp24/services/MarketplaceService.php
erp24/tests/unit/services/MarketplaceServiceDeliveryParsingTest.php