@extends('layout.app') @section('content')

Publicaciones Programadas: {{ $schedule->name }}

@php // Agrupar entradas por día $entriesByDay = $entries ->groupBy(function ($entry) { return $entry->date_estimate_execute ? \Carbon\Carbon::parse($entry->date_estimate_execute)->format('Y-m-d') : 'Sin fecha'; }) ->sortKeys(); @endphp @if ($entriesByDay->isEmpty())
No hay publicaciones programadas para mostrar.
@else @foreach ($entriesByDay as $date => $dayEntries)

@if ($date == 'Sin fecha') Sin fecha de programación @else {{ \Carbon\Carbon::parse($date)->formatLocalized('%A, %d de %B de %Y') }} @endif


@foreach ($dayEntries as $entry)
@if (isset($entry->post))

{{ $entry->feed_entry->title }}

{{ $entry->date_estimate_execute ? \Carbon\Carbon::parse($entry->date_estimate_execute)->format('l, d \d\e F \d\e Y, H:i') : 'Fecha no programada' }}
{{ $entry->post->social_network_name }}
@if (isset($entry->post))
@if ($entry->post->status == 'scheduled') Programado @elseif($entry->post->status == 'posted') Publicado @elseif($entry->post->status == 'failed') Fallido @else {{ $entry->post->status }} @endif
@endif Imagen de la publicación

{{ $entry->post->caption }}

@endif

Fecha de ejecución: {{ isset($entry->post->scheduled_at) ? \Carbon\Carbon::parse($entry->post->scheduled_at)->format('d/m/Y H:i') : 'Pendiente de ejecución' }}

@endforeach
@endforeach @endif
Volver
@endsection