Ooof, got the dependencies all up to date as well

Lots of tests needed fixing, but it seemed to be a whitespace parsing
error in the view files 🤔
This commit is contained in:
Jonny Barnes 2019-10-27 16:15:14 +00:00
parent ec01b3c6a2
commit b2b6693aec
61 changed files with 2057 additions and 1441 deletions

View file

@ -3,28 +3,30 @@
@section('title')New Article « Admin CP « @stop
@section('content')
@if(isset($message)) <p class="error">{{ $message }}</p>@endif
<form action="/admin/blog/" method="post" accept-charset="utf-8" enctype="multipart/form-data" class="admin-form form">
{{ csrf_field() }}
<div>
<label for="title">Title (URL):</label>
<input type="text" name="title" id="title" value="{{ old('title') }}" placeholder="Title here">
<input type="text" name="url" id="url" value="{{ old('url') }}" placeholder="Article URL">
</div>
<div>
<label for="main">Main:</label>
<textarea name="main" id="main" placeholder="Article here">{{ old('main') }}</textarea>
</div>
<div class="form-row">
<label for="published">Published:</label>
<input type="checkbox" name="published" id="published" value="1">
</div>
<p>Or you can upload an <code>.md</code> file:</p>
<div>
<input type="file" accept=".md" name="article">
</div>
<div>
<button type="submit" name="save">Save</button>
</div>
</form>
@if(isset($message))
<p class="error">{{ $message }}</p>
@endif
<form action="/admin/blog/" method="post" accept-charset="utf-8" enctype="multipart/form-data" class="admin-form form">
{{ csrf_field() }}
<div>
<label for="title">Title (URL):</label>
<input type="text" name="title" id="title" value="{{ old('title') }}" placeholder="Title here">
<input type="text" name="url" id="url" value="{{ old('url') }}" placeholder="Article URL">
</div>
<div>
<label for="main">Main:</label>
<textarea name="main" id="main" placeholder="Article here">{{ old('main') }}</textarea>
</div>
<div class="form-row">
<label for="published">Published:</label>
<input type="checkbox" name="published" id="published" value="1">
</div>
<p>Or you can upload an <code>.md</code> file:</p>
<div>
<input type="file" accept=".md" name="article">
</div>
<div>
<button type="submit" name="save">Save</button>
</div>
</form>
@stop

View file

@ -3,32 +3,32 @@
@section('title')Edit Article « Admin CP « @stop
@section('content')
<form action="/admin/blog/{{ $id }}" method="post" accept-charset="utf-8" class="admin-form form">
{{ csrf_field() }}
{{ method_field('PUT') }}
<div>
<label for="title">Title (URL):</label>
<input type="text" name="title" id="title" value="{!! $post['0']['title'] !!}">
<input type="url" name="url" id="url" value="{!! $post['0']['url'] !!}">
</div>
<div>
<label for="main">Main:</label>
<textarea name="main" id="main">{{ $post['0']['main'] }}</textarea>
</div>
<div class="form-row">
<label for="published">Published:</label>
<input type="checkbox" name="published" value="1"@if($post['0']['published'] == '1') checked="checked"@endif>
</div>
<div>
<button type="submit" name="save">Save</button>
</div>
</form>
<hr>
<form action="/admin/blog/{{ $id }}" method="post" class="admin-form form">
{{ csrf_field() }}
{{ method_field('DELETE') }}
<div>
<button type="submit" name="delete">Delete</button>
</div>
</form>
<form action="/admin/blog/{{ $id }}" method="post" accept-charset="utf-8" class="admin-form form">
{{ csrf_field() }}
{{ method_field('PUT') }}
<div>
<label for="title">Title (URL):</label>
<input type="text" name="title" id="title" value="{!! $post['0']['title'] !!}">
<input type="url" name="url" id="url" value="{!! $post['0']['url'] !!}">
</div>
<div>
<label for="main">Main:</label>
<textarea name="main" id="main">{{ $post['0']['main'] }}</textarea>
</div>
<div class="form-row">
<label for="published">Published:</label>
<input type="checkbox" name="published" value="1"@if($post['0']['published'] == '1') checked="checked"@endif>
</div>
<div>
<button type="submit" name="save">Save</button>
</div>
</form>
<hr>
<form action="/admin/blog/{{ $id }}" method="post" class="admin-form form">
{{ csrf_field() }}
{{ method_field('DELETE') }}
<div>
<button type="submit" name="delete">Delete</button>
</div>
</form>
@stop

View file

@ -3,10 +3,13 @@
@section('title')List Articles « Admin CP « @stop
@section('content')
<p>Select article to edit:</p>
<ol reversed>
@foreach($posts as $post)
<li><a href="/admin/blog/{{ $post['id'] }}/edit">{{ $post['title'] }}</a>@if($post['published'] == '0')<span class="notpublished">not published</span>@endif
@endforeach
</ol>
<p>Select article to edit:</p>
<ol reversed>
@foreach($posts as $post)
<li>
<a href="/admin/blog/{{ $post['id'] }}/edit">{{ $post['title'] }}</a>
@if($post['published'] == '0')<span class="notpublished">not published</span>@endif
</li>
@endforeach
</ol>
@stop