web541
Members-
Posts
700 -
Joined
-
Last visited
-
Days Won
17
Content Type
Profiles
Forums
phpVMS Resources
Downloads
Everything posted by web541
-
Jump Seat in Administrative Panel [ SOLVED]
web541 replied to eliezerazevedo's topic in Support Forum
No guarantees this work (haven't had a chance to test it so might've forgotten something) but I've removed the jumpseat from the pilot's side and moved it to the admin's side only. It will also be a free transfer for staff to move them. The functionality for the pilot's end jumpseat is still there if you want to add it in later. This is for parkho's FlightBookingSystem v1, so if you are using a different search at the moment (e.g. default) and want to make it work with that then it will require additional editing. -
Jump Seat in Administrative Panel [ SOLVED]
web541 replied to eliezerazevedo's topic in Support Forum
Also tell us if you are using a custom module to control the pilot's location. Examples would be https://github.com/DavidJClark/phpVMS-RealScheduleLite https://github.com/parkho/FlightBookingSystem.V1.1 -
Go into admin/maintenance.php and change this if(Config::Get('CLOSE_BIDS_AFTER_EXPIRE') === false) { SchedulesData::deleteExpiredBids(); CronData::set_lastupdate('check_expired_bids'); } To this if(Config::Get('CLOSE_BIDS_AFTER_EXPIRE') === true) { SchedulesData::deleteExpiredBids(); CronData::set_lastupdate('check_expired_bids'); } That should work it you've set the maintenance script to run. If you want to enable it again though, place the following into your local.config.php file # Whether to close any bids after a certain amount of time Config::Set('CLOSE_BIDS_AFTER_EXPIRE', true); Config::Set('BID_EXPIRE_TIME', '48'); # How many hours to hold bids for
-
If you've uploaded the module correctly, you should be able to go to http://yourvaurl.com/index.php/vFleetTracker and see the module on your website. In regards to putting the link somewhere, copy the core/templates/core_navigation.php file to your lib/skins/YOURSKINNAME/ folder and inside there, you are able to place this line wherever you want the link to show up. <a href="<?php echo url('/vFleetTracker'); ?>">vFleet Tracker</a>
-
Failed to load resource -> sound to me like a file is missing on your server. Check to see if it exists and if it is needed in your code, otherwise take it out. ReferenceError: Can't find variable: google <-- Could be what's breaking it. Could you please paste your core_htmlhead and the <head> part of your layout.php so we can make sure everything has been entered correctly (as per flyalaska above). You're welcome to hide the API Key.
-
Check your browser's console for errors and post any here (if any). By code, are you talking about the GoogleMapsAPI Key?
-
It's working for me http://i.imgur.com/ZRWQLzZ.jpg and I used Chrome & Firefox. Same result. Try removing <script src="https://maps.googleapis.com/maps/api/js?libraries=weather&" type="text/javascript"></script> And replace the line above it with this <script async defer src="https://maps.googleapis.com/maps/api/js?key=AIzaSyABv2_xOIGpz8gJ-mHEupw8eeTm7yyfgxM&libraries=weather&" type="text/javascript"></script> Also try to change this <script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> To this <script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js"></script> But it might break things like booking flights, etc. If it does, put this one back <script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> And clear your browser cache and your website cache. Then reset ACARS and try again.
-
Yeah, that's what I'm saying. The above was meerly just an example of how to sort them (not ideal). Instead of 100 1000 200 etc. It would be 0100 0200 1000 But again, not ideal. Not sure how to fix this one.
-
Weird, where did you put this? pilot_public_profile.php? It's working for me.
-
This won't work because this is the sorting for the default schedules. flyalaska is using dataTables pagination (I think) which again overrides the sorting. There is probably something in the dataTables docs about sorting with this, but what I've done in the past is just a simple check, but it's annoying when you have to do it for multiple numbers. <?php // Check the length of the pilotid and make sure it's less than 4 characters long if(strlen($pilot->pilotid) < 4) { echo '0'.$pilot->pilotid; // put a zero before the pilotid } else { echo $pilot->pilotid; // just show the pilotid } ?> To not show the zero, you could maybe add a div to not echo the 0 onto the page with style="display:none;" or something. Have a mess around with the above and see if you can get it working. I do suggest looking into the dataTables docs as well and see if you ca find anything else.
-
Nope, The developer may have just used the default .tpl file and just changed the extension without modifying the contents for the .php version. Change the following files registration_mainform.php registration_customfields.php
-
Ok, with your latest edition, the console errors seemed to have disappeared, but the page inside a page is still there. Can you book a flight still? What if you try crystal, do you still get the page inside a page?
-
Yeah, that is weird. I think it's just echoing another template inside the original page, weird how it's a full page though. Have you modified your schedule search at all. (module or template) Can you try changing your jQuery version to 1.8.3 and see if that works (again, might break things but its below 1.9.0) Do you need these script files for the skin to work? What if you remove them (referenced under your footer).
-
What other methods have you tried? Just airnav coordinates? What phpvms version are you using? This one http://phpvms.net/downloads/ or https://github.com/nabeelio/phpVMS Or this one https://github.com/DavidJClark/phpvms_5.5.x Can you try adding this manually ICAO: KLAX Airport Name: Los Angeles International Airport Latitude: 33.9425 Longitude: -118.408 With this one http://forum.phpvms.net/topic/22757-vacentral-status-and-updates/#entry120870 have you made sure it was in core/local.config.php. While in core/local.config.php check to see if your database tables are correct. If you go into your database in phpMyAdmin, do you see any data in the phpvms_airports table?
-
I believe this occurs when you have jQuery version 1.9.* or above. (In your case, you have 2.1.4). The browser has trouble "sniffing" the browser for information. For a fix, try and add this reference after loading all your jQuery files (core_htmlhead possibly unless you've referenced them in layout or elsewhere). <script src="http://code.jquery.com/jquery-migrate-1.2.1.js"></script> Or go and change your jQuery 2.1.4 to 1.9.0 and see if anything happens (note, this may break some core functions).
-
If you also want the http://www.vawebsite...p/profile/stats page with morris charts (as suggested above) then check this out http://forum.phpvms....ts/#entry122438 But I see you were referring to the public profile page. EDIT: Just saw that you posted on that thread a while back so you probably already know about it. Here is the public profile chart template = pilots_public_profile.php Add the following, make sure "morris charts" has been referenced on your page somewhere (layout.php?) <div id="pirepchart" style="height: 250px;"></div> <script type="text/javascript"> var json = (function () { var json = null; $.ajax({ 'async': false, 'global': false, 'url': "<?php echo actionurl('/profile/pirepchart');?>", 'dataType': "json", 'success': function (data) { json = data; } }); return json; }) (); new Morris.Line({ // ID of the element in which to draw the chart. element: 'pirepchart', // Chart data records -- each entry in this array corresponds to a point on // the chart. data: json, // The name of the data record attribute that contains x-values. xkey: 'ym', // A list of names of data record attributes that contain y-values. ykeys: ['total'], // Labels for the ykeys -- will be displayed when you hover over the // chart. labels: ['Flights'] }); </script> core/modules/Profile/Profile.php public function pirepchart() { $pilotid = Auth::$userinfo->pilotid; $data = PIREPData::getIntervalDataByDays(array('p.pilotid' => $pilotid), 30); header("Content-type: application/json"); echo json_encode($data); }
-
One more try /** * Get all of the bids for a pilot * * @param unknown_type $pilotid * @return unknown */ public static function getBids($pilotid) { $pilotid = DB::escape($pilotid); $sql = "SELECT s.*, b.bidid, a.name as aircraft, a.registration FROM ".TABLE_PREFIX."schedules s, ".TABLE_PREFIX."bids b, ".TABLE_PREFIX."aircraft a WHERE b.routeid = s.id AND s.aircraft = a.id AND b.pilotid = '$pilotid' ORDER BY b.bidid ASC "; return DB::get_results($sql); }
-
Try this one /** * Get all of the bids for a pilot * * @param unknown_type $pilotid * @return unknown */ public static function getBids($pilotid) { $pilotid = DB::escape($pilotid); $sql = "SELECT s.*, b.bidid, a.name as aircraft, a.registration FROM ".TABLE_PREFIX."schedules s, ".TABLE_PREFIX."bids b, ".TABLE_PREFIX."aircraft a WHERE b.routeid = s.id AND s.aircraft = a.id AND b.pilotid = '$pilotid' ORDER BY b.bidid ASC "; return DB::get_results($sql); } Made an error above
-
You have a few errors in your console, 1: This file was not found on your server http://www.gralexand...ir/bootstrap.js 2: You have included the GoogleMaps API more than once on your page, (this may be the issue) go into wherever it is located and remove this code <script type="text/javascript" src="https://maps.google.com/maps/api/js?sensor=true"></script> Might be in your layout.php. 3. On this line <script async defer src="https://maps.googleapis.com/maps/api/js?key=APIKEY&callback=initMap"></script> Remove the &callback=initMap (unless it doesn't work after that, then add it back on) 4. On this line <script src="https://maps.googleapis.com/maps/api/js?libraries=weather&sensor=false" type="text/javascript"></script> Remove ;sensor=false 5. Replace this line <script async defer src="https://maps.googleapis.com/maps/api/js?key=APIKEY&callback=initMap"></script> With this line <script async defer src="https://maps.googleapis.com/maps/api/js?key=APIKEY" type="text/javascript"></script> After these have been fixed, the last one should disappear on its own. Also, clear your browser cache at this time. Replace APIKEY with your "API KEY" as it's just there for reference.
-
Go into core/common/SchedulesData.class.php and find the function getBids($pilotid) replace it with this one /** * Get all of the bids for a pilot * * @param unknown_type $pilotid * @return unknown */ public static function getBids($pilotid) { $pilotid = DB::escape($pilotid); $sql = "SELECT s.*, b.bidid, a.name as aircraft, a.registration FROM ".TABLE_PREFIX."schedules s, ".TABLE_PREFIX."bids b, ".TABLE_PREFIX."aircraft a WHERE b.routeid = s.id AND s.aircraft = a.id AND b.pilotid = '$pilotid' ORDER BY b.bidid DESC "; return DB::get_results($sql); } And see if that fixes it. This is assuming that the bids were bidded in order, if they weren't, then you will need to apply extra code somewhere.
-
This happened to me a while back and decided to dig deeper into the code. I have this working: Go into core/common/PilotData.class.php and find the function findRetiredPilots() and replace it with this one (back it up first) What the original code is doing, is it's looking for any pilots who have logged in and have filed a PIREP before. The updated code above checks the inactive time and cross-checks it with the "joindate" column in your database and checks if they have filed a PIREP or not.
-
Working on my end with the default template file. Pilots.php
-
Not sure which one he has used, but I have this one working on a 5.5.x version public function index() { $this->set('pilot_list', PilotData::getAllPilots()); $this->render('pilots_list.tpl'); } I believe the code is for the old .tpl version which still had the $allpilots variable whereas the 5.5.x version has the newer $pilot_list variable
-
<?php echo OperationsData::getAllAircraft('true'); ?> Specifying the 'true' inside the brackets will trigger the command to only allow $enabled aircraft to be returned in the query.
-
Try this foreach($rankai as $ran) { echo $ran->icao.','; }