@extends('layout.default') @if($mode == 'edit') @section('title', $L('Edit recipe')) @else @section('title', $L('Create recipe')) @endif @section('viewJsName', 'recipeform') @push('pageScripts') @if(!empty($L('summernote_locale')))@endif @endpush @push('pageStyles') @endpush @section('content')

@yield('title')

@if($mode == 'edit') @if(!empty($recipe->picture_file_name)) @endif @endif
{{ $L('A name is required') }}
@php if($mode == 'edit') { $value = $recipe->base_servings; } else { $value = 1; } @endphp @include('components.numberpicker', array( 'id' => 'base_servings', 'label' => 'Servings', 'min' => 1, 'value' => $value, 'invalidFeedback' => $L('This cannot be lower than #1', '1'), 'hint' => $L('The ingredients listed here result in this amount of servings') ))
not_check_shoppinglist == 1) checked @endif class="form-check-input" type="checkbox" id="not_check_shoppinglist" name="not_check_shoppinglist" value="1">

{{ $L('Ingredients list') }} {{ $L('Add') }}

@if($mode == "edit") @foreach($recipePositions as $recipePosition) @endforeach @endif
# {{ $L('Product') }} {{ $L('Amount') }} {{ $L('Note') }} Hiden ingredient group
{{ FindObjectInArrayByPropertyValue($products, 'id', $recipePosition->product_id)->name }} @if($recipePosition->amount == round($recipePosition->amount)){{ round($recipePosition->amount) }}@else{{ $recipePosition->amount }}@endif {{ Pluralize($recipePosition->amount, FindObjectInArrayByPropertyValue($quantityunits, 'id', $recipePosition->qu_id)->name, FindObjectInArrayByPropertyValue($quantityunits, 'id', $recipePosition->qu_id)->name_plural) }} {{ $recipePosition->ingredient_group }}

{{ $L('Included recipes') }} {{ $L('Add') }}

@if($mode == "edit") @foreach($recipeNestings as $recipeNesting) @endforeach @endif
# {{ $L('Recipe') }}
{{ FindObjectInArrayByPropertyValue($recipes, 'id', $recipeNesting->includes_recipe_id)->name }}
@if(!empty($recipe->picture_file_name))

{{ $L('The current picture will be deleted when you save the recipe') }}

@else

{{ $L('No picture available') }}

@endif
@stop