Merge branch 'master' of github.com:akaunting/akaunting
This commit is contained in:
@ -34,6 +34,22 @@ class Uploads extends Controller
|
||||
return $this->streamMedia($media);
|
||||
}
|
||||
|
||||
public function inline($id)
|
||||
{
|
||||
try {
|
||||
$media = Media::find($id);
|
||||
} catch (\Exception $e) {
|
||||
return response(null, 204);
|
||||
}
|
||||
|
||||
// Get file path
|
||||
if (!$this->getMediaPathOnStorage($media)) {
|
||||
return response(null, 204);
|
||||
}
|
||||
|
||||
return $this->streamMedia($media, 'inline');
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the specified resource.
|
||||
*
|
||||
|
@ -14,9 +14,10 @@ class CustomMail extends FormRequest
|
||||
public function rules()
|
||||
{
|
||||
return [
|
||||
'to' => 'required|email',
|
||||
'subject' => 'required|string',
|
||||
'body' => 'required|string',
|
||||
'to' => 'required|email',
|
||||
'subject' => 'required|string',
|
||||
'body' => 'required|string',
|
||||
'attachments.*' => 'nullable|boolean',
|
||||
];
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user