CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Language and Locality »
  • UK Users Group (Moderator: Michael McAndrew) »
  • CiviCRM GiftAid - Proposed improvements for 4.2
Pages: [1] 2

Author Topic: CiviCRM GiftAid - Proposed improvements for 4.2  (Read 9032 times)

Rajesh

  • I post occasionally
  • **
  • Posts: 78
  • Karma: 10
  • CiviCRM version: 4.2.x, 4.3.x, 4.4.x
  • CMS version: Drupal 7.xx, Wordpress 3.5.x - 3.6.x, Joomla 3.1
  • MySQL version: 5.5.20
  • PHP version: 5.3.10
CiviCRM GiftAid - Proposed improvements for 4.2
May 15, 2012, 08:32:41 am
GiftAid has been ported to a Civi Extension for 4.2. Hope it will make Joomla folks happy, as there were requests to port the module as a Joomla Plugin :)

Before we make the release, we would like to make few changes in the structuring of the custom data, which will make more sense. No major changes in the functionality, But there are few changes in structuring the custom data group and giftaid report. Below is the list of fields under the 2 custom data group

Gift Aid Declaration

- UK Tax Payer (Radio)
- Address (View only - copied from Contact data when the declaration is created)
- Postcode (View only - copied from Contact data when the declaration is created)
- Start Date (Date)
- End Date (Date)
- Reason Ended (Alphanumeric)
- Source (Alphanumeric)
- Notes (Note)
- Scanned declaration (File)


Gift Aid

- Eligible for Gift Aid (Radio)
- Gift Aid Amount (View Only)
- Batch Name (View Only) – Useful but not required

Following columns in Giftaid report (which extends 'Contribution' custom groups)
- Name of donor
- Date of Payment
- Donation Amount
- Gift Aid Amount

The above changes are proposed based on the feedback from existing users of the giftaid module.

Any more ideas/suggestions out there?

Michael McAndrew

  • Forum Godess / God
  • I live on this forum
  • *****
  • Posts: 1274
  • Karma: 55
    • Third Sector Design
  • CiviCRM version: various
  • CMS version: Nearly always Drupal
  • MySQL version: 5.5
  • PHP version: 5.3
Re: CiviCRM GiftAid - Proposed improvements for 4.2
May 15, 2012, 08:51:08 am
that is very cool news - nice one :)
Service providers: Grow your business, build your reputation and support CiviCRM. Become a partner today

Rajesh

  • I post occasionally
  • **
  • Posts: 78
  • Karma: 10
  • CiviCRM version: 4.2.x, 4.3.x, 4.4.x
  • CMS version: Drupal 7.xx, Wordpress 3.5.x - 3.6.x, Joomla 3.1
  • MySQL version: 5.5.20
  • PHP version: 5.3.10
Re: CiviCRM GiftAid - Proposed improvements for 4.2
May 15, 2012, 10:05:31 am
One more feedback:

Regarding the address for giftaid declaration, it needs to be the contact's home address (http://www.hmrc.gov.uk/individuals/giving/gift-aid.htm#2) for the declaration to be valid.

Changes required
- Change the 'GiftAid' profile to use address fields of Location type: Home
- Copy the Contact's home address, post code to giftaid declaration, when the declaration is created
- Do we need to display a error message? - when a offline giftaid declaration is created or gift-aidable contribution is created for a contact who doesnt have a home address



TimG

  • I post occasionally
  • **
  • Posts: 41
  • Karma: 2
  • CiviCRM version: 4.4.6
  • CMS version: Joomla 2.5.24
  • MySQL version: 5.5.37
  • PHP version: 5.4.23
Re: CiviCRM GiftAid - Proposed improvements for 4.2
May 17, 2012, 02:19:43 am
Thanks for the work guys, this is looking good.
A couple of questions:
Can we flag payments through the system as 'gift-aidable' or 'Not gift-aidable' as only donations can be gift-aided - if the payment is for a tangible reward then it can't be gift aided - eg donation for a sponsored walk would be eligible, payment for an event wouldn't be. Memberships are a grey area; in our particular case we reckon memberships are eligible but others find their case isn't

Gift Aid applies to *any* donation made after the declaration date, even if the donor didn't explicitly say so on the subsequent donation - will the report show all relevant donations or just ones where the donor ticked the box for that particular donation

Rajesh

  • I post occasionally
  • **
  • Posts: 78
  • Karma: 10
  • CiviCRM version: 4.2.x, 4.3.x, 4.4.x
  • CMS version: Drupal 7.xx, Wordpress 3.5.x - 3.6.x, Joomla 3.1
  • MySQL version: 5.5.20
  • PHP version: 5.3.10
