2018-12-15 07:59:49 +01:00
|
|
|
<?php
|
|
|
|
|
/**
|
|
|
|
|
* AccountFactory.php
|
2020-02-16 13:58:48 +01:00
|
|
|
* Copyright (c) 2019 james@firefly-iii.org
|
2018-12-15 07:59:49 +01:00
|
|
|
*
|
2019-10-02 06:38:38 +02:00
|
|
|
* This file is part of Firefly III (https://github.com/firefly-iii).
|
2018-12-15 07:59:49 +01:00
|
|
|
*
|
2019-10-02 06:38:38 +02:00
|
|
|
* This program is free software: you can redistribute it and/or modify
|
|
|
|
|
* it under the terms of the GNU Affero General Public License as
|
|
|
|
|
* published by the Free Software Foundation, either version 3 of the
|
|
|
|
|
* License, or (at your option) any later version.
|
2018-12-15 07:59:49 +01:00
|
|
|
*
|
2019-10-02 06:38:38 +02:00
|
|
|
* This program is distributed in the hope that it will be useful,
|
2018-12-15 07:59:49 +01:00
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
2019-10-02 06:38:38 +02:00
|
|
|
* GNU Affero General Public License for more details.
|
2018-12-15 07:59:49 +01:00
|
|
|
*
|
2019-10-02 06:38:38 +02:00
|
|
|
* You should have received a copy of the GNU Affero General Public License
|
|
|
|
|
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
2018-12-15 07:59:49 +01:00
|
|
|
*/
|
|
|
|
|
declare(strict_types=1);
|
|
|
|
|
|
|
|
|
|
use Carbon\Carbon;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$factory->define(
|
|
|
|
|
FireflyIII\Models\Account::class,
|
|
|
|
|
function (Faker\Generator $faker) {
|
|
|
|
|
return [
|
2018-12-17 07:09:44 +01:00
|
|
|
'id' => $faker->unique()->numberBetween(1000, 10000),
|
2018-12-15 07:59:49 +01:00
|
|
|
'user_id' => 1,
|
|
|
|
|
'created_at' => new Carbon,
|
|
|
|
|
'updated_at' => new Carbon,
|
|
|
|
|
'name' => $faker->words(3, true),
|
|
|
|
|
'account_type_id' => random_int(2, 5),
|
|
|
|
|
'active' => true,
|
|
|
|
|
];
|
|
|
|
|
}
|
2018-12-31 07:48:23 +01:00
|
|
|
);
|