vanilophp / framework

The truly Laravel E-commerce Framework
https://vanilo.io
MIT License
818 stars 102 forks source link

Exception throws while editing pictures for product #28

Closed j-dohnalek closed 5 years ago

j-dohnalek commented 5 years ago

https://github.com/vanilophp/framework/blob/master/src/resources/views/product/_edit_images.blade.php#L41

The form in my code was missing the 'for'=>'product' so I have changed it to the code below

{!! Form::open(['route' => ['vanilo.media.store', 'for'=>'product' ], 'enctype'=>'multipart/form-data', 'class' => 'card']) !!}

if fixed, please ignore.

fulopattila122 commented 5 years ago

Thank you for the report.

The "missing" field is actually 3 lines below: https://github.com/vanilophp/framework/blob/master/src/resources/views/product/_edit_images.blade.php#L44

And it seems to be working on all instances/tests I know. But since you've been reporting some issues related to this, there's definitely some problem there, so I'd prefer to get more Information to find the problem.

What happens if you remove 'for' => 'prodcut' from the form definition while having the field below within the form?

{{ Form::hidden('for', 'product') }}
j-dohnalek commented 5 years ago

It works with

{{ Form::hidden('for', 'product') }}