Jump to content

Double Hours and Awards


Joshua John

Recommended Posts

Hey Guys,

Two things

1. To get more pilots flying we have created Wednesday Happy Hours so every wednesday between 3pm - 6pm pilots will get double hours for every PIREP filed between these times. So is there a way to get this to do automatically so that instead of having to go through the recent PIREPS and adding double hours for each pilot?

2. Is there a way for say like when a pilot reaches a certain amount of hours to get an award automatically because its annoying having to again go through all pilots and add an award manually.

Thanks!

Link to comment
Share on other sites

Hey Guys,

Two things

1. To get more pilots flying we have created Wednesday Happy Hours so every wednesday between 3pm - 6pm pilots will get double hours for every PIREP filed between these times. So is there a way to get this to do automatically so that instead of having to go through the recent PIREPS and adding double hours for each pilot?

2. Is there a way for say like when a pilot reaches a certain amount of hours to get an award automatically because its annoying having to again go through all pilots and add an award manually.

Thanks!

There is nothing in the standard install of PHPVMS that will do those things at this time. There was a post on here sometime ago about someone wanting to create an awards module but I don't think it has been released yet.

Link to comment
Share on other sites

Guest lorathon

My 2 cents -

Double hours

This can be done but it would either require modifying the PIREPData file or writing a script for a cron job. This script would have to be set so that it would grab the pireps for the day is question and then just multiple the flighttime & the flighttime_stamp by 2. This can obviously only run once or the flighttimes will keep doubling. The best bet would be to run the script on the day following the double hours day. Modifying the PIREPData would require that as the pirep is filed to check the day of week. If the day of the week matches the double hours day then once again the flighttime and flighttime_stamp should be doubled. This would allow the hours to be awarded to the pilot immediately upon pirep acceptance. But it would also be overwritten if you plan to use the beta versions of phpVMS. If I remember correctly you may be able to hook into the PIREP_FILED hook (can't remember at the moment) and you maybe able to write a script to run on the hook

Auto Awards

I have written a script for auto awards. There really can be no standard module for this. As each airline would want something different. Example - Airline A wants an award for 100 flights, this award id is 23. Airline B wants an award for 100 flights, this award id is 5. And the differences just grow as you think of the possibilities. And then if the VA changes the award the script may have to be changed. As far as I can see this needs to be coded by each individual airline. Or a massive module needs to be scripted allowing to set a bunch of options.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...