Exclusive eBooks, Software Solutions, Quality Guaranteed
 
Web NukeBiz
Welcome to NukeBiz · Members
Amazon
show cart or checkout0 items
Cart Value: 0.00

Forums » DragonflyCMS Projects » Treasury and Supporters » [solved] Treasury 9.3.3 - Block
[solved] Treasury 9.3.3 - Block
For managing donations, site expenses and supporters - further enhancements only in the Donations Pro version.
Topic initiation via Bugger.

Post new topic    Reply to topic    Printer Friendly Page     Forum Index »  eCommerce » Treasury and Supporters

View previous topic :: View next topic  
Author Message
Genocide...
Nice Poster
Nice Poster

Offline Offline
Joined: Aug 05, 2010
Posts: 11

PostPosted: Wed Aug 18, 2010 3:56 pm
Post subject: [solved] Treasury 9.3.3 - Block

i am unable to get this block working correctly.
it just does not add up for me Sad

tried to find the problem but being no expert in this field i have failed. FIIK

here is what i mean :-


Genocide...'s server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
Apache 2.0.34/CMS Version 9.2.1 /PHP Version 5.2.13 /MySQL Version 5.1.48
Back to top
View user's profile
Phoenix
Chairman
Chairman

Offline Offline
Joined: Mar 17, 2004
Posts: 1543
Location: Netizen
PostPosted: Thu Aug 19, 2010 6:34 am
Post subject: Re: Treasury 9.3.3 - Block

Looks very much like they are all manual entries - did you follow the guide for manual entries?

_________________
DonationsPro for vBulletin, SMF, MyBB, DragonflyCMS


Phoenix's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
Back to top
View user's profile Visit poster's website ICQ Number Yahoo Messenger Photo Gallery
Genocide...
Nice Poster
Nice Poster

Offline Offline
Joined: Aug 05, 2010
Posts: 11

PostPosted: Thu Aug 19, 2010 3:32 pm
Post subject: Re: Treasury 9.3.3 - Block

Phoenix wrote:
Looks very much like they are all manual entries - did you follow the guide for manual entries?

only 2 listed are manual entries.
i have removed some paypal sandbox entries and other manual entries prior to this but the data looks sound to me.

this pic doesn't show email addresses but i can confirm they are all same.

it's as if it only counts the first two donations FIIK


Genocide...'s server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
Apache 2.0.34/CMS Version 9.2.1 /PHP Version 5.2.13 /MySQL Version 5.1.48
Back to top
View user's profile
Phoenix
Chairman
Chairman

Offline Offline
Joined: Mar 17, 2004
Posts: 1543
Location: Netizen
PostPosted: Thu Aug 19, 2010 4:22 pm
Post subject: Re: Treasury 9.3.3 - Block

Okay - perhaps you have changed the PayPal email address being used.

Is it the same for all payments? This is the "business" field in the cms_treas_trans db table - the summary data is grouped on this field.

_________________
DonationsPro for vBulletin, SMF, MyBB, DragonflyCMS


Phoenix's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
Back to top
View user's profile Visit poster's website ICQ Number Yahoo Messenger Photo Gallery
Genocide...
Nice Poster
Nice Poster

Offline Offline
Joined: Aug 05, 2010
Posts: 11

PostPosted: Thu Aug 19, 2010 4:51 pm
Post subject: Re: Treasury 9.3.3 - Block

the problem is a strange one.

when entering funds manual through treasury admin , because there is no field name "item_name" this remains blank !

when entering funds through paypal the field name "item_name" is entered as "Donation"

The block somehow only adds the funds where "item_name" is blank !

then i used php-myadmin to fill in all "item_name" as "Donation" and guess what ? all Donations were added together ! Yes


so does the code need changing or another field adding to treasury admin ?


Genocide...'s server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
Apache 2.0.34/CMS Version 9.2.1 /PHP Version 5.2.13 /MySQL Version 5.1.48
Back to top
View user's profile
Phoenix
Chairman
Chairman

Offline Offline
Joined: Mar 17, 2004
Posts: 1543
Location: Netizen
PostPosted: Thu Aug 19, 2010 5:04 pm
Post subject: Re: Treasury 9.3.3 - Block

That doesn't make any sense - the sql query doesn't make use of the item_name field, so it cannot have any effect.
Code::
	SELECT business, COUNT( settle_amount ) AS count, SUM( mc_gross * exchange_rate ) AS receipts, SUM( settle_amount ) AS net,  FROM_UNIXTIME( $tr_period[1] , ' %b %e' ) AS due_by 
	FROM {$prefix}_treas_trans 
	WHERE $where 
		AND (payment_status = 'Completed' OR payment_status = 'Refunded') 
	GROUP BY business";

Presumably you are using the current block that comes with v9.3.3?

