Improve likes
Squashed commit of the following: commit 4dc223939c31fd5771b9e6895c8e9e0c88fc6663 Author: Jonny Barnes <jonny@jonnybarnes.uk> Date: Fri Jan 12 21:19:29 2018 +0000 update changelog commit 7b15937a097c12145e60dfec67cad19e385fcb9f Author: Jonny Barnes <jonny@jonnybarnes.uk> Date: Fri Jan 12 21:19:13 2018 +0000 re-compile frontend assets commit f533d5e463d06e158b7bedbfd3602af70113acbc Author: Jonny Barnes <jonny@jonnybarnes.uk> Date: Fri Jan 12 21:14:11 2018 +0000 Only use “by” if there is an author name to show commit 7b067fd559ce2f4a82ad747a3ebd3474e221169c Author: Jonny Barnes <jonny@jonnybarnes.uk> Date: Fri Jan 12 21:12:27 2018 +0000 Some styles for the likes page commit 039523f595115c1329a3939837ebf589184de995 Author: Jonny Barnes <jonny@jonnybarnes.uk> Date: Fri Jan 12 21:11:44 2018 +0000 Add a like with just the url to the seeder commit c43d4b07936fceeeb59460399a20abec7a9bc3ae Author: Jonny Barnes <jonny@jonnybarnes.uk> Date: Fri Jan 12 20:44:46 2018 +0000 Add test for the admin cp part of likes commit eb115fa481319e98bf54a9fa6aa682479e56787d Author: Jonny Barnes <jonny@jonnybarnes.uk> Date: Fri Jan 12 20:44:28 2018 +0000 Catch 400 errors from a POSSE attempt, its not that important commit 79f7aa7807534eb76ae57dee72002f99249255b0 Author: Jonny Barnes <jonny@jonnybarnes.uk> Date: Fri Jan 12 20:01:19 2018 +0000 Better fetch data for tweets, attempt to POSSE them back to twitter commit 1ad078929f918c00db550c0af315677cd991dad6 Author: Jonny Barnes <jonny@jonnybarnes.uk> Date: Fri Jan 12 20:00:40 2018 +0000 Only filter the like content when its actual HTML commit 10f1ba430d4d5262d28e24ca0413474900ea6145 Author: Jonny Barnes <jonny@jonnybarnes.uk> Date: Fri Jan 12 19:59:57 2018 +0000 Add link to POSSE to twitter via bridgy commit 7f8e5c6dd39716fb51b5766de2f24c7e01355dbb Author: Jonny Barnes <jonny@jonnybarnes.uk> Date: Fri Jan 12 19:59:22 2018 +0000 add links in the admin welcome page for likes commit ebe80b07759881ffb98f8f5117ef25310aaabe6c Author: Jonny Barnes <jonny@jonnybarnes.uk> Date: Fri Jan 12 18:22:35 2018 +0000 Add the admin routes commit 5e150a7c39f5d71688b7ef14c924d09ba2ec82ba Author: Jonny Barnes <jonny@jonnybarnes.uk> Date: Fri Jan 12 18:22:15 2018 +0000 Add admin functionality for likes
This commit is contained in:
parent
6ccd564d56
commit
50facf52de
23 changed files with 281 additions and 12 deletions
17
resources/views/admin/likes/create.blade.php
Normal file
17
resources/views/admin/likes/create.blade.php
Normal file
|
@ -0,0 +1,17 @@
|
|||
@extends('master')
|
||||
|
||||
@section('title')New Like « Admin CP « @stop
|
||||
|
||||
@section('content')
|
||||
<h1>New Like</h1>
|
||||
<form action="/admin/likes/" method="post" accept-charset="utf-8" class="admin-form form">
|
||||
{{ csrf_field() }}
|
||||
<div>
|
||||
<label for="like_url">Like URL:</label>
|
||||
<input type="text" name="like_url" id="like_url" placeholder="Like URL">
|
||||
</div>
|
||||
<div>
|
||||
<button type="submit" name="submit">Submit</button>
|
||||
</div>
|
||||
</form>
|
||||
@stop
|
24
resources/views/admin/likes/edit.blade.php
Normal file
24
resources/views/admin/likes/edit.blade.php
Normal file
|
@ -0,0 +1,24 @@
|
|||
@extends('master')
|
||||
|
||||
@section('title')Edit Like « Admin CP « @stop
|
||||
|
||||
@section('content')
|
||||
<h1>Edit Like</h1>
|
||||
<form action="/admin/likes/{{ $id }}" method="post" accept-charset="utf-8" class="admin-form form">
|
||||
{{ csrf_field() }}
|
||||
{{ method_field('PUT') }}
|
||||
<div>
|
||||
<label for="like_url">Like URL:</label>
|
||||
<input type="text" name="like_url" id="like_url" value="{{ $like_url }}">
|
||||
</div>
|
||||
<div>
|
||||
<button type="submit" name="edit">Edit</button>
|
||||
</div>
|
||||
</form>
|
||||
<hr>
|
||||
<form action="/admin/likes/{{ $id }}" method="post">
|
||||
{{ csrf_field() }}
|
||||
{{ method_field('DELETE') }}
|
||||
<button type="submit" name="delete">Delete Like</button>
|
||||
</form>
|
||||
@stop
|
15
resources/views/admin/likes/index.blade.php
Normal file
15
resources/views/admin/likes/index.blade.php
Normal file
|
@ -0,0 +1,15 @@
|
|||
@extends('master')
|
||||
|
||||
@section('title')List Likes « Admin CP « @stop
|
||||
|
||||
@section('content')
|
||||
<h1>Likes</h1>
|
||||
<ul>
|
||||
@foreach($likes as $like)
|
||||
<li>{{ $like['url'] }}
|
||||
<a href="/admin/likes/{{ $like['id'] }}/edit">edit?</a>
|
||||
</li>
|
||||
@endforeach
|
||||
</ul>
|
||||
<p>Create a <a href="/admin/likes/create">new like</a>?</p>
|
||||
@stop
|
|
@ -11,6 +11,9 @@
|
|||
<h2>Notes</h2>
|
||||
<p>You can either <a href="/admin/notes/create">create</a> new notes, or <a href="/admin/notes/">edit</a> them.<p>
|
||||
|
||||
<h2>Likes</h2>
|
||||
<p>You can either <a href="/admin/likes/create">create</a> a new like, or <a href="/admin/likes/">edit</a> them.<p>
|
||||
|
||||
<h2>Clients</h2>
|
||||
<p>You can either <a href="/admin/clients/create">create</a> new client names, or <a href="/admin/clients/">edit</a> them.</p>
|
||||
|
||||
|
|
|
@ -3,18 +3,20 @@
|
|||
@section('title')Likes « @stop
|
||||
|
||||
@section('content')
|
||||
<div class="h-feed top-space">
|
||||
<div class="h-feed">
|
||||
@foreach($likes as $like)
|
||||
<div class="h-entry">
|
||||
<div class="h-cite u-like-of">
|
||||
Liked <a class="u-url" href="{{ $like->url }}">a post</a> by
|
||||
<span class="p-author h-card">
|
||||
Liked <a class="u-url" href="{{ $like->url }}">a post</a>
|
||||
@isset($like->author_name)
|
||||
by <span class="p-author h-card">
|
||||
@isset($like->author_url)
|
||||
<a class="u-url p-name" href="{{ $like->author_url }}">{{ $like->author_name }}</a>
|
||||
@else
|
||||
<span class="p-name">{{ $like->author_name }}</span>
|
||||
@endisset
|
||||
</span>
|
||||
@endisset
|
||||
@isset($like->content)
|
||||
<blockquote class="e-content">
|
||||
{!! $like->content !!}
|
||||
|
|
|
@ -5,17 +5,22 @@
|
|||
@section('content')
|
||||
<div class="h-entry top-space">
|
||||
<div class="h-cite u-like-of">
|
||||
Liked <a class="u-url" href="{{ $like->url }}">a post</a> by
|
||||
<span class="p-author h-card">
|
||||
Liked <a class="u-url" href="{{ $like->url }}">a post</a>
|
||||
@isset($like->author_name)
|
||||
by <span class="p-author h-card">
|
||||
@isset($like->author_url)
|
||||
<a class="u-url p-name" href="{{ $like->author_url }}">{{ $like->author_name }}</a>
|
||||
@else
|
||||
<span class="p-name">{{ $like->author_name }}</span>
|
||||
@endisset
|
||||
</span>:
|
||||
</span>
|
||||
@endisset
|
||||
<blockquote class="e-content">
|
||||
{!! $like->content !!}
|
||||
</blockquote>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- POSSE to Twitter -->
|
||||
<a href="https://brid.gy/publish/twitter"></a>
|
||||
@stop
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue