up
This commit is contained in:
@@ -0,0 +1,32 @@
|
||||
<?php
|
||||
|
||||
namespace Database\Factories;
|
||||
|
||||
use Illuminate\Database\Eloquent\Factories\Factory;
|
||||
use Illuminate\Support\Str;
|
||||
use App\Models\Caja;
|
||||
use App\Models\MovimientoCaja;
|
||||
|
||||
class MovimientoCajaFactory extends Factory
|
||||
{
|
||||
/**
|
||||
* The name of the factory's corresponding model.
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
protected $model = MovimientoCaja::class;
|
||||
|
||||
/**
|
||||
* Define the model's default state.
|
||||
*/
|
||||
public function definition(): array
|
||||
{
|
||||
return [
|
||||
'caja_id' => Caja::factory(),
|
||||
'tipo' => fake()->randomElement(["Ingreso","Egreso"]),
|
||||
'monto' => fake()->randomFloat(2, 0, 99999999.99),
|
||||
'descripcion' => fake()->text(),
|
||||
'fecha' => fake()->dateTime(),
|
||||
];
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user