$this->_defaults = array();
$this->_defaults['amount'] = $this->_subscriptionDetails->amount;
$this->_defaults['installments'] = $this->_subscriptionDetails->installments;
+ $this->_defaults['campaign_id'] = $this->_subscriptionDetails->campaign_id;
$this->_defaults['is_notify'] = 1;
return $this->_defaults;
$this->add('checkbox', 'is_notify', ts('Notify Contributor?'));
}
+ if (CRM_Core_Permission::check('edit contributions')) {
+ $this->addEntityRef('campaign_id', 'Campaign', array('entity' => 'Campaign'));
+ }
+
$type = 'next';
if ($this->_selfService) {
$type = 'submit';
<span class="description">{ts}Total number of payments to be made. Set this to 0 if this is an open-ended commitment i.e. no set end date.{/ts}</span></td></tr>
{if !$self_service}
<tr><td class="label">{$form.is_notify.label}</td><td>{$form.is_notify.html}</td></tr>
+ <tr><td class="label">{$form.campaign_id.label}</td><td>{$form.campaign_id.html}</td></tr>
{/if}
{* Currently changes to interval, unit and cycle day are not supported. *}