. */ declare(strict_types=1); namespace FireflyIII\Models; use Illuminate\Database\Eloquent\Model; use Illuminate\Database\Eloquent\Relations\HasMany; /** * Class AccountType. * * @property string $type * @method whereType(string $type) * @property int $id * */ class AccountType extends Model { /** * */ public const DEFAULT = 'Default account'; /** * */ public const CASH = 'Cash account'; /** * */ public const ASSET = 'Asset account'; /** * */ public const EXPENSE = 'Expense account'; /** * */ public const REVENUE = 'Revenue account'; /** * */ public const INITIAL_BALANCE = 'Initial balance account'; /** * */ public const BENEFICIARY = 'Beneficiary account'; /** * */ public const IMPORT = 'Import account'; /** * */ public const RECONCILIATION = 'Reconciliation account'; /** * */ public const LOAN = 'Loan'; /** * The attributes that should be casted to native types. * * @var array */ protected $casts = [ 'created_at' => 'datetime', 'updated_at' => 'datetime', ]; /** @var array */ protected $fillable = ['type']; /** * @return HasMany * @codeCoverageIgnore */ public function accounts(): HasMany { return $this->hasMany(Account::class); } }