<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Model;

class SituacaoJuridica extends Model
{
    protected $table = 'sige.situacoes_juridicas';

    public function lotes()
    {
        //lote_id: na tabela Processos, id: na tabela Lotes
        //return $this->belongsTo(SituacaoJuridica::class, 'id', 'situacao_juridica_id');
        return $this->hasMany(Lote::class, 'situacao_juridica_id', 'id');
    }
}
