Using new blade directives

parent f296c292
...@@ -10,9 +10,8 @@ ...@@ -10,9 +10,8 @@
{!! Form::text("{$lang}[slug]", old("{$lang}.slug"), ['class' => 'form-control slug', 'data-slug' => 'target', 'placeholder' => trans('page::pages.form.slug')]) !!} {!! Form::text("{$lang}[slug]", old("{$lang}.slug"), ['class' => 'form-control slug', 'data-slug' => 'target', 'placeholder' => trans('page::pages.form.slug')]) !!}
{!! $errors->first("{$lang}.slug", '<span class="help-block">:message</span>') !!} {!! $errors->first("{$lang}.slug", '<span class="help-block">:message</span>') !!}
</div> </div>
@component($editor->getI18nComponentName(), compact('lang'))
{{ old("{$lang}.body") }} @editor('body', trans('page::pages.form.body'), old("{$lang}.body"), $lang)
@endcomponent
<?php if (config('asgard.page.config.partials.translatable.create') !== []): ?> <?php if (config('asgard.page.config.partials.translatable.create') !== []): ?>
<?php foreach (config('asgard.page.config.partials.translatable.create') as $partial): ?> <?php foreach (config('asgard.page.config.partials.translatable.create') as $partial): ?>
......
...@@ -13,10 +13,7 @@ ...@@ -13,10 +13,7 @@
{!! $errors->first("{$lang}.slug", '<span class="help-block">:message</span>') !!} {!! $errors->first("{$lang}.slug", '<span class="help-block">:message</span>') !!}
</div> </div>
@component($editor->getI18nComponentName(), compact('lang')) @editor('body', trans('page::pages.form.body'), old("$lang.body", $old), $lang)
<?php $old = $page->hasTranslation($lang) ? $page->translate($lang)->body : '' ?>
{!! old("$lang.body", $old) !!}
@endcomponent
<?php if (config('asgard.page.config.partials.translatable.edit') !== []): ?> <?php if (config('asgard.page.config.partials.translatable.edit') !== []): ?>
<?php foreach (config('asgard.page.config.partials.translatable.edit') as $partial): ?> <?php foreach (config('asgard.page.config.partials.translatable.edit') as $partial): ?>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment