@php $loop_count = 0; @endphp @foreach ($product_details as $details) @while ($details['qty'] > 0) @php $loop_count += 1; $is_new_row = $barcode_details->stickers_in_one_row == 1 || $loop_count % $barcode_details->stickers_in_one_row == 1 ? true : false; $is_new_paper = ($barcode_details->is_continuous && $is_new_row) || (!$barcode_details->is_continuous && $loop_count % $barcode_details->stickers_in_one_sheet == 1); $is_paper_end = ($barcode_details->is_continuous && $loop_count % $barcode_details->stickers_in_one_row == 0) || (!$barcode_details->is_continuous && $loop_count % $barcode_details->stickers_in_one_sheet == 0); @endphp @if ($is_new_paper) {{-- Actual Paper --}}
{{-- Paper Internal --}}
@endif @if ( !$barcode_details->is_continuous && $loop_count % $barcode_details->stickers_in_one_sheet <= $barcode_details->stickers_in_one_row) @php $first_row = true @endphp @elseif($barcode_details->is_continuous && $loop_count <= $barcode_details->stickers_in_one_row) @php $first_row = true @endphp @else @php $first_row = false @endphp @endif
@if ($result['role'] != 'Admin' && !empty($result['location_business_name'])) {{-- Business Name --}} @if (!empty($print['business_name'])) {{ $result['location_business_name'] }} @endif @else {{-- Business Name --}} @if (!empty($print['business_name'])) {{ $business_name }} @endif @endif {{-- Product Name --}} @if (!empty($print['name'])) {{ $details['details']->product_actual_name }} @endif {{-- Variation --}} @if (!empty($print['variations']) && $details['details']->is_dummy != 1) {{ $details['details']->product_variation_name }}:{{ $details['details']->variation_name }} @endif {{-- Price --}} @if (!empty($print['price'])) @lang('lang_v1.price'): {{ session('currency')['symbol'] ?? '' }} @if ($print['price_type'] == 'inclusive') {{ @num_format($details['details']->sell_price_inc_tax) }} @else {{ @num_format($details['details']->default_sell_price) }} @endif @endif
{{-- Barcode --}}
@if ($is_paper_end) {{-- Actual Paper --}}
{{-- Paper Internal --}}
@endif @php $details['qty'] = $details['qty'] - 1; @endphp @endwhile @endforeach @if (!$is_paper_end) {{-- Actual Paper --}}
{{-- Paper Internal --}} @endif