+{{--
-
The Classic Compose UI has been retired.
+
Compose New Post
New Post
+
--}}
+
+
@endsection
@push('scripts')
-
+
+
@endpush
\ No newline at end of file
diff --git a/routes/web.php b/routes/web.php
index b04997e48..bd39084ed 100644
--- a/routes/web.php
+++ b/routes/web.php
@@ -102,13 +102,12 @@ Route::domain(config('pixelfed.domain.app'))->middleware(['validemail', 'twofact
Route::get('status/{id}/replies', 'InternalApiController@statusReplies');
Route::post('moderator/action', 'InternalApiController@modAction');
Route::get('discover/categories', 'InternalApiController@discoverCategories');
- Route::post('status/compose', 'InternalApiController@composePost')->middleware('throttle:maxPostsPerHour,60')->middleware('throttle:maxPostsPerDay,1440');
Route::get('loops', 'DiscoverController@loopsApi');
Route::post('loops/watch', 'DiscoverController@loopWatch');
Route::get('discover/tag', 'DiscoverController@getHashtags');
});
Route::group(['prefix' => 'local'], function () {
- Route::post('status/compose', 'InternalApiController@compose')->middleware('throttle:maxPostsPerHour,60')->middleware('throttle:maxPostsPerDay,1440');
+ Route::post('status/compose', 'InternalApiController@composePost')->middleware('throttle:maxPostsPerHour,60')->middleware('throttle:maxPostsPerDay,1440');
Route::get('exp/rec', 'ApiController@userRecommendations');
Route::post('discover/tag/subscribe', 'HashtagFollowController@store')->middleware('throttle:maxHashtagFollowsPerHour,60')->middleware('throttle:maxHashtagFollowsPerDay,1440');;
Route::get('discover/tag/list', 'HashtagFollowController@getTags');
@@ -122,6 +121,10 @@ Route::domain(config('pixelfed.domain.app'))->middleware(['validemail', 'twofact
Route::post('collection/{id}/publish', 'CollectionController@publish')->middleware('throttle:maxCollectionsPerHour,60')->middleware('throttle:maxCollectionsPerDay,1440')->middleware('throttle:maxCollectionsPerMonth,43800');
Route::get('profile/collections/{id}', 'CollectionController@getUserCollections');
});
+ Route::group(['prefix' => 'admin'], function () {
+ Route::post('moderate', 'Api\AdminApiController@moderate');
+ });
+
});
Route::get('discover/tags/{hashtag}', 'DiscoverController@showTags');
diff --git a/webpack.mix.js b/webpack.mix.js
index 64ab467e4..faafe51b0 100644
--- a/webpack.mix.js
+++ b/webpack.mix.js
@@ -21,6 +21,7 @@ mix.js('resources/assets/js/app.js', 'public/js')
.js('resources/assets/js/status.js', 'public/js')
.js('resources/assets/js/timeline.js', 'public/js')
.js('resources/assets/js/compose.js', 'public/js')
+.js('resources/assets/js/compose-classic.js', 'public/js')
.js('resources/assets/js/search.js', 'public/js')
.js('resources/assets/js/developers.js', 'public/js')
.js('resources/assets/js/loops.js', 'public/js')
@@ -33,6 +34,7 @@ mix.js('resources/assets/js/app.js', 'public/js')
.js('resources/assets/js/hashtag.js', 'public/js')
.js('resources/assets/js/collectioncompose.js', 'public/js')
.js('resources/assets/js/collections.js', 'public/js')
+//.js('resources/assets/js/admin.js', 'public/js')
.extract([
'lodash',
From c176f8cc117150cad7d17bc72821f40294258a96 Mon Sep 17 00:00:00 2001
From: Daniel Supernault
Date: Thu, 22 Aug 2019 22:41:56 -0600
Subject: [PATCH 6/7] Update routes
---
routes/web.php | 1 +
1 file changed, 1 insertion(+)
diff --git a/routes/web.php b/routes/web.php
index bd39084ed..141fac2dd 100644
--- a/routes/web.php
+++ b/routes/web.php
@@ -105,6 +105,7 @@ Route::domain(config('pixelfed.domain.app'))->middleware(['validemail', 'twofact
Route::get('loops', 'DiscoverController@loopsApi');
Route::post('loops/watch', 'DiscoverController@loopWatch');
Route::get('discover/tag', 'DiscoverController@getHashtags');
+ Route::post('status/compose', 'InternalApiController@composePost')->middleware('throttle:maxPostsPerHour,60')->middleware('throttle:maxPostsPerDay,1440');
});
Route::group(['prefix' => 'local'], function () {
Route::post('status/compose', 'InternalApiController@composePost')->middleware('throttle:maxPostsPerHour,60')->middleware('throttle:maxPostsPerDay,1440');
From 0f0b3c2d058ec6c5e27189fc4eb8a2d45b240192 Mon Sep 17 00:00:00 2001
From: Daniel Supernault
Date: Fri, 23 Aug 2019 13:03:43 -0600
Subject: [PATCH 7/7] Update SettingsController
---
app/Http/Controllers/SettingsController.php | 4 ----
resources/views/settings/security.blade.php | 4 +---
2 files changed, 1 insertion(+), 7 deletions(-)
diff --git a/app/Http/Controllers/SettingsController.php b/app/Http/Controllers/SettingsController.php
index 2d5e69091..89f504079 100644
--- a/app/Http/Controllers/SettingsController.php
+++ b/app/Http/Controllers/SettingsController.php
@@ -95,7 +95,6 @@ class SettingsController extends Controller
$user = Auth::user();
abort_if(!config('pixelfed.account_deletion'), 403);
abort_if($user->is_admin, 403);
- abort_if($user->created_at->gt(now()->subHours(12)), 403);
return view('settings.remove.temporary');
}
@@ -105,7 +104,6 @@ class SettingsController extends Controller
$user = Auth::user();
abort_if(!config('pixelfed.account_deletion'), 403);
abort_if($user->is_admin, 403);
- abort_if($user->created_at->gt(now()->subHours(12)), 403);
$profile = $user->profile;
$user->status = 'disabled';
$profile->status = 'disabled';
@@ -120,7 +118,6 @@ class SettingsController extends Controller
{
$user = Auth::user();
abort_if($user->is_admin, 403);
- abort_if($user->created_at->gt(now()->subDays(7)), 403);
return view('settings.remove.permanent');
}
@@ -132,7 +129,6 @@ class SettingsController extends Controller
$user = Auth::user();
abort_if(!config('pixelfed.account_deletion'), 403);
abort_if($user->is_admin, 403);
- abort_if($user->created_at->gt(now()->subDays(7)), 403);
$profile = $user->profile;
$ts = Carbon::now()->addMonth();
$user->status = 'delete';
diff --git a/resources/views/settings/security.blade.php b/resources/views/settings/security.blade.php
index c0acc4a7c..b0802d402 100644
--- a/resources/views/settings/security.blade.php
+++ b/resources/views/settings/security.blade.php
@@ -27,7 +27,7 @@
@include('settings.security.device-panel')
- @if(config('pixelfed.account_deletion') && !$user->is_admin && $user->created_at->lt(now()->subHours(12)))
+ @if(config('pixelfed.account_deletion') && !$user->is_admin)
Danger Zone
- @if(!$user->is_admin && $user->created_at->lt(now()->subDays(7)) )
Delete this Account
@@ -50,7 +49,6 @@
Delete
- @endif
@endif