@extends('admin.layouts.app') @push('styles_top') @endpush @section('content') {{ trans('admin/main.'.(!empty($post) ? 'edit_blog' : 'create_blog')) }} {{trans('admin/main.dashboard')}} {{ trans('admin/main.blog') }} {{ csrf_field() }} @if(!empty(getGeneralSettings('content_translate')) and !empty($userLanguages)) {{ trans('auth.language') }} @foreach($userLanguages as $lang => $language) get('locale', app()->getLocale())) == mb_strtolower($lang)) selected @endif>{{ $language }} @endforeach @error('locale') {{ $message }} @enderror @else @endif {{ trans('update.author') }} @if(!empty($post)) {{ $post->author->full_name }} @else {{ trans('update.select_a_user') }} @endif @error('teacher_id') {{ $message }} @enderror {{ trans('admin/main.title') }} @error('title') {{ $message }} @enderror {{ trans('/admin/main.category') }} {{ trans('admin/main.choose_category') }} @foreach($categories as $category) category_id == $category->id) or (old('category_id') == $category->id)) ? 'selected="selected"' : '') }}>{{ $category->title }} @endforeach @error('category_id') {{ $message }} @enderror {{ trans('public.cover_image') }} @error('image') {{ $message }} @enderror {{ trans('public.description') }} {{ trans('admin/main.create_blog_description_hint') }} {!! !empty($post) ? $post->description : old('description') !!} @error('description') {{ $message }} @enderror {{ trans('admin/main.content') }} {{ trans('admin/main.create_blog_content_hint') }} {!! !empty($post) ? $post->content : old('content') !!} @error('content') {{ $message }} @enderror {{ trans('admin/pages/blog.meta_description') }} {!! !empty($post) ? $post->meta_description : old('meta_description') !!} @error('meta_description') {{ $message }} @enderror enable_comment) ? '' : 'checked' }}> {{ trans('admin/main.comments_section') }} status == 'pending') ? '' : 'checked' }}> {{ trans('admin/main.publish') }} {{ trans('admin/main.save_change') }} @endsection @push('scripts_bottom') @endpush