Make sure all dates are in UTC (#1139)

This commit is contained in:
Nabeel S
2021-04-13 09:25:38 -04:00
committed by GitHub
parent 7e9eb08135
commit bfddb2c84d
9 changed files with 16 additions and 13 deletions

View File

@@ -1,17 +1,20 @@
<?php
use App\Models\Journal;
use Carbon\Carbon;
use Faker\Generator as Faker;
use Ramsey\Uuid\Uuid;
$factory->define(App\Models\JournalTransactions::class, function (Faker $faker) {
$factory->define(App\Models\JournalTransaction::class, function (Faker $faker) {
return [
'transaction_group' => \Ramsey\Uuid\Uuid::uuid4()->toString(),
'transaction_group' => Uuid::uuid4()->toString(),
'journal_id' => function () {
return factory(\App\Models\Journal::class)->create()->id;
return factory(Journal::class)->create()->id;
},
'credit' => $faker->numberBetween(100, 10000),
'debit' => $faker->numberBetween(100, 10000),
'currency' => 'USD',
'memo' => $faker->sentence(6),
'post_date' => \Carbon\Carbon::now(),
'post_date' => Carbon::now('UTC'),
];
});