<?php
class ServiceKM{

    public static function getAll() {
        $query = "SELECT * FROM service_km";
        $statement = Connection::getStatement($query);
        $statement->execute();
        return $statement->fetchAll();
    }
    
    public static function getByID($id) {
        $query = "SELECT * FROM service_km WHERE Id = :id";
        $statement = Connection::getStatement($query);
        $statement->bindParam(":id", $id);
        $statement->execute();
        return $statement->fetch();
    }

    
}