adds feature to backfill daily change

This commit is contained in:
hackerESQ
2024-09-11 22:00:37 -05:00
parent a13d2d4323
commit c0c83ebdbd
4 changed files with 243 additions and 5 deletions
+8 -1
View File
@@ -39,7 +39,14 @@ class TransactionFactory extends Factory
public function yearsAgo(): static
{
return $this->state(fn (array $attributes) => [
'date' => $this->faker->date('Y-m-d', '-3 years'),
'date' => $this->faker->dateTimeBetween('-5 years', '-3 years')->format('Y-m-d'),
]);
}
public function lastMonth(): static
{
return $this->state(fn (array $attributes) => [
'date' => now()->subMonth()->format('Y-m-d'),
]);
}