<?php
require_once 'conexao.php';

require_once 'conexao.php';
require_once 'config.php';

$pdo  = Conexao::getInstance();
$sql = "SELECT observacao, id_categoria FROM observacoes ORDER BY id_categoria, observacao";
$stm = $pdo->prepare($sql);
$stm->execute();
$observacoes = $stm->fetchAll(PDO::FETCH_OBJ);

echo json_encode($observacoes);
?>
