Joshua John Posted August 22, 2011 Report Posted August 22, 2011 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! Quote
TennShadow Posted August 22, 2011 Report Posted August 22, 2011 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. Quote
Jeff Posted August 23, 2011 Report Posted August 23, 2011 Here is the thread you are looking for, but as Keith said it is not currently finished yet. http://forum.phpvms.net/topic/4397-autoawards-input-required/page__view__findpost__p__29137 Quote
Jon Posted August 23, 2011 Report Posted August 23, 2011 I use a simple php script that I saw posted a while ago that just shows on the pilot_public_profile. Just a basic if statment for the amount of hours to give rank awards etc. Ones such as staff and donator are manual. An example here: http://airfranceva.com/index.php/profile/view/1 regards Jon Quote
Guest lorathon Posted August 23, 2011 Report Posted August 23, 2011 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. Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.