{{ __('Últimos movimientos') }}
{{ __('Todavía no registramos propinas para tu cuenta. Cuando se importen cierres las verás aquí.') }}
@else@extends('layouts/layoutMaster') @php use Carbon\Carbon; $pageConfigs = [ 'myLayout' => 'blank', 'navbarType' => 'hidden', 'menuFixed' => false, 'contentLayout' => 'compact', ]; $locale = app()->getLocale(); $summary = $summary ?? ['accrued' => 0, 'paid' => 0, 'pending' => 0, 'currency' => 'EUR']; $entries = ($entries ?? collect())->map(function ($entry) use ($locale, $summary) { $createdAt = $entry->entry_date?->copy()->locale($locale) ?? $entry->created_at?->copy()->locale($locale); $billingPeriod = optional(optional($entry->source)->billingPeriod); $periodLabel = $billingPeriod ? $billingPeriod->periodLabel() : null; return [ 'id' => $entry->id, 'type' => $entry->entry_type, 'is_payment' => $entry->entry_type === 'tip_payment', 'amount' => (float) $entry->amount, 'amount_formatted' => number_format((float) $entry->amount, 2, ',', '.'), 'currency' => $entry->currency ?? $summary['currency'], 'description' => $entry->description ?: ($entry->entry_type === 'tip_payment' ? __('Propinas abonadas en nómina') : __('Propinas registradas')), 'date_label' => $createdAt ? $createdAt->isoFormat('D MMM YYYY · HH:mm') : '', 'period_label' => $periodLabel, ]; }); $periods = ($periods ?? collect())->map(function ($period) use ($summary) { return [ 'billing_period_id' => $period['billing_period_id'], 'label' => $period['label'], 'tips_total' => number_format((float) $period['tips_total'], 2, ',', '.'), 'paid' => number_format((float) $period['paid'], 2, ',', '.'), 'pending' => number_format((float) $period['pending'], 2, ',', '.'), 'currency' => $period['currency'] ?? $summary['currency'], ]; }); @endphp @section('title') {{ __('Propinas') }} @endsection @section('page-style') @endsection @section('content')
{{ __('Consulta las propinas registradas por Glovo, lo que ya se liquidó en tu nómina y lo que queda pendiente para el siguiente pago.') }}
{{ number_format($summary['pending'], 2, ',', '.') }} {{ $summary['currency'] }}
{{ number_format($summary['accrued'], 2, ',', '.') }} {{ $summary['currency'] }}
{{ number_format($summary['paid'], 2, ',', '.') }} {{ $summary['currency'] }}
{{ __('Todavía no registramos propinas para tu cuenta. Cuando se importen cierres las verás aquí.') }}
@else