Jump to content

Manual and Auto Ranks...


Recommended Posts

  • Moderators

Unfortunately no, the ranks can be either auto or manual. Alternatively, you will have to edit the core of the phpVMS. If you at least have some basic knowledge of coding you can give it a try. Do not forget to keep backup of every file before you edit it!


You will have to bypass your staff members from the auto ranks calculation function of your phpVMS system. This means that first of all, you will have to enable the rank editing option on the admin side for your staff members and stop the auto rank recalculation.


Step 1

Open your admin/templates/pilot_details.php and find the following:

if(Config::Get('RANKS_AUTOCALCULATE') == false) {

replace it with this:

if(Config::Get('RANKS_AUTOCALCULATE') == false || $pilotinfo->pilotid == X || $pilotinfo->pilotid == X) {

Step 2

After that, open your admin/modules/PilotAdmin/PilotAdmin.php and find the following:

if (Config::Get('RANKS_AUTOCALCULATE') == false) {

replace it with this:

if (Config::Get('RANKS_AUTOCALCULATE') == false || $this->post->pilotid == X || $this->post->pilotid == X) {

Step 3

Then, open your core/common/RanksData.class.php file and find the following:

foreach ($pilots as $pilot) {

below this line, add the following statement:

if($pilot->pilotid == X || $pilot->pilotid == X) continue;

In both of the pasted snippets, you will have to replace X with the pilot id which is just a number (for example: 1 or 5 or 11), do not confuse it with your pilot code and you can add ad many "|| $pilotinfo->pilotid == X" or "|| $this->post->pilotid == X" or "|| $pilot->pilotid == X" as you want based on the statements above. 


Give me an example what would you write if you wanted to bypass four different pilots. In any case, let us know if it worked for you.

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.

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.

  • Create New...