2019-10-01 11:53:12 +02:00
|
|
|
@extends('layouts.connected')
|
2019-09-18 16:50:01 +02:00
|
|
|
|
2019-09-30 16:32:40 +02:00
|
|
|
@inject('tag_detector', 'App\Services\TagDetectorService)
|
|
|
|
|
2019-09-18 16:50:01 +02:00
|
|
|
@section('content')
|
|
|
|
<div class="container">
|
|
|
|
<div class="row justify-content-center">
|
|
|
|
<div class="col-md-8">
|
|
|
|
<div class="card">
|
2019-09-25 15:20:22 +02:00
|
|
|
<div class="card-header">{{ __('Dashboard') }}</div>
|
2019-09-18 16:50:01 +02:00
|
|
|
|
|
|
|
<div class="card-body">
|
|
|
|
@if (session('status'))
|
|
|
|
<div class="alert alert-success" role="alert">
|
|
|
|
{{ session('status') }}
|
|
|
|
</div>
|
|
|
|
@endif
|
|
|
|
|
|
|
|
<h1>{{ strftime('%B %G', $today->format('U')) }}</h1>
|
2019-09-25 15:20:22 +02:00
|
|
|
@if($already)
|
|
|
|
<div class="alert alert-info" role="alert">L'activité du jour a été entrée.</div>
|
|
|
|
@else
|
2019-09-18 16:50:01 +02:00
|
|
|
<form action="{{ url('store') }}" method="post" accept-charset="utf-8">
|
|
|
|
@csrf
|
|
|
|
<div class="contact-form">
|
|
|
|
<div class="form-group">
|
|
|
|
<label class="control-label col-sm-5" for="message">Quoi de neuf aujourd'hui ?</label>
|
|
|
|
<div class="col-sm-10">
|
2019-10-01 11:53:12 +02:00
|
|
|
<div id="app">
|
|
|
|
</div>
|
2019-09-18 16:50:01 +02:00
|
|
|
<span class="text-danger">{{ $errors->first('message') }}</span>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="form-group">
|
|
|
|
<div class="col-sm-offset-2 col-sm-10">
|
|
|
|
<button type="submit" class="btn btn-default">J'enregistre ma journée</button>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</form>
|
2019-09-25 15:20:22 +02:00
|
|
|
@endif
|
2019-09-18 16:50:01 +02:00
|
|
|
@foreach($posts as $post)
|
|
|
|
<div class="post">
|
2019-09-25 15:20:22 +02:00
|
|
|
<p>{{ \Carbon\Carbon::instance($post->date_post)->diffForHumans() }}</p>
|
2019-09-30 16:32:40 +02:00
|
|
|
<p>{!! $tag_detector->linkTagFrom($post->content) !!}</p>
|
2019-09-18 16:50:01 +02:00
|
|
|
</div>
|
|
|
|
@endforeach
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
@endsection
|