_________________
DonationsPro for vBulletin, SMF, MyBB, DragonflyCMS


Phoenix's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
Back to top
View user's profile Visit poster's website ICQ Number Yahoo Messenger Photo Gallery
Genocide...
Nice Poster
Nice Poster

Offline Offline
Joined: Aug 05, 2010
Posts: 11

PostPosted: Thu Aug 19, 2010 5:37 pm
Post subject: Re: Treasury 9.3.3 - Block

i am using the block provided with treasury v9.3.3.
Quote::
/*************************************************************************
* NukeTreasury - Financial management for PHP-Nuke *
* Copyright (c) 2004 by Dave Lawrence AKA Thrash *
* thrash @ fragnastika.com *
* thrashn8r @ hotmail.com *
* This program is free software; you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation; either version 2 of the License. *
* *
* $Source: /0cvs/Treasury/blocks/block-Donat_o_Meter.php,v $ *
* $Revision: 1.4 $ *
* $Author: Phoenix $ *
* $Date: 2007/12/27 23:22:46 $ *
* *
* DragonflyCMS Version by Phoenix at nukebiz.com *
*************************************************************************/


Code::
			$query_Recordset1 = "SELECT business, COUNT( settle_amount ) AS count, SUM( settle_amount ) AS gross, SUM( settle_amount - mc_fee ) AS net, DATE_FORMAT( NOW( ) , '%M' ) AS mon,  DATE_FORMAT( SUBDATE( DATE_FORMAT( ADDDATE( NOW( ) , INTERVAL 1 MONTH ) , '%Y-%c-1' ) , INTERVAL 1 DAY ) , ' %b %e' ) AS due_by, DATE_FORMAT( NOW( ) , '%b' ) AS mon_short 
			FROM ".$prefix."_treas_trans 
			WHERE ( payment_date >= UNIX_TIMESTAMP(DATE_FORMAT( NOW( ) , '%Y-%m-$swingd' )) ) 
			GROUP BY item_name";
GROUP BY item_name could this be the culprit


Genocide...'s server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
Apache 2.0.34/CMS Version 9.2.1 /PHP Version 5.2.13 /MySQL Version 5.1.48
Back to top
View user's profile
Phoenix
Chairman
Chairman

Offline Offline
Joined: Mar 17, 2004
Posts: 1543
Location: Netizen
PostPosted: Fri Aug 20, 2010 4:06 am
Post subject: Re: Treasury 9.3.3 - Block

My apologies for misleading you - it's been a very long time and a couple of different CMSes since then - I was looking at the DonationsPro code for the block, where I had long since changed from using the item_name field to using the business field.

Now, back to Treasury - even though item_name is used, when a donation is manually added, Treasury admin collects the current config values for receiver email, item name, item number and currency symbol and adds them to that donation's record.

Therefore, it appears the item name was changed after the first 2 donations.

You need to retain the block code as it stands and be wary of changing the item name in PayPal config section.

_________________
DonationsPro for vBulletin, SMF, MyBB, DragonflyCMS


Phoenix's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
Back to top
View user's profile Visit poster's website ICQ Number Yahoo Messenger Photo Gallery
Genocide...
Nice Poster
Nice Poster

Offline Offline
Joined: Aug 05, 2010
Posts: 11

PostPosted: Fri Aug 20, 2010 7:07 am
Post subject: Re: Treasury 9.3.3 - Block

sorted Very Happy
  • cleared PayPal Item Name in paypal config
  • cleared contents of all previous 'Item Name' within sql database

now it works Wink cheers Pheonix


one more question: How do i go about applying a minimum donation?
( paypal fees are quite high when paying small donations )


Genocide...'s server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
Apache 2.0.34/CMS Version 9.2.1 /PHP Version 5.2.13 /MySQL Version 5.1.48
Back to top
View user's profile
Phoenix
Chairman
Chairman

Offline Offline
Joined: Mar 17, 2004
Posts: 1543
Location: Netizen
PostPosted: Fri Aug 20, 2010 7:52 am
Post subject: Re: Treasury 9.3.3 - Block

In DonationsPro it is configurable, along with several other features.

For Treasury, simply edit themes/default/template/treasury/index.html and remove lines 16 to 18
Code::
			<input type="radio" name="amount" value="" /> Other  
			<input type="text" name="amount" value="0.00" size="6" />
			<br />

_________________
DonationsPro for vBulletin, SMF, MyBB, DragonflyCMS


Phoenix's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
Back to top
View user's profile Visit poster's website ICQ Number Yahoo Messenger Photo Gallery
Display posts from previous:   
Post new topic    Reply to topic    Printer Friendly Page    Forum Index »  eCommerce » Treasury and Supporters
Page 1 of 1
All times are GMT + 9.5 Hours



Jump to:  


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum