mirror of
https://github.com/snipe/snipe-it.git
synced 2024-12-25 05:34:06 -08:00
Fixed #11393 - reject acceptance if no file is present
Signed-off-by: snipe <snipe@snipe.net>
This commit is contained in:
parent
25cb32ca6a
commit
b910db0617
|
@ -133,6 +133,12 @@ class AcceptanceController extends Controller
|
|||
$encoded_image = explode(',', $data_uri);
|
||||
$decoded_image = base64_decode($encoded_image[1]);
|
||||
Storage::put('private_uploads/signatures/'.$sig_filename, (string) $decoded_image);
|
||||
|
||||
// No image data is present, kick them back.
|
||||
// This mostly only applies to users on supoer-deuper crapola browsers *cough* IE *cough*
|
||||
} else {
|
||||
return redirect()->back()->with('error', trans('general.shitty_browser'));
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -363,5 +363,6 @@ return [
|
|||
'purge_not_allowed' => 'Purging deleted data has been disabled in the .env file. Contact support or your systems administrator.',
|
||||
'backup_delete_not_allowed' => 'Deleting backups has been disabled in the .env file. Contact support or your systems administrator.',
|
||||
'additional_files' => 'Additional Files',
|
||||
'shitty_browser' => 'No signature detected. If you are using an older browser, please use a more modern browser to complete your asset acceptance.',
|
||||
|
||||
];
|
|
@ -40,7 +40,7 @@
|
|||
|
||||
|
||||
<div class="row">
|
||||
<div class="col-sm-10 col-sm-offset-1 col-md-8 col-md-offset-2">
|
||||
<div class="col-sm-12 col-sm-offset-1 col-md-10 col-md-offset-1">
|
||||
<div class="panel box box-default">
|
||||
<div class="box-body">
|
||||
@if ($acceptance->checkoutable->getEula())
|
||||
|
|
Loading…
Reference in a new issue