@extends('layouts.app') @section('content')
{{-- BREADCRUMB --}}
{{-- BUTTONS --}}
YAZDIR @if (auth()->user()->current_team_id == 2 || auth()->user()->current_team_id == 49) ÖDEME NOTUNU GİZLE @endif @if (count($bulutadisyon_integrations) > 0 && $invoice->type == 'purchase_invoice') STOK DAĞITIMI @endif @if (!$invoice->stockAllocations || $invoice->stockAllocations->isEmpty()) BELGEYİ DÜZENLE @include('modals.cancel', [ 'title' => 'FATURA SİLİNECEK', 'subtitle' => 'Fatura silme işlemi geri alınamaz. Devam etmek istiyor musunuz?', 'route' => route('invoices.destroy', $invoice->id), 'cancel' => 'HAYIR, GERİ DÖN', 'confirm' => 'EVET, SİL', 'b_name' => 'BELGEYİ SİL', 'b_icon' => 'delete', 'b_color' => 'rose', 'b_ring' => 'rose', 'b_href' => '#', ]) @endif
{{-- FATURA GÖRSELLERİ --}} @if (count($invoice_images ?? []) > 0)

image Fatura Görselleri

{{-- GÖRSEL ÖNİZLEME MODALI --}}
@endif @if ($invoice->type == 'sales_invoice') @if ($invoice->durum == null) {{-- GÖNDER --}}

E-BELGE OLUŞTUR

@include('modals.cancel', [ 'title' => 'E-BELGE OLUŞTURULACAK', 'subtitle' => 'Belge oluşturulduktan sonra düzenleme ve silme işlemi yapamayacaksınız. Devam etmek istiyor musunuz?', 'route' => route('send', $invoice->id), 'cancel' => 'HAYIR, GERİ DÖN', 'confirm' => 'EVET, OLUŞTUR', 'b_name' => 'E-BELGE OLUŞTUR', 'b_icon' => 'receipt_long', 'b_color' => 'stone', 'b_ring' => 'amber', 'b_href' => '#', ])
@endif @if ($invoice->durum) {{-- Belge Durumu Bilgilendirme --}} @if ($invoice->durum == 1)

BELGE İŞLENMEYİ BEKLİYOR

Bu belge entegratör tarafından alınmıştır ancak henüz işlenmemiştir. Lütfen durumu kontrol etmek için aşağıdaki butonu kullanın.

@elseif ($invoice->durum == 'draft')

TASLAK OLARAK OLUŞTURULDU

Bu belge oluşturulmuştur ancak henüz GİB'e gönderilmemiştir. Belgeyi inceledikten sonra "ONAYLA" butonu ile GİB'e gönderebilirsiniz.

@elseif ($invoice->durum == 2)

BELGE İŞLENEMEDİ

Bu belge işlenirken bir hata oluştu. Lütfen fatura bilgilerinizi kontrol edin veya destek ekibiyle iletişime geçin.

@if ($invoice->gonderim_cevabi_detayi)

Hata Detayı: {{ $invoice->gonderim_cevabi_detayi }}

@endif
@elseif ($invoice->durum == 3)

BELGE BAŞARIYLA İŞLENDİ

Bu belge entegratörünüz tarafından başarıyla işlenmiştir. Oluşturulan e-belgeye ait detaylı bilgi ve işlemler için entegratör panelini kullanabilirsiniz.

@if ($invoice->ulasti_mi)

✓ Belge alıcıya ulaştı

@endif
@else

BELGE İŞLENDİ

Bu belge entegratör tarafından başarıyla işlenmiştir. Oluşturulan e-belgeye ait detaylı bilgi ve işlemler için entegratör panelini kullanabilirsiniz.

@endif {{-- DURUM GÜNCELLE --}}

Son güncelleme: {{ $invoice->updated_at ? $invoice->updated_at->diffForHumans() : 'Bilinmiyor' }}

{{-- E-FILE DETAILS AND STATUS --}} @if ($invoice->ettn || $invoice->uuid || $invoice->belgeOid)

E-Fatura Bilgileri

