Jump to content

Add Hours for pilots


Blu-Express VA

Recommended Posts

Thanks Joeri but i made a bad explanation about add Pilot hours. When new pilot is registered and have hours from other VA i can't update those hours on admin page, i must to do that directly from database and the recalculate rank, but in admin page filled the option tranfers hours and then save total hours remain in 0, "transfer hours" is enable on local config.

Best regards

Link to comment
Share on other sites

Guest lorathon

The transfer hours are not put into the total hours. These are two separate fields.

1. transferhours - manually input hour field. This can be used for pilot promotions or not (setting in local.config.php)

2. totalhours - this is the dynamically generated total number of hours flown. (accepted pirep hours are totalled for this field)

To combine for view you would need to add them together, if you want to include the transfer hours in totalhours.

$pilothours = $pilot->totalhours + $pilot->transferhours;

You will probably need to extend this to get a time return instead of a goofy number.

Link to comment
Share on other sites

Hi, regarding your post.....

1. transferhours - manually input hour field. This can be used for pilot promotions or not (setting in local.config.php)

That is the problem, on input manually the hours and then click on save.....they are not saved, the field remain in "0".

Regards and thanks

Link to comment
Share on other sites

Guest lorathon

You should probably check your files for corruption then. I would focus on the following files.

/admin/modules/PilotAdmin/PilotAdmin.php

/admin/templates/pilot_details.tpl

/core/common/PilotData.class.php

Link to comment
Share on other sites

  • 3 years later...

The transfer hours are not put into the total hours. These are two separate fields.

1. transferhours - manually input hour field. This can be used for pilot promotions or not (setting in local.config.php)

2. totalhours - this is the dynamically generated total number of hours flown. (accepted pirep hours are totalled for this field)

To combine for view you would need to add them together, if you want to include the transfer hours in totalhours.

$pilothours = $pilot->totalhours + $pilot->transferhours;

You will probably need to extend this to get a time return instead of a goofy number.

sorry, where to add this line?

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...