Move from getDates to array dates.

This commit is contained in:
James Cole
2016-01-15 22:32:21 +01:00
parent 0620830b10
commit f949d2476b
18 changed files with 31 additions and 170 deletions

View File

@@ -23,8 +23,8 @@ use Symfony\Component\HttpKernel\Exception\NotFoundHttpException;
* @property-read Collection|BudgetLimit[] $budgetlimits
* @property-read Collection|TransactionJournal[] $transactionjournals
* @property-read User $user
* @property string $dateFormatted
* @property string $budgeted
* @property string $dateFormatted
* @property string $budgeted
*/
class Budget extends Model
{
@@ -33,6 +33,7 @@ class Budget extends Model
protected $fillable = ['user_id', 'name', 'active'];
protected $hidden = ['encrypted'];
protected $dates = ['created_at', 'updated_at', 'deleted_at', 'startdate', 'enddate'];
/**
* @param array $fields
@@ -71,14 +72,6 @@ class Budget extends Model
return $this->hasMany('FireflyIII\Models\BudgetLimit');
}
/**
* @return array
*/
public function getDates()
{
return ['created_at', 'updated_at', 'deleted_at', 'startdate', 'enddate'];
}
/**
* @param $value
*