home page mobile changed
This commit is contained in:
parent
b35ad59b35
commit
81c28314e8
|
|
@ -68,7 +68,7 @@ class Category extends \Illuminate\Database\Eloquent\Model{
|
|||
|
||||
public function getTitleAttribute(){
|
||||
|
||||
return $this->{'title_'.Config::get('app.locale')};
|
||||
return $this->{'title_'.Config::get('app.locale')}??'#title_transation';
|
||||
}
|
||||
/**
|
||||
* The events associated with the category.
|
||||
|
|
|
|||
|
|
@ -225,7 +225,7 @@ class Event extends MyBaseModel
|
|||
|
||||
public function getDescriptionAttribute(){
|
||||
|
||||
return $this->{'description_'.Config::get('app.locale')};
|
||||
return $this->{'description_'.Config::get('app.locale')} ?? 'No translation';
|
||||
}
|
||||
/**
|
||||
* Get the embed url.
|
||||
|
|
|
|||
|
|
@ -8,7 +8,9 @@
|
|||
@endsection
|
||||
@section('content')
|
||||
@foreach($sub_cats as $cat)
|
||||
|
||||
@php
|
||||
$cat_events = $events->where('sub_category_id',$cat->id);
|
||||
@endphp
|
||||
<div class="section-section py-3">
|
||||
<div class="col-12 d-flex justify-content-between">
|
||||
<h5 >{{$cat->title}}
|
||||
|
|
@ -21,7 +23,7 @@
|
|||
</div>
|
||||
|
||||
<div class="owl-carousel owl-theme" id="section-slider{{$loop->iteration}}">
|
||||
@foreach($cat->cat_events as $event)
|
||||
@foreach($cat_events as $event)
|
||||
@include('mobile.Partials.EventListItem')
|
||||
@endforeach
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -15,9 +15,9 @@ Breadcrumbs::for('category', function ($trail, $category){
|
|||
|
||||
if(!empty($category) && $category->parent_id){
|
||||
$parent = $category->parent;
|
||||
$trail->push($parent->title,$parent->url);
|
||||
$trail->push($parent->title ?? '#title_transation', $parent->url?? '#');
|
||||
}
|
||||
$trail->push($category->title, $category->url ?? '#');
|
||||
$trail->push($category->title?? 'No translation', $category->url ?? '#');
|
||||
});
|
||||
|
||||
Breadcrumbs::for('event',function($trail, $event){
|
||||
|
|
@ -25,7 +25,7 @@ Breadcrumbs::for('event',function($trail, $event){
|
|||
$trail->parent('category', $event->subCategory);
|
||||
else
|
||||
$trail->parent('category', $event->mainCategory);
|
||||
$trail->push($event->title,$event->event_url);
|
||||
$trail->push($event->title?? '#title_transation',$event->event_url ?? '#');
|
||||
});
|
||||
|
||||
Breadcrumbs::for('seats',function ($trail,$event){
|
||||
|
|
@ -45,5 +45,5 @@ Breadcrumbs::for('add_event',function($trail){
|
|||
|
||||
Breadcrumbs::for('about',function($trail,$title){
|
||||
$trail->parent('home');
|
||||
$trail->push($title);
|
||||
$trail->push($title??'#title_transation');
|
||||
});
|
||||
|
|
|
|||
Loading…
Reference in New Issue