1 |
d7feebff
|
zabran
|
@extends('layouts.app')
|
2 |
|
|
|
3 |
|
|
@section('title', 'Charts')
|
4 |
|
|
|
5 |
|
|
@section('content')
|
6 |
|
|
<div class="container">
|
7 |
|
|
@if(isset($artefacts))
|
8 |
|
|
@if(count($artefacts) >= 1)
|
9 |
49b1d48f
|
zabran
|
<div class="fav-cat-mybooks">
|
10 |
|
|
<h1>Charts</h1>
|
11 |
|
|
</div>
|
12 |
d7feebff
|
zabran
|
@foreach($artefacts as $artefact)
|
13 |
|
|
<div class="artefacts-area mb-5">
|
14 |
|
|
<div class="card">
|
15 |
7c1c3ef3
|
zabran
|
<a href="{{ url('/artefact/' . $artefact->id) }}">
|
16 |
|
|
|
17 |
|
|
</a>
|
18 |
49b1d48f
|
zabran
|
<div class="container card-cus-bottom">
|
19 |
7c1c3ef3
|
zabran
|
<div class="d-flex flex-row row-list">
|
20 |
|
|
<div class="p-1 flex-fill bd-highlight left_panel_info">
|
21 |
|
|
<a href="{{ url('/artefact/' . $artefact->id) }}">
|
22 |
|
|
<h5 class="card-title ">{{$artefact->name}}</h5>
|
23 |
|
|
<h6 class="card-title">{{$artefact->author}}</h6>
|
24 |
|
|
</a>
|
25 |
d7feebff
|
zabran
|
</div>
|
26 |
7c1c3ef3
|
zabran
|
<div class="p-1 flex-fill bd-highlight float-center">
|
27 |
|
|
<div class="text-center right_panel_info">
|
28 |
|
|
|
29 |
|
|
<div class="charts float-center">
|
30 |
49b1d48f
|
zabran
|
@if (!$artefact->favourite)
|
31 |
7c1c3ef3
|
zabran
|
<form method="POST"
|
32 |
|
|
action="{{ url('/artefact/like/' . $artefact->id) }}">
|
33 |
|
|
@csrf
|
34 |
|
|
<button id="like_butt_{{$artefact->id}}" style="display: inline"
|
35 |
|
|
type="submit"
|
36 |
|
|
class="btn btn-primary button-image inter_like" ></button>
|
37 |
|
|
</form>
|
38 |
49b1d48f
|
zabran
|
@else
|
39 |
7c1c3ef3
|
zabran
|
<form method="POST"
|
40 |
|
|
action="{{ url('/artefact/unlike/' . $artefact->id) }}">
|
41 |
|
|
@csrf
|
42 |
|
|
<button id="like_butt_{{$artefact->id}}" style="display: inline"
|
43 |
|
|
type="submit"
|
44 |
|
|
class="btn btn-primary button-image inter_like_filled"></button>
|
45 |
|
|
</form>
|
46 |
49b1d48f
|
zabran
|
@endif
|
47 |
|
|
<span class="likes_text">
|
48 |
|
|
<h6>{{$artefact->likes}}</h6>
|
49 |
|
|
</span>
|
50 |
|
|
</div>
|
51 |
|
|
</div>
|
52 |
d7feebff
|
zabran
|
</div>
|
53 |
|
|
</div>
|
54 |
|
|
</div>
|
55 |
|
|
</div>
|
56 |
|
|
</div>
|
57 |
|
|
@endforeach
|
58 |
|
|
@else
|
59 |
|
|
<ul class="list-group">
|
60 |
|
|
<li class="list-group-item">
|
61 |
49b1d48f
|
zabran
|
<h3>No artefacts were added!</h3>
|
62 |
d7feebff
|
zabran
|
</li>
|
63 |
|
|
</ul>
|
64 |
|
|
@endif
|
65 |
|
|
@else
|
66 |
|
|
<ul class="list-group">
|
67 |
|
|
<li class="list-group-item">
|
68 |
|
|
<h3>Not found the USER in the database with number id {{$user->id}}!</h3>
|
69 |
|
|
</li>
|
70 |
|
|
</ul>
|
71 |
|
|
@endif
|
72 |
7c1c3ef3
|
zabran
|
</div>
|
73 |
d7feebff
|
zabran
|
@endsection
|