dev-master
9999999-devLaravel attachment bundle
MIT
The Requires
- php >=5.4.0
- illuminate/support 4.2.*
laravel eloquent attachment
Wallogit.com
2017 © Pedro Peláez
Laravel attachment bundle
Eloquent extension for store simply file attachments., (*1)
It's under development, not recommended for production use!, (*2)
Attachments storing in public/attachments directory. To override it:, (*3)
$attachment = new Attachment; $attachment->addFile($filename); $attachment->attachable()->associate($relatedModel); $attachment->save();
Extend Hlacos\Attachment\Attachment and set the $table attribute., (*4)
Extend Hlacos\Attachment\Attachment and set the $sizes array attribute. In the array sets the width of the required images;, (*5)
You can set polymoprhic relations in the realted models., (*6)
public function attachment() {
return $this->morphOne('Hlacos\Attachment\Attachment', 'attachable');
}
public function attachment() {
return $this->morphMany('Hlacos\Attachment\Attachment', 'attachable');
}
Laravel attachment bundle
MIT
laravel eloquent attachment