Re: CiviCRM GiftAid - Proposed improvements for 4.2
May 17, 2012, 02:45:22 am
Quote from: TimG on May 17, 2012, 02:19:43 am
Can we flag payments through the system as 'gift-aidable' or 'Not gift-aidable' as only donations can be gift-aided - if the payment is for a tangible reward then it can't be gift aided - eg donation for a sponsored walk would be eligible, payment for an event wouldn't be. Memberships are a grey area; in our particular case we reckon memberships are eligible but others find their case isn't

Previously when import the custom data, it is imported to used for 'Contributions' - 'Any'. Now i have changed the import xml to mark it to be used for 'Contributions'. After import, you can edit the settings for the 'Gift Aid' custom data group (which has the 'Eligible for Gift Aid?' field) to be used for only specific contribution types (eg. only donation)

Quote from: TimG on May 17, 2012, 02:19:43 am
Gift Aid applies to *any* donation made after the declaration date, even if the donor didn't explicitly say so on the subsequent donation - will the report show all relevant donations or just ones where the donor ticked the box for that particular donation

Donor or the admin (doing offline contribution) should set the 'Eligible for Gift Aid?' field to 'yes', to make the contribution gift-aidable, and only those contributions for which 'Eligible for Gift Aid?' field is 'yes' can be added to a batch. The report is just a list of contribution in a specific batch.

Present Process flow
1. Create contribution ( Set 'Eligible for Gift Aid?' field to 'yes' )
2. Search for contributions and select 'Add to Gift Aid batch' in actions menu
3. Only contributions for which 'Eligible for Gift Aid?' field is 'yes' and the related contact have a valid gift-aid declaration, are allowed to be added to the batch
4. Create batch
5. Can view the batch report (which shows the contributions in the batch)

Hope this is clear enough.

Let me know....
« Last Edit: April 12, 2013, 02:28:32 am by Rajesh »

Rajesh

  • I post occasionally
  • **
  • Posts: 78
  • Karma: 10
  • CiviCRM version: 4.2.x, 4.3.x, 4.4.x
  • CMS version: Drupal 7.xx, Wordpress 3.5.x - 3.6.x, Joomla 3.1
  • MySQL version: 5.5.20
  • PHP version: 5.3.10
Re: CiviCRM GiftAid - Proposed improvements for 4.2
May 18, 2012, 06:43:50 am
One more feedback:

Along with the present conditions to check whether a contribution is valid for giftaid or not, we need to check whether the contribution is of status 'Completed'.

Any comments?

TimG

  • I post occasionally
  • **
  • Posts: 41
  • Karma: 2
  • CiviCRM version: 4.4.6
  • CMS version: Joomla 2.5.24
  • MySQL version: 5.5.37
  • PHP version: 5.4.23
Re: CiviCRM GiftAid - Proposed improvements for 4.2
May 24, 2012, 01:59:23 am
That's looking good. Once the report has been exported we can manually produce the Gift Aid claim form. Presumably the items we have reported on will not be included on the next report we produce so we wouldn't run the risk of douoble-claiming on donations

AliB

  • I’m new here
  • *
  • Posts: 22
  • Karma: 0
  • CiviCRM version: 4.1
  • CMS version: D7
  • MySQL version: latest
  • PHP version: 5.3
Re: CiviCRM GiftAid - Proposed improvements for 4.2
August 12, 2012, 11:14:13 am
@TimG, a contribution can only be attached to 1 batch.

AliB

  • I’m new here
  • *
  • Posts: 22
  • Karma: 0
  • CiviCRM version: 4.1
  • CMS version: D7
  • MySQL version: latest
  • PHP version: 5.3
Re: CiviCRM GiftAid - Proposed improvements for 4.2
August 12, 2012, 11:22:56 am
Rajesh the changes proposed are an excellent improvement. Many thanks. Is there an ETA for these changes or can we try them out now?

AliB

  • I’m new here
  • *
  • Posts: 22
  • Karma: 0
  • CiviCRM version: 4.1
  • CMS version: D7
  • MySQL version: latest
  • PHP version: 5.3
Re: CiviCRM GiftAid - Proposed improvements for 4.2
August 12, 2012, 12:12:49 pm
Also, I remember there is a bit of an issue with the Custom field group and the Profile group or the declaration group having the same name meaning that if you try to modify and of the settings from the backend, it will throw up an error saying something like Label is already in use.

I'll try and look up what the issue was later but on my own installation, I've already resolved this by renaming one of the groups so it might be easier for you to spot.

