<?php

namespace App\Model\Table;

use Cake\ORM\TableRegistry;
use Cake\ORM\Query;
use Cake\ORM\RulesChecker;
use Cake\ORM\Table;
use Cake\Validation\Validator;

class MatriculasUsersTable extends Table
{
    public function initialize(array $config): void
    {
        parent::initialize($config);
    
        $this->setTable('matriculas_users');
        $this->setDisplayField('matricula_id');
        $this->setPrimaryKey('id');
        
        $this->addBehavior('Timestamp');
        
        $this->belongsTo('Matriculas', [
            'foreignKey' => 'matricula_id',
        ]);
        
        $this->belongsTo('Users', [
            'foreignKey' => 'user_id',
        ]);
        
    }
    
    
}
?>