# fluent-booking/1.5.22/app/Models/Meta.php

Fluent Booking – The Ultimate Appointments Scheduling, Events Booking, Events Calendar Solution, version 1.5.22. 38 lines.

- Page: https://pluginprobe.com/plugins/fluent-booking/1.5.22/code/app/Models/Meta.php
- Raw: https://pluginprobe.com/plugins/fluent-booking/1.5.22/raw/app/Models/Meta.php
- Modified: 2024-07-16T14:25:14+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-booking/1.5.22/code/app/Models/Meta.php#L10-L20`.

```php
<?php

namespace FluentBooking\App\Models;
class Meta extends Model
{
    protected $table = 'fcal_meta';

    protected $guarded = ['id'];

    protected $fillable = [
        'object_type',
        'object_id',
        'key',
        'value'
    ];

    public static function boot()
    {
        parent::boot();
    }

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

    public function getValueAttribute($value)
    {
        return \maybe_unserialize($value);
    }

    public function calendar_event()
    {
        return $this->belongsTo(CalendarSlot::class, 'object_id');
    }

}

```
