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

check receive/cancel/receipt/thankyou/participant_register-dates against CRM_Utils_Rule::dateTime

    Details

    • Type: Patch
    • Status: Done/Fixed
    • Priority: Minor
    • Resolution: Fixed/Completed
    • Affects Version/s: 3.4.0
    • Fix Version/s: 3.4.1
    • Component/s: CiviCRM API
    • Labels:
      None

      Description

      It seems api/v3/utils.php and api/v2/utils.v2.php ckecks the 'receive_date', 'cancel_date', 'receipt_date', 'thankyou_date', and 'participant_register_date' against CRM_Utils_Rule::date and not CRM_Utils_Rule::dateTime, while the other parts of the API use the correct function. The code snippets that need to be changed in the corresponding cases (lines 1007 and 1206) are

      if (!CRM_Utils_Rule::date($value)) {
      return civicrm_api3_create_error("$key not a valid date: $value");
      }
      break;

      The cases for 'join_date', 'membership_start_date', and 'membership_end_date' should not be touched since the don't contain the time in the database.

        Attachments

          Activity

            People

            • Assignee:
              erikhommel Erik Hommel
              Reporter:
              prolineserver Holger Motzkau
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Time Tracking

                Estimated:
                Original Estimate - 15 minutes
                15m
                Remaining:
                Remaining Estimate - 15 minutes
                15m
                Logged:
                Time Spent - Not Specified
                Not Specified