Game-Jaming/Backend/Controllers/Polls/GetVote.php

11 lines
285 B
PHP
Raw Normal View History

2021-03-11 12:21:16 +00:00
<?php
use Backend\Models\Vote;
require "../../../bootstrap.php";
require_once "../Group/Group.php";
if(isLogin()){
header('Content-Type: application/json;charset=UTF-8');
2021-03-12 13:05:31 +00:00
echo Vote::where('group_id',groupViaToken($_SESSION['token'])->id)->get()->toJson(JSON_PRETTY_PRINT);
2021-03-11 12:21:16 +00:00
}