# fluent-boards/2.0.0/app/Models/Attachment.php

FluentBoards – Project Management, Task Management, Goal Tracking, Kanban Board, and, Team Collaboration, version 2.0.0. 25 lines.

- Page: https://pluginprobe.com/plugins/fluent-boards/2.0.0/code/app/Models/Attachment.php
- Raw: https://pluginprobe.com/plugins/fluent-boards/2.0.0/raw/app/Models/Attachment.php
- Modified: 2024-08-23T12:13:22+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/fluent-boards/2.0.0/code/app/Models/Attachment.php#L10-L20`.

```php
<?php

namespace FluentBoards\App\Models;

class Attachment extends Model
{
    protected $table = 'fbs_attachments';

    protected $guarded = ['id'];
    protected $fillable = ['file_hash', 'object_type', 'object_id', 'settings', 'file_path', 'full_url', 'file_size', 'attachment_type'];
//    protected $hidden = ['full_url', 'file_path'];

    protected $appends = ['secure_url'];

    public function setSettingsAttribute($settings)
    {
        $this->attributes['settings'] = \maybe_serialize($settings);
    }

    public function getSettingsAttribute($settings)
    {
        return \maybe_unserialize($settings);
    }

}
```
