<?php

class Round extends Model
{

    // ===========
    // = Statics =
    // ===========

    protected static $table_name = 'MJ_ROUND';

    public static function getList()
    {
        $stm = parent::exec('ROUND_LIST');
        return $stm->fetchAll();
    }

    public static function getRow($id)
    {
        $stm = parent::exec('ROUND_GET_WITH_ID', ['id' => $id]);
        return $stm->fetchAll();
    }

    public static function getUsersInRound($id)
    {
        $stm = parent::exec('ROUND_GET_USERS', ['id' => $id]);
        return $stm->fetchAll();
    }
}