Skip to content
Snippets Groups Projects
Commit f55fb335 authored by Pradeep Nayak's avatar Pradeep Nayak
Browse files

-- added form rule for CRM-12233

parent e5786a6b
No related branches found
No related tags found
No related merge requests found
......@@ -833,8 +833,9 @@ class CRM_Contribute_Form_Contribution_Main extends CRM_Contribute_Form_Contribu
}
}
if ($membershipFieldId && (!CRM_Utils_Array::value('price_' . $contributionFieldId, $fields)
&& !CRM_Utils_Array::value('price_' . $otherFieldId, $fields))) {
if ($membershipFieldId && !(CRM_Utils_Array::value('price_' . $contributionFieldId, $fields)
&& $fields['price_' . $contributionFieldId] >= 0)
&& !CRM_Utils_Array::value('price_' . $otherFieldId, $fields)) {
$errors["price_{$errorKey}"] = ts('Additional Amount is required.');
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment