exportDealData
exportDealData($id, $options = array())
Description:
Returns HTML->link that generates a CSV export of the Activity table for the specific Deal.
Options:
//
$defaults = array(
'escape' => false
, 'link_content' => 'Download'
,
);
Example:
//
$exportDealData = $this->Deals->exportDealData($id, $options = array());
//
echo $exportDealData; // produces Download
public function exportDealData($id = null, $options = array()) {
//
$defaults = array(
'escape' => false
, 'link_content' => 'Download'
,
);
//
$options = am($defaults, $options);
//
$linkContent = $options['link_content'];
//
unset($options['link_content']);
//
return $this->Html->link(
$linkContent
, array(
'plugin' => 'activities'
, 'controller' => 'activities'
, 'action' => 'export'
, 'dashboard' => true
, $id
,
)
, $options
);
}