add todos from github

This commit is contained in:
Dennis Eichhorn 2019-12-31 19:54:45 +01:00
parent 310efc27bb
commit ada0319520
5 changed files with 60 additions and 4 deletions

View File

@ -17,6 +17,14 @@ namespace Modules\QA\Controller;
use Modules\QA\Models\QAQuestionMapper;
use phpOMS\Message\RequestAbstract;
use phpOMS\Message\ResponseAbstract;
use phpOMS\Model\Message\FormValidation;
use Modules\QA\Models\QAQuestion;
use phpOMS\Utils\Parser\Markdown\Markdown;
use Modules\QA\Models\QAQuestionStatus;
use Modules\QA\Models\QAAnswer;
use Modules\QA\Models\QAAnswerStatus;
use Modules\QA\Models\QACategoryMapper;
use Modules\QA\Models\QACategory;
/**
* Task class.
@ -25,6 +33,13 @@ use phpOMS\Message\ResponseAbstract;
* @license OMS License 1.0
* @link https://orange-management.org
* @since 1.0.0
*
* @todo Orange-Management/Modules#70
* There is no voting implemented right now, this needs to be added (visually and model/database)
*
* @todo Orange-Management/Modules#78
* Edit functionality
* Currently nothing can be edited (change)
*/
final class ApiController extends Controller
{
@ -147,7 +162,7 @@ final class ApiController extends Controller
$answer = new QAAnswer();
$answer->setName((string) $request->getData('title'));
$answer->setQuestion((string) $request->getData('plain'));
$answer->setAnswer((string) $request->getData('plain'));
$answer->setQuestion((int) $request->getData('question'));
$answer->setStatus((int) $request->getData('status'));

View File

@ -30,6 +30,10 @@ use phpOMS\Views\View;
* @license OMS License 1.0
* @link https://orange-management.org
* @since 1.0.0
*
* @todo Orange-Management/Modules#78
* Edit functionality
* Currently nothing can be edited (change)
*/
final class BackendController extends Controller
{

View File

@ -1,4 +1,17 @@
<?php declare(strict_types=1);
<?php
/**
* Orange Management
*
* PHP Version 7.4
*
* @package Modules\QA
* @copyright Dennis Eichhorn
* @license OMS License 1.0
* @version 1.0.0
* @link https://orange-management.org
*/
declare(strict_types=1);
$questions = $this->getData('questions');
echo $this->getData('nav')->render(); ?>

View File

@ -1,6 +1,25 @@
<?php declare(strict_types=1);
<?php
/**
* Orange Management
*
* PHP Version 7.4
*
* @package Modules\QA
* @copyright Dennis Eichhorn
* @license OMS License 1.0
* @version 1.0.0
* @link https://orange-management.org
*/
declare(strict_types=1);
/**
* @todo Orange-Management/Modules#73
* Profile pics
* There are no profile pics in questions and answers. Implement!
*/
$question = $this->getData('question');
$answers = $question->getAnswers();
$answers = $question->getAnswers();
echo $this->getData('nav')->render();
?>

View File

@ -12,6 +12,11 @@
*/
declare(strict_types=1);
/**
* @todo Orange-Management/Modules#73
* Profile pics
* There are no profile pics in questions and answers. Implement!
*/
$tags = $this->getData('tags');