@extends('admin.layouts.master') @section('content')

{{ trans('app.preview') }} ({{ trans('app.total_number_of_rows', ['value' => count($rows)]) }})

@can('create', \App\Models\Product::class) {{ trans('app.bulk_import') }} @endcan
{!! Form::open(['route' => 'admin.stock.inventory.import', 'id' => 'form', 'class' => 'inline-form', 'data-toggle' => 'validator']) !!}
@php $serializeData = []; @endphp @foreach ($rows as $row) @php $slug = $row['slug'] ?? convertToSlugString($row['title'], $row['sku']); $image_links = explode(',', $row['image_links']); @endphp {{ Form::hidden('data[]', serialize($row)) }} @endforeach
{{ trans('app.image') }} {{ trans('app.title') }} {{ trans('app.gtin') }} {{ trans('app.price') }} {{ trans('app.variants') }} {{ trans('app.listing') }} {{ trans('app.seo') }}
{{ $row['title'] }} {{ $row['gtin_type'] . ' ' . $row['gtin'] }} @if ($row['offer_price'])
{{ get_formated_currency((float) $row['offer_price'], 2, config('system_settings.currency.id')) }} {{ get_formated_currency((float) $row['price'], 2, config('system_settings.currency.id')) }}

({{ $row['offer_starts'] . ' - ' . $row['offer_ends'] }})

@else {{ get_formated_currency((float) $row['price'], 2, config('system_settings.currency.id')) }} @endif
@php $variants = array_filter( $row, function ($key) { return strpos($key, 'option_name_') === 0; }, ARRAY_FILTER_USE_KEY, ); @endphp
@foreach ($variants as $index => $variant) @if ($row['option_name_' . $loop->iteration] && $row['option_value_' . $loop->iteration])
{{ $row['option_name_' . $loop->iteration] }}:
{{ $row['option_value_' . $loop->iteration] }}
@endif @endforeach
{{ trans('app.sku') }}:
{{ $row['sku'] }}
{{ trans('app.quantity') }}:
{{ $row['stock_quantity'] }}
{{ trans('app.condition') }}:
{{ $row['condition'] }} @if ($row['condition_note']) {{ $row['condition_note'] }} @endif
@if ($row['brand'])
{{ trans('app.brand') }}:
{{ $row['brand'] }}
@endif @if (isset($row['available_from']))
{{ trans('app.available_from') }}:
{{ $row['available_from'] }}
@endif
{{ trans('app.min_order_quantity') }}:
{{ $row['min_order_quantity'] ? $row['min_order_quantity'] : 1 }}
{{ trans('app.free_shipping') }}:
@if ($row['offer_starts'])
{{ trans('app.offer_starts') }}:
{{ $row['offer_starts'] }}
@endif @if ($row['offer_ends'])
{{ trans('app.offer_ends') }}:
{{ $row['offer_ends'] }}
@endif @if ($row['shipping_weight'])
{{ trans('app.shipping_weight') }}:
{{ get_formated_weight($row['shipping_weight']) }}
@endif
{{ trans('app.active') }}:
{{ trans('app.slug') }}:
{{ $slug }}
@if ($row['tags'])
{{ trans('app.tags') }}:
{{ $row['tags'] }}
@endif @if ($row['meta_title'])
{{ trans('app.meta_title') }}:
{{ $row['meta_title'] }}
@endif @if ($row['meta_description'])
{{ trans('app.meta_description') }}:
{{ $row['meta_description'] }}
@endif
{!! Form::close() !!}
@endsection