From: soufiane Date: Mon, 12 Feb 2024 14:49:00 +0000 (+0100) Subject: wip #6717 @3:00 X-Git-Url: http://git.cubedesigners.com/?a=commitdiff_plain;h=b02e086db1e159968d1e3ec4c12d2638347cbd9b;p=fluidbook-toolbox.git wip #6717 @3:00 --- diff --git a/app/Http/Controllers/Admin/Operations/FluidbookPublication/DownloadOperation.php b/app/Http/Controllers/Admin/Operations/FluidbookPublication/DownloadOperation.php index 2d5701bf8..32e9fb43d 100644 --- a/app/Http/Controllers/Admin/Operations/FluidbookPublication/DownloadOperation.php +++ b/app/Http/Controllers/Admin/Operations/FluidbookPublication/DownloadOperation.php @@ -21,6 +21,7 @@ trait DownloadOperation Route::match(['get'], $segment . '/{id}/package/{action}/{version}', $controller . '@package'); Route::match(['get'], $segment . '/{id}/package/{action}/scorm/{scormversion}', $controller . '@packageScorm'); Route::match(['get'], $segment . '/{id}_{hash}/download/{file}', $controller . '@download')->withoutMiddleware([CheckIfAdmin::class]);; + Route::match(['get','post'], $segment . '/download_settings/{file}', $controller . '@downloadSettings')->withoutMiddleware([CheckIfAdmin::class])->name("download_settings"); } protected function setupDownloadDefaults() @@ -126,4 +127,11 @@ trait DownloadOperation Alert::add('success', __('La compilation a été placée en file d\'attente. Vous recevrez un email lorsqu\'elle sera terminée.'))->flash(); return back(); } + + protected function downloadSettings($file) { + $name = "settings_export"; + $path = base64_decode($file); + if(!file_exists($path)) abort(404); + return response()->download($path, $name . '.xlsx')->deleteFileAfterSend(true); + } } diff --git a/app/Mail/FluidbookQuoteReceived.php b/app/Mail/FluidbookQuoteReceived.php index c01a6860e..4cbc27a96 100644 --- a/app/Mail/FluidbookQuoteReceived.php +++ b/app/Mail/FluidbookQuoteReceived.php @@ -14,7 +14,6 @@ class FluidbookQuoteReceived extends Base */ public function setData($post) { - $this->replyTo($post['email'], $post['prenom'] . ' ' . $post['nom']); $this->from('tech@fluidbook.com'); $this->to('tech@fluidbook.com');