adding news section

This commit is contained in:
ROMANGOLIENKO 2024-04-15 16:28:08 +03:00
parent aca13d134d
commit 3057579f9e
2 changed files with 61 additions and 203 deletions

View File

@ -8,6 +8,7 @@ use App\Models\Admission;
use App\Models\Direction;
use App\Models\EntranceExamination;
use App\Models\Faculty;
use App\Models\News;
use App\Models\Subject;
use Illuminate\Contracts\View\Factory;
use Illuminate\Contracts\View\View;
@ -23,6 +24,7 @@ class PageController extends Controller
public function bakalavr()
{
$news = News::all();
$admissions = Admission::all();
$faculties = Faculty::all();
$subjects = EntranceExamination::all()
@ -175,10 +177,12 @@ class PageController extends Controller
'directionsWithInstitution',
'groupedDirections',
'admissions',
'news',
));
}
public function inostran()
{
$news = News::all();
$admissions = Admission::all();
$faculties = Faculty::all();
$subjects = EntranceExamination::all()
@ -331,11 +335,13 @@ class PageController extends Controller
'directionsWithInstitution',
'groupedDirections',
'admissions',
'news',
));
}
public function magistr()
{
$news = News::all();
$admissions = Admission::all();
$faculties = Faculty::all();
$subjects = EntranceExamination::all()
@ -488,6 +494,7 @@ class PageController extends Controller
'directionsWithInstitution',
'groupedDirections',
'admissions',
'news',
));
}

View File

