<?php

/* 
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

class ZkouskyModel extends Repository {
   
    public function getVysledkyByIdPsa($id) {
            return $this->connection->table('vysledky_zkousek')
            ->where('id_psa = ?', $id)->fetchAll();
    }
    
    public function getZkouskaById($id) {
            return $this->connection->table('vysledky_zkousek')
            ->where('id = ?', $id)->fetchAll();
    }
    
  

    public function deleteVysledek($id) {
        $this->connection->table('vysledky_zkousek')
            ->where('id = ?', $id)
            ->delete();
    }
    
    public function addVysledek($data) {
    $this->connection->table('vysledky_zkousek')
        ->insert($data);
    }
    

}

