# Pilot Financial Report V1.0

**URL:** <https://forum.phpvms.net/t/pilot-financial-report-v1-0/7224>\
**Category:** Parkho's Addons\
**Created:** [September 16, 2012, 3:40pm UTC](https://forum.phpvms.net/t/pilot-financial-report-v1-0/7224 "2012-09-16T15:40:52Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![Parkho](https://forum.phpvms.net/user_avatar/forum.phpvms.net/parkho/32/3273_2.png) [@Parkho](https://forum.phpvms.net/u/Parkho)\
**Post date:** [September 16, 2012, 3:40pm UTC](https://forum.phpvms.net/t/pilot-financial-report-v1-0/7224/1 "2012-09-16T15:40:52Z")

</div>

Here is another small add-on for those who want to show pilot’s financial reports. It’s based on pilot id, so the results are for each of you pilots.Cheers

Install

1. Download the zip from repo.

2. Unzip and upload in the order of folders.

3. Access financial report for a pilot by

-----------------OR----------------------

Access financial report for all pilots by

```
<?php echo url('/pfinance/pilots') ;?>

```

1. Enjoy.

Download:[PilotFinancialReport\_V1.0](https://github.com/parkho/FinancialReport_V1.0)

Screenshot for a pilot report:

Screenshot for all pilots report:

Change Log:

1. PilotFinance.class.php & pilots\_finance.tpl have been added. Those of you who have downloaded this before should re-download.

---

<div class="post-metadata">

**Author:** ![mattia](https://forum.phpvms.net/user_avatar/forum.phpvms.net/mattia/32/147_2.png) [@mattia](https://forum.phpvms.net/u/mattia)\
**Post date:** [September 16, 2012, 4:21pm UTC](https://forum.phpvms.net/t/pilot-financial-report-v1-0/7224/2 "2012-09-16T16:21:36Z")

</div>

hi parkho

i have this error:

**Warning** \*\* : mysql\_fetch\_assoc(): supplied argument is not a valid MySQL result resource in \*\*\*\* /var/www/virtual/italianivolanti.it/htdocs/iv/core/templates/pilot\_finance.tpl \*\*\*\* on line \*\*\*\* 12\*\*

**â‚¬ 0.00**

- 
- Your total flight fuel expenses in Italiani Volanti is:  
**Warning** \*\* : mysql\_fetch\_assoc(): supplied argument is not a valid MySQL result resource in \*\*\*\* /var/www/virtual/italianivolanti.it/htdocs/iv/core/templates/pilot\_finance.tpl \*\*\*\* on line \*\*\*\* 18\*\*  
**â‚¬ 0.00**
- Your total in flight expenses in Italiani Volanti is:  
**Warning** \*\* : mysql\_fetch\_assoc(): supplied argument is not a valid MySQL result resource in \*\*\*\* /var/www/virtual/italianivolanti.it/htdocs/iv/core/templates/pilot\_finance.tpl \*\*\*\* on line \*\*\*\* 24\*\*  
**â‚¬ 0.00**
- Your total flight revenue in Italiani Volanti is:  
**Warning** \*\* : mysql\_fetch\_assoc(): supplied argument is not a valid MySQL result resource in \*\*\*\* /var/www/virtual/italianivolanti.it/htdocs/iv/core/templates/pilot\_finance.tpl \*\*\*\* on line \*\*\*\* 31\*\*

---

<div class="post-metadata">

**Author:** ![servetas](https://forum.phpvms.net/user_avatar/forum.phpvms.net/servetas/32/75_2.png) [@servetas](https://forum.phpvms.net/u/servetas)\
**Post date:** [September 16, 2012, 4:37pm UTC](https://forum.phpvms.net/t/pilot-financial-report-v1-0/7224/3 "2012-09-16T16:37:17Z")

</div>

Screenshot?

---

<div class="post-metadata">

**Author:** ![mattia](https://forum.phpvms.net/user_avatar/forum.phpvms.net/mattia/32/147_2.png) [@mattia](https://forum.phpvms.net/u/mattia)\
**Post date:** [September 16, 2012, 5:00pm UTC](https://forum.phpvms.net/t/pilot-financial-report-v1-0/7224/4 "2012-09-16T17:00:06Z")

</div>

attach photos

![post-2342-0-99674300-1347814792.png](https://phpvms-forum.nyc3.digitaloceanspaces.com/original/2X/1/1c5d89aba6df152fd3779150c34e0d21bc653e4c.jpeg)

---

<div class="post-metadata">

**Author:** ![servetas](https://forum.phpvms.net/user_avatar/forum.phpvms.net/servetas/32/75_2.png) [@servetas](https://forum.phpvms.net/u/servetas)\
**Post date:** [September 16, 2012, 5:02pm UTC](https://forum.phpvms.net/t/pilot-financial-report-v1-0/7224/5 "2012-09-16T17:02:17Z")

</div>

I was talking about the general screen shot of the module in order to preview it…

---

<div class="post-metadata">

**Author:** ![Fernando](https://forum.phpvms.net/user_avatar/forum.phpvms.net/fernando/32/169_2.png) [@Fernando](https://forum.phpvms.net/u/Fernando)\
**Post date:** [September 16, 2012, 5:10pm UTC](https://forum.phpvms.net/t/pilot-financial-report-v1-0/7224/6 "2012-09-16T17:10:42Z")

</div>

Great Work, Parkho

I made some adjustments

---

<div class="post-metadata">

**Author:** ![Fernando](https://forum.phpvms.net/user_avatar/forum.phpvms.net/fernando/32/169_2.png) [@Fernando](https://forum.phpvms.net/u/Fernando)\
**Post date:** [September 16, 2012, 5:19pm UTC](https://forum.phpvms.net/t/pilot-financial-report-v1-0/7224/7 "2012-09-16T17:19:25Z")

</div>

Mattia

you touched on some of the files line by disponibilziados Parkho?

---

<div class="post-metadata">

**Author:** ![Parkho](https://forum.phpvms.net/user_avatar/forum.phpvms.net/parkho/32/3273_2.png) [@Parkho](https://forum.phpvms.net/u/Parkho)\
**Post date:** [September 16, 2012, 5:32pm UTC](https://forum.phpvms.net/t/pilot-financial-report-v1-0/7224/8 "2012-09-16T17:32:06Z")

</div>

> hi parkho
> 
> i have this error:
> 
> **Warning** \*\* : mysql\_fetch\_assoc(): supplied argument is not a valid MySQL result resource in \*\*\*\* /var/www/virtual/italianivolanti.it/htdocs/iv/core/templates/pilot\_finance.tpl \*\*\*\* on line \*\*\*\* 12\*\*
> 
> **â‚¬ 0.00**
> 
> - 
> - Your total flight fuel expenses in Italiani Volanti is:  
> **Warning** \*\* : mysql\_fetch\_assoc(): supplied argument is not a valid MySQL result resource in \*\*\*\* /var/www/virtual/italianivolanti.it/htdocs/iv/core/templates/pilot\_finance.tpl \*\*\*\* on line \*\*\*\* 18\*\*  
> **â‚¬ 0.00**
> - Your total in flight expenses in Italiani Volanti is:  
> **Warning** \*\* : mysql\_fetch\_assoc(): supplied argument is not a valid MySQL result resource in \*\*\*\* /var/www/virtual/italianivolanti.it/htdocs/iv/core/templates/pilot\_finance.tpl \*\*\*\* on line \*\*\*\* 24\*\*  
> **â‚¬ 0.00**
> - Your total flight revenue in Italiani Volanti is:  
> **Warning** \*\* : mysql\_fetch\_assoc(): supplied argument is not a valid MySQL result resource in \*\*\*\* /var/www/virtual/italianivolanti.it/htdocs/iv/core/templates/pilot\_finance.tpl \*\*\*\* on line \*\*\*\* 31\*\*

Are you using any shared server for your site? Cause I think that’s where the problem lies not sure though. It’s working just fine on this side.

---

<div class="post-metadata">

**Author:** ![Fernando](https://forum.phpvms.net/user_avatar/forum.phpvms.net/fernando/32/169_2.png) [@Fernando](https://forum.phpvms.net/u/Fernando)\
**Post date:** [September 16, 2012, 5:33pm UTC](https://forum.phpvms.net/t/pilot-financial-report-v1-0/7224/9 "2012-09-16T17:33:48Z")

</div>

Parkho,

seems to be a permission problem, what do you think?

---

<div class="post-metadata">

**Author:** ![Parkho](https://forum.phpvms.net/user_avatar/forum.phpvms.net/parkho/32/3273_2.png) [@Parkho](https://forum.phpvms.net/u/Parkho)\
**Post date:** [September 16, 2012, 5:38pm UTC](https://forum.phpvms.net/t/pilot-financial-report-v1-0/7224/10 "2012-09-16T17:38:19Z")

</div>

> I was talking about the general screen shot of the module in order to preview it…

---

<div class="post-metadata">

**Author:** ![mattia](https://forum.phpvms.net/user_avatar/forum.phpvms.net/mattia/32/147_2.png) [@mattia](https://forum.phpvms.net/u/mattia)\
**Post date:** [September 16, 2012, 6:39pm UTC](https://forum.phpvms.net/t/pilot-financial-report-v1-0/7224/11 "2012-09-16T18:39:29Z")

</div>

i copy the file in my site but dont work

---

<div class="post-metadata">

**Author:** ![Parkho](https://forum.phpvms.net/user_avatar/forum.phpvms.net/parkho/32/3273_2.png) [@Parkho](https://forum.phpvms.net/u/Parkho)\
**Post date:** [September 16, 2012, 8:17pm UTC](https://forum.phpvms.net/t/pilot-financial-report-v1-0/7224/12 "2012-09-16T20:17:03Z")

</div>

> i copy the file in my site but dont work

Strange! did you copy the .tpl in templates or your skin folder?

---

<div class="post-metadata">

**Author:** ![mattia](https://forum.phpvms.net/user_avatar/forum.phpvms.net/mattia/32/147_2.png) [@mattia](https://forum.phpvms.net/u/mattia)\
**Post date:** [September 16, 2012, 11:12pm UTC](https://forum.phpvms.net/t/pilot-financial-report-v1-0/7224/13 "2012-09-16T23:12:13Z")

</div>

yes,

pilot\_finance.tpl in templates folder and Pfinance folder in modules folder

---

<div class="post-metadata">

**Author:** ![SparrowBD](https://forum.phpvms.net/letter_avatar_proxy/v4/letter/s/7ea924/32.png) [@SparrowBD](https://forum.phpvms.net/u/SparrowBD)\
**Post date:** [September 17, 2012, 12:21am UTC](https://forum.phpvms.net/t/pilot-financial-report-v1-0/7224/14 "2012-09-17T00:21:00Z")

</div>

im getting that mysql error as well. one thing you should be able to do maybe in a future update is allow admins to view all the pilots profitability.

---

<div class="post-metadata">

**Author:** ![Fly\_Star\_Alliance](https://forum.phpvms.net/user_avatar/forum.phpvms.net/fly_star_alliance/32/102_2.png) [@Fly\_Star\_Alliance](https://forum.phpvms.net/u/Fly_Star_Alliance)\
**Post date:** [September 17, 2012, 1:45am UTC](https://forum.phpvms.net/t/pilot-financial-report-v1-0/7224/15 "2012-09-17T01:45:32Z")

</div>

Same here, MySql error

---

<div class="post-metadata">

**Author:** ![Parkho](https://forum.phpvms.net/user_avatar/forum.phpvms.net/parkho/32/3273_2.png) [@Parkho](https://forum.phpvms.net/u/Parkho)\
**Post date:** [September 17, 2012, 5:34am UTC](https://forum.phpvms.net/t/pilot-financial-report-v1-0/7224/16 "2012-09-17T05:34:01Z")

</div>

I think it’s fixed

---

<div class="post-metadata">

**Author:** ![Fly\_Star\_Alliance](https://forum.phpvms.net/user_avatar/forum.phpvms.net/fly_star_alliance/32/102_2.png) [@Fly\_Star\_Alliance](https://forum.phpvms.net/u/Fly_Star_Alliance)\
**Post date:** [September 17, 2012, 8:40am UTC](https://forum.phpvms.net/t/pilot-financial-report-v1-0/7224/17 "2012-09-17T08:40:27Z")

</div>

Better now, thanks Parkho, although I still have a couple of little problems to solve…

---

<div class="post-metadata">

**Author:** ![Parkho](https://forum.phpvms.net/user_avatar/forum.phpvms.net/parkho/32/3273_2.png) [@Parkho](https://forum.phpvms.net/u/Parkho)\
**Post date:** [September 17, 2012, 12:08pm UTC](https://forum.phpvms.net/t/pilot-financial-report-v1-0/7224/18 "2012-09-17T12:08:22Z")

</div>

I edited the .tpl as well, have you replaced that too?

---

<div class="post-metadata">

**Author:** ![CPC900](https://forum.phpvms.net/letter_avatar_proxy/v4/letter/c/a8b319/32.png) [@CPC900](https://forum.phpvms.net/u/CPC900)\
**Post date:** [September 17, 2012, 4:23pm UTC](https://forum.phpvms.net/t/pilot-financial-report-v1-0/7224/19 "2012-09-17T16:23:23Z")

</div>

Don’t forget, if you named your database to have something OTHER than “phpvms\_pireps” you will get the mysql errors. Change those lines in your “PilotFinance.class.php” to indicate your database ie “nameofdata\_pireps”; whatever yours is.

---

<div class="post-metadata">

**Author:** ![Parkho](https://forum.phpvms.net/user_avatar/forum.phpvms.net/parkho/32/3273_2.png) [@Parkho](https://forum.phpvms.net/u/Parkho)\
**Post date:** [September 17, 2012, 4:24pm UTC](https://forum.phpvms.net/t/pilot-financial-report-v1-0/7224/20 "2012-09-17T16:24:17Z")

</div>

Good point. Thanks

[Next page](https://forum.phpvms.net/t/pilot-financial-report-v1-0/7224.md?page=2)
