From 33cc1089003599ad9c7b7173b321f1ddabc5cfff Mon Sep 17 00:00:00 2001
From: IceToast
Date: Mon, 6 Feb 2023 11:32:19 +0100
Subject: [PATCH 01/20] =?UTF-8?q?fix:=20=F0=9F=90=9B=20getCsrfIgnoredRoute?=
=?UTF-8?q?s=20map=20all=20routes=20just=20once?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
app/Helpers/ExtensionHelper.php | 8 +++-----
1 file changed, 3 insertions(+), 5 deletions(-)
diff --git a/app/Helpers/ExtensionHelper.php b/app/Helpers/ExtensionHelper.php
index fdf880ab..7e1bbda3 100644
--- a/app/Helpers/ExtensionHelper.php
+++ b/app/Helpers/ExtensionHelper.php
@@ -51,13 +51,11 @@ public static function getAllCsrfIgnoredRoutes()
$routes = array_merge($routes, $config['RoutesIgnoreCsrf']);
}
- // add extension/ infront of every route
- foreach ($routes as $key => $route) {
- $routes[$key] = 'extensions/' . $route;
- }
+ // map over the routes and add the extension name as prefix
+ $result = array_map(fn ($item) => "extensions/{$item}", $routes);
}
- return $routes;
+ return $result;
}
/**
From 29e9ed6e4ab86af376fae7ae512174e28196adcf Mon Sep 17 00:00:00 2001
From: IceToast
Date: Mon, 6 Feb 2023 11:57:14 +0100
Subject: [PATCH 02/20] =?UTF-8?q?fix:=20=F0=9F=90=9B=20Wrong=20class=20nam?=
=?UTF-8?q?e?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
app/Console/Commands/CleanupOpenPayments.php | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/Console/Commands/CleanupOpenPayments.php b/app/Console/Commands/CleanupOpenPayments.php
index 31510b6a..6fd96a7a 100644
--- a/app/Console/Commands/CleanupOpenPayments.php
+++ b/app/Console/Commands/CleanupOpenPayments.php
@@ -5,7 +5,7 @@
use App\Models\Payment;
use Illuminate\Console\Command;
-class CleanupPayments extends Command
+class CleanupOpenPayments extends Command
{
/**
* The name and signature of the console command.
From 01fc6333032f1726a828eecbb135631174d0bb1a Mon Sep 17 00:00:00 2001
From: IceToast
Date: Mon, 6 Feb 2023 20:42:17 +0100
Subject: [PATCH 03/20] =?UTF-8?q?fix:=20=F0=9F=9A=91=EF=B8=8F=20Set=20Them?=
=?UTF-8?q?e=20to=20default=20when=20no=20setting=20or=20setting=20null?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
app/Providers/AppServiceProvider.php | 16 +++++++++-------
1 file changed, 9 insertions(+), 7 deletions(-)
diff --git a/app/Providers/AppServiceProvider.php b/app/Providers/AppServiceProvider.php
index 8fae42a6..6299bf4f 100644
--- a/app/Providers/AppServiceProvider.php
+++ b/app/Providers/AppServiceProvider.php
@@ -46,9 +46,9 @@ public function boot()
}
//if none of result array is true. it sets ok to false
- if (! in_array(true, $result)) {
+ if (!in_array(true, $result)) {
$ok = false;
- $validator->setCustomMessages(['multiple_date_format' => 'The format must be one of '.implode(',', $parameters)]);
+ $validator->setCustomMessages(['multiple_date_format' => 'The format must be one of ' . implode(',', $parameters)]);
}
return $ok;
@@ -60,7 +60,7 @@ public function boot()
view()->share('useful_links', $useful_links);
}
} catch (Exception $e) {
- Log::error("Couldnt find useful_links. Probably the installation is not completet. ".$e);
+ Log::error("Couldnt find useful_links. Probably the installation is not completet. " . $e);
}
//only run if the installer has been executed
@@ -71,12 +71,14 @@ public function boot()
config([$setting->key => $setting->value]);
}
- if(!file_exists(base_path('themes') . "/" . config("SETTINGS::SYSTEM:THEME"))){
+ if (!file_exists(base_path('themes') . "/" . config("SETTINGS::SYSTEM:THEME"))) {
config(['SETTINGS::SYSTEM:THEME' => "default"]);
}
- if(config('SETTINGS::SYSTEM:THEME') !== config('theme.active')){
- Theme::set(config("SETTINGS::SYSTEM:THEME"), "default");
+ if (config('SETTINGS::SYSTEM:THEME') && config('SETTINGS::SYSTEM:THEME') !== config('theme.active')) {
+ Theme::set(config("SETTINGS::SYSTEM:THEME", "default"), "default");
+ } else {
+ Theme::set("default", "default");
}
// Set Mail Config
@@ -126,7 +128,7 @@ public function boot()
}
try {
- $stringfromfile = file(base_path().'/.git/HEAD');
+ $stringfromfile = file(base_path() . '/.git/HEAD');
$firstLine = $stringfromfile[0]; //get the string from the array
From b8946d8666b8b42ca9016da7597b133a4ae2f4b7 Mon Sep 17 00:00:00 2001
From: IceToast
Date: Tue, 7 Feb 2023 13:59:09 +0100
Subject: [PATCH 04/20] =?UTF-8?q?fix:=20=F0=9F=9A=91=EF=B8=8F=20Paypal=20a?=
=?UTF-8?q?uthentication=20error=20->=20blank=20page?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../PaymentGateways/PayPal/index.php | 20 ++++++++++++++-----
1 file changed, 15 insertions(+), 5 deletions(-)
diff --git a/app/Extensions/PaymentGateways/PayPal/index.php b/app/Extensions/PaymentGateways/PayPal/index.php
index 88abc809..11ac4473 100644
--- a/app/Extensions/PaymentGateways/PayPal/index.php
+++ b/app/Extensions/PaymentGateways/PayPal/index.php
@@ -9,6 +9,7 @@
use Illuminate\Http\Request;
use Illuminate\Support\Facades\Auth;
use Illuminate\Support\Facades\Redirect;
+use Illuminate\Support\Facades\Log;
use PayPalCheckoutSdk\Core\PayPalHttpClient;
use PayPalCheckoutSdk\Core\ProductionEnvironment;
use PayPalCheckoutSdk\Core\SandboxEnvironment;
@@ -74,7 +75,7 @@ function PaypalPay(Request $request)
"application_context" => [
"cancel_url" => route('payment.Cancel'),
"return_url" => route('payment.PayPalSuccess', ['payment' => $payment->id]),
- 'brand_name' => config('app.name', 'Laravel'),
+ 'brand_name' => config('app.name', 'Controlpanel.GG'),
'shipping_preference' => 'NO_SHIPPING'
]
@@ -85,14 +86,23 @@ function PaypalPay(Request $request)
// Call API with your client and get a response for your call
$response = getPayPalClient()->execute($request);
+ // check for any errors in the response
+ if ($response->statusCode != 201) {
+ throw new \Exception($response->statusCode);
+ }
+
+ // make sure the link is not empty
+ if (empty($response->result->links[1]->href)) {
+ throw new \Exception('No redirect link found');
+ }
+
Redirect::away($response->result->links[1]->href)->send();
return;
} catch (HttpException $ex) {
- error_log($ex->statusCode);
- error_log($ex->getMessage());
-
+ Log::error('PayPal Payment: ' . $ex->getMessage());
$payment->delete();
- Redirect::route('payment.Cancel');
+
+ Redirect::route('store.index')->with('error', 'Payment failed')->send();
return;
}
}
From 128015f0fae38b9d1e7190f803291e6d39581278 Mon Sep 17 00:00:00 2001
From: IceToast
Date: Tue, 7 Feb 2023 14:18:22 +0100
Subject: [PATCH 05/20] =?UTF-8?q?chore:=20=F0=9F=8C=90=20localization?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
app/Extensions/PaymentGateways/PayPal/index.php | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/Extensions/PaymentGateways/PayPal/index.php b/app/Extensions/PaymentGateways/PayPal/index.php
index 11ac4473..648913ae 100644
--- a/app/Extensions/PaymentGateways/PayPal/index.php
+++ b/app/Extensions/PaymentGateways/PayPal/index.php
@@ -102,7 +102,7 @@ function PaypalPay(Request $request)
Log::error('PayPal Payment: ' . $ex->getMessage());
$payment->delete();
- Redirect::route('store.index')->with('error', 'Payment failed')->send();
+ Redirect::route('store.index')->with('error', __('Payment failed'))->send();
return;
}
}
From 040bcf2fa0bcea22092f319bb5d4894c9f12876d Mon Sep 17 00:00:00 2001
From: Johannes F
Date: Sat, 11 Feb 2023 22:17:42 +0100
Subject: [PATCH 06/20] =?UTF-8?q?fix:=20=F0=9F=9A=91=EF=B8=8F=20Wrong=20ti?=
=?UTF-8?q?cket=20priority=20getting=20displayed?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
themes/default/views/moderator/ticket/show.blade.php | 4 ++--
themes/default/views/ticket/show.blade.php | 4 ++--
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/themes/default/views/moderator/ticket/show.blade.php b/themes/default/views/moderator/ticket/show.blade.php
index 13711dd0..2d51c5dd 100644
--- a/themes/default/views/moderator/ticket/show.blade.php
+++ b/themes/default/views/moderator/ticket/show.blade.php
@@ -61,10 +61,10 @@
{{__("Low")}}
@break
@case("Medium")
- {{__("Closed")}}
+ {{__("Medium")}}
@break
@case("High")
- {{__("Answered")}}
+ {{__("High")}}
@break
@endswitch
diff --git a/themes/default/views/ticket/show.blade.php b/themes/default/views/ticket/show.blade.php
index 96a3b46b..8d9afa26 100644
--- a/themes/default/views/ticket/show.blade.php
+++ b/themes/default/views/ticket/show.blade.php
@@ -61,10 +61,10 @@
{{__("Low")}}
@break
@case("Medium")
- {{__("Closed")}}
+ {{__("Medium")}}
@break
@case("High")
- {{__("Answered")}}
+ {{__("High")}}
@break
@endswitch
From faf99505628e2267b9d2dcbfa30590b53ba68f83 Mon Sep 17 00:00:00 2001
From: 2IceCube <95680355+2IceCube@users.noreply.github.com>
Date: Mon, 13 Feb 2023 22:54:21 +0100
Subject: [PATCH 07/20] Add Theme Watermark
---
themes/BlueInfinity/views/layouts/main.blade.php | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/themes/BlueInfinity/views/layouts/main.blade.php b/themes/BlueInfinity/views/layouts/main.blade.php
index c4ba7cd8..f5d888d5 100644
--- a/themes/BlueInfinity/views/layouts/main.blade.php
+++ b/themes/BlueInfinity/views/layouts/main.blade.php
@@ -441,7 +441,7 @@ class="nav-link @if (Request::routeIs('admin.activitylogs.*')) active @endif">
Copyright © 2021-{{ date('Y') }} {{ env('APP_NAME', 'Laravel') }}.
All rights
- reserved. Powered by ControlPanel.
+ reserved. Powered by ControlPanel. | Theme by 2IceCube
@if (!str_contains(config('BRANCHNAME'), 'main') && !str_contains(config('BRANCHNAME'), 'unknown'))
Version {{ config('app')['version'] }} - {{ config('BRANCHNAME') }}
@endif
From 60359a19baffe45bb10a459977f5d79153ca7451 Mon Sep 17 00:00:00 2001
From: 2IceCube <95680355+2IceCube@users.noreply.github.com>
Date: Mon, 13 Feb 2023 22:57:31 +0100
Subject: [PATCH 08/20] Fixed Mobile View
---
public/themes/BlueInfinity/app.css | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/public/themes/BlueInfinity/app.css b/public/themes/BlueInfinity/app.css
index 898ee94c..7ad8941f 100644
--- a/public/themes/BlueInfinity/app.css
+++ b/public/themes/BlueInfinity/app.css
@@ -1 +1 @@
-@import "default.css";.layout-fixed .wrapper .sidebar{ height:calc(100vh - 3.5rem - 1px);background:radial-gradient(#061b29,black);}body:not(.sidebar-mini-md) .content-wrapper,body:not(.sidebar-mini-md) .main-footer,body:not(.sidebar-mini-md) .main-header{ transition:margin-left .3s ease-in-out;margin-left:250px;background:radial-gradient(#061b29,black);}[class*=sidebar-dark] .brand-link,[class*=sidebar-dark] .brand-link .pushmenu{ color:hsla(0,0%,100%,.8);background:radial-gradient(#061b29,black);}.main-sidebar .brand-text,.main-sidebar .logo-xl,.main-sidebar .logo-xs,.sidebar .nav-link p,.sidebar .user-panel .info{ transition:margin-left .3s linear,opacity .3s ease,visibility .3s ease;color:#d3d3d3;}.sidebar-dark-primary .nav-sidebar>.nav-item>.nav-link.active,.sidebar-light-primary .nav-sidebar>.nav-item>.nav-link.active{ color:#fff;background:radial-gradient(#1b4b61,#fd030300);border-radius:50px;}.dark-mode .card{ background-color:#00000000;color:#ffffff99;border-width:3px;border-color:#f7f7f7;border-style:double;border-radius:15px;}.btn-info{ color:#ffffff;background-color:#b8171700;border-color:#ffffff;box-shadow:none;}.btn-warning{ color:#ffffff;background-color:#ffc10700;border-color:#ffffff;box-shadow:none;}.card-title{ float:left;font-size:1.1rem;font-weight:400;margin:0;color:white;}.dark-mode .text-muted{ color:#ffffff99!important;}.dark-mode .list-group-item{ background-color:#343a4000;border-color:#ffffff99;}.dark-mode .info-box{ background-color:#343a4000;color:#fff;border:3px;border-style:double;border-radius:15px;border-color:white;}label:not(.form-check-label):not(.custom-file-label){ font-weight:700;color:#ffffffc2;}.dark-mode .custom-control-label:before,.dark-mode .custom-file-label,.dark-mode .custom-file-label:after,.dark-mode .custom-select,.dark-mode .form-control,.dark-mode .input-group-text{ background-color:#007af400;color:#828282;}.alert-success{ color:#fff;background-color:#28a745;border-color:#ffffff;border-radius:15px;border-style:double;}.dark-mode{ color:#fff;background:radial-gradient(#061b29,black);}.dark-mode .invoice{ background-color:#343a4000;border:3px;border-radius:15px;border-color:white;border:double;}.dark-mode .nav-tabs .nav-item.show .nav-link,.dark-mode .nav-tabs .nav-link.active{ background-color:#ffffff1c;color:#fff;}.slim-crop-area img,.slim-image-editor img,.slim-popover img,.slim img{ background:black;}.dark-mode .callout{ background-color:#00ff0333;}.callout.callout-info{ border-left-color:#00e11d;}.p-3{ padding:1rem!important;background:#061b29;}.small-box>.small-box-footer{ color:hsla(0,0%,100%,.8);display:block;padding:3px 0;position:relative;text-align:center;text-decoration:none;z-index:10;background:#061b29;}.dark-mode .dropdown-menu{ background-color:#061b29;border-color:white;}.card-header:first-child{ border-radius:14px 14px 0px 0px;background:#061b29;}.card-body{ flex:1 1 auto;min-height:1px;padding:1.25rem;background:#061b29;}.justify-content-between{ justify-content:space-between!important;background:#061b29;}.dark-mode .card .card-footer{ background-color:#061b29;border-radius:0px 0px 14px 14px;}.dark-mode .select2-selection--single{ background-color:#061b29;border-color:#6c757d;}.select2-search--dropdown{ display:block;padding:4px;background:#061b29;}.select2-container--default .select2-results__option{ padding:6px 12px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;background:blue;background:#061b29;}.dark-mode .select2-dropdown,.dark-mode .select2-dropdown .select2-search__field,.dark-mode .select2-search--inline .select2-search__field{ background-color:#061b29;border-color:#ffffff;color:#fff;}.modal-header{ background:#061b29;}.modal-body{ position:relative;flex:1 1 auto;padding:1rem;background:#061b29;}.dark-mode .modal-footer,.dark-mode .modal-header{ border-color:#ffffff;background:#061b29;}
+@import "default.css";.layout-fixed .wrapper .sidebar{ height:calc(100vh - 3.5rem - 1px);background:radial-gradient(#061b29,black);}body:not(.sidebar-mini-md) .content-wrapper,body:not(.sidebar-mini-md) .main-footer,body:not(.sidebar-mini-md) .main-header{ transition:margin-left .3s ease-in-out;background:radial-gradient(#061b29,black);}[class*=sidebar-dark] .brand-link,[class*=sidebar-dark] .brand-link .pushmenu{ color:hsla(0,0%,100%,.8);background:radial-gradient(#061b29,black);}.main-sidebar .brand-text,.main-sidebar .logo-xl,.main-sidebar .logo-xs,.sidebar .nav-link p,.sidebar .user-panel .info{ transition:margin-left .3s linear,opacity .3s ease,visibility .3s ease;color:#d3d3d3;}.sidebar-dark-primary .nav-sidebar>.nav-item>.nav-link.active,.sidebar-light-primary .nav-sidebar>.nav-item>.nav-link.active{ color:#fff;background:radial-gradient(#1b4b61,#fd030300);border-radius:50px;}.dark-mode .card{ background-color:#00000000;color:#ffffff99;border-width:3px;border-color:#f7f7f7;border-style:double;border-radius:15px;}.btn-info{ color:#ffffff;background-color:#b8171700;border-color:#ffffff;box-shadow:none;}.btn-warning{ color:#ffffff;background-color:#ffc10700;border-color:#ffffff;box-shadow:none;}.card-title{ float:left;font-size:1.1rem;font-weight:400;margin:0;color:white;}.dark-mode .text-muted{ color:#ffffff99!important;}.dark-mode .list-group-item{ background-color:#343a4000;border-color:#ffffff99;}.dark-mode .info-box{ background-color:#343a4000;color:#fff;border:3px;border-style:double;border-radius:15px;border-color:white;}label:not(.form-check-label):not(.custom-file-label){ font-weight:700;color:#ffffffc2;}.dark-mode .custom-control-label:before,.dark-mode .custom-file-label,.dark-mode .custom-file-label:after,.dark-mode .custom-select,.dark-mode .form-control,.dark-mode .input-group-text{ background-color:#007af400;color:#828282;}.alert-success{ color:#fff;background-color:#28a745;border-color:#ffffff;border-radius:15px;border-style:double;}.dark-mode{ color:#fff;background:radial-gradient(#061b29,black);}.dark-mode .invoice{ background-color:#343a4000;border:3px;border-radius:15px;border-color:white;border:double;}.dark-mode .nav-tabs .nav-item.show .nav-link,.dark-mode .nav-tabs .nav-link.active{ background-color:#ffffff1c;color:#fff;}.slim-crop-area img,.slim-image-editor img,.slim-popover img,.slim img{ background:black;}.dark-mode .callout{ background-color:#00ff0333;}.callout.callout-info{ border-left-color:#00e11d;}.p-3{ padding:1rem!important;background:#061b29;}.small-box>.small-box-footer{ color:hsla(0,0%,100%,.8);display:block;padding:3px 0;position:relative;text-align:center;text-decoration:none;z-index:10;background:#061b29;}.dark-mode .dropdown-menu{ background-color:#061b29;border-color:white;}.card-header:first-child{ border-radius:14px 14px 0px 0px;background:#061b29;}.card-body{ flex:1 1 auto;min-height:1px;padding:1.25rem;background:#061b29;}.justify-content-between{ justify-content:space-between!important;background:#061b29;}.dark-mode .card .card-footer{ background-color:#061b29;border-radius:0px 0px 14px 14px;}.dark-mode .select2-selection--single{ background-color:#061b29;border-color:#6c757d;}.select2-search--dropdown{ display:block;padding:4px;background:#061b29;}.select2-container--default .select2-results__option{ padding:6px 12px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;background:blue;background:#061b29;}.dark-mode .select2-dropdown,.dark-mode .select2-dropdown .select2-search__field,.dark-mode .select2-search--inline .select2-search__field{ background-color:#061b29;border-color:#ffffff;color:#fff;}.modal-header{ background:#061b29;}.modal-body{ position:relative;flex:1 1 auto;padding:1rem;background:#061b29;}.dark-mode .modal-footer,.dark-mode .modal-header{ border-color:#ffffff;background:#061b29;}
From 8c2289ed74582b3579eea78934a7058559681843 Mon Sep 17 00:00:00 2001
From: Johannes F
Date: Sat, 11 Feb 2023 22:54:35 +0100
Subject: [PATCH 09/20] =?UTF-8?q?fix:=20=F0=9F=9A=91=EF=B8=8F=20Wrong=20St?=
=?UTF-8?q?ore=20Page=20Name?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
themes/default/views/store/index.blade.php | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/themes/default/views/store/index.blade.php b/themes/default/views/store/index.blade.php
index 7d105867..5f024d48 100644
--- a/themes/default/views/store/index.blade.php
+++ b/themes/default/views/store/index.blade.php
@@ -36,7 +36,7 @@
From af5d28e2a50654e3417870df538fc445288a20f6 Mon Sep 17 00:00:00 2001
From: Johannes F
Date: Sun, 12 Feb 2023 00:15:36 +0100
Subject: [PATCH 10/20] =?UTF-8?q?feat:=20=E2=9C=A8=20Reopen=20tickets?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../Moderation/TicketsController.php | 16 +-
app/Http/Controllers/TicketsController.php | 16 +-
routes/web.php | 4 +-
.../views/moderator/ticket/show.blade.php | 31 +++-
themes/default/views/store/index.blade.php | 2 +-
themes/default/views/ticket/show.blade.php | 157 ++++++++++--------
6 files changed, 141 insertions(+), 85 deletions(-)
diff --git a/app/Http/Controllers/Moderation/TicketsController.php b/app/Http/Controllers/Moderation/TicketsController.php
index be974ad2..a020098e 100644
--- a/app/Http/Controllers/Moderation/TicketsController.php
+++ b/app/Http/Controllers/Moderation/TicketsController.php
@@ -33,9 +33,14 @@ public function show($ticket_id)
return view('moderator.ticket.show', compact('ticket', 'ticketcategory', 'ticketcomments', 'server'));
}
- public function close($ticket_id)
+ public function changeStatus($ticket_id)
{
$ticket = Ticket::where('ticket_id', $ticket_id)->firstOrFail();
+ if($ticket->status == "Closed"){
+ $ticket->status = "Reopened";
+ $ticket->save();
+ return redirect()->back()->with('success', __('A ticket has been reopened, ID: #') . $ticket->ticket_id);
+ }
$ticket->status = 'Closed';
$ticket->save();
$ticketOwner = $ticket->user;
@@ -85,12 +90,16 @@ public function dataTable()
return ''.$tickets->user->name.'';
})
->addColumn('actions', function (Ticket $tickets) {
+ $statusButtonColor = ($tickets->status == "Closed") ? 'btn-success' : 'btn-warning';
+ $statusButtonIcon = ($tickets->status == "Closed") ? 'fa-redo' : 'fa-times';
+ $statusButtonText = ($tickets->status == "Closed") ? __('Reopen') : __('Close');
+
return '
-
diff --git a/routes/web.php b/routes/web.php
index c86a0c66..fbbdb028 100644
--- a/routes/web.php
+++ b/routes/web.php
@@ -113,7 +113,7 @@
Route::post('ticket/new', [TicketsController::class, 'store'])->middleware(['throttle:ticket-new'])->name('ticket.new.store');
Route::get('ticket/show/{ticket_id}', [TicketsController::class, 'show'])->name('ticket.show');
Route::post('ticket/reply', [TicketsController::class, 'reply'])->middleware(['throttle:ticket-reply'])->name('ticket.reply');
- Route::post('ticket/close/{ticket_id}', [TicketsController::class, 'close'])->name('ticket.close');
+ Route::post('ticket/status/{ticket_id}', [TicketsController::class, 'changeStatus'])->name('ticket.changeStatus');
}
//admin
@@ -211,7 +211,7 @@
Route::get('ticket/datatable', [ModTicketsController::class, 'datatable'])->name('ticket.datatable');
Route::get('ticket/show/{ticket_id}', [ModTicketsController::class, 'show'])->name('ticket.show');
Route::post('ticket/reply', [ModTicketsController::class, 'reply'])->name('ticket.reply');
- Route::post('ticket/close/{ticket_id}', [ModTicketsController::class, 'close'])->name('ticket.close');
+ Route::post('ticket/status/{ticket_id}', [ModTicketsController::class, 'changeStatus'])->name('ticket.changeStatus');
Route::post('ticket/delete/{ticket_id}', [ModTicketsController::class, 'delete'])->name('ticket.delete');
//ticket moderation blacklist
Route::get('ticket/blacklist', [ModTicketsController::class, 'blacklist'])->name('ticket.blacklist');
diff --git a/themes/default/views/moderator/ticket/show.blade.php b/themes/default/views/moderator/ticket/show.blade.php
index 2d51c5dd..dda8c1f9 100644
--- a/themes/default/views/moderator/ticket/show.blade.php
+++ b/themes/default/views/moderator/ticket/show.blade.php
@@ -44,6 +44,9 @@
@case("Open")
{{__("Open")}}
@break
+ @case("Reopened")
+ {{__("Reopened")}}
+ @break
@case("Closed")
{{__("Closed")}}
@break
@@ -69,13 +72,27 @@
@endswitch
{{__("Created on")}}: {{ $ticket->created_at->diffForHumans() }}
- @if($ticket->status!='Closed')
-
- @endif
+ @if($ticket->status=='Closed')
+
+ @else
+
+ @endif
diff --git a/themes/default/views/store/index.blade.php b/themes/default/views/store/index.blade.php
index 5f024d48..7d105867 100644
--- a/themes/default/views/store/index.blade.php
+++ b/themes/default/views/store/index.blade.php
@@ -36,7 +36,7 @@
diff --git a/themes/default/views/ticket/show.blade.php b/themes/default/views/ticket/show.blade.php
index 8d9afa26..7401038f 100644
--- a/themes/default/views/ticket/show.blade.php
+++ b/themes/default/views/ticket/show.blade.php
@@ -35,43 +35,58 @@
@if(!empty($server))
-
{{__("Server")}}: {{ $server->name }}
+
{{__("Server")}}: {{ $server->name }}
@endif
-
{{__("Title")}}: {{ $ticket->title }}
-
{{__("Category")}}: {{ $ticketcategory->name }}
-
{{__("Status")}}:
- @switch($ticket->status)
- @case("Open")
- {{__("Open")}}
- @break
- @case("Closed")
- {{__("Closed")}}
- @break
- @case("Answered")
- {{__("Answered")}}
- @break
- @case("Client Reply")
- {{__("Client Reply")}}
- @break
- @endswitch
-
-
Priority:
- @switch($ticket->priority)
- @case("Low")
- {{__("Low")}}
- @break
- @case("Medium")
- {{__("Medium")}}
- @break
- @case("High")
- {{__("High")}}
- @break
- @endswitch
-
+
{{__("Title")}}: {{ $ticket->title }}
+
{{__("Category")}}: {{ $ticketcategory->name }}
+
{{__("Status")}}:
+ @switch($ticket->status)
+ @case("Open")
+ {{__("Open")}}
+ @break
+ @case("Reopened")
+ {{__("Reopened")}}
+ @break
+ @case("Closed")
+ {{__("Closed")}}
+ @break
+ @case("Answered")
+ {{__("Answered")}}
+ @break
+ @case("Client Reply")
+ {{__("Client Reply")}}
+ @break
+ @endswitch
+
+
Priority:
+ @switch($ticket->priority)
+ @case("Low")
+ {{__("Low")}}
+ @break
+ @case("Medium")
+ {{__("Medium")}}
+ @break
+ @case("High")
+ {{__("High")}}
+ @break
+ @endswitch
+
{{__("Created on")}}: {{ $ticket->created_at->diffForHumans() }}
- @if($ticket->status!='Closed')
+ @if($ticket->status=='Closed')
+ @else
+
@foreach ($ticketcomments as $ticketcomment)
-
-