commit
40f34d2ab0
|
|
@ -33,7 +33,7 @@ class ProductDownloadableLinkRepository extends Repository
|
|||
foreach ($data as $type => $file) {
|
||||
if (request()->hasFile($type)) {
|
||||
return [
|
||||
$type => $path = request()->file($type)->store('product/' . $productId),
|
||||
$type => $path = request()->file($type)->store('product_downloadable_links/' . $productId),
|
||||
$type . '_name' => $file->getClientOriginalName(),
|
||||
$type . '_url' => Storage::url($path)
|
||||
];
|
||||
|
|
|
|||
|
|
@ -32,7 +32,7 @@ class ProductDownloadableSampleRepository extends Repository
|
|||
{
|
||||
if (request()->hasFile('file')) {
|
||||
return [
|
||||
'file' => $path = request()->file('file')->store('product/' . $productId),
|
||||
'file' => $path = request()->file('file')->store('product_downloadable_links/' . $productId),
|
||||
'file_name' => request()->file('file')->getClientOriginalName(),
|
||||
'file_url' => Storage::url($path)
|
||||
];
|
||||
|
|
|
|||
Loading…
Reference in New Issue