@extends('layouts.auth') @section('title') {{ __('words.Post Ad') }} @endsection @push('page_style') @endpush @php @endphp @section('content') @include("loader.loader")
@php $firstcatgeory = $subSubCategory->getFirstCatgeoryOfParent(); @endphp @if (!empty($model->id)) back-icon{{ __('detail.go back') }} @else @if ( !empty($subSubCategory->parent->parent) && ($subSubCategory->parent->parent->slug == 'sale' || $subSubCategory->parent->parent->slug == 'buy')) @php $previousCategory = $subSubCategory->parent->parent->subCategory()->first(); if ( $previousCategory->slug == 'office_school' || $previousCategory->slug == 'adopt_pets' || $previousCategory->slug == 'fashion' ) { $previousCategory = \App\Models\Category::where('id', '>', $previousCategory->id) ->where('parent_id', $subSubCategory->parent->parent_id) ->first(); if ( $previousCategory->slug == 'old_traditional_fashion' || $previousCategory->slug == 'fashion' ) { $previousCategory = \App\Models\Category::where('id', '>', $previousCategory->id) ->where('parent_id', $subCategory->parent_id) ->first(); } } @endphp @else @if ( !empty($subSubCategory->parent) && $subSubCategory->parent->slug != 'buy' && $subSubCategory->parent->slug != 'sale' && $subSubCategory->parent->slug != 'crypto' && $subSubCategory->parent->slug != 'business' && $subSubCategory->parent->slug != 'toys_games' && $subSubCategory->parent->slug != 'home_garden' && $subSubCategory->parent->slug != 'services' && $subSubCategory->parent->slug != 'jobs' && $subSubCategory->parent->slug != 'websites_domains' && $subSubCategory->parent->slug != 'others') @else @endif @endif @endif
{{ __('words.Post Your Ad') }}
@php $allPrents = $subSubCategory->getAllParentCategories($subSubCategory); $parentSlug = $subSubCategory->parent->slug; $allowedParentSlugs = [ 'crypto', 'business', 'home_garden', 'toys_games', 'services', 'jobs', 'websites_domains', 'others', ]; @endphp

{{ __('words.SELECTED CATEGORY') }} @if ( !empty($subSubCategory->parent->parent) && ($subSubCategory->parent->parent->slug == 'sale' || $subSubCategory->parent->parent->slug == 'buy' || $subSubCategory->slug == 'sale' || $subSubCategory->slug == 'buy')) @php $previousCategory = $subSubCategory->parent->parent->subCategory()->first(); if ( $previousCategory->slug == 'office_school' || $previousCategory->slug == 'fashion' || $previousCategory->slug == 'adopt_pets' ) { $previousCategory = \App\Models\Category::where('id', '>', $previousCategory->id) ->where('parent_id', $subSubCategory->parent->parent_id) ->first(); if ( $previousCategory->slug == 'old_traditional_fashion' || $previousCategory->slug == 'fashion' ) { $previousCategory = \App\Models\Category::where( 'id', '>', $previousCategory->id, ) ->where('parent_id', $subCategory->parent_id) ->first(); } } @endphp {{ __('words.Change') }} @else @if ( $parentSlug != 'buy' && $parentSlug != 'sale' && $parentSlug != 'crypto' && $parentSlug != 'business' && $parentSlug != 'home_garden' && $parentSlug != 'toys_games' && $parentSlug != 'services' && $parentSlug != 'jobs' && $parentSlug != 'websites_domains' && $parentSlug != 'others') {{ __('words.Change') }} @else @endif @endif
@foreach ($allPrents as $parent) {{ !empty($parent) ? __("category.$parent->title") : '' }} @if ( $parentSlug == 'crypto' || $parentSlug == 'business' || $parentSlug == 'home_garden' || $parentSlug == 'toys_games' || $parentSlug == 'services' || $parentSlug == 'jobs' || $parentSlug == 'websites_domains' || $parentSlug == 'others') {{ __("category.$subSubCategory->title") }} @endif @endforeach @if (!in_array($parentSlug, $allowedParentSlugs)) {{ $subSubCategory->title }} @endif


@csrf @php $mainCategory = $subSubCategory->getTopRootParentCategory($subSubCategory); @endphp @include('advertisment.partials.category') @foreach ($allPrents as $parent) @endforeach @if ( $subSubCategory->slug != 'adopt_pets' && $subSubCategory->slug != 'fashion' && $subSubCategory->slug != 'office_school') @if ($subSubCategory->getTopSecondRootParentCategory($subSubCategory)->slug != 'buy')

{{ __('attribute.Upload Photos') }} *
{{ __( 'words.The maximum size of a single image is 5 MB. We suggest that images are smaller than 1200/1200px. All photos must be clear and show an actual product or service.', ) }}

{{ __('attribute.(Max. 6 images)') }}

{{--
id }}>
--}} {{--
@if ($files)
@foreach ($files as $file)
@endforeach
@endif
--}}
@if ($files) @foreach ($files as $file)
@endforeach @endif
{{-- Upload Buttons --}}
{{-- Camera Button --}} {{-- Upload from Gallery Button --}}
@endif @if ( !empty($category->slug) && ($category->slug == 'sale' || $subCategory->slug == 'sale' || $subSubCategory->slug == 'sale' || $subSubCategory->getTopSecondRootParentCategory($subSubCategory)->slug == 'sale')) @endif
{{ __('words.Please review the fields marked in red and correct the information.') }}

@include('advertisment.partials.setPrice')

{{ __('attribute.PAYMENT METHODS') }}

@php if ($subSubCategory->parent->slug != 'jobs') { if ( $subSubCategory->getTopSecondRootParentCategory($subSubCategory) ->slug == 'sale' ) { $cryptotext = 'Add up to 5 Cryptocurrency you have accept'; } else { $cryptotext = 'Add up to 5 Cryptocurrency you want to pay with'; } } else { if ( $subSubCategory->getTopSecondRootParentCategory($subSubCategory) ->slug == 'sale' ) { $cryptotext = 'Add up to 5 Cryptocurrency you want to pay with'; } else { $cryptotext = 'Add up to 5 Cryptocurrency you have accept'; } } @endphp {{ __("attribute.$cryptotext") }} *
{{ __('words.Add up to 5 Cryptocurrencies that you accept as a payment method.') }}

{{ __('attribute.(minimum 1 Currency)') }}

@if ($model->cryptoPayment->count() > '0') @foreach ($model->cryptoPayment as $method)
@if (!empty($method->payment->image))

{{ $method->payment->title }} {{ $method->payment->symbol }}

@else

{{ $otherValue }}

@endif
@endforeach @endif
@php $text = !empty($model->id) ? 'Edit' : '+ Add'; @endphp {{ __('attribute.+ Add') }} @if ($errors->has('payment_methods')) {{ $errors->first('payment_methods') }} @endif
@include('advertisment.partials.money') {{-- @if ($category->slug != 'excursions_vacations') --}} @include('advertisment.partials.good-service') {{-- @endif --}} @include('advertisment.partials.ad-schedule')
{{-- --}}

@endif
@include('advertisment.partials.adsModal')
@push('page_script') @endpush @endsection