SarahG (FountainTribe)

  • Ask me questions
  • ****
  • Posts: 782
  • Karma: 29
  • CiviCRM version: 4.4.7
  • CMS version: Drupal 6, Drupal 7
  • MySQL version: 5.5
  • PHP version: 5.3
Re: CiviCRM GiftAid - Proposed improvements for 4.2
August 13, 2012, 02:24:44 pm
If a person who is already in the system already has a declaration on file, then all future donations from the person should be marked as "GiftAid-able".     How will this work in practice?  Why does the CiviCRM GiftAid profile asking on a transaction-level if the transaction is GiftAid able?      Seems like it would make more sense to ask the person to make a GiftAid declaration ( but only if a declaration does not already exist for that individual)
Did I help you? Please donate to the Civi-Make-It-Happen campaign  CiviCRM for mobile devices! 

Rajesh

  • I post occasionally
  • **
  • Posts: 78
  • Karma: 10
  • CiviCRM version: 4.2.x, 4.3.x, 4.4.x
  • CMS version: Drupal 7.xx, Wordpress 3.5.x - 3.6.x, Joomla 3.1
  • MySQL version: 5.5.20
  • PHP version: 5.3.10
Re: CiviCRM GiftAid - Proposed improvements for 4.2
August 14, 2012, 05:04:37 am
CiviGiftaid Extension 4.2 has been released. Please visit the below blog post for more information.

http://civicrm.org/blogs/rajesh/civigiftaid-extension

SarahG (FountainTribe)

  • Ask me questions
  • ****
  • Posts: 782
  • Karma: 29
  • CiviCRM version: 4.4.7
  • CMS version: Drupal 6, Drupal 7
  • MySQL version: 5.5
  • PHP version: 5.3
Re: CiviCRM GiftAid - Proposed improvements for 4.2
September 25, 2012, 10:42:03 pm
I am installing the new 4.2 version of the GiftAid extension into an environment that was previously running the Drupal6 version of the GiftAid module.

