Merge pull request #15986 from civicrm/5.20
[civicrm-core.git] / CRM / Contribute / Form / Search.php
index 574ef9f87b4c622dccf5941a58575ba7e17c3df2..295ff79b39f99e3d95ad41435f0a4d87ebf0d24d 100644 (file)
@@ -264,7 +264,6 @@ class CRM_Contribute_Form_Search extends CRM_Core_Form_Search {
         'contribution_soft_credit_type_id',
         'contribution_status_id',
         'contribution_trxn_id',
-        'contribution_page_id',
         'contribution_product_id',
         'invoice_id',
         'payment_instrument_id',
@@ -457,6 +456,12 @@ class CRM_Contribute_Form_Search extends CRM_Core_Form_Search {
       $this->_formValues['receive_date_high'] = date('Y-m-d H:i:s', strtotime($highReceiveDate));
       CRM_Core_Error::deprecatedFunctionWarning('pass receive_date_high not end');
     }
+    //check for contribution page id.
+    $contribPageId = CRM_Utils_Request::retrieve('pid', 'Positive', $this);
+    if ($contribPageId) {
+      CRM_Core_Error::deprecatedFunctionWarning('pass contribution_page_id');
+      $this->_formValues['contribution_page_id'] = $contribPageId;
+    }
   }
 
 }