You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
xshop/resources/views/website/index.blade.php

164 lines
7.5 KiB
PHTML

@extends('website.layout.layout')
2 years ago
@section('content')
<section id="index-top">
<div class="container">
<div class="grid">
<div class="display-block position-relative">
2 years ago
<div class="fa fa-mobile-alt fa-bg"></div>
<h2 class="mt-5 ms-3">
{{\App\Helpers\getSetting('top1text')}}
</h2>
<div class="clearfix mt-5 mb-5"></div>
2 years ago
<div id="owl2" class="owl-carousel owl-theme">
2 years ago
@foreach(\App\Helpers\getProductByCat(\App\Helpers\getSetting('top1cat'),'id','desc',10) as $p)
2 years ago
<div class="item">
2 years ago
<div class="box">
<a href="{{route('product',$p->slug)}}">
<img src="{{$p->thumbUrl()}}" class="img-fluid" alt="{{$p->name}}" title="{{$p->name}}">
<h4>
{{$p->name}}
</h4>
</a>
<span>
{{$p->getPrice()}}
</span>
<a href="{{route('card.add',$p->slug)}}" class="add-to-card btn btn-primary btn-block mt-2 mb-2">
<img src="{{asset('images/basket.svg')}}" class="basket-icon" alt=""> &nbsp;
افزودن به سبد خرید
</a>
</div>
2 years ago
</div>
@endforeach
</div>
</div>
2 years ago
<div class="position-relative">
@foreach(\App\Helpers\getProductByCat(\App\Helpers\getSetting('top2cat'),'id','desc',2) as $p)
<article>
<a href="{{route('product',$p->slug)}}">
<img src="{{$p->thumbUrl()}}" alt="{{$p->name}}" title="{{$p->name}}">
<div>
<div class="text-light">
{{$p->getPrice()}}
</div>
</div>
</a>
<span class="badge bg-secondary discount">
{{\App\Helpers\getSetting('top2text')}}
</span>
</article>
@endforeach
2 years ago
</div>
2 years ago
<div class="position-relative">
@foreach(\App\Helpers\getProductByCat(\App\Helpers\getSetting('top3cat'),'id','desc',2) as $p)
<article>
<a href="{{route('product',$p->slug)}}">
<img src="{{$p->thumbUrl()}}" alt="{{$p->name}}" title="{{$p->name}}">
<div>
<div class="text-light">
{{$p->getPrice()}}
</div>
</div>
</a>
<span class="badge bg-secondary discount">
{{\App\Helpers\getSetting('top3text')}}
</span>
</article>
@endforeach
2 years ago
</div>
</div>
</div>
</section>
2 years ago
<section id="new-products" class="mt-5 long-box">
2 years ago
<div class="container pt-4 pb-4">
<h1 class="mb-4">
{{\App\Helpers\getSetting('sectext')}}
</h1>
2 years ago
<div id="owl1" class="owl-carousel owl-theme">
2 years ago
@foreach(\App\Helpers\getProductByCat(\App\Helpers\getSetting('seccat'),'id','desc',10) as $p)
2 years ago
<div class="item ">
<div class="box">
<a href="{{route('product',$p->slug)}}">
<img src="{{$p->thumbUrl()}}" class="img-fluid" alt="{{$p->name}}" title="{{$p->name}}">
</a>
<a href="{{route('product',$p->slug)}}">
<h4>
{{$p->name}}
</h4>
<span>
{{$p->getPrice()}}
</span>
</a>
<div>
<a href="{{route('card.add',$p->slug)}}" class="add-to-card btn btn-primary btn-block mt-2 mb-2 corner">
<img src="{{asset('images/basket.svg')}}" class="basket-icon" alt=""> &nbsp;
افزودن به سبد خرید
</a>
</div>
</div>
2 years ago
</div>
@endforeach
</div>
2 years ago
<a href="{{route('products')}}" class="float-end btn btn-outline-primary">
همه محصولات
</a>
<br>
<br>
2 years ago
</div>
</section>
2 years ago
<section id="filtering" class="pb-4 pt-4 bg long-box">
2 years ago
<div class="container">
<h1>
2 years ago
{{\App\Helpers\getSetting('3text')}}
2 years ago
</h1>
2 years ago
<div class="btn-group mt-3" role="group" aria-label="Basic example">
<button type="button" class="btn btn-primary active" data-cat="all">همه</button>
@foreach(\App\Helpers\getSubCats(\App\Helpers\getSetting('3cat')) as $cat)
<button type="button" class="btn btn-primary" data-cat="cat{{$cat->id}}">
{{$cat->name}}
</button>
2 years ago
@endforeach
</div>
2 years ago
<div id="da-thumbs" class="da-thumbs">
@foreach(\App\Helpers\getProductByCat(\App\Helpers\getSetting('3cat'),'stock_quantity','desc',12) as $p)
<div class="item custom @foreach($p->categories()->pluck('id')->toArray() as $c) cat{{$c}} @endforeach shad pad">
<div class="box">
<a href="{{route('product',$p->slug)}}">
<img src="{{$p->thumbUrl()}}" class="img-fluid" alt="{{$p->name}}" title="{{$p->name}}" >
<h4>
{{$p->name}}
</h4>
</a>
<span>
{{$p->getPrice()}}
</span>
</div>
2 years ago
</div>
@endforeach
2 years ago
2 years ago
</div>
</div>
</section>
2 years ago
<section id="brand" class="pt-4 pb-4">
2 years ago
<div class="container">
<h1>
2 years ago
برندها
2 years ago
</h1>
<div class="row">
@foreach(\App\Helpers\getSubCats(\App\Helpers\getSetting('4cat')) as $cat)
2 years ago
<div class="col-md-2 col-sm-3 col-4">
2 years ago
<a href="{{route('cat',$cat->slug)}}">
2 years ago
<img src="{{$cat->thumbUrl()}}" title="{{$cat->name}}" alt="{{$cat->name}}">
2 years ago
</a>
</div>
@endforeach
</div>
</div>
</section>
@endsection