- Laravel 11 backend with API REST - React 18 + TypeScript + Vite frontend - Multi-parser architecture for accounting systems (CONTPAQi, Aspel, SAP) - 27+ financial metrics calculation - PDF report generation with Browsershot - Complete documentation (10 documents) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
35 lines
612 B
PHP
35 lines
612 B
PHP
<?php
|
|
|
|
namespace App\Models;
|
|
|
|
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
|
use Illuminate\Database\Eloquent\Model;
|
|
use Illuminate\Database\Eloquent\Relations\HasMany;
|
|
|
|
class Giro extends Model
|
|
{
|
|
use HasFactory;
|
|
|
|
protected $fillable = [
|
|
'nombre',
|
|
'activo',
|
|
];
|
|
|
|
protected function casts(): array
|
|
{
|
|
return [
|
|
'activo' => 'boolean',
|
|
];
|
|
}
|
|
|
|
public function clientes(): HasMany
|
|
{
|
|
return $this->hasMany(Cliente::class);
|
|
}
|
|
|
|
public function umbrales(): HasMany
|
|
{
|
|
return $this->hasMany(Umbral::class);
|
|
}
|
|
}
|