FEATURE #1435: few smaller UI tweaks in creating new content page
This commit is contained in:
+5
@@ -13032,4 +13032,9 @@ a:focus {
|
|||||||
color: #FF4444;
|
color: #FF4444;
|
||||||
font-size: 13px;
|
font-size: 13px;
|
||||||
display: block !important;
|
display: block !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tab-with-error {
|
||||||
|
color: red !important;
|
||||||
|
font-weight: bold;
|
||||||
}
|
}
|
||||||
@@ -1430,13 +1430,13 @@ $ (document).ready (function () {
|
|||||||
target.val (slugify (source.val (), true));
|
target.val (slugify (source.val (), true));
|
||||||
});
|
});
|
||||||
|
|
||||||
|
// find if any error occured and mark tab with that error
|
||||||
$('.has-error').each(function () {
|
$('.has-error').each(function () {
|
||||||
var error = $(this);
|
var error = $(this);
|
||||||
var tabCard = error.closest('.tab-pane');
|
var tabCard = error.closest('.tab-pane');
|
||||||
|
|
||||||
$("#"+tabCard.prop('id')+"-tab").css('background-color', 'red');
|
$("#"+tabCard.prop('id')+"-tab").addClass('tab-with-error');
|
||||||
});
|
});
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -47,4 +47,5 @@ return [
|
|||||||
'files' => 'Files',
|
'files' => 'Files',
|
||||||
'lockUrl' => 'Keep URL',
|
'lockUrl' => 'Keep URL',
|
||||||
'noCategory' => ' -- No category -- ',
|
'noCategory' => ' -- No category -- ',
|
||||||
|
'noTemplates' => 'Cannot create content page. There are no available templates for this module.'
|
||||||
];
|
];
|
||||||
@@ -12,7 +12,6 @@
|
|||||||
@lang('admin/contents.uploadTitleImage')
|
@lang('admin/contents.uploadTitleImage')
|
||||||
</label>
|
</label>
|
||||||
<input type="file" id="titlePhoto" name="titlePhoto" class="form-control" />
|
<input type="file" id="titlePhoto" name="titlePhoto" class="form-control" />
|
||||||
<span class="has-error">Neplatny template</span>
|
|
||||||
|
|
||||||
@include('admin.snippets.hasError', ['field' => 'titlePhoto'])
|
@include('admin.snippets.hasError', ['field' => 'titlePhoto'])
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-lg-6">
|
<div class="col-lg-6">
|
||||||
<input type="text" name="title" class="form-control slug-source"
|
<input type="text" name="title" required class="form-control slug-source"
|
||||||
placeholder="@lang('admin/contents.field_title')"
|
placeholder="@lang('admin/contents.field_title')"
|
||||||
value="{{old('title', $page->title)}}" />
|
value="{{old('title', $page->title)}}" />
|
||||||
|
|
||||||
|
|||||||
@@ -4,7 +4,10 @@
|
|||||||
<div class="col-lg-6">
|
<div class="col-lg-6">
|
||||||
<ul>
|
<ul>
|
||||||
@foreach($page->files as $file)
|
@foreach($page->files as $file)
|
||||||
<li><label><input type="checkbox" name="keepAssigned[{{$file->id}}]" checked /> {{$file->original_filename}}</label></li>
|
<li>
|
||||||
|
<input type="checkbox" name="keepAssigned[{{$file->id}}]" checked />
|
||||||
|
{{$file->original_filename}}
|
||||||
|
</li>
|
||||||
@endforeach
|
@endforeach
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
@@ -15,6 +18,6 @@
|
|||||||
@lang('admin/contents.files')
|
@lang('admin/contents.files')
|
||||||
</label>
|
</label>
|
||||||
|
|
||||||
<input type="file" name="files[]" class="form-control" multiple />
|
<input type="file" name="files[]" class="form-control" multiple />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -3,6 +3,13 @@
|
|||||||
@section('pageHeading', @trans('admin/contents.new', ['name' => $moduleName]))
|
@section('pageHeading', @trans('admin/contents.new', ['name' => $moduleName]))
|
||||||
|
|
||||||
@section('content')
|
@section('content')
|
||||||
|
|
||||||
|
@if(!count($templates))
|
||||||
|
<div class="alert alert-warning">
|
||||||
|
@lang('admin/contents.noTemplates')
|
||||||
|
</div>
|
||||||
|
@endif
|
||||||
|
|
||||||
<form method="POST" enctype="multipart/form-data" action="{{route('content.newPost', ['moduleId' => $moduleId])}}">
|
<form method="POST" enctype="multipart/form-data" action="{{route('content.newPost', ['moduleId' => $moduleId])}}">
|
||||||
{!! csrf_field() !!}
|
{!! csrf_field() !!}
|
||||||
|
|
||||||
@@ -10,7 +17,7 @@
|
|||||||
|
|
||||||
<button type="submit" class="btn btn-primary">@lang('admin/contents.save')</button>
|
<button type="submit" class="btn btn-primary">@lang('admin/contents.save')</button>
|
||||||
</form>
|
</form>
|
||||||
@stop
|
@endsection
|
||||||
|
|
||||||
@section('javascripts')
|
@section('javascripts')
|
||||||
@include('admin.snippets.ckEditor', ['textareaId' => 'pageContent'])
|
@include('admin.snippets.ckEditor', ['textareaId' => 'pageContent'])
|
||||||
|
|||||||
Reference in New Issue
Block a user