3911012c65
Broad sweep across the whole codebase:
- Blade views (39 files, 315 wraps): tag-text and title/placeholder/alt
attributes wrapped with {{ __() }}. Excludes scripts, styles, @php,
@verbatim, {{ }}, {!! !!}, comments to avoid touching interpolations.
- PHP (54 files, 179 wraps): array 'key' => 'RO value' patterns and
list items with diacritics wrapped with __(). Reverted __() inside
const arrays (PHP disallows non-constant expressions).
- Added 269 new keys to lang/{ru,en}.json (identity fallback for
unknowns → 161 human RU + 163 EN translations added for the most
common enums, stages, roles, statuses, payment methods, vehicle
categories, warehouse, portal, form actions.
Missing translations fall back to RO so the UI never breaks. All 306
tests pass; view cache compiles cleanly.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
49 lines
1.8 KiB
PHP
49 lines
1.8 KiB
PHP
@php
|
|
$url = $wo->trackingUrl();
|
|
$qrSvg = (new \chillerlan\QRCode\QRCode(new \chillerlan\QRCode\QROptions([
|
|
'outputType' => \chillerlan\QRCode\QRCode::OUTPUT_MARKUP_SVG,
|
|
'eccLevel' => \chillerlan\QRCode\QRCode::ECC_M,
|
|
'scale' => 8,
|
|
'imageBase64' => false,
|
|
'addQuietzone' => true,
|
|
])))->render($url);
|
|
@endphp
|
|
<div class="space-y-4">
|
|
<p class="text-sm text-gray-600 dark:text-gray-300">
|
|
{{ __('Trimite acest link clientului — vede statusul fișei, ETA și fotografiile fără să se logheze.') }}
|
|
</p>
|
|
|
|
<div class="flex justify-center bg-white rounded-lg p-4 border border-gray-200 dark:border-gray-700">
|
|
<div style="max-width: 240px;">{!! $qrSvg !!}</div>
|
|
</div>
|
|
|
|
<div class="space-y-2">
|
|
<label class="block text-xs font-medium text-gray-500 dark:text-gray-400 uppercase tracking-wide">Link</label>
|
|
<div class="flex gap-2">
|
|
<input
|
|
type="text"
|
|
value="{{ $url }}"
|
|
readonly
|
|
onclick="this.select()"
|
|
class="flex-1 text-sm rounded-md border-gray-300 dark:border-gray-600 dark:bg-gray-800 dark:text-gray-100 font-mono px-3 py-2"
|
|
>
|
|
<a
|
|
href="{{ $url }}"
|
|
target="_blank"
|
|
rel="noopener"
|
|
class="inline-flex items-center px-3 py-2 text-sm rounded-md bg-primary-600 text-white hover:bg-primary-700"
|
|
>
|
|
{{ __('Deschide →') }}
|
|
</a>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="flex gap-2">
|
|
<a
|
|
href="{{ route('tracking.qr', $wo->tracking_token) }}"
|
|
download="WO-{{ $wo->number }}-qr.svg"
|
|
class="text-xs text-primary-600 hover:underline"
|
|
>{{ __('Descarcă QR (SVG)') }}</a>
|
|
</div>
|
|
</div>
|