@include('components.form.select', [
'name' => 'product_type',
'id_name' => 'product_type',
'list' => $models_options,
'value' => $article['product_type'] ?? null,
'class' => 'select2',
'with_empty' => '',
'label' => 'Familles de produit',
'required' => true,
])
@include('components.form.select', [
'name' => 'product_id',
'id_name' => 'product_id',
'list' => $products ?? [],
'value' => $article['product_id'] ?? null,
'class' => 'select2',
'with_empty' => '',
'label' => 'Produit',
'required' => true,
])
@include('components.form.select', [
'name' => 'article_nature_id',
'id_name' => 'article_nature_id',
'list' => $natures_options,
'value' => $article['article_nature_id'] ?? null,
'class' => 'select2',
'with_empty' => '',
'label' => __('shop.article_natures.name'),
'required' => true,
])
@include('components.form.input', [
'name' => 'name',
'value' => $article['name'] ?? null,
'label' => 'Nom',
'required' => true,
])
@include('components.form.input', [
'name' => 'ref',
'value' => $article['ref'] ?? null,
'label' => 'Référence',
'required' => true,
])
@include('components.form.select', [
'name' => 'categories[]',
'list' => $categories_options,
'values' => $article['categories'] ?? null,
'class' => 'select2',
'multiple' => true,
'label' => __('shop.shelves.title'),
])
@include('components.form.toggle', [
'name' => 'visible',
'value' => $article['visible'] ?? null,
'on' => __('oui'),
'off' => __('non'),
'meta' => 'data-id=' . ($article['id'] ?? null),
'size' => 'sm',
'label' => 'Visible',
])
@include('components.form.toggle', [
'name' => 'homepage',
'value' => $article['homepage'] ?? null,
'on' => __('oui'),
'off' => __('non'),
'meta' => 'data-id=' . ($article['id'] ?? null),
'size' => 'sm',
'label' => 'Accueil',
])
@include('components.form.selects.select-tree', [
'name' => 'tags[]',
'list' => $tags_list,
'values' => $article['tags'] ?? null,
'class' => 'select2',
'multiple' => true,
'label' => 'Tags',
])
@include('Admin.Shop.Articles.partials.product.description')
@include('components.form.textarea', [
'name' => 'description',
'value' => $article['description'] ?? null,
'class' => 'editor',
'required' => false,
'label' => 'Description',
])
@include('Admin.Shop.Articles.partials.product.images')
@include('components.uploader.widget', [
'load_url' => route('Admin.Shop.Articles.getImages', ['id' => $article['id'] ?? false]),
'delete_url' => route('Admin.Shop.Articles.deleteImage'),
'title' => 'Photos',
'name' => 'images',
])
@include('Admin.Core.Comments.partials.comments', [
'model' => 'Shop.Article',
'model_id' => $article['id'] ?? false,
'comments' => $article['comments'] ?? false,
])