@if ($invoice->ettn)
ETTN:
{{ $invoice->ettn }}
@endif @if ($invoice->uuid)
UUID:
{{ Str::limit($invoice->uuid, 20) }}
@endif @if ($invoice->belgeOid)
Belge OID:
{{ $invoice->belgeOid }}
@endif @if ($invoice->gonderim_cevabi_kodu)
Cevap Kodu:
{{ $invoice->gonderim_cevabi_kodu }}
@endif
@endif

DİKKAT

Oluşturulan e-belgeler üzerinde düzenleme yapılamaz. İptal etmek isterseniz entegratör portalından iptal ettikten sonra buradan iptalini yapabilirsiniz.

@endif {{-- NOTIFICATION FOR STOCK ALLOCATION --}} @if ($invoice->stockAllocations && $invoice->stockAllocations->isNotEmpty())

DİKKAT

Bu fatura için stok dağıtım kayıtları bulunmaktadır. Bu nedenle fatura üzerinde işlem yapamazsınız.

@endif @endif @if ($invoice->stockAllocations && $invoice->stockAllocations->isNotEmpty()) {{-- STOCK ALLOCATIONS --}}
STOK DAĞITIMLARI
@foreach ($invoice->stockAllocations as $stockAllocation)
{{ $stockAllocation->invoiceLine->name }} x {{ $stockAllocation->allocated_quantity }} -> {{ $stockAllocation->targetAccount ? $stockAllocation->targetAccount->title : 'Hesap Bilgisi Yok' }} @if ($stockAllocation->warehouse) / {{ $stockAllocation->warehouse->name }} @else / ANA DEPO @endif
{{ (function ($name) { $parts = explode(' ', trim($name)); if (count($parts) === 0) { return ''; } $firstName = array_shift($parts); $initials = implode( ' ', array_map(function ($word) { return mb_strtoupper(mb_substr($word, 0, 1)) . '.'; }, $parts), ); return $firstName . ($initials ? ' ' . $initials : ''); })($stockAllocation->user->name) }}
@endforeach

Faturada stok dağıtım kayıtları bulunmaktadır. Bu nedenle fatura üzerinde işlem yapamazsınız.

@endif {{-- AKTİVİTELER --}}

history Düzenleme Geçmişi

  • {{ $invoice->user->name }}
    Belgeyi oluşturdu.

    @if ($invoice->created_at) @endif
@include('invoice._partials.header') @if ($invoice->type == 'sales_invoice' || $invoice->type == 'purchase_invoice') @include('invoice._partials.invoice-content') @elseif ($invoice->type == 'received' || $invoice->type == 'paid') @include('invoice._partials.bill-content') @endif @if (auth()->user()->current_team_id == 2 || auth()->user()->current_team_id == 49)

{{ date('d.m.Y', strtotime($invoice->due_date)) }} tarihine kadar {{ number_format($invoice->ex_amount, 2, ',', '.') }} {{ $invoice->currency }} ({{ number_format($invoice->total_amount, 2, ',', '.') }} TRL) ödenmesi bekleniyor

ÖDEME BİLGİLERİ

Yerel banka hesap bilgileri - TRL

UGUR KARAGOZ

IBAN - TR92 0015 7000 0000 0044 7868 54

BANKA - ENPARA BANK

@if ($invoice->currency == 'EUR')

Uluslararası banka hesap bilgileri - EUR

APPER SOFTWARE OÜ

IBAN - BE29 9058 3935 6464

BIC - TRWIBEB1XXX

BANKA - WISE, Rue du Trône 100, 3rd floor, Brussels, 1050, Belgium

@elseif ($invoice->currency == 'USD')

Uluslararası banka hesap bilgileri - USD

APPER SOFTWARE OÜ

IBAN - 217689072765

BIC - TRWIUS35XXX

BANKA - WISE US Inc, 108 W 13th St, Wilmington, DE, 19801, United States

@elseif ($invoice->currency == 'GBP')

Uluslararası banka hesap bilgileri - USD

APPER SOFTWARE OÜ

IBAN - GB47TRWI60846477365932

BIC - TRWIGB2LXXX

BANKA - WISE Payments Limited, Worship Square, 65 Clifton Street, London, EC2A 4JE, United Kingdom

@endif
@endif
@endsection @section('scripts') @endsection