Administrators ProAvia Posted October 17, 2017 Administrators Report Share Posted October 17, 2017 In the aircraft table, what is the purpose of the minrank and ranklevel fields? I'm assuming one if them is for the minimum rank level to use that specific equipment. Also, in phpVMS 5.2.2 - does restricting the aircraft by rank actually work correctly. I'm using simpilot's Front Schedules if that makes any difference. Thanks Quote Link to comment Share on other sites More sharing options...
web541 Posted October 17, 2017 Report Share Posted October 17, 2017 minrank is indeed used for schedules, etc. to restrict the pilot's minimum rank to that rank in the table if it's implemented correctly. ranklevel I believe is the same thing (number), but it works differently on the backend. In the default schedules (in phpVMS 5.5.2), it should work as advertised provided in your local.config.php, this is set Config::Set('RESTRICT_AIRCRAFT_RANKS', true); In the front schedules module, I don't think it takes this in by default, so you'd have to modify the module in order to check this. Right now, I believe it's just spitting out any schedule within parameters in the form. Quote Link to comment Share on other sites More sharing options...
Administrators ProAvia Posted October 18, 2017 Author Administrators Report Share Posted October 18, 2017 (edited) Thanks for the reply! Yes, that's what I'm seeing in Front Schedules. And local.config is set to true for restrict aircraft ranks. In the aircraft table, minrank consistently is one number higher than ranklevel..... If minrank=3, ranklevel=2. EDIT - checked via Schedules also - restricted rank aircraft schedules all show. I used a new account I set up with the minimum rank level. Edited October 18, 2017 by ProAvia Quote Link to comment Share on other sites More sharing options...
Moderators servetas Posted October 18, 2017 Moderators Report Share Posted October 18, 2017 First of all, there is no need to check your system's database. phpVMS automatically calculates the ranklevel of each rank. The minrank value is the id of the rank you have selected. The ranklevel value is the row of the rank. The initial pilot rank is 1, then goes to 2 and so one. Of course this cannot be the same with the rank id. You may add ranks in a different row in your system for any reason. Did you check the default phpVMS schedules page? Which phpVMS version are you using? Quote Link to comment Share on other sites More sharing options...
Administrators ProAvia Posted October 18, 2017 Author Administrators Report Share Posted October 18, 2017 (edited) Using version 5.2.2 Yes, I checked the default schedules page also. All routes show, even when ranks are restricted. I created a new account for testing which carries the minimum rank. The restricted aircaft list a rank one or two levels above this minimum rank. I only checked the database to see if there was something amiss - after verifying minimum rank didn't seem to have any affect. Edited October 18, 2017 by ProAvia Quote Link to comment Share on other sites More sharing options...
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.