Jump to content

ProAvia

Administrators
  • Posts

    1648
  • Joined

  • Last visited

  • Days Won

    72

Posts posted by ProAvia

  1. I'm having two small issues.

    1 - In order to get our Staff of 3 to be able to see pretty much everything they need to see, we have given them an hours total of 40000 (40k). I have been able to have them NOT show in the pilot roster using the following in '/pl/pilots_list.php - starting about line 24.

    <?php
    foreach($pilots as $pilot)
    {
     // following to not show Staff & Retired in Pilot Roster
     if($pilot->rankid == 23)  { continue; } //staff
     if($pilot->retired == 1) { continue; }
    ?>

    While I can use the '... rankid == 23 ...' to made staff not show in Top Pilots All Time (Hours Flown), their hours are still taken into account there - hence I only see two non-staff pilots listed out of the possible five (3 staff + 2 non-staff = 5) for that area. Is it possible to not take the staff hours into account there? I'd like to display the top 5 non-staff pilots.

     

    2. Top Pilots All Time (Hours Flown) is only showing total flight hours (I'm guessing a sum of all 'hours' from the 'top_flights' table) - but that's not including transfer hours (transfer hours is set to true in local.config.php). Is there a way to add in the transfer hours? Here's the code from that section of 'tp_index.php' - starting on about line 33.

    echo '<center>';
    echo '<b>Top Pilots All Time </b>(Hours Flown)';
    echo '<table class="profiletop">';
    echo '<tr>';
    echo '<th>Pilot</th>';
    echo '<th>Hours Flown</th>';
    echo '</tr>';
    $all_hours= TopPilotData::alltime_hours(5);
    foreach($all_hours as $all) {
        $pilot = PilotData::GetPilotData($all->pilotid);
        echo '<tr>';
        echo '<td>'.$pilot->firstname.' '.$pilot->lastname.' - '.PilotData::GetPilotCode($pilot->code, $pilot->pilotid).'</td>';
        echo '<td>'.$all->totalhours.'</td>';
        echo '</tr>';

    I have been successful in getting totalhours and transferhours to display there together, I have NO idea on how to make the SUM of totalhours and transferhours display.

    Thanks in advance for any insight!

  2. 2 hours ago, joooseb said:

    Help!!

     

    Strict Standards: Non-static method PirepAcData::editSettings() should not be called statically, assuming $this from incompatible context in /home1/mcfilmsp/public_html/php/admin/modules/PirepAutoAccept/PirepAutoAccept.php on line 135

    Settings Are Saved


    Strict Standards: Non-static method PirepAcData::get_criteria() should not be called statically, assuming $this from incompatible context in /home1/mcfilmsp/public_html/php/admin/modules/PirepAutoAccept/PirepAutoAccept.php on line 145


    Strict Standards: Non-static method PirepAcData::get_settings() should not be called statically, assuming $this from incompatible context in /home1/mcfilmsp/public_html/php/admin/modules/PirepAutoAccept/PirepAutoAccept.php on line 147

     

    When I put landing rate 800 and enabled the module (I'm using php 5.3)

    See my reply to your post 'Expense Error' here:

     

  3. Look in FinanceData.class.php about line 149 for ... setExpensesforMonth ... - does that line start with public function or public static function ?

    Many(all??)  of the same Strict Standards: Non-static method .... errors can be fixed by changing the public function to public static function in ....Data.class.php files. The word(s) after non-static method and before the :: will clue you in on which ...Data.class.php file to edit. The words after :: and before should are the function call to search for.

    I say this while trying to figure out why I can't see 'Pilot Pay' in any of my financial reports. Since I don't have any expenses entered anywhere, I don't know whether expenses are affected the same as my pilot pay situation. Oh well, time to search the forums - AGAIN! :lol::blink:

  4. 1 hour ago, vbegin7 said:

    found out the problem no solution though here is the error the schedules are not enabled within the schedules in admin panel but when i enable it i get this error

    There was an error editing the schedule: Unknown column 'week1' in 'field list'

    As web541 mentioned above, it would be best to use the database from the 5.5.2 install and then move/copy the data from each 2.1.x table over. The 5.5.2 database includes several new fields within various tables - the schedules table being but one of those with additions. If I recall, 'schedules' table added week1, week2, week3, week4.

    You don't necessarily NEED to enter data into the additional fields in the 'schedules' table, but you do need to have those fields so as not to get the error you show above.

  5. Not showing any errors.

    I'll have a look at those links at a later date. Right now, I need to finish the site update from 2.1.934 to 5.5.2 so I can change the live site over. Don't really need the charts right now - and have been doing without on the old live site too. This will give me something to do after the update.

    Thanks!

  6. Cool! Thank you to both you and Kyle.

    So, in the admin panel - am I supposed to see a chart for the last 30 days? And on the My Stats page as well? I do have the default 5.5.2 ChartsData.class.php file in place, as well as the gchart/gchart.php.

  7. On ‎11‎/‎29‎/‎2016 at 3:12 PM, OmerAslan said:

    Hi,

    i download it and i see the airports but they are empty. It says There are no charts!

    On Charts Admin page, i see all the airports but how i will add charts in it? There is no option for it. When i click on Icao codes in admin side comes this page admin/index.php/viewcharts?icao=AGAT and it says The module "VIEWCHARTS" doesn't exist!

    help please.

    See this post:

    After downloading/installing the updated module referenced in post #2 (the "here" link), make the edit suggested in post #3.

    Hope that helps!

     

  8. Thanks! Yeah - I thought the default 5.5.2 file did something like that. On the main admin page, I don't get a chart. Nothing at /index.php/profile/stats either. Hence my question if I need to download anything else to make ChartsData.class.php work - see my first post.

    I messed with it some before loading your update. And I was able to get it to load. But I took mine out and used yours instead, cause yours looked cleaner and adds a few changes not in the original files.

    There is one small omission/error that was in the original files - and carried over into yours. admin/templates/charts/index.php, line 41

    // Originally:
    <a href="viewcharts?icao=<?php echo $airport->icao; ?>"><?php echo $airport->icao; ?></a>
    
    // Change to:
    <a href="chartsadmin/viewcharts?icao=<?php echo $airport->icao; ?>"><?php echo $airport->icao; ?></a>
    
    //This will allow viewing the charts in the admin panel without the error of:
    //The module "VIEWCHARTS" doesn't exist!

    After changing that, it works great! If you'd like, maybe send a pull request to Kyle.

    I'll look at the AirCharts module too and then decide which to offer - heck, maybe both. I do like the option of viewing from the schedule briefing page in AirCharts.

    Thanks again!

    • Like 1
  9. In the default phpVMS 5.5.2 (Simpilot version), there is a file in 'core/common' named 'ChartsData.class.php -  it's not in version 2.1.934. I see in that file a reference to -

    #replacement functions for OFC charts - Google Charts API - simpilot
    #load Google Chart Wrapper library (3rd party)
    require CORE_LIB_PATH . '/gChart/gChart.php';

    - at the top of the file. Is there something else I need to download/install for ChartsData.class.php to function? Seems this file provides a replacement for OFC (Open Flash Chart) functionality. What exactly does this file do and is it linked to specific default modules?

    ______________________________

    My main reason for asking about this file is that on my version 2.1.934 site, I am using Airport Charts - by Vansers. That add-on module contains the exact same file name... ChartsData.class.php. The two files are nowhere near similar in content. I'd like to use the Airport Charts module in phpVMS 5.5.2 - AND any functions of the default chart as well. I don't think renaming a default file would be a good thing - as it would break stuff that I'm not even aware of.

    Kyle hasn't updated Airport Charts since 10/2011. I can get the original to work in version phpVMS 5.5.2 using the normal methods found here for other modules. I saw in the Airport Charts thread that Kyle is fine with the module being modded for personal use. Maybe I need to mod the Airport Charts folders/files to 'NavCharts' from 'Charts'?  I suppose the best course of action is to use the new name of 'NavCharts' throughout the module to make it easier to keep track of the mod files (and rename the DB table to 'navcharts' also).

  10. The reason I requested clarification is that some have had issues with free hosting and phpVMS.

    Have you tried reverting the settings to the defaults and trying the email function again? Here's the default settings from 'app.config.php' for reference:

    # Email Settings
    Config::Set('EMAIL_FROM_NAME', '');
    Config::Set('EMAIL_FROM_ADDRESS', '');
    
    Config::Set('EMAIL_USE_SMTP', false);
    # Add multiple SMTP servers by separating them with ;
    Config::Set('EMAIL_SMTP_SERVERS', '');
    Config::Set('EMAIL_SMTP_PORT', '25');
    Config::Set('EMAIL_SMTP_USE_AUTH', false);
    Config::Set('EMAIL_SMTP_SECURE', ''); # must be "ssl" for Google Apps
    Config::Set('EMAIL_SMTP_USER', '');
    Config::Set('EMAIL_SMTP_PASS', '');
    
    # Set specific email addresses to send notifications to
    Config::Set('EMAIL_NEW_REGISTRATION', '');
    Config::Set('EMAIL_NEW_PIREP', '');
    
    # Whether to send an email or not
    Config::Set('EMAIL_SEND_PIREP', true);
    
    # This is email to specifically send email sent error to, such
    # as failure notices with an invalid email or something
    # If blank, it'll default to the "from" email that's specified
    Config::Set('EMAIL_RETURN_PATH', '');

    The only change in 'local.config.php' on mine is Config::Set('EMAIL_SMTP_SECURE', 'ssl'); # must be "ssl" for Google Apps - but I can't tell you exactly why it's set that way (as I copied my settings from phpVMS 2.1.936 to phpVMS 5.5.2).

    With these settings, emails are send from the email address provided during install. I set up a "main_office@MyAirlineName.com" email address through CPanel prior to installing phpVMS.

  11. I left all those email settings at their default. I set up phpVMS using an email address associated with the domain I run the program on. The site sends emails correctly.

    Site: www.MyAirlineName.com

    Email: me@MyAirlineName.com

     

  12. It's not that I necessarily want it changed - but on my 5.5.2 test site, I processed a test Pirep and noticed the flight time addition was odd. The pilot had 3348.38 total hours - 3348 hours 38 minutes. His Pirep added 2.22 - 2 hours 22 minutes. The result should have been 3351.00 - 3351 hours 00 minutes. Instead the result was 3350.6 - 3350 hours 60 minutes. While I know that 3350 hours 60 minutes is actually 3351 hours 00 minutes, it might be confusing to my pilots.

    I'll do some more testing to see if the times add up correctly. Maybe there's an issue with 60 minutes not converting over to 1 hour - possibly it happens at 61 minutes?

    I thought there was a reference - maybe during install - to choose between a period or colon for the separator.

  13. I could swear I've seen this somewhere, but can't find it now. And was unable to find ANY reference using Search.

    Can the flight time separator be changed from ' . ' to ' : '? And where is this setting? My present 2.x site uses the period ( . ) and I'd like to change to the colon ( : ) on my 5.5.2 site.

    With a 5.5.2 site, does it matter which separator is used? Is there an advantage to using one over the other?

    TIA!

  14. Using phpVMS 5.5.2

    In 'app.config.php' (file date 10/25/2016) on or near line 321 is the entry: Config::Set('TPL_EXTENSION', '.tpl');

    Should the '.tpl' be changed to '.php'?

    If so, should the line Config::Set('TPL_EXTENSION', '.php'); be added to the 'local.config.php' or just edited in the 'app.config.php'?

  15. I really can't tell you which version of PHP you should run. But I can say that I'm running phpVMS 5.5.2 on PHP version 5.6.18. phpVMS 5.5.2 runs fine on PHP 5.6.18 - with a few fixable errors. I'm still in the process of going through everything and attempting to fix any errors with some older modules.

    I believe it's been mentioned that phpVMS 5.5.2 will NOT run on PHP version 7.x. But, I personally haven't tried it.

  16. phpVMS 5.5.2

    When attempting to access the Admin Activity Logs via Admin, Site & Settings, I receive the following:

    Fatal error: Allowed memory size of 33554432 bytes exhausted (tried to allocate 3 bytes) in /home/xxxxxx/public_html/xxxxxxxxxx/phpvmsTEST/core/classes/ezdb/ezdb_mysqli.class.php on line 287

    I'm using the original file provided with version 5.5.2. Is this something I need to worry about and is there a fix?

    Thanks for any insight!

    EDIT: Disregard - I think I found my issue.

    Search is my friend! ----- walking away, shaking my head ------- Search is my.......

×
×
  • Create New...