@extends('admin.layout') @section('content') @php $vendorId = App\Models\Listing\Listing::where('id', $listing_id)->pluck('vendor_id')->first(); if ($vendorId != 0) { $current_package = App\Http\Helpers\VendorPermissionHelper::packagePermission($vendorId); if (!empty($current_package) && !empty($current_package->features)) { $permissions = json_decode($current_package->features, true); $additionalFeatureLimit = packageTotalAdditionalSpecification($vendorId) - $totalFeature; } else { $permissions = null; $additionalFeatureLimit = 0; } } else { $permissions = ['Feature']; $additionalFeatureLimit = 999999; } @endphp
{{ __('Features') }}
{{ __('Back') }} @php $dContent = App\Models\Listing\ListingContent::where('listing_id', $listing_id) ->where('language_id', $defaultLang->id) ->first(); $slug = !empty($dContent) ? $dContent->slug : ''; @endphp @if ($dContent) {{ __('Preview') }} @endif
    @csrf @if (is_array($permissions) && in_array('Feature', $permissions))

    {{ __('Features') }}

    @foreach ($features as $feature)
    @foreach ($languages as $language) @php $feature_content = App\Models\Listing\ListingFeatureContent::where([ ['language_id', $language->id], ['listing_feature_id', $feature->id], ])->first(); @endphp
    @endforeach X
    @php $feature_content = App\Models\Listing\ListingFeatureContent::where( 'listing_feature_id', $feature->id, )->get(); $op = json_decode($feature_content[0]['feature_value']); @endphp @if ($op) @foreach ($op as $opIn => $w)
    @php $opArr = []; for ($i = 0; $i < count($languages); $i++) { $opArr[$i] = json_decode($feature_content[$i]['feature_value'] ?? ''); } @endphp @for ($i = 0; $i < count($languages); $i++)
    @endfor
    @endforeach @endif
    @endforeach
    @endif
    @endsection @section('script') @endsection @section('variables') @endsection