@extends('layouts/contentLayoutMaster') @section('title', 'Templates') @section('main-page', 'Templates') @section('sub-page', 'Add New Template') @section('main-page-url', route("product-templates.index")) @section('sub-page-url', route("product-templates.create")) @section('vendor-style') @endsection @php $category = request('q') == 'tableau' ?\App\Models\Category::whereIsTableau(true)->first() :(request('category_id') ? \App\Models\Category::find(request('category_id')) : null); $HasMockupCategory = \App\Models\Category::find(request('category_id')); @endphp @section('content') @csrf {{-- @if(request()->query('q') == 'without')--}} {{-- --}} {{-- --}} {{-- --}} {{-- Template Colors--}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- Color Value * --}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- Pick a color or type hex (e.g.--}} {{-- #FFAA00).--}} {{-- --}} {{-- --}} {{-- Color Image * --}} {{-- --}} {{-- --}} {{-- Drop image or click--}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- Delete--}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- Add New Color--}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- @endif--}} Template Details Language @foreach(config("app.locales") as $locale) {{ $locale == 'en' ? 'English' : 'Arabic'}} @endforeach Template Type @php $type = \App\Models\Type::whereValue(\App\Enums\Template\TypeEnum::FRONT)->first(); @endphp has_mockup == false ? $type->value === \App\Enums\Template\TypeEnum::FRONT || $type->value === \App\Enums\Template\TypeEnum::BACK :$type->value === \App\Enums\Template\TypeEnum::FRONT ) > {{ $type->value->label() }} @if(request()->query('q') == 'without' || request()->query('q') == 'tableau') Upload Print File (Front) Drop front image here or click Allowed formats: PNG, JPG, JPEG, WEBP. Maximum file size: 30 MB. Minimum dimensions: 1000 × 1000 px. Upload Print File (Back) Drop back image here or click Allowed formats: PNG, JPG, JPEG, WEBP. Maximum file size: 30 MB. Minimum dimensions: 1000 × 1000 px. Upload Print File (General) Drop general image here or click Allowed formats: PNG, JPG, JPEG, WEBP. Maximum file size: 30 MB. Minimum dimensions: 1000 × 1000 px. @endif @if(($HasMockupCategory && !$HasMockupCategory->has_mockup) || !$HasMockupCategory) Template Model Image Drop image here or click to upload Upload an image with an 8:9 aspect ratio (for example, 618 × 700 px). @endif Name (EN) Name (AR) Description (AR) Description (EN) Price Products & Categories Products With Categories @foreach($associatedData['product_with_categories'] as $cate) id === ($category?->id ?? 1)) data-is-tableau="{{ $cate->is_tableau ? '1' : '0' }}" > {{ $cate->getTranslation('name', app()->getLocale()) }} @endforeach Categories Products Without Categories @foreach($associatedData['product_without_categories'] as $cate) id === ($category?->id ?? 1)) data-is-tableau="{{ $cate->is_tableau ? '1' : '0' }}" data-has-mockup="{{ $cate->has_mockup ? '1' : '0' }}"> {{ $cate->getTranslation('name', app()->getLocale()) }} @endforeach {{-- TABLEAU SCENE IMAGE --}} {{-- TABLEAU SCENE --}} Tableau Scene {{-- Choose existing scene --}} @foreach(\App\Models\TableauScene::where('is_active', true)->latest()->get() as $scene) {{ $scene->getTranslation('name', app()->getLocale(), false) ?: 'Scene #' . $scene->id }} @endforeach or create new scene {{-- New scene name --}} Scene Name (EN) Scene Name (AR) {{-- New scene image --}} Drop tableau scene image here or click Create Scene Upload the scene image, then click Create Scene. The created scene will be selected automatically. {{-- SCENE POSITION EDITOR --}} Scene Position Editor {{-- Tabs --}} Save Positions {{-- Panels --}} Drag the template overlay on each scene, then click Save Positions before submitting the template. Industry Industries @foreach($associatedData['industries'] as $industry) {{ $industry->getTranslation('name', 'en'). "({$industry->getTranslation('name', 'ar')})" }} @endforeach Sub Industries Tags @foreach($associatedData['tags'] as $tag) {{ $tag->getTranslation('name', app()->getLocale()) }} @endforeach @can("tags_create") Add New Tag @endcan @if(request()->query('q') == 'with') Design Specifications Orientation chooese orientation @foreach(\App\Enums\OrientationEnum::cases() as $orientation) {{$orientation->label()}} @endforeach Guides Settings {{-- Persisted resources (used on submit) --}} Shape {{-- Shape (col-6) --}} Circle Other Corners Choose Corner @foreach(\App\Enums\CornerEnum::cases() as $border) {{$border->label()}} @endforeach {{-- Safety Area (col-6) --}} {{-- send 0 when unchecked --}} Enable Safety Area Safety Area @foreach(\App\Enums\SafetyAreaEnum::cases() as $area) {{ $area->label() }} @endforeach Padding inside the design area. {{-- Cut Margin (col-6) --}} {{-- send 0 when unchecked --}} Enable Cut Margin Cut Margin @foreach(\App\Enums\SafetyAreaEnum::cases() as $area) {{ $area->label() }} @endforeach {{-- Padding inside the design--}} {{-- area.--}} Sizes Select Size If no size is selected, the default 650×650 will be applied. @endif Cancel Add Template as Draft Back Side Design x Do you want to use the same front design for the back side, or upload a different one? Use Same Design Upload Different @include('modals.tags.add-tag') @php // لو route محتاج parameter اسمه mockup $mockupUpdateUrlTemplate = route('mockups.edit', ['mockup' => '__ID__']); @endphp @endsection @section('vendor-script') @endsection @section('page-script') @endsection
Drag the template overlay on each scene, then click Save Positions before submitting the template.
Do you want to use the same front design for the back side, or upload a different one?