EV3-388 Verzióváltott teszt- Új beszállító felvitele
This commit is contained in:
parent
9a7610f14f
commit
2cf461b771
1
.gitignore
vendored
1
.gitignore
vendored
@ -23,3 +23,4 @@ Homestead.json
|
||||
Homestead.yaml
|
||||
Thumbs.db
|
||||
/storage/tmp/
|
||||
/public/images/supplierLogo/
|
||||
|
||||
@ -132,10 +132,14 @@ private function getSupplierDataFromRequest(Request $request)
|
||||
|
||||
if ($request->file('logoFile')) {
|
||||
$disk = 'image';
|
||||
$diskPath = \Storage::disk($disk)->getAdapter()->getPathPrefix();
|
||||
// A Storage::path('') visszaadja a disk root könyvtárát
|
||||
$diskPath = \Storage::disk($disk)->path('');
|
||||
|
||||
// Kiszámoljuk a relatív útvonalat a public mappához képest
|
||||
$pathPrefix = str_replace(public_path(), '', $diskPath);
|
||||
$pathPrefix = ltrim($pathPrefix, DIRECTORY_SEPARATOR);
|
||||
$pathPrefix = str_replace('\\', '/', $pathPrefix);
|
||||
|
||||
// ha van mar akkor torolni kell!!!
|
||||
if ($request->route('supplier')) {
|
||||
$supplier = Supplier::with('attachment')->find($request->route('supplier'));
|
||||
|
||||
Loading…
Reference in New Issue
Block a user