- Fix: globalna wyszukiwarka - Content-Type, Cache-Control, POST,
FETCH_ASSOC, try/catch wrapper
- New: document.title w szczegółach zamówienia = numer zamówienia
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Fix: (int) cast na apilo_order_id (format "PPxxxxxx") dawał 0, przez co
syncApiloPayment() i syncApiloStatus() pomijały wywołanie API Apilo.
Zmiana na empty() w obu metodach.
New: logowanie ApiloLogger w syncApiloPaymentIfNeeded() i
syncApiloStatusIfNeeded() — każda ścieżka decyzyjna zapisuje wpis
do pp_log z kontekstem.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- curl_getinfo() po curl_close() dawał HTTP 0 — przeniesienie przed close
- nieskończona pętla wysyłki zamówienia przy błędzie serwera Apilo (apilo_order_id = -1)
- ceny 0.00 PLN — string "0.00" z MySQL jest truthy, zmiana na (float) > 0
- walidacja zerowych cen przed wysyłką (apilo_order_id = -2)
- niezainicjalizowana $order_message
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Fix: race condition callback płatności przed wysłaniem do Apilo
- Fix: processApiloSyncQueue czeka na apilo_order_id zamiast usuwać task
- Fix: drugie wywołanie processApiloSyncQueue po wysyłce zamówień w cronie
- Fix: ceny w szczegółach zamówienia (effective price zamiast 0 zł)
- New: persistence filtrów tabel admin (localStorage)
- Testy: 760 tests, 2141 assertions
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Nowa zakladka "Logi" w sekcji Integracje - podglad tabeli pp_log
z paginacja, sortowaniem, filtrami i rozwijalnym kontekstem JSON.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- ApiloLogger: logowanie operacji Apilo do pp_log z kontekstem JSON
- Cache-busting: ?ver=filemtime() dla CSS i JS w admin main-layout
- Fix: inicjalizacja $mdb przed SettingsRepository w admin/index.php
- Fix: rzutowanie (string) w ShopProductController::escapeHtml()
- UI: text-overflow ellipsis dla kategorii produktow + title tooltip
- JS: navigator.clipboard API w copyToClipboard() z fallbackiem
- CSS: uproszczenie .site-content, usuniecie .with-menu
- Migracja: pp_log + kolumny action, order_id, context
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Kolorowe badge statusow na liscie zamowien (pp_shop_statuses.color)
- Walidacja hex koloru z DB (regex), sanityzacja HTML transport
- Polaczenie 2 zapytan SQL w jedno orderStatusData()
- Path-based form submit w table-list.php (admin URL routing)
- 11 nowych testow (750 total, 2114 assertions)
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Added a new remote host configuration to config.php for database connection.
- Updated migration script to ensure proper addition of 'min_order_amount' column in pp_shop_payment_methods table.
- Created .gitignore file to exclude cache directory.
- Added project configuration file for Serena with initial settings and tool configurations.
When all payment methods for a transport are filtered out by
min_order_amount/max_order_amount limits, the transport is now hidden
from the basket. Prevents showing delivery options with empty payment
method lists (e.g. "Kurier - płatność przy odbiorze" when COD exceeds
max amount).
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
PowerShell 5.1 Out-File -Encoding UTF8 adds BOM (EF BB BF) which
breaks SQL execution on production. Also fix manifest JSON serializing
full PS objects instead of plain strings.
- build-update.ps1: use UTF8Encoding($false) for all file writes
- build-update.ps1: force .ToString() on Get-Content results
- UpdateRepository.php: strip BOM and normalize line endings in executeSql
- Rebuild ver_0.304 package files (clean SQL + manifest)
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Replace hardcoded PayPo condition (id=6, 40-1000 PLN) with generic
min/max order amount columns on pp_shop_payment_methods. Admin form
fields added, frontend basket checkout filters dynamically. Cache
invalidation on save. 4 new tests (734 total, 2080 assertions).
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Fix: product attributes with the same sort order value were overwriting
each other in getProductAttributes(), causing only one attribute to
display on the frontend. Now uses usort() with sequential keys.
New: Preview button in product edit form opens product page in new tab.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Table filters hidden by default with toggle button (icon + active count badge)
- Filter state persisted in localStorage; auto-show when filters active
- Order details mobile layout: icon-only action bar, full-width stacking,
compact product list (image + name + qty x price = total), bottom-sheet
dropdown for integrations menu
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Replaces the manual ZIP packaging workflow with an automated build script.
UpdateRepository now supports both manifest JSON format (new) and legacy
_sql.txt/_files.txt format (fallback), enabling a smooth transition for
existing client instances.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- New API layer: ApiRouter, OrdersApiController, DictionariesApiController
- Orders API: list (with filters/pagination/updated_since), details, change status, set paid/unpaid
- Dictionaries API: order statuses, transport methods, payment methods
- X-Api-Key authentication via pp_settings.api_key
- OrderRepository: listForApi(), findForApi(), touchUpdatedAt()
- updated_at column on pp_shop_orders for polling support
- api.php: skip session for API requests, route to ApiRouter
- SettingsController: api_key field in system tab
- 30 new tests (666 total, 1930 assertions)
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Order product CRUD in admin panel (add, delete, edit quantity/prices)
- AJAX product search endpoint for order edit form
- Automatic stock adjustment when editing order products
- Transport cost recalculation based on free delivery threshold
- Fix: promo price = 0 when equal to base price (no real promotion)
- Clean up stale temp/ build artifacts
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Full codebase review of autoload/ directory (96 classes, ~1144 methods).
Fixes: null safety (query/find guards), redundant DI bypass, undefined
variables, missing globals, and Imagick WebP mime type bug in Helpers.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Created new PHP classes for handling shop coupons and orders in the autoload front controls and factories.
- Added a new view class for ShopOrder.
- Introduced a new ShopProducerController and Producer class for managing producers.
- Included version 0.291 zip file with the necessary updates and new files.