0, 'total_revenue' => 0, 'total_expenses' => 0, 'transferable' => true, ]; /** * @var array */ protected $fillable = [ 'user_id', 'balance', 'total_expenses', 'total_revenue', 'transferable', ]; /** * @var array */ protected $casts = [ 'transferable' => 'bool', ]; public function getBalanceFormatAttribute() { return trim_trailing_zeros(bcdiv($this->attributes['balance'], 100, 2)); } }