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.
22 lines
421 B
22 lines
421 B
<?php
|
|
|
|
namespace App;
|
|
|
|
use Illuminate\Database\Eloquent\Model;
|
|
|
|
class EmplQuestion extends Model
|
|
{
|
|
/**
|
|
* @return mixed
|
|
*/
|
|
public function getQuestionsListAttribute()
|
|
{
|
|
return json_decode($this->attributes['questions_list']);
|
|
}
|
|
|
|
public function setQuestionsListAttribute($value)
|
|
{
|
|
$this->attributes['questions_list'] = json_encode($value, JSON_UNESCAPED_UNICODE);
|
|
}
|
|
}
|