Uploaded image for project: 'CiviCRM'
  1. CiviCRM
  2. CRM-10704

Gift Aid module fixes for Civi 4.2 under Drupal 6 and 7

    Details

      Description

      See http://forum.civicrm.org/index.php/topic,23474.msg108857.html#msg108857

      The current v4.2 svn version of civicrm_giftaid module at
      http://svn.civicrm.org/tools/branches/v4.2/drupal/modules/civicrm_giftaid/civicrm_giftaid.module
      does not work with Civi 4.2, due to a 4.2 schema change in civicrm_batch ("label" renamed "title").

      The first patch attached, giftaid-4.2-civi-fixes, contains the following changes:

      • changed instances of "label" field to "title" in GiftAid/Form/Task/AddToGiftAid.php, GiftAid/Utils/Contribution.php
      • changed wording for the settings form, as it refers to "Basic Rate", which most UK users would understand to be the Basic Rate of Income Tax, but AFAICS this value is actually now used for the percentage of a donation that can be claimed as Gift Aid, which is not the same thing.
      • added default value for variable_get() in civicrm_giftaid.admin.inc and GiftAid/Utils/Contribution.php (mandatory in D6 and does no harm in D7)
      • fixed parameters to ts() in GiftAid/Form/Task/AddToGiftAid.php

      The second patch attached, giftaid-4.2-drupal6-fixes, contains the following additional changes to get it working with Civi 4.2 on Drupal 6:

      • 7.x -> 6.x in .info file
      • removed $form param from function giftaid_form() in civicrm_giftaid.admin.inc
      • changed settings URL from admin/config/system/gift-aid to admin/settings/system/gift-aid, in line with D6 conventions.

      I don't know where the Civi 4.2 / Drupal 6 version of the code should live. I'd suggest the first patch can be applied, if it looks OK, under tools/branches/v4.2/drupal/modules/civicrm_giftaid . The second patch should only be applied for the D6 version, wherever that may be.

      Dave J

        Attachments

        1. giftaid-4.2-civi-fixes
          5 kB
          Dave Jenkins
        2. giftaid-4.2-drupal6-fixes
          2 kB
          Dave Jenkins

          Activity

            People

            • Assignee:
              deepak Deepak Srivastava
              Reporter:
              davej Dave Jenkins
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: