diff --git a/app/Models/Asset.php b/app/Models/Asset.php index 6ddc597188..d0720c7938 100644 --- a/app/Models/Asset.php +++ b/app/Models/Asset.php @@ -199,6 +199,12 @@ class Asset extends Depreciable } } + foreach ($this->model->fieldset->fields as $field){ + if($field->format == 'BOOLEAN'){ + $this->{$field->db_column} = filter_var($this->{$field->db_column}, FILTER_VALIDATE_BOOLEAN); + } + } + return parent::save($params); }