@version(2)
@if ($item->is_recommend === 'Y'){{ $lang->shop_badge_recommend }} @endif
@foreach ($item->badge_list ?? [] as $shp_bg)
@php
$shp_bg_style = '';
if (!empty($shp_bg->bg_color)) { $shp_bg_style .= 'background:' . $shp_bg->bg_color . ';'; }
if (!empty($shp_bg->color)) { $shp_bg_style .= 'color:' . $shp_bg->color . ';'; }
@endphp
{{ $shp_bg->title }}
@endforeach
@if ($item->is_new === 'Y')NEW @endif
@if ($item->is_adult === 'Y'){{ $lang->shop_adult_item }} @endif
@if ($item->tax_type === 'free'){{ $lang->shop_tax_free }} @endif
@php
// 상품명 표기 규약: "브랜드 / 상품명" 으로 적으면 브랜드를 윗줄에 따로 세운다.
$shp_dp = explode(' / ', (string)$item->item_name, 2);
$shp_dbrand = count($shp_dp) === 2 ? trim($shp_dp[0]) : '';
$shp_dname = count($shp_dp) === 2 ? trim($shp_dp[1]) : trim((string)$item->item_name);
@endphp
@if ($shp_dbrand !== ''){{ $shp_dbrand }}
@endif
{{ $shp_dname }}
@if (!empty($item->summary))
{{ $item->summary }}
@endif
@php
$shp_attrs = json_decode((string)($item->attrs ?? ''), true);
$shp_attrs = is_array($shp_attrs) ? $shp_attrs : [];
@endphp
@if (count($shp_attrs))
@foreach ($shp_attrs as $shp_at)
{{ $shp_at['name'] ?? '' }} {{ $shp_at['value'] ?? '' }}
@endforeach
@endif
{{-- 아래 합계 계산도 위 표시가와 같은 값을 써야 한다. 등급가가 있으면 그것이 기준가다 --}}
@php $shp_buy_price = !empty($item->grade_price) ? (int)$item->grade_price : (int)($disp_effective_price ?? $effective_price); @endphp
@if (!empty($item->grade_price))
{{ shop_item_price($item, 'effective') }} {{ shop_item_price($item, 'grade') }}
{{ $lang->shop_grade }}
@elseif (shop_item_on_sale($item))
@php
$ss_base = isset($item->disp_price) ? (int)$item->disp_price : (int)($item->price ?? 0);
$ss_now = isset($item->disp_sale_price) ? (int)$item->disp_sale_price : (int)($item->sale_price ?? 0);
$ss_off = $ss_base > 0 ? (int)round(($ss_base - $ss_now) / $ss_base * 100) : 0;
@endphp
@if ($ss_off > 0){{ $ss_off }}% @endif
{{ shop_item_price($item, 'price') }} {{ shop_item_price($item, 'sale') }}
@else
{{ shop_item_price($item, 'price') }}
@endif
@php
$shp_ship_type = $item->ship_fee_type ?? 'default';
$shp_ship_fee = $shp_ship_type === 'fixed' ? (int)$item->ship_fee : (int)($shop_config->default_ship_fee ?? 0);
$shp_free_over = (int)($shop_config->free_ship_over ?? 0);
@endphp
@if (!empty($credit_rate) && $credit_rate > 0)
{{ $lang->shop_credit_benefit }}
{{ sprintf($lang->shop_credit_rate_note, rtrim(rtrim(number_format($credit_rate, 2), '0'), '.')) }}
@endif
{{ $lang->shop_ship_fee }}
@if ($shp_ship_type === 'free' || $shp_ship_fee <= 0)
{{ $lang->shop_ship_free }}
@else
{{ shop_money($shp_ship_fee) }}
@if ($shp_free_over > 0) {{ sprintf($lang->shop_free_over_note, shop_money($shp_free_over)) }} @endif
@endif
@if (!$purchasable)
{{ $lang->shop_not_purchasable }}
@elseif (!$adult_ok)
{{ $lang->shop_adult_gate }}
@else
@endif
{{-- 안내 문구는 테마 레이아웃 언어파일에 있다. 상점 화면에서는 레이아웃이 로드되지 않아 여기서 직접 읽는다 --}}
@php
$shp_g = \Context::loadLang(\RX_BASEDIR . 'themes/streetlab/layouts/streetlab/lang');
$shp_g_ship = $lang->ss_g_ship ?? 'Delivery';
$shp_g_ship_text = $lang->ss_g_ship_text ?? '';
$shp_g_fit = $lang->ss_g_fresh ?? 'Fit';
$shp_g_fit_text = $lang->ss_g_fresh_text ?? '';
$shp_g_return = $lang->ss_g_return ?? 'Returns';
$shp_g_return_text = $lang->ss_g_return_text ?? '';
@endphp
{{ $shp_g_ship }} {{ $shp_g_ship_text }}
{{ $shp_g_fit }} {{ $shp_g_fit_text }}
{{ $shp_g_return }} {{ $shp_g_return_text }}