fix: duplikaty zamowien + status COD (is_cod flag)
- summaryView(): guard — redirect do istniejacego zamowienia gdy ORDER_SUBMIT_LAST_ORDER_ID w sesji - basketSave(): try-catch wokol createFromBasket(), wyjatki logowane, koszyk zachowany - OrderRepository: usunieto hardkodowane payment_id == 3, uzywana flaga is_cod - PaymentMethodRepository: nowe pole is_cod w normalizacji, save() i forTransport() SQL - ShopPaymentMethodController: switch "Platnosc przy odbiorze" w formularzu edycji - migrations/0.338.sql: ALTER TABLE pp_shop_payment_methods ADD COLUMN is_cod Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -184,6 +184,7 @@ class ShopPaymentMethodController
|
||||
'apilo_payment_type_id' => $paymentMethod['apilo_payment_type_id'] ?? '',
|
||||
'min_order_amount' => $paymentMethod['min_order_amount'] ?? '',
|
||||
'max_order_amount' => $paymentMethod['max_order_amount'] ?? '',
|
||||
'is_cod' => (int)($paymentMethod['is_cod'] ?? 0),
|
||||
];
|
||||
|
||||
$fields = [
|
||||
@@ -220,6 +221,10 @@ class ShopPaymentMethodController
|
||||
'tab' => 'settings',
|
||||
'options' => $apiloOptions,
|
||||
]),
|
||||
FormField::switch('is_cod', [
|
||||
'label' => 'Platnosc przy odbiorze',
|
||||
'tab' => 'settings',
|
||||
]),
|
||||
FormField::switch('status', [
|
||||
'label' => 'Aktywny',
|
||||
'tab' => 'settings',
|
||||
|
||||
Reference in New Issue
Block a user