}
$this->_showHide->addToTemplate();
$this->assign('inDate', $this->_inDate);
-
if (!empty($defaults['payment_processor'])) {
- $defaults['payment_processor'] = str_replace(CRM_Core_DAO::VALUE_SEPARATOR, ',',
+ $defaults['payment_processor'] = array_fill_keys(explode(CRM_Core_DAO::VALUE_SEPARATOR,
$defaults['payment_processor']
- );
+ ), '1');
}
+
return $defaults;
}
$paymentProcessor = CRM_Core_PseudoConstant::paymentProcessor();
$this->assign('paymentProcessor', $paymentProcessor);
-
- $this->addEntityRef('payment_processor', ts('Payment Processor'), array(
- 'entity' => 'PaymentProcessor',
- 'multiple' => TRUE,
- 'api' => array(
- 'params' => array('domain_id' => CRM_Core_Config::domainID()),
- ),
- 'select' => array('minimumInputLength' => 0),
- ));
+ $this->addCheckBox('payment_processor', ts('Payment Processor'),
+ array_flip($paymentProcessor),
+ NULL, NULL, NULL, NULL,
+ array(' ', ' ', ' ', '<br/>')
+ );
// financial type
if (!CRM_Financial_BAO_FinancialType::isACLFinancialTypeStatus() ||
}
if (!empty($params['payment_processor'])) {
- $params['payment_processor'] = str_replace(',', CRM_Core_DAO::VALUE_SEPARATOR, $params['payment_processor']);
+ $params['payment_processor'] = implode(CRM_Core_DAO::VALUE_SEPARATOR, array_keys($params['payment_processor']));
}
else {
$params['payment_processor'] = 'null';