Video Multiple Upload
How to declare a Video Multiple Upload.
use Hoggarcrud\Hoggar\Fields\MultipleVideo;
MultipleVideo::make('videos')
->label('New label') // optional
->notInDatabase() // optional, if you don't want this field in database
These videos are returned in JSON format. If you’re saving them using Eloquent, you should be sure to add an array cast to the model property:
use Illuminate\Database\Eloquent\Model;
class Post extends Model
{
protected $casts = [
'videos' => 'array',
];
}
When you update, if you want the field and the record not nullable do this.
->fieldAndRecordNotNull()