@extends('layouts.admin.app') @section('title', '') @push('css_or_js') @endpush @section('content')
{{ translate('QTY') }} | {{ translate('DESC') }} | {{ translate('Price') }} |
---|---|---|
{{ $detail['quantity'] }} |
{{ Str::limit($detail->product['name'], 200) }} @if (count(json_decode($detail['variation'], true)) > 0) {{ translate('variation') }} : @foreach (json_decode($detail['variation'], true) as $variation) @if (isset($variation['name']) && isset($variation['values'])) {{ $variation['name'] }} - @foreach ($variation['values'] as $value) {{ $value['label'] }} : {{ \App\CentralLogics\Helpers::set_symbol($value['optionPrice']) }} @endforeach @else @if (isset(json_decode($detail['variation'], true)[0])) @foreach (json_decode($detail['variation'], true)[0] as $key1 => $variation)
{{ $key1 }} :
{{ $variation }}
@endforeach
@endif
@break
@endif
@endforeach
@else
{{ translate('Price') }} :
{{ \App\CentralLogics\Helpers::set_symbol($detail->price) }}
@endif
{{-- @if (count(json_decode($detail['variation'], true)) > 0) --}}
{{-- {{translate('Variation : ')}} --}}
{{-- @foreach (json_decode($detail['variation'], true)[0] as $key1 => $variation) --}}
{{-- --}}
{{-- {{$key1}} : --}}
{{-- {{ $key1 == 'price' ? Helpers::set_symbol($variation) : $variation }} --}}
{{-- --}}
{{-- @endforeach --}}
{{-- @endif --}}
@foreach (json_decode($detail['add_on_ids'], true) as $key2 => $id)
@php($addon = \App\Model\AddOn::find($id))
@if ($key2 == 0)
{{ translate('Addons : ') }}
@endif
@if ($add_on_qtys == null)
@php($add_on_qty = 1)
@else
@php($add_on_qty = $add_on_qtys[$key2])
@endif
{{ $addon['name'] }} :
{{ $add_on_qty }} x
{{ \App\CentralLogics\Helpers::set_symbol($addon['price']) }}
@php($add_ons_cost += $addon['price'] * $add_on_qty)
@endforeach
{{ translate('Discount : ') }}{{ \App\CentralLogics\Helpers::set_symbol($detail['discount_on_product']) }}
|
@php($amount = ($detail['price'] - $detail['discount_on_product']) * $detail['quantity']) {{ \App\CentralLogics\Helpers::set_symbol($amount) }} |