|
Nakroma Passenger Performance Period ".date("Y")."
|
| Ship |
: |
Nakroma |
, |
Rute |
: |
Dili-Atauro |
|
|
";
$qry="select totalseat from ".DB_APORTIL.".tbl_ship_information where id=1";
if($this->fn_row_isexists($qry)){
$totalseat=$this->fn_get_fieldvalue("totalseat",$qry);
$j=10;$s=5;
for($i=1;$i<=$totalseat;$i++){
$colors="#ecf0f1";$colorfont="black";
if($i==1||$i==($j+1)){
echo "";
}
// Content
// === Dili atauro
$qrycheckin="select inctiket,status from ".DB_APORTIL.".tbl_passenger_tiket
where inctiket='$i' and idship=1 and idroutestart=1 and cast(dates as date)=cast(now() as date)";
if($this->fn_row_isexists($qrycheckin)){
$colorfont="white";
$status=$this->fn_get_fieldvalue("status",$qrycheckin);
$colors="#f1c40f";
if($status==1){$colors="#3498db";}
if($status==-2){$colors="#ecf0f1";$colorfont="black";}
}
echo "|
$i
| ";
if($i==$s){
echo "  | ";
}
if($i%10==0){
$j+=10;$s+=10;
echo " ";
}
}
}
//$arr=array("4-H"=>"#f1c40f","5-C"=>"#f1c40f","5-F"=>"#f1c40f","5-G"=>"#f1c40f","5-H"=>"#f1c40f","20-C"=>"#2980b9","20-D"=>"#2980b9","30-D"=>"#2980b9");
// === Seat Code
// echo "";
// for($h=1;$h<=10;$h++){
// if($h==1){
// echo "|   | ";
// }
// echo " ".chr(64+$h)." | ";
// if($h==5){
// echo "  | ";
// }
// }
// echo " ";
//
// === SEAT Number
// for($i=1;$i<=30;$i++){
// echo "";
// for($j=1;$j<=10;$j++)
// {
// $colors="#ecf0f1";
//if($i==4&&$j==8){$colors="#f1c40f";}
// if(array_key_exists("$i-".chr(64+$j),$arr)){
// $colors=$arr["$i-".chr(64+$j)];
// }
// if($j==1){
// echo "| $i. | ";
// }
// echo "
//
//
//
// | ";
// if($j==5){
// echo "  | ";
// }
// }
// echo " ";
// }
echo "
|