Jump to content

Parkho

Moderators
  • Posts

    1375
  • Joined

  • Last visited

  • Days Won

    5

Everything posted by Parkho

  1. Create a PHP file and name it whatever you want then inside add the following: <Table> <thead><tr><th colspan="2">Confirmed!</th></tr></thead> <tr> <td align="center">Your flight has been booked succecfully!</td> <td align="center"> <a href="<?php echo url('/profile'); ?>"><input class="button alt" type="submit" name="submit" value="Go To Pilot Center" /> <a href="<?php echo url('/schedules/bids'); ?>"><input class="button alt" type="submit" name="submit" value="Remove Bid" /> </td> </tr> </table> Then open modules/schedules and go to addbid function line 172 and alter it to the following: if ($ret == true) { $this->show('yourfilename.php'); } else { echo 'Already in bids!'; }
  2. Try this: <?php $a = "SELECT count(pirepid) AS count FROM phpvms_pireps WHERE accepted = 0 AND pilotid = Auth::$userinfo->pilotid"; $ab = DB::get_row($a); ?> <p> You have <?php echo $ab->count ;?> pending pireps</p>
  3. Try this: $a = "SELECT count(pirepid) AS count FROM phpvms_pireps WHERE accepted = 0"; $ab = DB::get_row($a); <p> You have <?php echo $ab->count ;?> pending pireps</p>
  4. This is the most common issue that goes back to skin other than the default. I have been trying to resolve the issue but no luck. What i did finally was I forwarded the bidding results to schedules/bids page with an option to remove it if necessary and so far it's been working fine.
  5. V1.1 is now stable. V2.0 was never developed and removed, I can confirm now that V1.1 is up and running
  6. Yeah I know I was fixing that
  7. I saw you scratching your head, so I changed it before you finish !!!!
  8. Try this: <?php MainController::Run('Airlinemap', 'YourTemplateName', 5); // 5 is number of records to be sgown ?>
  9. This is a new release compatible with phpVMS 5.5x by Simpilot. Install: 1.Create SQL table using the one provided in the folder(flightbookingsystem.sql) 2.Upload the files in the order into the PHPvms software. 3.Copy the following to core/local.config.php : Config::Set('JUMPSEAT_COST', '.25'); //0.25 is the cost. 4.Access it by: <?php echo url('/FBSV11") ;?> 5.Enjoy Download: FlightBookingSystem V1.1
  10. Absolutely. Glad I could help. Cheers
  11. Delete the DB and create a new one, delete all files and start from scratch, this time upload to your site root. Remember to use simpilot's version.
  12. Okay then you need to upload the files in www or public_html root.
  13. Try this: http://www.bluech-virtualaviation.com/install/install.php
  14. Why are you using ftp URL to install phpVMS? I think that's why you see that error!
  15. The selection menu calculates the distance between airports and shows the amount the pilot needs to pay. If it's replaced with text box that calculation will be no more, so that's off the topic unless you rewrite the code for it. It is possible to separate the jump-seat into another module but keep in mind that your pilots have to go to another page to change their location and come back to book their flights. If a VA does that to me as a pilot I will simply leave the VA!!! And what seems to be the problem with the jump-seat?
  16. Easiest way is to give access to your email that's used for your VA to your staff. The hard way is to implement a function into the filepirep function inside PIREPS module to send email to your staff. If you chose the hard way then you'll have to have a php knowledge or find someone to write the code for you.
  17. Try this: $tme = strtotime($pilot->joindate); $time = date("Y-m-d", $tme); echo $time;
  18. you're missing a function in your PIREPData.class.php if you see the function in the class file then the function has a bug.
  19. I see that you've added the call inside the foreach loop with a counter. Try calling it out side the loop. I have tested the function and it worked correctly on my side.
  20. Try this: <?php echo date("Y-m-d", $pilot->joindate);?>
  21. Put this in any class file like OperationsData at the end: public static function pilot_pay($pilotid) { #Get the flight time from last submitted pirep by the pilot $ft = "SELECT flighttime FROM phpvms_pireps WHERE pilotid = '$pilotid' ORDER BY submitdate DESC"; $flttme = DB::get_row($ft); #Extract the hour from it $hr = intval($flttme->flighttime); #Now the minutes $mn = ($flttme->flighttime - $hr) * 100; #Put everything together as minutes $min = ($hr * 60) + $mn; #How much the pilotpay is $fr = "SELECT pilotpay FROM phpvms_pireps WHERE pilotid = '$pilotid' ORDER BY submitdate DESC"; $payrate = DB::get_row($fr); #pilot pay per minute $pay = $payrate->pilotpay / 60; #We need total money for the pilot $pp = "SELECT totalpay FROM phpvms_pilots WHERE pilotid = '$pilotid'"; $ppay = DB::get_row($pp); $pipay = $payrate->totalpay; #Multiply it by the minutes $ftupdt = $min * $pay; #Add it to pilot money $ttalpay = $ftupdt + $pipay; $totalpay = ROUND($ttalpay, 2); #Update the table $updt = "UPDATE phpvms_pilots SET totalpay = '$totalpay' + totalpay WHERE pilotid = '$pilotid'"; DB::query($updt); } Then call it like this: OperationsData::pilot_pay(Auth::$userinfo->pilotid); Remember if you call the function inside pilot profile, pilotpay column will get updated with the last pirep submitted on each page load, so I suggest u call it inside filereport function and as soon as you hit the accept button it will update the profile.
  22. You can create a function to get the pay rate from PIREPS and multiply it by the hours of the PREP and update the pilot pay in pilots table then call the function in pilot profile giving it the pilot ID. I think this is much faster solution than actually fixing the bug. I can write the code for it if you want.
×
×
  • Create New...