@extends('layouts.frontend') @section('content')

Мой кабинет

@if(Auth::user()->is_admin)
Перейти в админку
@endif
Customer Info

Имя пользователя: {{ Auth::user()->name }}

Email: {{ Auth::user()->email }}


Your Orders
@php $orders = Auth::user()->orders ?? collect(); @endphp @if($orders->count() > 0)
@foreach($orders as $order) @endforeach
Order ID Товары Сумма Статус оплаты Статус заказа Дата
#052{{ $order->id }} @php $products = json_decode($order->products, true); @endphp @if($products)
    @foreach($products as $productId => $quantity) @php $product = \App\Models\Product::find($productId); $images = $product && $product->images ? json_decode($product->images, true) : []; $image = $images[0] ?? null; @endphp
  • @if($image) {{ $product->name ?? '' }} @else
    @endif {{ $product->name ?? 'Товар #' . $productId }} — {{ $quantity }} шт.
  • @endforeach
@endif
{{ $order->total }} {{ $order->payment_currency ?? '' }} {{ ucfirst($order->payment_status) }} {{ ucfirst($order->order_status) }} {{ $order->created_at->format('H:i d.m.Y') }}
@else

У вас пока нет заказов.

@endif
Сменить пароль
@if(session('success'))
{{ session('success') }}
@endif @if(Auth::user()->temporary_password)
Ваш временный пароль: {{ Auth::user()->temporary_password }}
@endif
@csrf
@error('current_password') {{ $message }} @enderror
@error('new_password') {{ $message }} @enderror
@endsection