I have added functions to give the ADMIN some records in Dashboard area.
Install:
-Download and replace PManagerData.class.php from Github.
-Add the following lines to admin/dashboard.php
<?php $days = Config::Get('PILOT_INACTIVE_TIME');?>
<strong>Inavtive Pilots: </strong><?php echo count(PManagerData::InactivePilots());?>
<strong>Pilots With No Pireps In <?php echo $days;?> Days: </strong><?php echo count(PManagerData::PastDuePireps());?>
<strong>Pilots With No Pireps AT All: </strong><?php echo count(PManagerData::NoPireps());?>
Inavtive Pilots: <?php echo count(PManagerData::InactivePilots());?> Pilots With No Pireps In <?php echo $days;?> Days: <?php echo count(PManagerData::PastDuePireps());?> Pilots With No Pireps AT All: <?php echo count(PManagerData::NoPireps());?>
Screenshot:
Cheers
Hello,
Can you please tell me where to add this inside the file, cause everytime im trying, im getting errors
Hey Parkho, I canât help but notice on your dev site, there is a place in the dashboard to edit email templates. However, in version 2.2 php version, there is not when Installed on my site. Is this on purpose? If not, I think we are missing the sidebar_pm.php maybe?
And one very tiny small issue, when I click Pilot manager in the admin panel, it literally opens every category drawer all the way down the admin page.
I attached an image with all the category drawers open. Pardon my non artistic graphical skills!
Hi Ray, the reason the sidebar drawers open is the Javascript conflict of the module which I will fix in next version soon. Also, the sidebar pm is under development for next version and is not yet published. Thank you for your support of my modules. It definitely helps me keep up my work.
Take a look at my website please. I fixed the drawers issue but for the sidebar pm I still need to figure out how the user can add/edit warning/welcome messages since I want them to send the email with details.(eg pilot name current time etc.)
⌠since I want them to send the email with details.(eg pilot name current time etc.)
Well, we are on the same thinking wave pattern I see. I was kind of curious over that myself. The email system is what has plagued me with a module I am working on as well. I wish you luck in figuring that one out. Iâm sure if you do it will be spot on.
Fatal error: Class âPilotManagerDataâ not found in /home/flyaka/public_html/core/modules/PilotManager/PilotManager.php on line 271
Any ideas?
Well that line is looking for the pilotâs last pirep and since new pilots have none, youâll get this error. Open âPManagerData.class.phpâ in âcommonâ folder. At line 67 is the following function:
public static function getpirep($pilotid) { $sql="SELECT \* FROM phpvms\_pireps WHERE pilotid = '$pilotid' ORDER BY submitdate DESC"; $check = DB::get\_row($sql); }
change it to the following:
public static function getpirep($pilotid) { $sql="SELECT \* FROM phpvms\_pireps WHERE pilotid = '$pilotid' ORDER BY submitdate DESC"; $check = DB::get\_row($sql); if($check) { return DB::get\_row($sql); } }
Try this and let me know if the issue is resolved. Thanks for noticing.