api/App/Models/Doc.php

22 lines
358 B
PHP

<?php
namespace App\Models;
use Core\Model;
use PDO;
class Doc extends Model
{
/**
* Get all the users as an associative array
*
* @return array
*/
public static function getAll()
{
$db = static::getDB();
$stmt = $db->query('SELECT * FROM users');
return $stmt->fetchAll(PDO::FETCH_ASSOC);
}
}