You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

34 lines
669 B

<?php
declare (strict_types=1);
namespace App\Model;
/**
*/
class ActivityBind extends Model
{
/**
* The table associated with the model.
*
* @var string
*/
protected $table = 'lanzu_activity_bind';
/**
* The attributes that are mass assignable.
*
* @var array
*/
protected $fillable = ['bind_type', 'source_id', 'user_id', 'json_data'];
/**
* The attributes that should be cast to native types.
*
* @var array
*/
protected $casts = [];
public function setJsonDataAttribute($value)
{
$this->attributes['json_data'] = json_encode(json_decode($value, true));
}
}