コード例 #1
0
ファイル: PDFCheckList.php プロジェクト: brian-nelson/ianseo
$pdf->SetFont($pdf->FontStd, '', 10);
$pdf->Cell(40, 7, get_text('TourCommitee', 'Tournament') . ": ", 'L', 0, 'L', 0);
$pdf->SetFont($pdf->FontStd, 'B', 10);
$pdf->Cell(150, 7, $RowTournament->ToCommitee . " - " . $RowTournament->ToComDescr, 'R', 1, 'L', 0);
//Luogo e data di Svolgimento
$pdf->SetFont($pdf->FontStd, '', 10);
$pdf->Cell(40, 7, get_text('TourWhen', 'Tournament') . ": ", 'L', 0, 'L', 0);
$pdf->SetFont($pdf->FontStd, 'B', 10);
$pdf->Cell(50, 7, TournamentDate2String($RowTournament->DtFrom, $RowTournament->DtTo), 0, 0, 'L', 0);
$pdf->SetFont($pdf->FontStd, '', 10);
$pdf->Cell(30, 7, get_text('TourWhere', 'Tournament') . ": ", 0, 0, 'R', 0);
$pdf->SetFont($pdf->FontStd, 'B', 10);
$pdf->Cell(70, 7, $RowTournament->ToWhere, 'R', 1, 'L', 0);
$pdf->SetFont($pdf->FontStd, 'B', 1);
$pdf->Cell(190, 0.5, '', 1, 1, 'L', 1);
$pdf->SetXY($pdf->GetX(), $pdf->GetY() + 5);
//Parte di Report vera e propria
/*$MySql = "SELECT FrqId, FrqStatus, FrqQuestion, FrqTip, FrqType, FrqOptions, TtCategory "
	. "FROM FinalReportQ "
	. "INNER JOIN Tournament ON ToId=" . StrSafe_DB($_SESSION['TourId']) . " "
	. "INNER JOIN Tournament*Type ON TtId=ToType ";
if($AllQuestions)
	$MySql .= "WHERE FrqStatus > 0 ";
else
	$MySql .= "WHERE (FrqStatus & TtCategory) > 0 ";
$MySql .= "ORDER BY FrqId";*/
$MySql = "SELECT FrqId, FrqStatus, FrqQuestion, FrqTip, FrqType, FrqOptions, ToCategory AS TtCategory " . "FROM FinalReportQ " . "INNER JOIN Tournament ON ToId=" . StrSafe_DB($_SESSION['TourId']) . " ";
if ($AllQuestions) {
    $MySql .= "WHERE FrqStatus > 0 ";
} else {
    $MySql .= "WHERE (FrqStatus & ToCategory) > 0 ";
コード例 #2
0
ファイル: PrnMedalTeam.php プロジェクト: brian-nelson/ianseo
 if ($CurTeam != $MyRow->NationCode) {
     // Sicuramente devo incrementare la posizione
     $MyPos++;
     // Se non ho parimerito il ranking � uguale alla posizione
     if (!($MyRow->TeScore == $MyScoreOld && $MyRow->TeGold == $MyGoldOld && $MyRow->TeXnine == $MyXNineOld)) {
         $MyRank = $MyPos;
     }
     if ($MyRank <= 3) {
         $pdf->SetFont($pdf->FontStd, 'B', 8);
         $pdf->Cell(20, 4 * $MyRow->Quanti, $MyRank == 1 ? get_text('MedalGold') : ($MyRank == 2 ? get_text('MedalSilver') : ($MyRank == 3 ? get_text('MedalBronze') : "")), 1, 0, 'L', 0);
         $pdf->SetFont($pdf->FontStd, '', 7);
         $pdf->Cell(10, 4 * $MyRow->Quanti, $MyRow->NationCode, 'LTB', 0, 'C', 0);
         $pdf->Cell(75, 4 * $MyRow->Quanti, $MyRow->Nation, 'RTB', 0, 'L', 0);
     }
 } else {
     $pdf->SetX($pdf->GetX() + 105);
 }
 if ($MyRank <= 3) {
     $pdf->SetFont($pdf->FontStd, '', 7);
     $pdf->Cell(50, 4, $MyRow->FirstName . ' ' . $MyRow->Name, 'TRB', 0, 'L', 0);
     $pdf->SetFont($pdf->FontFix, '', 6);
     $pdf->Cell(8, 4, number_format($MyRow->QuScore, 0, '', get_text('NumberThousandsSeparator')), 1, 0, 'R', 0);
     if ($CurTeam != $MyRow->NationCode) {
         $CurTeam = $MyRow->NationCode;
         $pdf->SetFont($pdf->FontFix, 'B', 8);
         $pdf->Cell(11, 4 * $MyRow->Quanti, number_format($MyRow->TeScore, 0, '', get_text('NumberThousandsSeparator')), 'TB', 0, 'R', 0);
         $pdf->SetFont($pdf->FontFix, '', 7);
         $pdf->Cell(8, 4 * $MyRow->Quanti, $MyRow->TeGold, 'TB', 0, 'R', 0);
         $pdf->Cell(8, 4 * $MyRow->Quanti, $MyRow->TeXnine, 'TBR', 0, 'R', 0);
     }
     $pdf->Cell(0.5, 4, '', 0, 1, 'C', 0);