Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

dev/financial#12 move soft credit item count to object property #12011

Merged
merged 1 commit into from
May 16, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions CRM/Contribute/Form/Contribution.php
Original file line number Diff line number Diff line change
Expand Up @@ -203,6 +203,14 @@ class CRM_Contribute_Form_Contribution extends CRM_Contribute_Form_AbstractEditP
*/
protected $statusMessageTitle;

/**
* @var int
*
* Max row count for soft credits. The value here is +1 the actual number of
* rows displayed.
*/
public $_softCreditItemCount = 11;

/**
* Explicitly declare the form context.
*/
Expand Down
2 changes: 1 addition & 1 deletion CRM/Contribute/Form/SoftCredit.php
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ public static function buildQuickForm(&$form) {
}

// by default generate 10 blocks
$item_count = 11;
$item_count = $form->_softCreditItemCount;

$showSoftCreditRow = 2;
if ($form->getAction() & CRM_Core_Action::UPDATE) {
Expand Down