@extends('admin.social-automation.layout') @section('title', 'İş #'.$job->id) @section('sma_content')

{{ $job->displayName() }} {{ $job->status }}

@if ($job->name)

İş #{{ $job->id }}

@endif @if ($job->recurringContentPlan)

Otomatik İçerik planından üretildi: {{ $job->recurringContentPlan->name }}

@endif

Tarif: {{ $job->keywords ?: '—' }}

@if ($job->status === \App\Models\SocialAutomation\ContentJob::STATUS_FAILED && $job->error_message)
⚠️ Üretim başarısız oldu: {{ $job->error_message }}
@endif @php $isEditable = in_array($job->status, [\App\Models\SocialAutomation\ContentJob::STATUS_AWAITING_APPROVAL, \App\Models\SocialAutomation\ContentJob::STATUS_SCHEDULED], true); @endphp

Hikaye

@php $storyReady = ! in_array($job->status, [\App\Models\SocialAutomation\ContentJob::STATUS_QUEUED, \App\Models\SocialAutomation\ContentJob::STATUS_GENERATING_STORY], true); @endphp @if ($storyReady) @if ($isEditable)
@csrf @method('PATCH') @if ($job->story_text)

{{ $job->story_text }}

@endif @error('title')

{{ $message }}

@enderror @error('caption')

{{ $message }}

@enderror
@else

{{ $job->title }}

{{ $job->story_text }}

{{ $job->caption }}

{{ implode(' ', $job->hashtags ?? []) }}

@endif @else

Hikaye henüz üretilmedi...

@endif

Üretilen Görsel / Video

@if ($job->media_paths) @foreach ($job->media_paths as $ratio => $group)

{{ ['vertical' => 'Dikey (Story/Reels/Shorts)', 'square' => 'Kare (Post)', 'horizontal' => 'Yatay (Normal Video)'][$ratio] ?? $ratio }}

@if (isset($group['image'])) Üretilen görsel @endif @if (isset($group['video'])) @endif
@endforeach @else

Henüz üretilmedi...

@endif
@if ($job->status === 'awaiting_approval')

Sonucu beğendin mi?

Yukarıdaki hikaye/görsel/video hazır ama henüz hiçbir yere paylaşılmadı. Beğenmediysen bir şey yapmana gerek yok — paylaşmak istediğin platformları seçip aşağıdan onaylarsan gönderilir.

@csrf
@foreach ($platforms as $key => $meta) @php $platformAccounts = $accounts[$key] ?? collect(); @endphp
@if (in_array($key, ['youtube', 'linkedin', 'pinterest', 'facebook', 'threads', 'tiktok', 'x']) && $platformAccounts->count() > 1) @endif @if (isset($meta['content_types'])) @endif
@endforeach
@error('platforms')

{{ $message }}

@enderror

Boş bırakırsan hemen paylaşılır. Bir tarih/saat seçersen, o ana kadar hiçbir yere gönderilmez.

@error('scheduled_at')

{{ $message }}

@enderror
@endif @if ($job->status === 'scheduled')

Zamanlandı

Bu iş {{ $job->scheduled_at?->translatedFormat('d F Y H:i') }} tarihinde otomatik olarak şu platformlara paylaşılacak: {{ collect($job->target_platforms)->map(fn ($p) => $platforms[$p]['label'] ?? $p)->join(', ') }}.

@csrf @method('DELETE')
@endif

Platform Sonuçları

@php $metricLabels = [ 'views' => 'Görüntülenme', 'likes' => 'Beğeni', 'comments' => 'Yorum', 'retweets' => 'Retweet', 'replies' => 'Yanıt', 'impressions' => 'Gösterim', 'saves' => 'Kaydetme', 'pin_clicks' => 'Pin Tıklama', 'outbound_clicks' => 'Dış Bağlantı Tıklama', ]; @endphp @foreach ($job->publishResults as $result) @endforeach
PlatformDurumBağlantı / NotMetrikler
@include('admin.social-automation.partials.platform-icon', ['platform' => $result->platform, 'size' => 18]) {{ $platforms[$result->platform]['label'] ?? $result->platform }} {{ $result->status }} @if ($result->external_url) görüntüle @else {{ $result->error_message }} @endif @if ($result->status === 'success') @if ($result->metrics)
@foreach ($result->metrics as $metricKey => $metricValue)
{{ $metricLabels[$metricKey] ?? $metricKey }}: {{ number_format($metricValue) }}
@endforeach

Son güncelleme: {{ $result->metrics_fetched_at?->diffForHumans() }}

@endif
@csrf
@else — @endif
@if (count($job->publishResults) === 0 && $job->status === 'publishing')

Paylaşım sonuçları bekleniyor...

@elseif (count($job->publishResults) === 0)

Henüz paylaşım yapılmadı.

@endif
← Önceki Görevler'e dön @endsection