public function getAllowedGroupsAttribute($allowed_groups) { return array_map('intval', explode(',', $allowed_groups)); }