Before I tried to install te new extension, I disabled the old module. I did not delete the GiftAid custom data field on each contribution record, as I did not want to loose any previously recorded data. ( At this point in time contributions have been marked as "Is GiftAid?" yes/no,   but no other custom data is being used. ( There are no giftaid declarations on any contact records)

When I try to install the new extension, it throws the following SQL error and stack trace:


Code: [Select]
ALTER TABLE civicrm_value_gift_aid_declaration ADD COLUMN `eligible_for_gift_aid` tinyint [nativecode=1060 ** Duplicate column name 'eligible_for_gift_aid']
Code: [Select]
#0 /home/dev6/public_html/sites/all/modules/civicrm/CRM/Core/Error.php(148): CRM_Core_Error::backtrace()
#1 [internal function](): CRM_Core_Error::handle(Object(DB_Error))
#2 /home/dev6/public_html/sites/all/modules/civicrm/packages/PEAR.php(931): call_user_func((Array:2), Object(DB_Error))
#3 /home/dev6/public_html/sites/all/modules/civicrm/packages/DB.php(971): PEAR_Error->PEAR_Error("DB Error: a515ac9c2796ca0e23adbe92c68fc9fc", "a515ac9c2796ca0e23adbe92c68fc9fc", 16, (Array:2), "        ALTER TABLE civicrm_value_gift_aid_declaration\n        ADD COLUMN `e...")
#4 /home/dev6/public_html/sites/all/modules/civicrm/packages/PEAR.php(564): DB_Error->DB_Error("a515ac9c2796ca0e23adbe92c68fc9fc", 16, (Array:2), "        ALTER TABLE civicrm_value_gift_aid_declaration\n        ADD COLUMN `e...")
#5 /home/dev6/public_html/sites/all/modules/civicrm/packages/DB/common.php(1903): PEAR->raiseError(NULL, "a515ac9c2796ca0e23adbe92c68fc9fc", NULL, NULL, "        ALTER TABLE civicrm_value_gift_aid_declaration\n        ADD COLUMN `e...", "DB_Error", TRUE)
#6 /home/dev6/public_html/sites/all/modules/civicrm/packages/DB/mysql.php(898): DB_common->raiseError("a515ac9c2796ca0e23adbe92c68fc9fc", NULL, NULL, NULL, "1060 ** Duplicate column name 'eligible_for_gift_aid'")
#7 /home/dev6/public_html/sites/all/modules/civicrm/packages/DB/mysql.php(327): DB_mysql->mysqlRaiseError()
#8 /home/dev6/public_html/sites/all/modules/civicrm/packages/DB/common.php(1216): DB_mysql->simpleQuery("        ALTER TABLE civicrm_value_gift_aid_declaration\n        ADD COLUMN `e...")
#9 /home/dev6/public_html/sites/all/modules/civicrm/packages/DB/DataObject.php(2421): DB_common->query("        ALTER TABLE civicrm_value_gift_aid_declaration\n        ADD COLUMN `e...")
#10 /home/dev6/public_html/sites/all/modules/civicrm/packages/DB/DataObject.php(1613): DB_DataObject->_query("        ALTER TABLE civicrm_value_gift_aid_declaration\n        ADD COLUMN `e...")
#11 /home/dev6/public_html/sites/all/modules/civicrm/CRM/Core/DAO.php(155): DB_DataObject->query("        ALTER TABLE civicrm_value_gift_aid_declaration\n        ADD COLUMN `e...")
#12 /home/dev6/public_html/sites/all/modules/civicrm/CRM/Core/DAO.php(922): CRM_Core_DAO->query("        ALTER TABLE civicrm_value_gift_aid_declaration\n        ADD COLUMN `e...", FALSE)
#13 /home/dev6/public_html/sites/all/modules/civicrm/CRM/Core/BAO/SchemaHandler.php(299): CRM_Core_DAO::executeQuery("        ALTER TABLE civicrm_value_gift_aid_declaration\n        ADD COLUMN `e...", (Array:0), TRUE, NULL, FALSE, FALSE)
#14 /home/dev6/public_html/sites/all/modules/civicrm/CRM/Core/BAO/CustomField.php(1803): CRM_Core_BAO_SchemaHandler::alterFieldSQL((Array:6), FALSE)
#15 /home/dev6/public_html/sites/all/modules/civicrm/CRM/Utils/Migrate/Import.php(290): CRM_Core_BAO_CustomField::createField(Object(CRM_Core_DAO_CustomField), "add")
#16 /home/dev6/public_html/sites/all/modules/civicrm/CRM/Utils/Migrate/Import.php(58): CRM_Utils_Migrate_Import->customFields(Object(SimpleXMLElement), (Array:2))
#17 /home/dev6/public_html/civicrm_extensions/rajeshrhino-uk.co.nfpservices.module.civigiftaid/civigiftaid.php(17): CRM_Utils_Migrate_Import->run("/home/dev6/public_html/civicrm_extensions/rajeshrhino-uk.co.nfpservices.modul...")
#18 /home/dev6/public_html/sites/all/modules/civicrm/CRM/Core/Extensions/Module.php(56): civigiftaid_civicrm_install()
#19 /home/dev6/public_html/sites/all/modules/civicrm/CRM/Core/Extensions/Module.php(64): CRM_Core_Extensions_Module->callHook("civigiftaid", "/home/dev6/public_html/civicrm_extensions//rajeshrhino-uk.co.nfpservices.modu...", "install")
#20 /home/dev6/public_html/sites/all/modules/civicrm/CRM/Core/Extensions/Module.php(44): CRM_Core_Extensions_Module->commonInstall("install")
#21 /home/dev6/public_html/sites/all/modules/civicrm/CRM/Core/Extensions/Extension.php(419): CRM_Core_Extensions_Module->install()
#22 /home/dev6/public_html/sites/all/modules/civicrm/CRM/Core/Extensions/Extension.php(220): CRM_Core_Extensions_Extension->_registerExtensionByType()
#23 /home/dev6/public_html/sites/all/modules/civicrm/CRM/Core/Extensions.php(626): CRM_Core_Extensions_Extension->install()
#24 /home/dev6/public_html/sites/all/modules/civicrm/CRM/Admin/Form/Extensions.php(167): CRM_Core_Extensions->install(NULL, "rajeshrhino-uk.co.nfpservices.module.civigiftaid")
#25 /home/dev6/public_html/sites/all/modules/civicrm/CRM/Core/Form.php(246): CRM_Admin_Form_Extensions->postProcess()
#26 /home/dev6/public_html/sites/all/modules/civicrm/CRM/Core/StateMachine.php(159): CRM_Core_Form->mainProcess()
#27 /home/dev6/public_html/sites/all/modules/civicrm/CRM/Core/QuickForm/Action/Next.php(60): CRM_Core_StateMachine->perform(Object(CRM_Admin_Form_Extensions), "next", "Next")
#28 /home/dev6/public_html/sites/all/modules/civicrm/packages/HTML/QuickForm/Controller.php(203): CRM_Core_QuickForm_Action_Next->perform(Object(CRM_Admin_Form_Extensions), "next")
#29 /home/dev6/public_html/sites/all/modules/civicrm/packages/HTML/QuickForm/Page.php(103): HTML_QuickForm_Controller->handle(Object(CRM_Admin_Form_Extensions), "next")
#30 /home/dev6/public_html/sites/all/modules/civicrm/CRM/Core/Controller.php(289): HTML_QuickForm_Page->handle("next")
#31 /home/dev6/public_html/sites/all/modules/civicrm/CRM/Core/Page/Basic.php(378): CRM_Core_Controller->run()
#32 /home/dev6/public_html/sites/all/modules/civicrm/CRM/Core/Page/Basic.php(182): CRM_Core_Page_Basic->edit(1, NULL)
#33 /home/dev6/public_html/sites/all/modules/civicrm/CRM/Admin/Page/Extensions.php(133): CRM_Core_Page_Basic->run()
#34 /home/dev6/public_html/sites/all/modules/civicrm/CRM/Core/Invoke.php(228): CRM_Admin_Page_Extensions->run((Array:3), NULL)
#35 /home/dev6/public_html/sites/all/modules/civicrm/drupal/civicrm.module(382): CRM_Core_Invoke::invoke((Array:3))
#36 [internal function](): civicrm_invoke("admin", "extensions")
#37 /home/dev6/public_html/includes/menu.inc(348): call_user_func_array("civicrm_invoke", (Array:2))
#38 /home/dev6/public_html/index.php(18): menu_execute_active_handler()
#39 {main}
« Last Edit: September 26, 2012, 12:21:29 pm by Sarah Gladstone »
Did I help you? Please donate to the Civi-Make-It-Happen campaign  CiviCRM for mobile devices! 

myles

  • I post frequently
  • ***
  • Posts: 263
  • Karma: 11
Re: CiviCRM GiftAid - Proposed improvements for 4.2
September 29, 2012, 03:42:21 am
Perhaps the same as above - on installing the extension on a civicrm installation that had previously had the drupal 6.x gift aid module I was given an unknown DB error.

I turned on debugging (civicrm)

Ran installation again

This time it installed, noting the existing db entries`..

  Found name, reason_ended, civicrm_option_group
Found label, Contact Declined, civicrm_option_value
Found label, HMRC Declined, civicrm_option_value
Found name, Gift_Aid_Declaration, civicrm_custom_group
Found name, Gift_Aid, civicrm_custom_group
Found label, UK Tax Payer?, civicrm_custom_field
Found label, Start Date, civicrm_custom_field
Found label, End Date, civicrm_custom_field
Found label, Reason Ended, civicrm_custom_field
Found label, Source, civicrm_custom_field
Found label, Notes, civicrm_custom_field
Found label, Eligible for Gift Aid?, civicrm_custom_field
Found label, Amount, civicrm_custom_field
Found label, Gift Aid Amount, civicrm_custom_field
Found title, Gift Aid, civicrm_uf_group
Found field_name, first_name, civicrm_uf_field
Found field_name, last_name, civicrm_uf_field
Found field_name, street_address, civicrm_uf_field
Found field_name, supplemental_address_1, civicrm_uf_field
Found field_name, supplemental_address_2, civicrm_uf_field
Found field_name, city, civicrm_uf_field
Found field_name, state_province, civicrm_uf_field
Found field_name, postal_code, civicrm_uf_field
Extension has been installed.

I have not yet tested the functionality

Rajesh

  • I post occasionally
  • **
  • Posts: 78
  • Karma: 10
  • CiviCRM version: 4.2.x, 4.3.x, 4.4.x
  • CMS version: Drupal 7.xx, Wordpress 3.5.x - 3.6.x, Joomla 3.1
  • MySQL version: 5.5.20
  • PHP version: 5.3.10
Re: CiviCRM GiftAid - Proposed improvements for 4.2
October 01, 2012, 02:15:58 am
Hi myles

The giftaid extension was trying to import the custom groups/fields which will be used by the extension and as the custom groups/fields already exists (as your have installed the giftaid module before) civi is throwing the warnings. Those are just warnings that the fields already exists in the database and it will not affect the installation of the extension.

Also please make sure you have upgraded to CiviCRM 4.2, for this extension to work properly, as there has been change in 'civicrm_batch' table structure.

Thanks

Pages: [1] 2
  • CiviCRM Community Forums (archive) »
  • Language and Locality »
  • UK Users Group (Moderator: Michael McAndrew) »
  • CiviCRM GiftAid - Proposed improvements for 4.2

This forum was archived on 2017-11-26.