@ -554,212 +554,61 @@
</div>
</div>
{{-- <div style="background-image: url({{ URL::to('img/front-page/bakalavr-special/fon1_blok.png') }}); background-repeat: no-repeat; background-size: cover; background-attachment: fixed; ">
{{-- Начало новостей --}} <div style="background-image: url({{ URL::to('img/front-page/bakalavr-special/fon1_blok.png') }}); background-repeat: no-repeat; background-size: cover; background-attachment: fixed; ">
<div id="carouselExampleIndicators" class="carousel slide">
<div class="carousel-indicators">
<button type="button" data-bs-target="#carouselExampleIndicators" data-bs-slide-to="0" class="active" aria-current="true" aria-label="Slide 1"></button>
<button type="button" data-bs-target="#carouselExampleIndicators" data-bs-slide-to="1" aria-label="Slide 2"></button>
<button type="button" data-bs-target="#carouselExampleIndicators" data-bs-slide-to="2" aria-label="Slide 3"></button>
<button type="button" data-bs-target="#carouselExampleIndicators" data-bs-slide-to="3" aria-label="Slide 3"></button>
</div>
<div id="carouselExampleIndicators" class="carousel slide ">
<div class="carousel-inner px-5 pt-5">
<div class="carousel-item active " >
<div class="row d-flex align-items-center " >
<div class="col-xl col-12 " style=" height: 25em;">
@php
$all_news = array()
@endphp
@foreach($news as $item)
@php
$all_news[$item->name]['name'] = $item->name;
$all_news[$item->name]['text'] = $item->text;
$all_news[$item->name]['url'] = asset($item->photo);
@endphp
@endforeach
<div class="w-100 h-75 position-relative " style="border-radius: 20px; background-image: url({{ URL::to('img/front-page/e3305c89b9b89821588364d5e898afc0.jpg') }}); background-repeat: no-repeat; background-size: cover; ">
@php
$out = array_chunk($all_news, 4, true);
@endphp
@foreach($out as $id => $page)
<div class="carousel-item @if($id == 1) active @endif \" >
<div class="row d-flex align-items-center justify-content-center " >
@foreach($page as $item)
<div class="col-xl col-12 " style=" max-width: 20%; ">
<div class="position-absolute bottom-0 bg-white " style="border-radius: 20px; ">
<div class="gradient-text p-3">
<strong class="fs-5" style="font-family: Geologica-Light"> Завершение приема документов </strong>
<p style="font-family: Geologica-ExtraLight"> Но явные признаки победы институционализации представлены в исключительно положительном свете. </p>
<img src="{{$item['url']}}" class="img-fluid">
<div class="bg-white " style="border-radius: 20px; height: 8em; overflow-y: auto">
<div class="gradient-text p-3" style="">
<strong class="fs-5" style="font-family: Geologica-Light"> {{$item['name']}} </strong>
<p style="font-family: Geologica-ExtraLight; " > {{$item['text']}} </p>
</div>
</div>
</div>
</div>
</div>
@endforeach
</div>
<div class="col-xl col-12 " style=" height: 25em;">
<div class="w-100 h-75 position-relative" style="border-radius: 20px; background-image: url({{ URL::to('img/front-page/e3305c89b9b89821588364d5e898afc0.jpg') }}); background-repeat: no-repeat; background-size: cover;">
<div class="position-absolute bottom-0 bg-white " style="border-radius: 20px;">
<div class="gradient-text p-3">
<strong class="fs-5" style="font-family: Geologica-Light"> Завершение приема документов </strong>
<p style="font-family: Geologica-ExtraLight"> Но явные признаки победы институционализации представлены в исключительно положительном свете. </p>
</div>
</div>
</div>
</div>
<div class="col-xl col-12" style=" height: 25em;">
<div class="w-100 h-75 position-relative" style="border-radius: 20px; background-image: url({{ URL::to('img/front-page/e3305c89b9b89821588364d5e898afc0.jpg') }}); background-repeat: no-repeat; background-size: cover;">
<div class="position-absolute bottom-0 bg-white " style="border-radius: 20px;">
<div class="gradient-text p-3">
<strong class="fs-5" style="font-family: Geologica-Light"> Завершение приема документов </strong>
<p style="font-family: Geologica-ExtraLight"> Но явные признаки победы институционализации представлены в исключительно положительном свете. </p>
</div>
</div>
</div>
</div>
<div class="col-xl col-12" style=" height: 25em;">
<div class="w-100 h-75 position-relative" style="border-radius: 20px; background-image: url({{ URL::to('img/front-page/e3305c89b9b89821588364d5e898afc0.jpg') }}); background-repeat: no-repeat; background-size: cover;">
<div class="position-absolute bottom-0 bg-white " style="border-radius: 20px;">
<div class="gradient-text p-3">
<strong class="fs-5" style="font-family: Geologica-Light"> Завершение приема документов </strong>
<p style="font-family: Geologica-ExtraLight"> Но явные признаки победы институционализации представлены в исключительно положительном свете. </p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="carousel-item " >
<div class="row d-flex align-items-center " >
<div class="col-xl col-12 " style=" height: 25em;">
<div class="w-100 h-75 position-relative " style="border-radius: 20px; background-image: url({{ URL::to('img/front-page/e3305c89b9b89821588364d5e898afc0.jpg') }}); background-repeat: no-repeat; background-size: cover; ">
<br><br><br><br>
</div>
@endforeach
<div class="position-absolute bottom-0 bg-white " style="border-radius: 20px; ">
<div class="gradient-text p-3">
<strong class="fs-5" style="font-family: Geologica-Light"> Завершение приема документов </strong>
<p style="font-family: Geologica-ExtraLight"> Но явные признаки победы институционализации представлены в исключительно положительном свете. </p>
</div>
</div>
</div>
</div>
<div class="col-xl col-12 " style=" height: 25em;">
<div class="w-100 h-75 position-relative" style="border-radius: 20px; background-image: url({{ URL::to('img/front-page/e3305c89b9b89821588364d5e898afc0.jpg') }}); background-repeat: no-repeat; background-size: cover;">
<div class="position-absolute bottom-0 bg-white " style="border-radius: 20px;">
<div class="gradient-text p-3">
<strong class="fs-5" style="font-family: Geologica-Light"> Завершение приема документов </strong>
<p style="font-family: Geologica-ExtraLight"> Но явные признаки победы институционализации представлены в исключительно положительном свете. </p>
</div>
</div>
</div>
</div>
<div class="col-xl col-12" style=" height: 25em;">
<div class="w-100 h-75 position-relative" style="border-radius: 20px; background-image: url({{ URL::to('img/front-page/e3305c89b9b89821588364d5e898afc0.jpg') }}); background-repeat: no-repeat; background-size: cover;">
<div class="position-absolute bottom-0 bg-white " style="border-radius: 20px;">
<div class="gradient-text p-3">
<strong class="fs-5" style="font-family: Geologica-Light"> Завершение приема документов </strong>
<p style="font-family: Geologica-ExtraLight"> Но явные признаки победы институционализации представлены в исключительно положительном свете. </p>
</div>
</div>
</div>
</div>
<div class="col-xl col-12" style=" height: 25em;">
<div class="w-100 h-75 position-relative" style="border-radius: 20px; background-image: url({{ URL::to('img/front-page/e3305c89b9b89821588364d5e898afc0.jpg') }}); background-repeat: no-repeat; background-size: cover;">
<div class="position-absolute bottom-0 bg-white " style="border-radius: 20px;">
<div class="gradient-text p-3">
<strong class="fs-5" style="font-family: Geologica-Light"> Завершение приема документов </strong>
<p style="font-family: Geologica-ExtraLight"> Но явные признаки победы институционализации представлены в исключительно положительном свете. </p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="carousel-item " >
<div class="row d-flex align-items-center " >
<div class="col-xl col-12 " style=" height: 25em;">
<div class="w-100 h-75 position-relative " style="border-radius: 20px; background-image: url({{ URL::to('img/front-page/e3305c89b9b89821588364d5e898afc0.jpg') }}); background-repeat: no-repeat; background-size: cover; ">
<div class="position-absolute bottom-0 bg-white " style="border-radius: 20px; ">
<div class="gradient-text p-3">
<strong class="fs-5" style="font-family: Geologica-Light"> Завершение приема документов </strong>
<p style="font-family: Geologica-ExtraLight"> Но явные признаки победы институционализации представлены в исключительно положительном свете. </p>
</div>
</div>
</div>
</div>
<div class="col-xl col-12 " style=" height: 25em;">
<div class="w-100 h-75 position-relative" style="border-radius: 20px; background-image: url({{ URL::to('img/front-page/e3305c89b9b89821588364d5e898afc0.jpg') }}); background-repeat: no-repeat; background-size: cover;">
<div class="position-absolute bottom-0 bg-white " style="border-radius: 20px;">
<div class="gradient-text p-3">
<strong class="fs-5" style="font-family: Geologica-Light"> Завершение приема документов </strong>
<p style="font-family: Geologica-ExtraLight"> Но явные признаки победы институционализации представлены в исключительно положительном свете. </p>
</div>
</div>
</div>
</div>
<div class="col-xl col-12" style=" height: 25em;">
<div class="w-100 h-75 position-relative" style="border-radius: 20px; background-image: url({{ URL::to('img/front-page/e3305c89b9b89821588364d5e898afc0.jpg') }}); background-repeat: no-repeat; background-size: cover;">
<div class="position-absolute bottom-0 bg-white " style="border-radius: 20px;">
<div class="gradient-text p-3">
<strong class="fs-5" style="font-family: Geologica-Light"> Завершение приема документов </strong>
<p style="font-family: Geologica-ExtraLight"> Но явные признаки победы институционализации представлены в исключительно положительном свете. </p>
</div>
</div>
</div>
</div>
<div class="col-xl col-12" style=" height: 25em;">
<div class="w-100 h-75 position-relative" style="border-radius: 20px; background-image: url({{ URL::to('img/front-page/e3305c89b9b89821588364d5e898afc0.jpg') }}); background-repeat: no-repeat; background-size: cover;">
<div class="position-absolute bottom-0 bg-white " style="border-radius: 20px;">
<div class="gradient-text p-3">
<strong class="fs-5" style="font-family: Geologica-Light"> Завершение приема документов </strong>
<p style="font-family: Geologica-ExtraLight"> Но явные признаки победы институционализации представлены в исключительно положительном свете. </p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="carousel-item " >
<div class="row d-flex align-items-center " >
<div class="col-xl col-12 " style=" height: 25em;">
<div class="w-100 h-75 position-relative " style="border-radius: 20px; background-image: url({{ URL::to('img/front-page/e3305c89b9b89821588364d5e898afc0.jpg') }}); background-repeat: no-repeat; background-size: cover; ">
<div class="position-absolute bottom-0 bg-white " style="border-radius: 20px; ">
<div class="gradient-text p-3">
<strong class="fs-5" style="font-family: Geologica-Light"> Завершение приема документов </strong>
<p style="font-family: Geologica-ExtraLight"> Но явные признаки победы институционализации представлены в исключительно положительном свете.qwfqaswefqaswfswfqaeswf </p>
</div>
</div>
</div>
</div>
<div class="col-xl col-12 " style=" height: 25em;">
<div class="w-100 h-75 position-relative" style="border-radius: 20px; background-image: url({{ URL::to('img/front-page/e3305c89b9b89821588364d5e898afc0.jpg') }}); background-repeat: no-repeat; background-size: cover;">
<div class="position-absolute bottom-0 bg-white " style="border-radius: 20px;">
<div class="gradient-text p-3">
<strong class="fs-5" style="font-family: Geologica-Light"> Завершение приема документов </strong>
<p style="font-family: Geologica-ExtraLight"> Но явные признаки победы институционализации представлены в исключительно положительном свете. </p>
</div>
</div>
</div>
</div>
<div class="col-xl col-12" style=" height: 25em;">
<div class="w-100 h-75 position-relative" style="border-radius: 20px; background-image: url({{ URL::to('img/front-page/e3305c89b9b89821588364d5e898afc0.jpg') }}); background-repeat: no-repeat; background-size: cover;">
<div class="position-absolute bottom-0 bg-white " style="border-radius: 20px;">
<div class="gradient-text p-3">
<strong class="fs-5" style="font-family: Geologica-Light"> Завершение приема документов </strong>
<p style="font-family: Geologica-ExtraLight"> Но явные признаки победы институционализации представлены в исключительно положительном свете. </p>
</div>
</div>
</div>
</div>
<div class="col-xl col-12" style=" height: 25em;">
<div class="w-100 h-75 position-relative" style="border-radius: 20px; background-image: url({{ URL::to('img/front-page/e3305c89b9b89821588364d5e898afc0.jpg') }}); background-repeat: no-repeat; background-size: cover;">
<div class="position-absolute bottom-0 bg-white " style="border-radius: 20px;">
<div class="gradient-text p-3">
<strong class="fs-5" style="font-family: Geologica-Light"> Завершение приема документов </strong>
<p style="font-family: Geologica-ExtraLight"> Но явные признаки победы институционализации представлены в исключительно положительном свете. </p>
</div>
</div>
</div>
</div>
</div>
<div class="carousel-indicators mt-5">
<button type="button" data-bs-target="#carouselExampleIndicators" data-bs-slide-to="0" class="active" aria-current="true" aria-label="Slide 1"></button>
<button type="button" data-bs-target="#carouselExampleIndicators" data-bs-slide-to="1" aria-label="Slide 2"></button>
<button type="button" data-bs-target="#carouselExampleIndicators" data-bs-slide-to="2" aria-label="Slide 3"></button>
<button type="button" data-bs-target="#carouselExampleIndicators" data-bs-slide-to="3" aria-label="Slide 3"></button>
</div>
@ -773,33 +622,35 @@
<span class="visually-hidden">Next</span>
</button>
</div>
</div> --}}
<div style="background-image: url({{ URL::to('img/front-page/bakalavr-special/footer_fon.png') }}); background-size: cover; ">
</div>
{{-- Конец новостей --}}
<div style="background-image: url({{ URL::to('img/front-page/bakalavr-special/fon3_blok.png') }}); background-size: cover; ">
<div class="container-fluid ms-sm-5 pt-5 ">
<div class="row">
<div class="row gradient-text">
<div class="ms-4 col-auto ">
<div class="col-11">
<div class="text-white fs-4"> Приемная коммисия:</div>
<div class=" fs-4"> Приемная коммисия:</div>
<p class="text-white"> (8772) 52-30-08 </p>
</div>
<div class="col-11">
<div class="text-white fs-4"> Приёмная комиссия филиала МГТУ в пос. Яблоновском:</div>
<p class="text-white"> 8-938-530-53-14 </p>
<div class=" fs-4"> Приёмная комиссия филиала МГТУ в пос. Яблоновском:</div>
<p class=""> 8-938-530-53-14 </p>
</div>
<div class="col-11">
<div class="text-white fs-4"> Почта:</div>
<p class="text-white"> info@mkgtu.ru </p>
<div class=" fs-4"> Почта:</div>
<p class=""> info@mkgtu.ru </p>
</div>
<div class="col-11">
<p class="text-white fs-4"> 385000, Республика Адыгея, г. Майкоп, ул. Первомайская, д. 191 </p>
<p class=" fs-4"> 385000, Республика Адыгея, г. Майкоп, ул. Первомайская, д. 191 </p>
</div>
<div class="col-11">
<a href="#"><img width="30px" height="30px" src="{{ URL::to('img/front-page/vid.png') }}" alt="vid"></a>