@@ -19,7 +19,7 @@ class CheckoutController extends Controller
|
||||
$items = $this->cartItems($request);
|
||||
|
||||
if ($items->isEmpty()) {
|
||||
return redirect()->route('cart.index')->with('status', 'Корзина пустая. Добавьте товары перед оформлением.');
|
||||
return redirect()->route('cart.index')->with('status', __('Корзина пустая. Добавьте товары перед оформлением.'));
|
||||
}
|
||||
|
||||
return view('shop.checkout', [
|
||||
@@ -34,7 +34,7 @@ class CheckoutController extends Controller
|
||||
$items = $this->cartItems($request);
|
||||
|
||||
if ($items->isEmpty()) {
|
||||
return redirect()->route('cart.index')->with('status', 'Корзина пустая. Добавьте товары перед оформлением.');
|
||||
return redirect()->route('cart.index')->with('status', __('Корзина пустая. Добавьте товары перед оформлением.'));
|
||||
}
|
||||
|
||||
$validated = $request->validate([
|
||||
@@ -56,12 +56,12 @@ class CheckoutController extends Controller
|
||||
$items = $this->cartItems($request);
|
||||
|
||||
if ($items->isEmpty()) {
|
||||
return redirect()->route('cart.index')->with('status', 'Корзина пустая. Добавьте товары перед оформлением.');
|
||||
return redirect()->route('cart.index')->with('status', __('Корзина пустая. Добавьте товары перед оформлением.'));
|
||||
}
|
||||
|
||||
$customer = $request->session()->get(self::CHECKOUT_CUSTOMER_KEY);
|
||||
if (!is_array($customer)) {
|
||||
return redirect()->route('checkout.show')->with('status', 'Сначала заполните данные получателя.');
|
||||
return redirect()->route('checkout.show')->with('status', __('Сначала заполните данные получателя.'));
|
||||
}
|
||||
|
||||
return view('shop.checkout-payment', [
|
||||
@@ -77,12 +77,12 @@ class CheckoutController extends Controller
|
||||
$items = $this->cartItems($request);
|
||||
|
||||
if ($items->isEmpty()) {
|
||||
return redirect()->route('cart.index')->with('status', 'Корзина пустая. Добавьте товары перед оформлением.');
|
||||
return redirect()->route('cart.index')->with('status', __('Корзина пустая. Добавьте товары перед оформлением.'));
|
||||
}
|
||||
|
||||
$validated = $request->session()->get(self::CHECKOUT_CUSTOMER_KEY);
|
||||
if (!is_array($validated)) {
|
||||
return redirect()->route('checkout.show')->with('status', 'Сначала заполните данные получателя.');
|
||||
return redirect()->route('checkout.show')->with('status', __('Сначала заполните данные получателя.'));
|
||||
}
|
||||
|
||||
$validator = validator($validated, [
|
||||
|
||||
Reference in New Issue
Block a user