Donation percent complete not accurate using {loadmodule}

  • ghardin
  • Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
6 years 6 months ago #114269 by ghardin
I am working on a website for a client using JoomDonation 5.4.2. In an article using the {loadmodule mod_jd_campaigns,"name of campaign module"} we are finding the the percent donated in at least one case, shows 100% complete when the goal and raised are not equal. The difference is $295 and the percent donated should show 99.64%. Can someone tell me where that calculation is made so I can correct this? The reason the client is making the request, is that when the percent shows as 100%, there is a risk that donors may stop contributing. While it is only $295, as a nonprofit every dollar counts and they need to make sure the project is FULLY funded before it shows as 100%.

Thanks!

Please Log in or Create an account to join the conversation.

More
6 years 6 months ago #114293 by Mr. Dam
Hi,
You can find the code to calculate the donated percentage in file: root > components > com_jdonation > view > campaigns > tmpl > default.php
The code line is:
Code:
$donatedPercent = ceil($item->total_donated/ $item->goal *100);
Thanks
Dam

Please Log in or Create an account to join the conversation.

Moderators: Mr. DamDũng Nguyễn Việt