exportados no código C++ caso você gere de uma prova específica. Os problemas podem ser exportados como um bundle apenas, contendo todo o banco de dados do sistema. </p> <button id="testproblems-bt-new"> Anexar Problema </button> <div id="testproblems-ct-list" class="centering"> <?php include "view/TestSelect.php"; $filter = new TestSelect(); $selectedTest = $_GET['tpb_tst_id']; ?> <br /><div><label for="tpb_tst_id">Filtrar por Prova</label>:<?php $filter->render("tpb_tst_id", $selectedTest, null, 'test-filter'); ?> </div><?php include "view/TestProblemsList.php"; $wdg = new TestProblemsList(); $wdg->renderNotDeleted($selectedTest); ?> </div> <div id="testproblems-new-form" style="display:none;"> <?php include "./view/TestProblemsEdit.php"; $widget = new TestProblemsEdit(null); $widget->render($selectedTest); ?> </div>
public function render($selectTest = null, $selectProblem = null) { $update = true; if (!isset($this->tproblems)) { $this->tproblems = new TestProblems(); $update = false; } ?> <form method="POST" class="centering" action="./controller/TestProblemsController.php"> <table class="formTable"> <tr> <td><label for="tpb_questionNumber">Número da Questão</label>:</td> <td><input name="tpb_questionNumber" type="text" size=30 class="notempty integer" value="<?php echo @$this->tproblems->get("tpb_questionNumber"); ?> " />*</td> </tr> <tr> <td><label for="tpb_weight">Peso da Questão</label>:</td> <td><input name="tpb_weight" type="text" size=30 class="notempty number" value="<?php echo @$this->tproblems->get("tpb_weight"); ?> " />*</td> </tr> <?php if ($update !== true) { ?> <tr> <td><label for="tpb_tst_id">Prova</label>:</td> <td> <?php $select = new TestSelect(); $select->render("tpb_tst_id", $selectTest, "notempty"); ?> * </td> </tr> <tr> <td><label for="tpb_prb_id">Problema</label>:</td> <td> <?php $select = new ProblemSelect(); $select->render("tpb_prb_id", $selectProblem, "notempty"); ?> * </td> </tr> <?php } ?> </table> <?php if ($update === true) { ?> <input type="hidden" name="tpb_tst_id" value="<?php echo @$this->tproblems->get("tpb_tst_id"); ?> " /> <input type="hidden" name="tpb_prb_id" value="<?php echo @$this->tproblems->get("tpb_prb_id"); ?> " /> <?php } ?> <input type="hidden" name="_action" value="<?php echo $update === true ? "update" : "save"; ?> " /> <input type="submit" value="Salvar" /> <input type="reset" value="Limpar Campos" /> </form> <?php }