コード例 #1
0
function getCurrentPincho($idNombre)
{
    return Pincho::getByIdnombre($idNombre);
}
コード例 #2
0
ファイル: pwctrl_user.php プロジェクト: ndrs92/PinchoWire
 public static function pinchoConsumed()
 {
     global $l;
     if (!isset($_SESSION)) {
         session_start();
     }
     if (get_class($_SESSION["user"]) != "JuradoPopular") {
         header("Location: ../view/403.php");
         exit;
     }
     if ($_POST["markeatenpincho_probado_idpincho"] && $_POST["markeatenpincho_probado_idemail"]) {
         $pincho = Pincho::getByIdnombre($_POST["markeatenpincho_probado_idpincho"]);
         $pincho->toggleMarcado($_POST["markeatenpincho_probado_idemail"]);
         if ($pincho->isProbado($_POST["markeatenpincho_probado_idemail"])) {
             $_SESSION["alert"]["success"] = $l["alertify_eatenPincho_eaten"];
         } else {
             $_SESSION["alert"]["success"] = $l["alertify_eatenPincho_noEaten"];
         }
         header("Location: ../view/list.php");
     } else {
         header("Location: ../view/404.php");
         exit;
     }
 }
コード例 #3
0
ファイル: concurso.php プロジェクト: ndrs92/PinchoWire
 public function getGanadoresProfesionales()
 {
     $tuplas = ConcursoMapper::retrieveGanadoresProfesionales();
     $toRet = NULL;
     foreach ($tuplas as $key => $values) {
         $toRet[$key] = Pincho::getByIdnombre($values);
     }
     return $toRet;
 }
コード例 #4
0
ファイル: pincho.php プロジェクト: ndrs92/PinchoWire
 public static function getPinchoFromCode($code)
 {
     return Pincho::getByIdnombre(PinchoMapper::getPinchoIdFromCode($code));
 }
コード例 #5
0
 function validate_pincho()
 {
     $idnombre = $_GET["idnombre"];
     $target = Pincho::getByIdnombre($idnombre);
     $target->setEstadopropuesta($_GET["estado"]);
     header("Location: ../view/view_admin_propuestas.php");
 }