This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// window.resolveLocalFileURL(path, callback success, callback error) | |
// Tasks | |
/** | |
1. retrieve the app's folder. create if it doesn't exist | |
2. retrieve the image file | |
3. move image to app folder | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Event::listen(CommandStarting::class, function ($event) { | |
if ($event->command === 'migrate:fresh') { | |
Storage::deleteDirectory('/public/clubs'); | |
Storage::deleteDirectory('/public/users'); | |
} | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
factory(User::class, 10)->create()->each(function ($user) { | |
GenerateUserPoster::dispatch($user); | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#User Model | |
=========== | |
<?php | |
... class User | |
{ | |
public function videos() { | |
return $this->belongsTo('Watch\Video'); |